opencv中cv::GPU::ORB_GPU使用的问题

来源:互联网 发布:高铁订票软件 知乎 编辑:程序博客网 时间:2024/05/17 02:50

 检测出来的ORB特征点的分布是这样子的


这个主要问题在于,提取特征点的时候,FAST特征点出了问题,提取长度不够

ORB_GPU(int nFeatures, float scaleFactor, int nLevels, int edgeThreshold, int firstLevel, int WTA_K, int scoreType, int patchSize) :    nFeatures_(nFeatures), scaleFactor_(scaleFactor), nLevels_(nLevels), edgeThreshold_(edgeThreshold), firstLevel_(firstLevel), WTA_K_(WTA_K),    scoreType_(scoreType), patchSize_(patchSize), fastDetector_(DEFAULT_FAST_THRESHOLD)
源代码初始化,这里最后一项是FAST特征点,FAST的特征点定义如下,

explicit FAST_GPU(int threshold, bool nonmaxSuppression = true, double keypointsRatio = 0.05);
最后一个
keypointsRatio = 0.05;
会影响储存FAST点的长度,具体懒得找了,是0.05*1920*1080,也就10k个点,显然对于这种图不够用啊

自己定义了一个

lmw::ORB_GPU0::ORB_GPU0(int nFeatures, float scaleFactor, int nLevels, int edgeThreshold, int firstLevel, int WTA_K, int scoreType, int patchSize) :    nFeatures_(nFeatures), scaleFactor_(scaleFactor), nLevels_(nLevels), edgeThreshold_(edgeThreshold), firstLevel_(firstLevel), WTA_K_(WTA_K),    scoreType_(scoreType), patchSize_(patchSize), fastDetector_(DEFAULT_FAST_THRESHOLD, true, 0.05)

好了

原创粉丝点击