Lines Matching full:distance
107 template <typename Distance>
111 typedef typename Distance::ElementType ElementType;
112 typedef typename Distance::ResultType DistanceType;
121 @param distance
202 GenericIndex(const Mat& features, const ::cvflann::IndexParams& params, Distance distance = Distance());
236 ::cvflann::Index<Distance>* nnIndex;
244 "the distance using cvflann::set_distance_type. This is no longer working as expected "\
245 "(cv::flann::Index always uses L2). You should create the index templated on the distance, "\
246 "for example for L1 distance use: GenericIndex< L1<float> > \n"); \
250 template <typename Distance>
251 GenericIndex<Distance>::GenericIndex(const Mat& dataset, const ::cvflann::IndexParams& params, Distance distance)
257 nnIndex = new ::cvflann::Index<Distance>(m_dataset, params, distance);
264 template <typename Distance>
265 GenericIndex<Distance>::~GenericIndex()
270 template <typename Distance>
271 void GenericIndex<Distance>::knnSearch(const std::vector<ElementType>& query, std::vector<int>& indices, std::vector<DistanceType>& dists, int knn, const ::cvflann::SearchParams& searchParams)
283 template <typename Distance>
284 void GenericIndex<Distance>::knnSearch(const Mat& queries, Mat& indices, Mat& dists, int knn, const ::cvflann::SearchParams& searchParams)
303 template <typename Distance>
304 int GenericIndex<Distance>::radiusSearch(const std::vector<ElementType>& query, std::vector<int>& indices, std::vector<DistanceType>& dists, DistanceType radius, const ::cvflann::SearchParams& searchParams)
315 template <typename Distance>
316 int GenericIndex<Distance>::radiusSearch(const Mat& query, Mat& indices, Mat& dists, DistanceType radius, const ::cvflann::SearchParams& searchParams)
407 Distance> instead\n");
423 "For other distance types you must use cv::flann::GenericIndex<Distance>\n");
503 Distance::ElementType.
505 Distance::ResultType. The number of rows in this matrix represents the number of clusters desired,
511 @param d Distance to be used for clustering.
517 template <typename Distance>
519 Distance d = Distance())
521 typedef typename Distance::ElementType ElementType;
522 typedef typename Distance::ResultType DistanceType;
532 return ::cvflann::hierarchicalClustering<Distance>(m_features, m_centers, params, d);
541 "cv::flann::hierarchicalClustering<Distance> instead\n");
552 "For other distance types you must use cv::flann::hierarchicalClustering<Distance>\n");