我想计算两个向量(或两个 Matrx 行,无关紧要)之间的欧氏距离。在 OpenCV 中有一个好的函数吗?
最佳答案
Mat a,b; // num of rows/cols/channels does not matter, they just have to be equal for both
double dist = norm(a,b,NORM_L2);
关于两个向量之间的 OpenCV 欧氏距离,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23105777/