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

Mat* Impala::Core::Matrix::MatKeepSpecificRows ( Mat *  data,
std::vector< int > &  keepers 
)

Definition at line 16 of file MatKeepSpecificRows.h.

References MatE(), and MatNrCol().

Referenced by KmeansClustering(), and MatDrawRandomRows().

00017 {
00018     // we have the indices; now copy vectors
00019     int d = MatNrCol(data);
00020     Mat* res = MatCreate<Mat>(keepers.size(), d);
00021     for(int j = 0; j < keepers.size(); j++)
00022     {
00023         int k = keepers[j];
00024         for(int i = 0; i < d; i++)
00025             *MatE(res, j, i) = *MatE(data, k, i);
00026     }
00027     return res;
00028 }

Here is the call graph for this function:


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