123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- /**
- * @file testRF.cpp
- * @brief test random forest implementation
- * @author Björn Fröhlich
- * @date 06/08/2010
- */
- #include "core/basics/Config.h"
- #include "vislearning/classifier/fpclassifier/randomforest/FPCRandomForests.h"
- #include "vislearning/classifier/classifierbase/FeaturePoolClassifier.h"
- #include "vislearning/baselib/Globals.h"
- using namespace OBJREC;
- using namespace NICE;
- using namespace std;
- int main( int argc, char **argv )
- {
- if ( argc < 1 )
- {
- cerr << "Bitte Datei angeben" << endl;
- return -1;
- }
- string filename;
- filename += argv[1];
- cout << "file: " << filename << endl;
- Config *conf = new Config();
- FeaturePoolClassifier *fpcrfCs = new FPCRandomForests( conf, "CsurkaForest" );
- //Vector *vec = new Vector(384);
- //Example ex(vec);
- fpcrfCs->setMaxClassNo( 8 );
- fpcrfCs->read( filename );
- /*
- ClassificationResult r;
- if(fpcrfCs != NULL)
- {
- r = fpcrfCs->classify ( ex );
- }
- */
- return 0;
- }
|