The TwoStateSpace is a discrete Space with only two values, for example {0,1} or {-1,1}. More...
#include <shark/Unsupervised/RBM/StateSpaces/TwoStateSpace.h>
Public Types | |
| typedef tags::DiscreteSpace | EnumerationTag |
| Tag which tells an approximating function of the partition function, that this space can be enumerated. | |
Static Public Member Functions | |
| static std::size_t | numberOfStates (std::size_t numberOfNeurons) |
| Returns the number of states a vector of n random variables (neurons) with values in this state space may have. | |
| template<class V > | |
| static void | state (V &&vec, std::size_t stateNumber) |
| Returns the i-th state vector for a matrix row. | |
The TwoStateSpace is a discrete Space with only two values, for example {0,1} or {-1,1}.
Definition at line 41 of file TwoStateSpace.h.
| typedef tags::DiscreteSpace shark::TwoStateSpace< State1, State2 >::EnumerationTag |
Tag which tells an approximating function of the partition function, that this space can be enumerated.
Definition at line 44 of file TwoStateSpace.h.
|
inlinestatic |
Returns the number of states a vector of n random variables (neurons) with values in this state space may have.
For example if {a,b} is the state space it returns the cardinality of the set \( {a,b}^n = 2^n \)
| numberOfNeurons | the size of the vector |
Definition at line 51 of file TwoStateSpace.h.
References SHARK_RUNTIME_CHECK.
|
inlinestatic |
Returns the i-th state vector for a matrix row.
| vec | the vector the i-th state vector is stored in |
| stateNumber | the number of the state |
Definition at line 63 of file TwoStateSpace.h.