OpenCV  2.4.13.3
Open Source Computer Vision
CvRTrees Class Reference

#include <ml.hpp>

Inheritance diagram for CvRTrees:
CvStatModel CvERTrees

Public Member Functions

 CvRTrees ()
 
virtual ~CvRTrees ()
 
virtual bool train (const CvMat *trainData, int tflag, const CvMat *responses, const CvMat *varIdx=0, const CvMat *sampleIdx=0, const CvMat *varType=0, const CvMat *missingDataMask=0, CvRTParams params=CvRTParams())
 
virtual bool train (CvMLData *data, CvRTParams params=CvRTParams())
 
virtual float predict (const CvMat *sample, const CvMat *missing=0) const
 
virtual float predict_prob (const CvMat *sample, const CvMat *missing=0) const
 
virtual bool train (const cv::Mat &trainData, int tflag, const cv::Mat &responses, const cv::Mat &varIdx=cv::Mat(), const cv::Mat &sampleIdx=cv::Mat(), const cv::Mat &varType=cv::Mat(), const cv::Mat &missingDataMask=cv::Mat(), CvRTParams params=CvRTParams())
 
virtual float predict (const cv::Mat &sample, const cv::Mat &missing=cv::Mat()) const
 
virtual float predict_prob (const cv::Mat &sample, const cv::Mat &missing=cv::Mat()) const
 
virtual cv::Mat getVarImportance ()
 
virtual void clear ()
 
virtual const CvMatget_var_importance ()
 
virtual float get_proximity (const CvMat *sample1, const CvMat *sample2, const CvMat *missing1=0, const CvMat *missing2=0) const
 
virtual float calc_error (CvMLData *data, int type, std::vector< float > *resp=0)
 
virtual float get_train_error ()
 
virtual void read (CvFileStorage *fs, CvFileNode *node)
 
virtual void write (CvFileStorage *fs, const char *name) const
 
CvMatget_active_var_mask ()
 
CvRNGget_rng ()
 
int get_tree_count () const
 
CvForestTreeget_tree (int i) const
 
- Public Member Functions inherited from CvStatModel
 CvStatModel ()
 
virtual ~CvStatModel ()
 
virtual void save (const char *filename, const char *name=0) const
 
virtual void load (const char *filename, const char *name=0)
 

Protected Member Functions

virtual std::string getName () const
 
virtual bool grow_forest (const CvTermCriteria term_crit)
 

Protected Attributes

CvForestTree ** trees
 
CvDTreeTrainDatadata
 
int ntrees
 
int nclasses
 
double oob_error
 
CvMatvar_importance
 
int nsamples
 
cv::RNGrng
 
CvMatactive_var_mask
 
- Protected Attributes inherited from CvStatModel
const char * default_model_name
 

Constructor & Destructor Documentation

§ CvRTrees()

CvRTrees::CvRTrees ( )

§ ~CvRTrees()

virtual CvRTrees::~CvRTrees ( )
virtual

Member Function Documentation

§ calc_error()

virtual float CvRTrees::calc_error ( CvMLData data,
int  type,
std::vector< float > *  resp = 0 
)
virtual

§ clear()

virtual void CvRTrees::clear ( )
virtual

Reimplemented from CvStatModel.

§ get_active_var_mask()

CvMat* CvRTrees::get_active_var_mask ( )

§ get_proximity()

virtual float CvRTrees::get_proximity ( const CvMat sample1,
const CvMat sample2,
const CvMat missing1 = 0,
const CvMat missing2 = 0 
) const
virtual

§ get_rng()

CvRNG* CvRTrees::get_rng ( )

§ get_train_error()

virtual float CvRTrees::get_train_error ( )
virtual

§ get_tree()

CvForestTree* CvRTrees::get_tree ( int  i) const

§ get_tree_count()

int CvRTrees::get_tree_count ( ) const

§ get_var_importance()

virtual const CvMat* CvRTrees::get_var_importance ( )
virtual

§ getName()

virtual std::string CvRTrees::getName ( ) const
protectedvirtual

Reimplemented in CvERTrees.

§ getVarImportance()

virtual cv::Mat CvRTrees::getVarImportance ( )
virtual

§ grow_forest()

virtual bool CvRTrees::grow_forest ( const CvTermCriteria  term_crit)
protectedvirtual

Reimplemented in CvERTrees.

§ predict() [1/2]

virtual float CvRTrees::predict ( const CvMat sample,
const CvMat missing = 0 
) const
virtual

§ predict() [2/2]

virtual float CvRTrees::predict ( const cv::Mat sample,
const cv::Mat missing = cv::Mat() 
) const
virtual

§ predict_prob() [1/2]

virtual float CvRTrees::predict_prob ( const CvMat sample,
const CvMat missing = 0 
) const
virtual

§ predict_prob() [2/2]

virtual float CvRTrees::predict_prob ( const cv::Mat sample,
const cv::Mat missing = cv::Mat() 
) const
virtual

§ read()

virtual void CvRTrees::read ( CvFileStorage fs,
CvFileNode node 
)
virtual

Reimplemented from CvStatModel.

§ train() [1/3]

virtual bool CvRTrees::train ( const CvMat trainData,
int  tflag,
const CvMat responses,
const CvMat varIdx = 0,
const CvMat sampleIdx = 0,
const CvMat varType = 0,
const CvMat missingDataMask = 0,
CvRTParams  params = CvRTParams() 
)
virtual

Reimplemented in CvERTrees.

§ train() [2/3]

virtual bool CvRTrees::train ( CvMLData data,
CvRTParams  params = CvRTParams() 
)
virtual

Reimplemented in CvERTrees.

§ train() [3/3]

virtual bool CvRTrees::train ( const cv::Mat trainData,
int  tflag,
const cv::Mat responses,
const cv::Mat varIdx = cv::Mat(),
const cv::Mat sampleIdx = cv::Mat(),
const cv::Mat varType = cv::Mat(),
const cv::Mat missingDataMask = cv::Mat(),
CvRTParams  params = CvRTParams() 
)
virtual

Reimplemented in CvERTrees.

§ write()

virtual void CvRTrees::write ( CvFileStorage fs,
const char *  name 
) const
virtual

Reimplemented from CvStatModel.

Member Data Documentation

§ active_var_mask

CvMat* CvRTrees::active_var_mask
protected

§ data

CvDTreeTrainData* CvRTrees::data
protected

§ nclasses

int CvRTrees::nclasses
protected

§ nsamples

int CvRTrees::nsamples
protected

§ ntrees

int CvRTrees::ntrees
protected

§ oob_error

double CvRTrees::oob_error
protected

§ rng

cv::RNG* CvRTrees::rng
protected

§ trees

CvForestTree** CvRTrees::trees
protected

§ var_importance

CvMat* CvRTrees::var_importance
protected

The documentation for this class was generated from the following file: