c++ - 我应该使用什么距离度量来匹配 RIFT 描述符?
问题描述
我目前正在尝试使用 PCL 库中的 FLANN 模块在其特征空间中找到一个点的最近邻 (NN)。
我要比较的点是 RIFT 描述符,格式为pcl::Histogram<32>
,因为我使用 4 个 bin 表示距离,8 个 bin 表示梯度(就像在原始文章中一样)。
我想知道我应该使用什么距离度量,因为默认的是 L2 范数,当匹配高维特征空间中的点时,这似乎有点弱。
我使用KdTreeMultiIndexCreator
FLANN 的索引来加快搜索速度。
我一定会使用下面的 flann 模块:
// Useful types
typedef pcl::Histogram<32> FeatureT;
typedef flann::L2<float> DistanceT;
typedef pcl::search::FlannSearch<FeatureT, DistanceT> SearchT;
typedef typename SearchT::FlannIndexCreatorPtr CreatorPtrT;
typedef typename SearchT::KdTreeMultiIndexCreator IndexT;
typedef typename SearchT::PointRepresentationPtr RepresentationPtrT;
// Instantiate search object with 4 randomized trees and 128 checks
SearchT search (true, CreatorPtrT (new IndexT (4)));
search.setPointRepresentation (RepresentationPtrT (new DefaultFeatureRepresentation<FeatureT>));
search.setChecks (128); // The more checks the more precise the solution
// search_cloud is filled with the keypoints to match
search.setInputCloud (search_cloud);
search.nearestKSearch(point_to_match, 1, indices, distances);
那么,FLANN 中最适合我的问题的距离测量是什么?
解决方案
推荐阅读
- crashlytics - 在 iOS 上使用 Flutter 的 Crashlytics - 为什么向 FirebaseCrashlytics 构建阶段提供 Info.plist 位置
- ruby-on-rails - 无法解决 @babel 解决问题 Yarn/Rails
- node.js - 具有自定义参数和 EventEmitter 的 Node.JS 模块不起作用
- regex - 拆分字符串,然后删除 Google 表格中的前缀
- python-3.x - 部署 Django 项目后 Weasyprint 不显示图像
- reactjs - UseEffect 中的异步生成器 - 如何取消订阅更新
- node.js - 如果任何值与集合中的数组元素匹配,则查找记录
- r - R组合字符串以循环访问对象
- mongodb - 如何在部署集中添加具有 mongodb 数据库的持久性卷声明,以供部署在 kubernetes 中的 nodejs 微服务使用
- reactjs - React Typescript:类型参数不可分配给类型参数