iRoCS Toolbox  1.1.0
Public Member Functions | Data Fields
lRandomForest Class Reference

#include <lRandomForest.hh>

Collaboration diagram for lRandomForest:

Public Member Functions

 lRandomForest (int nTree)
 
 ~lRandomForest ()
 
int GetSize () const
 
void loadForest (const char *filename, unsigned int offset=0)
 
void loadForest (std::stringstream *&ss)
 
double outlier (float *f, int cl) const
 
int predict (float *f) const
 
int predict (float *f, float &p) const
 
int predict (float *f, float *p) const
 
double proximity (float *f, int cl, int self=-1) const
 
double rawOutlier (float *f, int cl, int self=-1) const
 
void saveForest (const char *filename, unsigned int offset=0)
 
void saveForest (std::stringstream *&ss)
 
void selfTest ()
 
void SetTrees (int n)
 
void trainForest (float **X, int *L, int m, int n, int m_try, int max_depth, int min_samples=1, int num_grid=20)
 

Data Fields

int _maxLabel
 
int _nTree
 
double * absDevRawOutlier
 
int * classCount
 
float * classWeight
 
double * medianRawOutlier
 
int nSample
 
std::vector< lRandomTree * > vTrees
 

Detailed Description

Definition at line 42 of file lRandomForest.hh.

Constructor & Destructor Documentation

◆ lRandomForest()

lRandomForest::lRandomForest ( int  nTree)

◆ ~lRandomForest()

lRandomForest::~lRandomForest ( )

Member Function Documentation

◆ SetTrees()

void lRandomForest::SetTrees ( int  n)

◆ GetSize()

int lRandomForest::GetSize ( ) const

◆ predict() [1/3]

int lRandomForest::predict ( float *  f) const

◆ predict() [2/3]

int lRandomForest::predict ( float *  f,
float &  p 
) const

◆ predict() [3/3]

int lRandomForest::predict ( float *  f,
float *  p 
) const

◆ proximity()

double lRandomForest::proximity ( float *  f,
int  cl,
int  self = -1 
) const

◆ rawOutlier()

double lRandomForest::rawOutlier ( float *  f,
int  cl,
int  self = -1 
) const

◆ outlier()

double lRandomForest::outlier ( float *  f,
int  cl 
) const

◆ trainForest()

void lRandomForest::trainForest ( float **  X,
int *  L,
int  m,
int  n,
int  m_try,
int  max_depth,
int  min_samples = 1,
int  num_grid = 20 
)

◆ saveForest() [1/2]

void lRandomForest::saveForest ( const char *  filename,
unsigned int  offset = 0 
)

◆ loadForest() [1/2]

void lRandomForest::loadForest ( const char *  filename,
unsigned int  offset = 0 
)

◆ saveForest() [2/2]

void lRandomForest::saveForest ( std::stringstream *&  ss)

◆ loadForest() [2/2]

void lRandomForest::loadForest ( std::stringstream *&  ss)

◆ selfTest()

void lRandomForest::selfTest ( )

Field Documentation

◆ vTrees

std::vector<lRandomTree*> lRandomForest::vTrees

Definition at line 83 of file lRandomForest.hh.

◆ _nTree

int lRandomForest::_nTree

Definition at line 84 of file lRandomForest.hh.

◆ nSample

int lRandomForest::nSample

Definition at line 85 of file lRandomForest.hh.

◆ _maxLabel

int lRandomForest::_maxLabel

Definition at line 86 of file lRandomForest.hh.

◆ classCount

int* lRandomForest::classCount

Definition at line 88 of file lRandomForest.hh.

◆ classWeight

float* lRandomForest::classWeight

Definition at line 89 of file lRandomForest.hh.

◆ medianRawOutlier

double* lRandomForest::medianRawOutlier

Definition at line 91 of file lRandomForest.hh.

◆ absDevRawOutlier

double* lRandomForest::absDevRawOutlier

Definition at line 92 of file lRandomForest.hh.


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