Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

cv::flann::index::knnsearch values of indices and dists

ok given the following code

    index.knnSearch(mat,indices,dists,3);
for (int i = 0; i < indices.rows; i++ )
{
   indices.at<int>(i,0) // this is the index of the match
   indices.at<int>(i,1) // ????? what is this?
   indices.at<int>(i,2) // and this?
}

also for dists, what do I do with the 3 values in each row? how do I make it into a useful ratio or percentage match? in the indices I need to know how many descriptors out of 500 matched, I'm sure that data shows that somehow, but I don't understand it. Please help

cv::flann::index::knnsearch values of indices and dists

ok given the following code

    index.knnSearch(mat,indices,dists,3);
for (int i = 0; i < indices.rows; i++ )
{
   indices.at<int>(i,0) // this is the index of the match
   indices.at<int>(i,1) // ????? what is this?
   indices.at<int>(i,2) // and this?
}

also for dists, what do I do with the 3 values in each row? when using binary descriptors how do I make it dists results into a useful ratio or percentage match? in the indices I need to know how many descriptors out of 500 matched, I'm sure that data shows that somehow, but I don't understand it. Please helpmatch?