What are the values of the SURF descriptor?
Hi,
I'm extracting SURF descriptors from an image using the following simple lines:
Ptr<DescriptorExtractor> descriptor = DescriptorExtractor::create("SURF");
descriptor->compute(im1, kp, desc1);
Now, when I "watch" the variable desc1.data, it contains integer values in the range 0 to 255.
However, when I investigate the values using the code:
for (int j=0;j<desc1.cols; j++){
float a=desc1.at<float>(0,j);
it contains values between -1 and 1. How is that possible? SURF shouldn't return integer values like SIFT?
Thanks in advance!
hmm, that should be float values indeed.
what do you mean by 'watch' ? can it be, it's looking at the data pointer ? (which is uchar*)
if it's vs there, try :
(float*)(desc1.data),128
yes, I'm looking at the data pointer and it contains integer values between 0 and 255, but when I execute float a=desc1.at<float>(0,j); I get that a is between -1 and 1.