[ VIGRA Homepage | Function Index | Class Index | Namespaces | File List | Main Page ]
![]() |
VisitorBase | ![]() |
#include <vigra/random_forest/rf_visitors.hxx>
Public Member Functions | |
double | return_val () |
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | |
void | visit_after_split (Tree &tree, Split &split, Region &parent, Region &leftChild, Region &rightChild, Feature_t &features, Label_t &labels) |
template<class RF, class PR, class SM, class ST> | |
void | visit_after_tree (RF &rf, PR &pr, SM &sm, ST &st, int index) |
template<class RF, class PR> | |
void | visit_at_beginning (RF const &rf, PR const &pr) |
template<class RF, class PR> | |
void | visit_at_end (RF const &rf, PR const &pr) |
template<class TR, class IntT, class TopT, class Feat> | |
void | visit_external_node (TR &tr, IntT index, TopT node_t, Feat &features) |
template<class TR, class IntT, class TopT, class Feat> | |
void | visit_internal_node (TR &tr, IntT index, TopT node_t, Feat &features) |
double return_val | ( | ) |
return a double value. The value of the first visitor encountered that has a return value is returned with the RandomForest::learn() method - or -1.0 if no return value visitor existed. This functionality basically only exists so that the OOB - visitor can return the oob error rate like in the old version of the random forest.
Reimplemented in StopVisiting, and OOB_Visitor.
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
template<class Tree, class Split, class Region, class Feature_t, class Label_t> | ||||
void visit_after_split | ( | Tree & | tree, | |
Split & | split, | |||
Region & | parent, | |||
Region & | leftChild, | |||
Region & | rightChild, | |||
Feature_t & | features, | |||
Label_t & | labels | |||
) |
do something after the the Split has decided how to process the Region (Stack entry)
tree | reference to the tree that is currently being learned | |
split | reference to the split object | |
parent | current stack entry which was used to decide the split | |
leftChild | left stack entry that will be pushed | |
rightChild | right stack entry that will be pushed. | |
features | features matrix | |
labels | label matrix |
Reimplemented in OnlineLearnVisitor, and VariableImportanceVisitor.
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
template<class RF, class PR, class SM, class ST> | ||||
void visit_after_tree | ( | RF & | rf, | |
PR & | pr, | |||
SM & | sm, | |||
ST & | st, | |||
int | index | |||
) |
do something after each tree has been learned
rf | reference to the random forest object that called this visitor | |
pr | reference to the preprocessor that processed the input | |
sm | reference to the sampler object | |
st | reference to the first stack entry | |
index | index of current tree |
Reimplemented in OnlineLearnVisitor, OOB_Visitor, and VariableImportanceVisitor.
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
void visit_at_beginning | ( | RF const & | rf, | |
PR const & | pr | |||
) |
do something before learning starts
rf | reference to the random forest object that called this visitor | |
pr | reference to the Processor class used. |
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
template<class RF, class PR> | ||||
void visit_at_end | ( | RF const & | rf, | |
PR const & | pr | |||
) |
do something after all trees have been learned
rf | reference to the random forest object that called this visitor | |
pr | reference to the preprocessor that processed the input |
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
void visit_external_node | ( | TR & | tr, | |
IntT | index, | |||
TopT | node_t, | |||
Feat & | features | |||
) |
do some thing while traversing tree after it has been learned (external nodes)
tr | reference to the tree object that called this visitor | |
index | index in the topology_ array we currently are at | |
node_t | type of node we have (will be e_.... - ) | |
weight | Node weight of current node. |
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
template<class TR, class IntT, class TopT, class Feat> | ||||
void visit_internal_node | ( | TR & | tr, | |
IntT | index, | |||
TopT | node_t, | |||
Feat & | features | |||
) |
do something when visiting a internal node after it has been learned
Reimplemented in OnlineLearnVisitor.
© Ullrich Köthe (ullrich.koethe@iwr.uni-heidelberg.de) |
html generated using doxygen and Python
|