Home || Visual Search || Applications || Architecture || Important Messages || OGL || Src

void Impala::Core::Table::AnnotationTable::Sort (  )  [inline]

after sorting the positive examples come first (sorted on quids), then the skipped, then the negative examples (sorted on quids)

Note:
this function is only for backwards compatibility of mainTrainModel.cpp

Definition at line 610 of file AnnotationTable.h.

References Impala::Core::Table::TableTem< Col1T, Col2T, Col3T, Col4T, Col5T, Col6T, Col7T, Col8T, Col9T >::Get2(), Impala::Core::Table::TableTem< Col1T, Col2T, Col3T, Col4T, Col5T, Col6T, Col7T, Col8T, Col9T >::GetColumn1(), Impala::Core::Table::TableTem< Col1T, Col2T, Col3T, Col4T, Col5T, Col6T, Col7T, Col8T, Col9T >::GetColumn2(), Impala::Util::QuickSort(), Impala::Util::QuickSortDescCo(), and Impala::Core::Table::Table::Size().

00611     {
00612         Util::QuickSortDescCo
00613             (GetColumn2()->GetData(), GetColumn1()->GetData(), 0, Size()-1);
00614         //sort positive examples
00615         int to;
00616         for(int i=0 ; i<Size() ; ++i)
00617         {
00618             to = i;
00619             if(Get2(i) != 1)
00620                 break;
00621         }
00622         Util::QuickSort(GetColumn1()->GetData(), 0, to-1);
00623         //sort negative examples
00624         int from;
00625         for(int i=to ; i<Size() ; ++i)
00626         {
00627             from = i;
00628             if(Get2(i) == -1)
00629                 break;
00630         }
00631         Util::QuickSort(GetColumn1()->GetData(), from, Size()-1);
00632     }

Here is the call graph for this function:


Generated on Thu Jan 13 09:20:45 2011 for ImpalaSrc by  doxygen 1.5.1