Repository navigation
ICP covariance matrix and Monte Carlo ICP uncertainty - #667
Merged
Merged
Conversation
- PairWiseICP / PoseGraphLoopClosure::compute_icp_uncertainty return the sigmas together with IcpResidualStatistics, which now carries the pose covariance sigma0^2 * (J^T J)^-1. - PairWiseICP::compute_icp_montecarlo runs ICP from randomly perturbed start poses (fixed seed) and returns the spread of the results (IcpSpread); PoseGraphLoopClosure::compute_icp_montecarlo runs it on an edge. - PairWiseICP::verbose (default true) silences the per-iteration log. - Step 2 loop closure GUI: an "uncertainty method" dropdown (point-to-point, point-to-plane, ICP Monte Carlo) with one Calculate button; shows the result tables and the 6x6 covariance in mm and degrees. The active edge's translation ellipsoid is drawn for the shown result (yellow: point-to-point/ plane at the current pose; magenta: Monte Carlo at the mean result). - session_uncertainty_calculation: new options --method, --search-radius, --runs, --start-offset-m, --start-offset-deg, --node-step, --decimation, --tls-decimation; the TLS is cropped to each chunk; one progress line per node with ETA. Defaults keep the previous results. The CSV gains the upper triangle of the pose covariance (cov_px_px ... cov_ka_ka) as extra columns. - scripts/plot_session_uncertainty.py plots that CSV: trajectory top view coloured by position sigma with x-y covariance ellipses, and the pose sigmas over time. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: MichalPelka <michalpelka@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I've implemented naive, way to find uncertainty using random perturbation of solution.
We challenge optimized ICP solution with random perturbation, and we rerun ICP.
If solution is true sharp global minimum, it will converge again, if not it will stay for this dimension.
To find covariance, we can compute covariance of resulting samples.
I've tested it against https://huggingface.co/datasets/MichalPelka/UndegroundParkingDataset
Agentic summary: