How to get a binary representation of a binary descriptor
Hello, I'm working with binary descriptors like ORB and AKAZE in opencv and want to store each descriptor (a col of the descriptor mat) as binary string. To perform the query, I want to save these representation as a array of integers (int = 32 bits and I have a 32 bit machine), so I can easy compare binary string with hamming distance.
My problem is to extract the bit representation from the mat because the at has byte representation. Is there something that I must conside if want to extract the bits?
thank you! :)
i don't think, you have to convert the descriptors at all.
why not use a simple
norm(a,b,NORM_HAMMING);
?no I doesn't normalize the descriptor. Is this important? And after the normaliztion, I can easy extract each row and concatendate the byte to a integer?
it's not about normalization, the norm() function calculates a distance (hamming in this case)
ah...of course...but no, I want not use intern functions of opencv for this. I want only extract the string representation
An integer is sort of already a binary array. Store them as integers and operate on bit-level. Also, you can always do something like this: http://stackoverflow.com/questions/79...