我正在使用OpenCV上的SIFT和BFMATCHER缝制从无人机拍摄的几张图像。除了SIFT产生的描述符外,我还具有将像素映射到地面坐标的近似(实际上非常好),并希望使用这些信息来提高比赛的质量。
我的第一个方法是正常运行BFMatcher,然后根据关键点之间的物理距离过滤匹配,以删除潜在的不良/非物理匹配。但是,我认为在实际匹配算法中使用惩罚身体遥远匹配的自定义指标将是一个不错的补充。
是否可以在Python中定义自定义距离函数并将其传递给BFMatcher?据我所知,您只能使用
I'm working on stitching several images taken from a drone using the SIFT and BFMatcher on OpenCV. In addition to the descriptors produced by SIFT I also have an approximate (quite good actually) mapping of pixels to ground coordinates and was hoping of using this information to improve the qualities of the matches.
My first approach was to first run BFMatcher normally and then filter the matches based on the physical distance between the key points to remove potentially bad/unphysical matches. However, I thought that using a custom metric that penalizes physically distant matches during the actual matching algorithm would be a nice addition.
Is it possible to define a custom distance function in Python and pass it to BFMatcher? As far as I can tell you can only use those defined under NormTypes
发布评论