- this repo contains examples showing the fix for interpolation in scale space
- most notably this includes DoG used along with SIFT and other descriptors
- fixes available for Kornia and OpenCV
- shows location bias on the DoG detectors without matching on descriptors
- backprojects the detected locations on the rotated image and matches via mnn
- shown on OpenCV, Kornia and hloc (hloc - using VLFeat - doesn't have the bias)
- shown on OpenCV and Kornia baseline and corrected version
- "corrected version" is a naive fix, which simply subtracts the bias from the location
- shows location bias as in Rotation mnn, only this time by scaling
- the aspect ratio is exactly preserved (otherwise arithmetic errors due to aspect ratio change creep into the results)
- shown on OpenCV and Kornia
- presents the problem in OpenCV on 6 experiments on homography estimation
- shown on baseline and proper fix
- the fixed version is locally built OpenCV - to use it one needs to swap the dependency (or rebuilt OpenCV without fix)
- presents the problem in OpenCV as in OpenCV H estimation.ipynb
- uses VSAC for homography estimation
- presents the problem in Kornia as in OpenCV H estimation.ipynb
- uses numpy/OpenCV API for the actual homography estimation
- for Kornia there are 3 versions
FIXED
andNOT_FIXED
are using code mirroring Kornia, but with toggleable flag for the upscaling fix- (see
scale_pyramid.py
,conv_quad_interp3d.py
,scale_space_detector.py
)
- (see
ORIGINAL
is using Kornia directlyNOT_FIXED
's andORIGINAL
's results are close but not identical asNOT_FIXED
still contains fixes not related to the problem of the interpolation
- presents the problem in Kornia as in Kornia_DoG_H_estimation_OpenCV_API.ipynb
- uses numpy/OpenCV API for the actual homography estimation
- tests the fix in interpolation using Harris and Hessian detectors
- presents the problem in Kornia as in Kornia_DoG_H_estimation_OpenCV_API.ipynb
- uses torch/Kornia API for the actual homography estimation
- probably due to the Kornia API not being optimized the RANSAC params had to be relaxed
> conda create -n <env_name> python=3.9
> conda activate <env_name>
> conda install pip
> pip install -r requirements.txt
- while the respective environment is activated - build, setup and install as instructed at VSAC git-hub
- while the respective environment is activated - install as instructed at hloc git-hub