Bjoern Froehlich 13 жил өмнө
parent
commit
503c3c9986

+ 6 - 5
semseg/SemSegContextTree.cpp

@@ -1977,7 +1977,7 @@ void SemSegContextTree::semanticseg ( CachedExample *ce, NICE::Image & segresult
 #endif
   }
 
-  cout << forest[0][currentfeats.get ( xpos, ypos, 0 ) ].dist << endl;
+//  cout << forest[0][currentfeats.get ( xpos, ypos, 0 ) ].dist << endl;
 
 #ifdef WRITEGLOB
   ofstream outstream("globtest.feat",ofstream::app);
@@ -1986,11 +1986,11 @@ void SemSegContextTree::semanticseg ( CachedExample *ce, NICE::Image & segresult
   outstream.close();
 #endif
 
-  vector<int> useclass ( classes, 1 );
-
   string cndir = conf->gS ( "SSContextTree", "cndir", "" );
-#ifdef WRITEGLOB
   int classes = ( int ) probabilities.numChannels;
+  vector<int> useclass ( classes, 1 );
+#ifdef WRITEGLOB
+  
   
   std::vector< std::string > list;
   StringTools::split ( currentFile, '/', list );
@@ -2000,7 +2000,7 @@ void SemSegContextTree::semanticseg ( CachedExample *ce, NICE::Image & segresult
   ofstream ostream("filelist.txt",ofstream::app);
   ostream << orgname << ".dat" << endl;
   ostream.close();
-#endif
+
   if ( cndir != "" )
   {
     useclass = vector<int> ( classes, 0 );
@@ -2052,6 +2052,7 @@ void SemSegContextTree::semanticseg ( CachedExample *ce, NICE::Image & segresult
       }
     }
   }
+#endif
   
   if ( pixelWiseLabeling )
   {