From: Mehrdad on
I am trying to write a function in c++ that does what pdist function of matlab would do.

I have used the exact same code as is used by matlab in the c file. However, after compilation in release mode with all optimizations enabled, I don't get the same speed as in matlab, at least three times slower.

Has anybody know why is that happening ? and if you know any fast implementation of this functionality in c++ ??


Thanks.