28 #ifndef GUM_NODE_DATABASE_H 29 #define GUM_NODE_DATABASE_H 54 template < TESTNAME AttributeSelection,
bool isScalar >
58 template <
typename GUM_SCALAR >
85 void*
operator new(
size_t s) {
88 void operator delete(
void* p) {
219 #endif // GUM_NODE_DATABASE_H Template trick for efficient development.
Idx __valueDomain(Int2Type< false >) const
const TestPolicy< ValueType > * testPolicy(const DiscreteVariable *var) const
Returns a reference to nDB test policy for given variable (so that test policy information can be mer...
const DiscreteVariable * __value
So does this reference on the value observed.
Base class for discrete random variable.
Header file of gum::Sequence, a class for storing (ordered) sequences of objects. ...
HashTable< ValueType, Idx > __valueCount
const HashTableConstIteratorSafe< ValueType, Idx > cendValues() const
Merges given NodeDatabase informations into current nDB.
Safe Const Iterators for hashtables.
void __addObservation(const Observation *, Int2Type< true >)
Updates database with new observation.
typename TestSelect< AttributeSelection, GTestPolicy< GUM_SCALAR >, Chi2TestPolicy< GUM_SCALAR >, LeastSquareTestPolicy< GUM_SCALAR > >::type TestPolicy
Idx __valueDomain(Int2Type< true >) const
NodeDatabase(const Set< const DiscreteVariable * > *, const DiscreteVariable *=nullptr)
Default constructor.
Base class for discrete random variable.
gum is the global namespace for all aGrUM entities
INLINE bool isTestRelevant(const DiscreteVariable *var) const
Indicates wether or not, node has sufficient observation so that any statistic is relevant...
<agrum/multidim/core/testPolicy/Chi2TestPolicy.h>
<agrum/multidim/core/testPolicy/leastSquareTestPolicy.h>
INLINE double testOtherCriterion(const DiscreteVariable *var) const
Returns the performance of given variables according to selection secondary criterion (to break ties)...
The class for generic Hash Tables.
Headers of the GTestPolicy.
Headers of the Chi2TestPolicy.
Representation of a setA Set is a structure that contains arbitrary elements.
virtual Size domainSize() const =0
std::string toString() const
void addObservation(const Observation *)
Nb observation taken into account by this instance.
INLINE double testValue(const DiscreteVariable *var) const
Returns the performance of given variables according to selection criterion.
<agrum/multidim/core/testPolicies/GTestPolicy.h>
Headers of the Observation class.
const HashTableConstIteratorSafe< ValueType, Idx > cbeginValues() const
Iterators on value count to recopy correctly its content.
ValueSelect< isScalar, double, Idx >::type ValueType
NodeDatabase< AttributeSelection, isScalar > & operator+=(const NodeDatabase< AttributeSelection, isScalar > &src)
Merges given NodeDatabase informations into current nDB.
Template implémentations of the NodeDatabase class.
void deallocate(void *pDeallocatedObject, const size_t &objectSize)
Deallocates an object.
Headers of the LeastSquareTestPolicy.
Size Idx
Type for indexes.
void * allocate(const size_t &objectSize)
Allocates a block.
INLINE Idx nbObservation() const
Nb observation taken into account by this instance.
Idx effectif(Idx moda) const
static SmallObjectAllocator & instance()
~NodeDatabase()
Default destructor.
Class hash tables iterators.
<agrum/FMDP/learning/datastructure/nodeDatabase.h>
HashTable< const DiscreteVariable *, TestPolicy< ValueType > *> __attrTable
Table giving for every variables its instantiation.