For example, when we define the output matrix as
flann::Matrix idx(data, rows, 3, 4);
which means we need to find 3 nearest neighbor, but we want to save the results to a matrix of stride=4, then the result is wrong.
This bug can be fixed changing only one place in kdtree_cuda_3d_index.cu.
knnSearchGpu gives wrong results if knn!=ostride.
For example, when we define the output matrix as flann::Matrix idx(data, rows, 3, 4);
which means we need to find 3 nearest neighbor, but we want to save the results to a matrix of stride=4, then the result is wrong.
This bug can be fixed changing only one place in kdtree_cuda_3d_index.cu.