First time here? Check out the FAQ!

Ask Your Question
0

FeatureDetector for SURF

asked Feb 25 '15

Hello.

I was wondering if it is possible to specify the Hessian threshold for the surf detector in the FeatureDetector class

cv::Mat image;
//get the image
cv::Ptr<cv::FeatureDetector> surf_detector;
surf_detector = FeatureDetector::create("SURF");
// I would like to set the Hessian threshold to 400
vector<cv::KeyPoint> keypoints;
surf_detector->detect(image, keypoints);

Or Will I need to continue using the cv::SurfFeatureDetector class and initialize it with the proper value?

while this specifically asks about the SURF detector, I'd like to know if it is possible to pass parameters to the underlying detector class. AKA specify the hessian value for surf, set non-maximal suppression for fast detector, and so on.

Preview: (hide)

2 answers

Sort by » oldest newest most voted
2

answered Feb 25 '15

Potato gravatar image

For the stable version(Without using pointers) --> SurfFeatureDetector detector(400);

For the beta version (3.0.0) --> Ptr<SURF> surf = SURF::create(400);

Preview: (hide)
1

answered Feb 25 '15

Eduardo gravatar image

Hi,

Something like this should work:

surf_detector->set("hessianThreshold", 400);

See: set

Preview: (hide)

Question Tools

1 follower

Stats

Asked: Feb 25 '15

Seen: 810 times

Last updated: Feb 25 '15