Pārlūkot izejas kodu

Merge branch 'persistent' of dbv.inf-cv.uni-jena.de:nice/nice-semseg into cmake_merge_b_persistent

Johannes Ruehle 11 gadi atpakaļ
vecāks
revīzija
14370eca4e
1 mainītis faili ar 24 papildinājumiem un 0 dzēšanām
  1. 24 0
      semseg/SemSegNovelty.cpp

+ 24 - 0
semseg/SemSegNovelty.cpp

@@ -44,6 +44,30 @@ SemSegNovelty::SemSegNovelty ( )
 SemSegNovelty::SemSegNovelty ( const Config * _conf,
                                const MultiDataset *md )
 {
+  ///////////
+  // same code as in empty constructor - duplication can be avoided with C++11 allowing for constructor delegation
+  ///////////  
+  this->forbidden_classesTrain.clear();
+  this->forbidden_classesActiveLearning.clear();
+  this->classesInUse.clear();
+  
+  this->globalMaxUncert = -numeric_limits<double>::max();  
+  
+  //we don't have queried any region so far
+  this->queriedRegions.clear(); 
+  
+  this->featExtract = new LocalFeatureColorWeijer ();
+  
+  // those two guys need to be NULL, since only one of them will be active later on
+  this->classifier = NULL;
+  this->vclassifier = NULL;
+  
+  // this one here as well
+  this->regionSeg = NULL;  
+  
+  ///////////
+  // here comes the new code part different from the empty constructor
+  ///////////    
   SemanticSegmentation::setClassNames ( & ( md->getClassNames ( "train" ) ) );
   
   this->initFromConfig( _conf );