facebookresearch / silk

SiLK (Simple Learned Keypoint) is a self-supervised deep learning keypoint model.
GNU General Public License v3.0
644 stars 58 forks source link

Hard-coded scale factor #22

Closed mertkaraoglu closed 1 year ago

mertkaraoglu commented 1 year ago

How did you end up with the descriptor scaling factor 1.41. Can you elaborate on the intuition of why such a scale is practically beneficial?

gleize commented 1 year ago

Hi @mertkaraoglu,

SILK_SCALE_FACTOR is a scaling factor of the descriptors (desc <- SILK_SCALE_FACTOR * desc) done after unit normalization. A value of 1.41 (square root of 2) will essentially bring the descriptors on the hypersphere surface of radius 2. This is here for legacy reasons, and has little importance (with the exception mentioned below). You can just treat it as a constant.

Moreover, changing that value won't change the MNN matching, nor the ratio-test. BUT, it will affect the double-softmax matching, as changing SILK_SCALE_FACTOR is similar to changing the softmax temperature.

mertkaraoglu commented 1 year ago

Yes, I see; thanks for the reply.