BlackCat_Tensors
A GPU-supported autograd and linear algebra library, designed for neural network construction
Public Types | Public Member Functions | Friends | List of all members
bc::nn::Layer_Manager< Derived, Layer > Struct Template Reference

#include <layer_manager.h>

Inheritance diagram for bc::nn::Layer_Manager< Derived, Layer >:
Inheritance graph
[legend]
Collaboration diagram for bc::nn::Layer_Manager< Derived, Layer >:
Collaboration graph
[legend]

Public Types

using input_tensor_dim = typename layer_traits< Layer >::input_tensor_dim
 
using output_tensor_dim = typename layer_traits< Layer >::output_tensor_dim
 
using allocator_type = typename layer_traits< Layer >::allocator_type
 
using value_type = typename layer_traits< Layer >::value_type
 
using input_tensor_type = bc::Tensor< input_tensor_dim::value, value_type, allocator_type >
 
using batched_input_tensor_type = bc::Tensor< input_tensor_dim::value+1, value_type, allocator_type >
 
using batched_output_tensor_type = bc::Tensor< output_tensor_dim::value+1, value_type, allocator_type >
 
template<char C, class Tensor , cache_key_type override = cache_key_type::inherit>
using key_type = cache_key< bc::utility::Name< C >, Tensor, override >
 

Public Member Functions

template<class... Args>
 Layer_Manager (Args... args)
 
template<class T , class l = Layer>
auto forward_propagation (const T &expression)
 
template<class T >
auto back_propagation (const T &dy)
 
template<class T >
auto predict (const T &expression)
 
template<class T >
auto single_predict (const T &expression)
 
void update_weights ()
 
virtual void save (Layer_Loader &loader) const override
 
virtual void load (Layer_Loader &loader) override
 
void copy_training_data_to_single_predict (int batch_index)
 
const Cacheget_cache () const
 
Cacheget_cache ()
 
void zero_time_index ()
 
void increment_time_index ()
 

Friends

template<class D , class L >
class Layer_Manager
 

Member Typedef Documentation

◆ allocator_type

template<class Derived, class Layer>
using bc::nn::Layer_Manager< Derived, Layer >::allocator_type = typename layer_traits<Layer>::allocator_type

◆ batched_input_tensor_type

template<class Derived, class Layer>
using bc::nn::Layer_Manager< Derived, Layer >::batched_input_tensor_type = bc::Tensor<input_tensor_dim::value+1, value_type, allocator_type>

◆ batched_output_tensor_type

template<class Derived, class Layer>
using bc::nn::Layer_Manager< Derived, Layer >::batched_output_tensor_type = bc::Tensor<output_tensor_dim::value+1, value_type, allocator_type>

◆ input_tensor_dim

template<class Derived, class Layer>
using bc::nn::Layer_Manager< Derived, Layer >::input_tensor_dim = typename layer_traits<Layer>::input_tensor_dim

◆ input_tensor_type

template<class Derived, class Layer>
using bc::nn::Layer_Manager< Derived, Layer >::input_tensor_type = bc::Tensor<input_tensor_dim::value, value_type, allocator_type>

◆ key_type

template<class Derived, class Layer>
template<char C, class Tensor , cache_key_type override = cache_key_type::inherit>
using bc::nn::Layer_Manager< Derived, Layer >::key_type = cache_key<bc::utility::Name<C>, Tensor, override>

◆ output_tensor_dim

template<class Derived, class Layer>
using bc::nn::Layer_Manager< Derived, Layer >::output_tensor_dim = typename layer_traits<Layer>::output_tensor_dim

◆ value_type

template<class Derived, class Layer>
using bc::nn::Layer_Manager< Derived, Layer >::value_type = typename layer_traits<Layer>::value_type

Constructor & Destructor Documentation

◆ Layer_Manager()

template<class Derived, class Layer>
template<class... Args>
bc::nn::Layer_Manager< Derived, Layer >::Layer_Manager ( Args...  args)
inline

Member Function Documentation

◆ back_propagation()

template<class Derived, class Layer>
template<class T >
auto bc::nn::Layer_Manager< Derived, Layer >::back_propagation ( const T &  dy)
inline

◆ copy_training_data_to_single_predict()

template<class Derived, class Layer>
void bc::nn::Layer_Manager< Derived, Layer >::copy_training_data_to_single_predict ( int  batch_index)
inline

◆ forward_propagation()

template<class Derived, class Layer>
template<class T , class l = Layer>
auto bc::nn::Layer_Manager< Derived, Layer >::forward_propagation ( const T &  expression)
inline

◆ get_cache() [1/2]

template<class Derived, class Layer>
const Cache& bc::nn::Layer_Manager< Derived, Layer >::get_cache ( ) const
inline

◆ get_cache() [2/2]

template<class Derived, class Layer>
Cache& bc::nn::Layer_Manager< Derived, Layer >::get_cache ( )
inline

◆ increment_time_index()

template<class Derived, class Layer>
void bc::nn::Layer_Manager< Derived, Layer >::increment_time_index ( )
inline

◆ load()

template<class Derived, class Layer>
virtual void bc::nn::Layer_Manager< Derived, Layer >::load ( Layer_Loader loader)
inlineoverridevirtual

◆ predict()

template<class Derived, class Layer>
template<class T >
auto bc::nn::Layer_Manager< Derived, Layer >::predict ( const T &  expression)
inline

◆ save()

template<class Derived, class Layer>
virtual void bc::nn::Layer_Manager< Derived, Layer >::save ( Layer_Loader loader) const
inlineoverridevirtual

◆ single_predict()

template<class Derived, class Layer>
template<class T >
auto bc::nn::Layer_Manager< Derived, Layer >::single_predict ( const T &  expression)
inline

◆ update_weights()

template<class Derived, class Layer>
void bc::nn::Layer_Manager< Derived, Layer >::update_weights ( )
inline

◆ zero_time_index()

template<class Derived, class Layer>
void bc::nn::Layer_Manager< Derived, Layer >::zero_time_index ( )
inline

Friends And Related Function Documentation

◆ Layer_Manager

template<class Derived, class Layer>
template<class D , class L >
friend class Layer_Manager
friend

The documentation for this struct was generated from the following file: