Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

features2d: Keypoint matching very slow

Hello!

I'm using OpenCV features2d to match a pair of high resolution images for stereo reconstruction. What I do looks as follows:

  • Detect keypoints
  • Extract descriptors
  • Do a knn match with k=2
  • Drop matches using the distance ratio
  • Estimate a homography and drop all outliers

Basically this works fine for me. I retrieve between 60000 and 120000 initial keypoints from the images. BUT: Some combinations of Detector/Extractor/Matcher need a lot of time to finish.

For the time measurements here I measured detecting/extracting/matching.

Surf/Surf/FLANN takes about 82 seconds. This amount of time is reasonable for my needs. It gives me about 100k initial keypoints. My parameters here are as follows. 6 octaves, 2 layers per octave, hessian thres. 50, extended descriptors

Surf/Freak/BFMatcher needs 9m 50s which is quite a long time. Surf has the same config as before. Is there a way to speed this up? Should FLANN with LSH give a speedup here? Does the time BFMatcher needs solely depend on the total number of descriptors, or does the quality of the descriptors have an influence on this?

If you have some additional advice for me I would appreciate it. I need as much good matches as I can get :).

Thanks

features2d: Keypoint matching very slow

Hello!

I'm using OpenCV features2d to match a pair of high resolution images for stereo reconstruction. What I do looks as follows:

  • Detect keypoints
  • Extract descriptors
  • Do a knn match with k=2
  • Drop matches using the distance ratio
  • Estimate a homography and drop all outliers

Basically this works fine for me. I retrieve between 60000 and 120000 initial keypoints from the images. BUT: Some combinations of Detector/Extractor/Matcher need a lot of time to finish.finish.

For the time measurements here I measured detecting/extracting/matching.

Surf/Surf/FLANN takes about 82 seconds. This amount of time is reasonable for my needs. It gives me about 100k initial keypoints. My parameters here are as follows. 6 octaves, 2 layers per octave, hessian thres. 50, extended descriptors

Surf/Freak/BFMatcher needs 9m 50s which is quite a long time. time, with more than 9 min spent for matching. Surf has the same config as before. Is there a way to speed this up? Should FLANN with LSH give a speedup here? Does the time BFMatcher needs solely depend on the total number of descriptors, or does the quality of the descriptors have an influence on this?

If you have some additional advice for me I would appreciate it. I need as much good matches as I can get :).

Thanks

features2d: Keypoint matching very slow

Hello!

I'm using OpenCV features2d to match a pair of high resolution images for stereo reconstruction. What I do looks as follows:

  • Detect keypoints
  • Extract descriptors
  • Do a knn match with k=2
  • Drop matches using the distance ratio
  • Estimate a homography and drop all outliers

Basically this works fine for me. I retrieve between 60000 and 120000 initial keypoints from the images. BUT: Some combinations of Detector/Extractor/Matcher need a lot of time to finish.

For the time measurements here I measured detecting/extracting/matching.

Surf/Surf/FLANN takes about 82 seconds. This amount of time is reasonable for my needs. It gives me about 100k initial keypoints. My parameters here are as follows. 6 octaves, 2 layers per octave, hessian thres. 50, extended descriptors

Surf/Freak/BFMatcher needs 9m 50s which is quite a long time, with more than 9 min spent for matching. Surf has the same config as before. Is there a way to speed this up? Should FLANN with LSH give a speedup here? Does the time BFMatcher needs solely depend on the total number of descriptors, or does the quality of the descriptors have an influence on this?

http://answers.opencv.org/question/924/lsh-matching-very-slow/ Looking at these time emasurements for 1.000.000 ORB descriptors I wonder. Are ORB descriptors faster to match than FREAK ones? Have they been matched on the GPU?

If you have some additional advice for me I would appreciate it. I need as much good matches as I can get :).

Thanks

click to hide/show revision 4
retagged

updated 2013-10-05 02:58:21 -0600

berak gravatar image

features2d: Keypoint matching very slow

Hello!

I'm using OpenCV features2d to match a pair of high resolution images for stereo reconstruction. What I do looks as follows:

  • Detect keypoints
  • Extract descriptors
  • Do a knn match with k=2
  • Drop matches using the distance ratio
  • Estimate a homography and drop all outliers

Basically this works fine for me. I retrieve between 60000 and 120000 initial keypoints from the images. BUT: Some combinations of Detector/Extractor/Matcher need a lot of time to finish.

For the time measurements here I measured detecting/extracting/matching.

Surf/Surf/FLANN takes about 82 seconds. This amount of time is reasonable for my needs. It gives me about 100k initial keypoints. My parameters here are as follows. 6 octaves, 2 layers per octave, hessian thres. 50, extended descriptors

Surf/Freak/BFMatcher needs 9m 50s which is quite a long time, with more than 9 min spent for matching. Surf has the same config as before. Is there a way to speed this up? Should FLANN with LSH give a speedup here? Does the time BFMatcher needs solely depend on the total number of descriptors, or does the quality of the descriptors have an influence on this?

http://answers.opencv.org/question/924/lsh-matching-very-slow/ Looking at these time emasurements for 1.000.000 ORB descriptors I wonder. Are ORB descriptors faster to match than FREAK ones? Have they been matched on the GPU?

If you have some additional advice for me I would appreciate it. I need as much good matches as I can get :).

Thanks