mlpack  master
Public Member Functions | Private Member Functions | Private Attributes | List of all members
mlpack::ann::SetInputWidthVisitor Class Reference

SetInputWidthVisitor updates the input width parameter with the given input width. More...

Inheritance diagram for mlpack::ann::SetInputWidthVisitor:
Inheritance graph
[legend]

Public Member Functions

 SetInputWidthVisitor (const size_t inputWidth=0, const bool reset=false)
 Update the input width parameter with the given input width. More...
 
template<typename LayerType >
bool operator() (LayerType *layer) const
 Update the input width parameter. More...
 

Private Member Functions

template<typename T >
std::enable_if< !HasInputWidth< T, size_t &(T::*)()>::value &&!HasModelCheck< T, std::vector< LayerTypes > &(T::*)()>::value, bool >::type LayerInputWidth (T *layer) const
 Do nothing if the module doesn't implement the InputWidth() or Model() function. More...
 
template<typename T >
std::enable_if< HasInputWidth< T, size_t &(T::*)()>::value &&!HasModelCheck< T, std::vector< LayerTypes > &(T::*)()>::value, bool >::type LayerInputWidth (T *layer) const
 Update the input width if the module implements the InputWidth() function. More...
 
template<typename T >
std::enable_if< !HasInputWidth< T, size_t &(T::*)()>::value &&HasModelCheck< T, std::vector< LayerTypes > &(T::*)()>::value, bool >::type LayerInputWidth (T *layer) const
 Update the input width if the module implements the Model() function. More...
 
template<typename T >
std::enable_if< HasInputWidth< T, size_t &(T::*)()>::value &&HasModelCheck< T, std::vector< LayerTypes > &(T::*)()>::value, bool >::type LayerInputWidth (T *layer) const
 Update the input width if the module implements the InputWidth() or Model() function. More...
 

Private Attributes

size_t inputWidth
 The input width parameter. More...
 
bool reset
 If set reset the height parameter if already set. More...
 

Detailed Description

SetInputWidthVisitor updates the input width parameter with the given input width.

Definition at line 28 of file set_input_width_visitor.hpp.

Constructor & Destructor Documentation

mlpack::ann::SetInputWidthVisitor::SetInputWidthVisitor ( const size_t  inputWidth = 0,
const bool  reset = false 
)

Update the input width parameter with the given input width.

Member Function Documentation

template<typename T >
std::enable_if< !HasInputWidth<T, size_t&(T::*)()>::value && !HasModelCheck<T, std::vector<LayerTypes>&(T::*)()>::value, bool>::type mlpack::ann::SetInputWidthVisitor::LayerInputWidth ( T *  layer) const
private

Do nothing if the module doesn't implement the InputWidth() or Model() function.

template<typename T >
std::enable_if< HasInputWidth<T, size_t&(T::*)()>::value && !HasModelCheck<T, std::vector<LayerTypes>&(T::*)()>::value, bool>::type mlpack::ann::SetInputWidthVisitor::LayerInputWidth ( T *  layer) const
private

Update the input width if the module implements the InputWidth() function.

template<typename T >
std::enable_if< !HasInputWidth<T, size_t&(T::*)()>::value && HasModelCheck<T, std::vector<LayerTypes>&(T::*)()>::value, bool>::type mlpack::ann::SetInputWidthVisitor::LayerInputWidth ( T *  layer) const
private

Update the input width if the module implements the Model() function.

template<typename T >
std::enable_if< HasInputWidth<T, size_t&(T::*)()>::value && HasModelCheck<T, std::vector<LayerTypes>&(T::*)()>::value, bool>::type mlpack::ann::SetInputWidthVisitor::LayerInputWidth ( T *  layer) const
private

Update the input width if the module implements the InputWidth() or Model() function.

template<typename LayerType >
bool mlpack::ann::SetInputWidthVisitor::operator() ( LayerType *  layer) const

Update the input width parameter.

Member Data Documentation

size_t mlpack::ann::SetInputWidthVisitor::inputWidth
private

The input width parameter.

Definition at line 40 of file set_input_width_visitor.hpp.

bool mlpack::ann::SetInputWidthVisitor::reset
private

If set reset the height parameter if already set.

Definition at line 43 of file set_input_width_visitor.hpp.


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