![]() |
aGrUM
0.16.0
|
Class used to manipulate context during Function Graph Operations. More...
#include <agrum/multidim/FunctionGraphUtilities/o4DGContext.h>
Public Member Functions | |
Constructors, Destructors. | |
O4DGContext (Idx *, Idx) | |
Default constructor. More... | |
~O4DGContext () | |
Default destructor. More... | |
void * | operator new (size_t s) |
Operator new overload to use the SmallObjectAllocator. More... | |
void | operator delete (void *p) |
Operator delete overload to use the SmallObjectAllocator. More... | |
Diagrams current nodes setters & getters. | |
void | setDG1Node (const NodeId &) |
Set DG1 diagram current explored Node. More... | |
const NodeId & | DG1Node () const |
Get DG1 diagram current explored Node. More... | |
void | setDG2Node (const NodeId &) |
Set DG2 diagram current explored Node. More... | |
const NodeId & | DG2Node () const |
Get DG2 diagram current explored Node. More... | |
Variables modalities handlers | |
void | chgVarModality (Idx, Idx) |
Changes given variable modality. More... | |
Idx | varModality (Idx) |
Changes given variable modality. More... | |
O4DG Handling methods | |
const double & | key (short int *instNeeded) |
Returns o4DGContext key. More... | |
Class used to manipulate context during Function Graph Operations.
Definition at line 49 of file o4DGContext.h.
Default constructor.
Definition at line 70 of file o4DGContext.cpp.
References __nbVar, and __varInstantiation.
gum::O4DGContext::~O4DGContext | ( | ) |
Default destructor.
Definition at line 78 of file o4DGContext.cpp.
Changes given variable modality.
Definition at line 46 of file o4DGContext_inl.h.
References __varInstantiation.
Referenced by gum::Regress< GUM_SCALAR, COMBINEOPERATOR, PROJECTOPERATOR, TerminalNodePolicy >::__compute(), gum::MultiDimFunctionGraphOperator< GUM_SCALAR, FUNCTOR, TerminalNodePolicy >::__compute(), and DG2Node().
|
inline |
Get DG1 diagram current explored Node.
Definition at line 86 of file o4DGContext.h.
References __DG1ExploredNode, and setDG2Node().
Referenced by gum::Regress< GUM_SCALAR, COMBINEOPERATOR, PROJECTOPERATOR, TerminalNodePolicy >::__compute(), and gum::MultiDimFunctionGraphOperator< GUM_SCALAR, FUNCTOR, TerminalNodePolicy >::__compute().
|
inline |
Get DG2 diagram current explored Node.
Definition at line 92 of file o4DGContext.h.
References __DG2ExploredNode, chgVarModality(), key(), and varModality().
Referenced by gum::Regress< GUM_SCALAR, COMBINEOPERATOR, PROJECTOPERATOR, TerminalNodePolicy >::__compute(), and gum::MultiDimFunctionGraphOperator< GUM_SCALAR, FUNCTOR, TerminalNodePolicy >::__compute().
INLINE const double & gum::O4DGContext::key | ( | short int * | instNeeded | ) |
Returns o4DGContext key.
Definition at line 56 of file o4DGContext_inl.h.
References __DG1ExploredNode, __DG2ExploredNode, __key, __logPrime, __nbVar, __offset1, __offset2, __offsetv, and __varInstantiation.
Referenced by gum::Regress< GUM_SCALAR, COMBINEOPERATOR, PROJECTOPERATOR, TerminalNodePolicy >::__compute(), gum::MultiDimFunctionGraphOperator< GUM_SCALAR, FUNCTOR, TerminalNodePolicy >::__compute(), and DG2Node().
INLINE void gum::O4DGContext::operator delete | ( | void * | p | ) |
Operator delete overload to use the SmallObjectAllocator.
Definition at line 71 of file o4DGContext_inl.h.
References gum::SmallObjectAllocator::deallocate(), and gum::SmallObjectAllocator::instance().
INLINE void * gum::O4DGContext::operator new | ( | size_t | s | ) |
Operator new overload to use the SmallObjectAllocator.
Definition at line 67 of file o4DGContext_inl.h.
References gum::SmallObjectAllocator::allocate(), and gum::SmallObjectAllocator::instance().
INLINE void gum::O4DGContext::setDG1Node | ( | const NodeId & | exploredNode | ) |
Set DG1 diagram current explored Node.
Definition at line 36 of file o4DGContext_inl.h.
References __DG1ExploredNode.
Referenced by gum::Regress< GUM_SCALAR, COMBINEOPERATOR, PROJECTOPERATOR, TerminalNodePolicy >::__compute(), gum::MultiDimFunctionGraphOperator< GUM_SCALAR, FUNCTOR, TerminalNodePolicy >::__compute(), gum::Regress< GUM_SCALAR, COMBINEOPERATOR, PROJECTOPERATOR, TerminalNodePolicy >::compute(), and gum::MultiDimFunctionGraphOperator< GUM_SCALAR, FUNCTOR, TerminalNodePolicy >::compute().
INLINE void gum::O4DGContext::setDG2Node | ( | const NodeId & | exploredNode | ) |
Set DG2 diagram current explored Node.
Definition at line 41 of file o4DGContext_inl.h.
References __DG2ExploredNode.
Referenced by gum::Regress< GUM_SCALAR, COMBINEOPERATOR, PROJECTOPERATOR, TerminalNodePolicy >::__compute(), gum::MultiDimFunctionGraphOperator< GUM_SCALAR, FUNCTOR, TerminalNodePolicy >::__compute(), gum::Regress< GUM_SCALAR, COMBINEOPERATOR, PROJECTOPERATOR, TerminalNodePolicy >::compute(), gum::MultiDimFunctionGraphOperator< GUM_SCALAR, FUNCTOR, TerminalNodePolicy >::compute(), and DG1Node().
Changes given variable modality.
Definition at line 51 of file o4DGContext_inl.h.
References __varInstantiation.
Referenced by gum::Regress< GUM_SCALAR, COMBINEOPERATOR, PROJECTOPERATOR, TerminalNodePolicy >::__compute(), gum::MultiDimFunctionGraphOperator< GUM_SCALAR, FUNCTOR, TerminalNodePolicy >::__compute(), and DG2Node().
|
private |
DG1 Diagram current explored node.
Definition at line 119 of file o4DGContext.h.
Referenced by DG1Node(), key(), and setDG1Node().
|
private |
DG2 Diagram current explored node.
Definition at line 122 of file o4DGContext.h.
Referenced by DG2Node(), key(), and setDG2Node().
|
private |
The key use to store the context as a key in the hashtable.
Definition at line 130 of file o4DGContext.h.
Referenced by key().
|
staticprivate |
Table containing the log2 of prime numbers.
Definition at line 133 of file o4DGContext.h.
Referenced by key().
|
staticprivate |
Definition at line 134 of file o4DGContext.h.
|
private |
Definition at line 127 of file o4DGContext.h.
Referenced by key(), and O4DGContext().
|
staticprivate |
Definition at line 134 of file o4DGContext.h.
Referenced by key().
|
staticprivate |
Definition at line 134 of file o4DGContext.h.
Referenced by key().
|
staticprivate |
Definition at line 134 of file o4DGContext.h.
Referenced by key().
|
private |
Vector containing for each retrograde variable its current modality 0 meaning no instantiation done => there's an offset.
Definition at line 126 of file o4DGContext.h.
Referenced by chgVarModality(), key(), O4DGContext(), and varModality().