![]() |
aGrUM 2.3.2
a C++ library for (probabilistic) graphical models
|
Class used to perform Decision Tree Operation in the FMDP Framework. More...
#include <agrum/base/multidim/patterns/treeOperator.h>
Public Member Functions | |
Constructors / Destructors | |
| TreeOperator (const MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > *dt1, const MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > *dt2) | |
| Default constructor. | |
| TreeOperator (const MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > *dt1, const MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > *dt2, const HashTable< const DiscreteVariable *, Idx > givenContext) | |
| Default constructor. | |
| ~TreeOperator () | |
| Default destructor. | |
Main Method | |
| MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > * | compute () |
| Computes and builds the Function Graph that is the result of the operation. | |
Private Member Functions | |
| NodeId | _xPloreDT1_ (NodeId currentNodeId) |
| The main recursion function. | |
| NodeId | _xPloreDT2_ (NodeId currentNodeId) |
| The main recursion function. | |
| NodeId | _checkRedundancy_ (const DiscreteVariable *, NodeId *) |
Private Attributes | |
| const MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > * | _dt1_ |
| The two function graphs used for the operation. | |
| const MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > * | _dt2_ |
| MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > * | _rd_ |
| The resulting function graph. | |
| const COMBINEOPERATOR< GUM_SCALAR > | _combine_ |
| The function to be performed on the leaves. | |
| HashTable< const DiscreteVariable *, Idx > | _context_ |
| NodeId | _curDT1Leaf_ |
Class used to perform Decision Tree Operation in the FMDP Framework.
Definition at line 70 of file treeOperator.h.
| INLINE gum::TreeOperator< GUM_SCALAR, COMBINEOPERATOR, TerminalNodePolicy >::TreeOperator | ( | const MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > * | dt1, |
| const MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > * | dt2 ) |
Default constructor.
Definition at line 63 of file treeOperator_tpl.h.
References TreeOperator(), _combine_, _dt1_, _dt2_, _rd_, and gum::MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy >::getTreeInstance().
Referenced by TreeOperator(), TreeOperator(), and ~TreeOperator().
| INLINE gum::TreeOperator< GUM_SCALAR, COMBINEOPERATOR, TerminalNodePolicy >::TreeOperator | ( | const MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > * | dt1, |
| const MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > * | dt2, | ||
| const HashTable< const DiscreteVariable *, Idx > | givenContext ) |
Default constructor.
Definition at line 75 of file treeOperator_tpl.h.
References TreeOperator(), _combine_, _context_, _dt1_, _dt2_, _rd_, and gum::MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy >::getTreeInstance().
| INLINE gum::TreeOperator< GUM_SCALAR, COMBINEOPERATOR, TerminalNodePolicy >::~TreeOperator | ( | ) |
Default destructor.
Definition at line 88 of file treeOperator_tpl.h.
References TreeOperator().
|
private |
Definition at line 161 of file treeOperator_tpl.h.
References _rd_, DEALLOCATE, and gum::DiscreteVariable::domainSize().
Referenced by _xPloreDT1_(), and _xPloreDT2_().
|
private |
The main recursion function.
Definition at line 109 of file treeOperator_tpl.h.
References _checkRedundancy_(), _context_, _curDT1Leaf_, _dt1_, _dt2_, _rd_, _xPloreDT1_(), _xPloreDT2_(), ALLOCATE, gum::DiscreteVariable::domainSize(), gum::InternalNode::nodeVar(), and gum::InternalNode::son().
Referenced by _xPloreDT1_(), and compute().
|
private |
The main recursion function.
Definition at line 134 of file treeOperator_tpl.h.
References _checkRedundancy_(), _combine_, _context_, _curDT1Leaf_, _dt1_, _dt2_, _rd_, _xPloreDT2_(), ALLOCATE, gum::DiscreteVariable::domainSize(), gum::InternalNode::nodeVar(), and gum::InternalNode::son().
Referenced by _xPloreDT1_(), and _xPloreDT2_().
| INLINE MultiDimFunctionGraph< GUM_SCALAR, TerminalNodePolicy > * gum::TreeOperator< GUM_SCALAR, COMBINEOPERATOR, TerminalNodePolicy >::compute | ( | ) |
Computes and builds the Function Graph that is the result of the operation.
Definition at line 98 of file treeOperator_tpl.h.
References _dt1_, _rd_, and _xPloreDT1_().
Referenced by gum::TreeRegress< GUM_SCALAR, COMBINEOPERATOR, PROJECTOPERATOR, TerminalNodePolicy >::_xPloreVFunc_(), gum::TreeOperatorStrategy< GUM_SCALAR >::add(), gum::TreeOperatorStrategy< GUM_SCALAR >::argmaximize(), gum::TreeOperatorStrategy< GUM_SCALAR >::maximize(), gum::TreeOperatorStrategy< GUM_SCALAR >::minimize(), gum::TreeOperatorStrategy< GUM_SCALAR >::multiply(), and gum::TreeOperatorStrategy< GUM_SCALAR >::subtract().
|
private |
The function to be performed on the leaves.
Definition at line 124 of file treeOperator.h.
Referenced by TreeOperator(), TreeOperator(), and _xPloreDT2_().
|
private |
Definition at line 126 of file treeOperator.h.
Referenced by TreeOperator(), _xPloreDT1_(), and _xPloreDT2_().
|
private |
Definition at line 127 of file treeOperator.h.
Referenced by _xPloreDT1_(), and _xPloreDT2_().
|
private |
The two function graphs used for the operation.
Definition at line 117 of file treeOperator.h.
Referenced by TreeOperator(), TreeOperator(), _xPloreDT1_(), _xPloreDT2_(), and compute().
|
private |
Definition at line 118 of file treeOperator.h.
Referenced by TreeOperator(), TreeOperator(), _xPloreDT1_(), and _xPloreDT2_().
|
private |
The resulting function graph.
Definition at line 121 of file treeOperator.h.
Referenced by TreeOperator(), TreeOperator(), _checkRedundancy_(), _xPloreDT1_(), _xPloreDT2_(), and compute().