Ask Your Question
0

Surf Giving Weird Keypoints

asked 2015-05-25 00:08:32 -0600

jpistorino gravatar image

updated 2015-06-19 16:45:11 -0600

I am attempting to simply run the SurfDetector on an image and am getting weird kepypoint results.

I am pulling full HD images from a Logitech c930 camera using OpenCV 3.0 on a Win8.1 64 bit machine using VS2012 C++/cli.

Here is the image of keypoints that results from running SurfDetector with a minHessian set at 400.image description

alt text

As you can see, the kepypoints are all over the place and are do not appear to correspond to anything in particular. I tried setting the minHessian value at 100 also with no apparent effect.

The code that gets this result looks like:

 cvtColor(OriginalImage,GrayImage,CV_BGR2GRAY);
 SurfDetector->detect(GrayImage,tSurfKeypoints);
 drawKeypoints( OriginalImage,tSurfKeypoints,OriginalImage, Scalar::all(-1), DrawMatchesFlags::DEFAULT );

Is this right? It does not seem like it could be.

By contrast, using the same images, FAST gives the following result:

image description

That seems more like what I would expect.

Any help appreciated.

Regards,

James

edit retag flag offensive close merge delete

Comments

1

Guess these keypoints around the border appear due to the scale space of SURF. The same should happen with SIFT.

Guanta gravatar imageGuanta ( 2015-06-20 11:14:20 -0600 )edit
1

FAST is a corner detector for tracking, so it is natural that it will find only corners. SURF, for another side detects regions that are identifiable in several scales, such that it can be relatively scale independent for feature matching. You will be able to see that if you draw the circles according the size attribute of cv::Keypoint.

R.Saracchini gravatar imageR.Saracchini ( 2015-06-22 05:17:58 -0600 )edit

Thanks. That is very helpful. However, because the points are not even on the fork and there are several like that, won't this cause me all sorts of problems trying to do object matching based on them? I can match several points, none of which are actually on the fork.

jpistorino gravatar imagejpistorino ( 2015-06-22 23:32:36 -0600 )edit

Well, the feature will match with such background and the fork, so if you change the background that feature wont be present at all. Of course, there is the possibility of false matching, but this happens even with features found within the fork. At first, you should not match directly a feature with the closest feature found in the image, rather do a more robust comparison do eliminate ambiguous matches (check this book here : http://szeliski.org/Book/ , it is very helpfull)

R.Saracchini gravatar imageR.Saracchini ( 2015-06-23 04:27:35 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2015-06-23 11:50:05 -0600

jpistorino gravatar image

Thanks so much. Obviously, I am a novice and these kinds of answers are a huge help.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2015-05-25 00:08:32 -0600

Seen: 269 times

Last updated: Jun 19 '15