Principle:Kornia Kornia Geometric Verification
| Knowledge Sources | |
|---|---|
| Domains | Vision, Geometry, Robust_Estimation |
| Last Updated | 2026-02-09 15:00 GMT |
Overview
Technique of robustly estimating geometric models (homographies, fundamental matrices) from noisy feature correspondences while identifying inliers and outliers.
Description
Feature matching inevitably produces outlier (incorrect) correspondences. RANSAC (Random Sample Consensus) robustly estimates a geometric model by: (1) randomly sampling minimal sets of correspondences, (2) fitting a model (e.g., homography from 4 point pairs), (3) scoring the model by counting inlier correspondences (within distance threshold), (4) iterating to find the best model. Local optimization refines the best model using all inliers. The algorithm outputs both the estimated model and an inlier mask for downstream use.
Usage
Use after feature matching to filter outlier matches and estimate geometric transformations between images. Essential for image stitching, visual localization, and multi-view geometry.
Theoretical Basis
RANSAC algorithm:
For i in 1..max_iter:
- Sample
minimal_sample_sizepoints. - Fit model
M_i. - Count inliers:
|{j : error(M_i, (p1_j, p2_j)) < threshold}|. - If best, polish with all inliers.
- Early stop if confidence reached:
k = log(1 - p) / log(1 - (w^n)), wherew = inlier_ratio,n = sample_size,p = confidence.