![]() |
aGrUM
0.16.0
|
#include <agrum/FMDP/learning/observation.h>
Public Member Functions | |
std::string | toString () const |
Constructor & destructor. | |
Observation () | |
Default constructor. More... | |
~Observation () | |
Default destructor. More... | |
void * | operator new (size_t s) |
Allocators and Deallocators redefinition. More... | |
void | operator delete (void *p) |
Default constructor. More... | |
Observation Handlers | |
INLINE Idx | modality (const DiscreteVariable *var) const |
Returns the modality assumed by the given variable in this observation. More... | |
INLINE Idx | rModality (const DiscreteVariable *var) const |
Returns the modality assumed by the given variable in this observation. More... | |
INLINE void | setModality (const DiscreteVariable *var, Idx modality) |
Sets the modality assumed by the given variable in this observation. More... | |
INLINE void | setRModality (const DiscreteVariable *var, Idx modality) |
Returns the modality assumed by the given variable in this observation. More... | |
double | reward () const |
Returns the modality assumed by the given variable in this observation. More... | |
void | setReward (double reward) |
Returns the modality assumed by the given variable in this observation. More... | |
Iterators on Variables | |
HashTableConstIteratorSafe< const DiscreteVariable *, Idx > | cbeginVariablesSafe () const |
Returns an const safe iterator on the beginning of the list of variables in this observation. More... | |
HashTableConstIteratorSafe< const DiscreteVariable *, Idx > | cendVariablesSafe () const |
Returns an const safe iterator on the end of the list of variables in this observation. More... | |
Definition at line 53 of file observation.h.
|
inline |
|
inline |
|
inline |
Returns an const safe iterator on the beginning of the list of variables in this observation.
Definition at line 140 of file observation.h.
References __varInst.
|
inline |
Returns an const safe iterator on the end of the list of variables in this observation.
Definition at line 149 of file observation.h.
References __varInst.
|
inline |
Returns the modality assumed by the given variable in this observation.
NotFound | if variable is not in this observation |
Definition at line 94 of file observation.h.
References __varInst.
Referenced by gum::NodeDatabase< AttributeSelection, isScalar >::__addObservation(), gum::IncrementalGraphLearner< AttributeSelection, isScalar >::__assumeValue(), and gum::IncrementalGraphLearner< AttributeSelection, isScalar >::__branchObs().
|
inline |
Default constructor.
Definition at line 76 of file observation.h.
References gum::SmallObjectAllocator::deallocate(), and gum::SmallObjectAllocator::instance().
|
inline |
Allocators and Deallocators redefinition.
Definition at line 73 of file observation.h.
References gum::SmallObjectAllocator::allocate(), and gum::SmallObjectAllocator::instance().
|
inline |
Returns the modality assumed by the given variable in this observation.
NotFound | if variable is not in this observation |
Definition at line 119 of file observation.h.
References __reward.
Referenced by gum::NodeDatabase< AttributeSelection, isScalar >::__addObservation(), gum::IncrementalGraphLearner< AttributeSelection, isScalar >::__assumeValue(), gum::FMDPLearner< VariableAttributeSelection, RewardAttributeSelection, LearnerSelection >::addObservation(), and setReward().
|
inline |
Returns the modality assumed by the given variable in this observation.
NotFound | if variable is not in this observation |
Definition at line 97 of file observation.h.
References __rInst.
Referenced by gum::NodeDatabase< AttributeSelection, isScalar >::__addObservation(), and gum::IncrementalGraphLearner< AttributeSelection, isScalar >::__branchObs().
|
inline |
Sets the modality assumed by the given variable in this observation.
DuplicateElement | if a value has already be assigned to this variable |
Definition at line 109 of file observation.h.
References __varInst.
Referenced by gum::SDYNA::feedback().
|
inline |
Returns the modality assumed by the given variable in this observation.
NotFound | if variable is not in this observation |
Definition at line 124 of file observation.h.
References __reward, reward(), and toString().
Referenced by gum::SDYNA::feedback().
|
inline |
Returns the modality assumed by the given variable in this observation.
NotFound | if variable is not in this observation |
Definition at line 112 of file observation.h.
References __rInst.
Referenced by gum::SDYNA::feedback().
std::string gum::Observation::toString | ( | ) | const |
Definition at line 27 of file observation.cpp.
References __rInst, and __varInst.
Referenced by setReward().
|
private |
The reward associated to this transition.
Definition at line 161 of file observation.h.
Referenced by reward(), and setReward().
|
private |
Definition at line 158 of file observation.h.
Referenced by rModality(), setRModality(), and toString().
|
private |
Table giving for every variables its instantiation.
Definition at line 157 of file observation.h.
Referenced by cbeginVariablesSafe(), cendVariablesSafe(), modality(), setModality(), and toString().