Ask Your Question

studentstudent's profile - activity

2015-07-21 10:32:07 -0600 received badge  Enthusiast
2015-07-15 14:16:02 -0600 received badge  Student (source)
2015-07-15 11:33:06 -0600 commented question What is the distance used by K-nearest neighbour in opencv

The implementation of k nearest neighbour in opencv was not professional! In addition, we can not get the indices of the k-nearest neighbours and we can note use an other distance.

2015-07-15 11:26:20 -0600 commented question What is the distance used by K-nearest neighbour in opencv

In fact I need to use the chi-2 square distance because I have implemented it on mathematica and it gives a good results in my case. I need to use it with opencv knearest neighbours.

2015-07-15 11:12:51 -0600 commented question What is the distance used by K-nearest neighbour in opencv

So, what is the solution to use other distances than euclidian distance? I think it was a bad idea to use just euclidian distance!! They have to make the distance used as an input parameters!

2015-07-15 11:07:39 -0600 commented question What is the distance used by K-nearest neighbour in opencv

you can find a long discussion here distance euclidian problems in high dimensions

2015-07-14 23:02:02 -0600 asked a question What is the distance used by K-nearest neighbour in opencv

Hello,

I am using the machine learning k-nearest neighbour algrithm c++. I have a dataset with a high dimensional features. So, the euclidian distance will be not the best. I try to find which distance used in knearest.cpp to change it and used different distances but I could not because the code lacks comments. I find this block in the 189 but It seems that it not used in the find_nearest function. Any help?

> for( ; t < d; t++ )
>                 {
>                 
>                    double t0 = u[t] - v[t];
>                     sum += t0*t0;
>                     
>                 }