how to calculate SIFT descriptor for MSER keypoints?

asked 2017-02-27 09:37:44 -0500

Hao gravatar image


I want to use SIFT descriptors to represent a region detected by MSER, here is my code:

MserFeatureDetector detector();
vector<KeyPoint> keypoints;
detector.detect( src_gray, keypoints );

Mat descriptors, mask( src_gray.rows, src_gray.cols, CV_8UC1, 255 );
cv::SIFT detector = SIFT::SIFT(); 
detector( src_gray, mask, keypoints, descriptors, true );

I get the descriptors successfully, but the keypoints of MSER won’t have octave, scale, and angle. However, I put them into SIFT extraction forcibly to get descriptors. Thus, i think the descriptors finally I get, will lost the invariant to illumination changes but still have scale & rotational invariance. Is my opinion correct? Or, it is wrong way to use?

edit retag flag offensive close merge delete


Hey, I am currently doing similar stuff and stuck at this same problem. How did u converted MSER regions to keypoints!!!

ronak gravatar imageronak ( 2018-06-20 06:48:38 -0500 )edit

Hello! there is a pre-written function in openCV to convert a point into a KeyPoint, maybe that's what your are looking for :

potato_49 gravatar imagepotato_49 ( 2018-07-17 05:31:39 -0500 )edit