Almost every batch estimation problem in robotics is
a sum of squared residuals weighted by their covariances. Maximum likelihood under Gaussian noise gives exactly this, which is where the squares come from — and also where their fragility comes from, since a Gaussian assigns vanishing probability to large errors and therefore an enormous cost to explaining one.
Linearise and the minimiser of the linearised problem solves the normal equations
The matrix on the left is the information matrix of the estimate. The same object as in the filter, arrived at from the optimisation side.
Robust kernels address a different failure. One wrong data association produces a residual of a hundred pixels; squared, it dominates the sum, and the optimiser distorts the entire solution to reduce it. A robust kernel grows sub-quadratically — Huber is quadratic near zero and linear beyond a threshold — so a large residual contributes a bounded gradient.
The implementation is one line in an IRLS loop: multiply each residual's information by and re-solve. For Huber, inside the band and outside. So a robust kernel is literally down-weighting suspicious measurements, and is the statement "residuals beyond this are probably not noise".
Your bundle adjustment converges to a low cost but the reconstruction is visibly wrong. What are the two most likely explanations?
Show answer
First, a local minimum: the initialisation was poor, and the linearised model was only ever valid in a basin containing the wrong answer. Low cost is not evidence of global optimality; nothing in Gauss–Newton offers that.
Second, outliers accepted as inliers: if wrong correspondences were fitted rather than down-weighted, the optimiser found a consistent explanation for inconsistent data. Check the residual histogram — a clean fit has a roughly Gaussian bulk, and a heavy tail means the kernel threshold was set too loosely, or was not applied at all.