How can use cv::hierarchicalClustering with custom distance? how should the operator declaration should be?
for example if I have 2D dataset, I want something like this:
[](auto l, auto r){
return l[0]*r[0]+l[1]r[1];
}
How can I prepare it to be passed to cv::hierarchicalClustering