Point Cloud Library (PCL) 1.15.0
|
Trainer for decision trees. More...
#include <pcl/ml/dt/decision_forest_trainer.h>
Public Member Functions | |
DecisionForestTrainer () | |
Constructor. | |
virtual | ~DecisionForestTrainer () |
Destructor. | |
void | setNumberOfTreesToTrain (const std::size_t num_of_trees) |
Sets the number of trees to train. | |
void | setFeatureHandler (pcl::FeatureHandler< FeatureType, DataSet, ExampleIndex > &feature_handler) |
Sets the feature handler used to create and evaluate features. | |
void | setStatsEstimator (pcl::StatsEstimator< LabelType, NodeType, DataSet, ExampleIndex > &stats_estimator) |
Sets the object for estimating the statistics for tree nodes. | |
void | setMaxTreeDepth (const std::size_t max_tree_depth) |
Sets the maximum depth of the learned tree. | |
void | setNumOfFeatures (const std::size_t num_of_features) |
Sets the number of features used to find optimal decision features. | |
void | setNumOfThresholds (const std::size_t num_of_threshold) |
Sets the number of thresholds tested for finding the optimal decision threshold on the feature responses. | |
void | setTrainingDataSet (DataSet &data_set) |
Sets the input data set used for training. | |
void | setExamples (std::vector< ExampleIndex > &examples) |
Example indices that specify the data used for training. | |
void | setLabelData (std::vector< LabelType > &label_data) |
Sets the label data corresponding to the example data. | |
void | setMinExamplesForSplit (std::size_t n) |
Sets the minimum number of examples to continue growing a tree. | |
void | setThresholds (std::vector< float > &thres) |
Specify the thresholds to be used when evaluating features. | |
void | setDecisionTreeDataProvider (typename pcl::DecisionTreeTrainerDataProvider< FeatureType, DataSet, LabelType, ExampleIndex, NodeType >::Ptr &dtdp) |
Specify the data provider. | |
void | setRandomFeaturesAtSplitNode (bool b) |
Specify if the features are randomly generated at each split node. | |
void | train (DecisionForest< NodeType > &forest) |
Trains a decision forest using the set training data and settings. | |
Trainer for decision trees.
Definition at line 57 of file decision_forest_trainer.h.
pcl::DecisionForestTrainer< FeatureType, DataSet, LabelType, ExampleIndex, NodeType >::DecisionForestTrainer | ( | ) |
Constructor.
Definition at line 47 of file decision_forest_trainer.hpp.
|
virtualdefault |
Destructor.
|
inline |
Specify the data provider.
[in] | dtdp | the data provider that should implement getDatasetAndLabels() function |
Definition at line 185 of file decision_forest_trainer.h.
|
inline |
Example indices that specify the data used for training.
[in] | examples | the examples |
Definition at line 144 of file decision_forest_trainer.h.
|
inline |
Sets the feature handler used to create and evaluate features.
[in] | feature_handler | the feature handler |
Definition at line 81 of file decision_forest_trainer.h.
|
inline |
Sets the label data corresponding to the example data.
[in] | label_data | the label data |
Definition at line 154 of file decision_forest_trainer.h.
|
inline |
Sets the maximum depth of the learned tree.
[in] | max_tree_depth | maximum depth of the learned tree |
Definition at line 103 of file decision_forest_trainer.h.
|
inline |
Sets the minimum number of examples to continue growing a tree.
[in] | n | number of examples |
Definition at line 164 of file decision_forest_trainer.h.
|
inline |
Sets the number of trees to train.
[in] | num_of_trees | the number of trees |
Definition at line 71 of file decision_forest_trainer.h.
|
inline |
Sets the number of features used to find optimal decision features.
[in] | num_of_features | the number of features |
Definition at line 113 of file decision_forest_trainer.h.
|
inline |
Sets the number of thresholds tested for finding the optimal decision threshold on the feature responses.
[in] | num_of_threshold | the number of thresholds |
Definition at line 124 of file decision_forest_trainer.h.
|
inline |
Specify if the features are randomly generated at each split node.
[in] | b | do it or not |
Definition at line 200 of file decision_forest_trainer.h.
|
inline |
Sets the object for estimating the statistics for tree nodes.
[in] | stats_estimator | the statistics estimator |
Definition at line 92 of file decision_forest_trainer.h.
|
inline |
Specify the thresholds to be used when evaluating features.
[in] | thres | the threshold values |
Definition at line 174 of file decision_forest_trainer.h.
|
inline |
Sets the input data set used for training.
[in] | data_set | the data set used for training |
Definition at line 134 of file decision_forest_trainer.h.
void pcl::DecisionForestTrainer< FeatureType, DataSet, LabelType, ExampleIndex, NodeType >::train | ( | pcl::DecisionForest< NodeType > & | forest | ) |
Trains a decision forest using the set training data and settings.
[out] | forest | destination for the trained forest |
Definition at line 66 of file decision_forest_trainer.hpp.