Repository navigation
Keep GICP k-NN covariance preparation on GPU - #173
Merged
Merged
Conversation
rsasaki0109
changed the base branch from
codex/gpu-point-to-plane-reduction
to
main
October 13, 2026 00:05
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.
Depends on #172 (resident point-to-plane reductions); this PR contains only the GICP k-NN covariance slice.
GICP's existing GPU reduction path still prepares k-NN covariances on CPU and uploads the source-sized covariance arrays. Add
align_with_gpu_resident_covariancesandGpuGicpInput::upload_with_gpu_covariancesto compute bounded k-NN, centered/scaled sample covariance and plane eigenvectors on GPU, then retain those covariances for the existing equation/update loop. Original query/sample positions and target tree are reused; source-tree upload is counted. No neighborhood/covariance readback or covariance re-upload occurs.CPU tree construction, normalized 6x6 solve and world pose updates remain. The new path supports k=3..=64, epsilon as f32 in 1e-4..=1 and covariance_radius=None. Existing CPU/uploaded/radius paths retain their behavior. Malformed neighborhoods or unsupported arithmetic invalidate all covariance and equation payload (equation status bit 16); f32 products/eigenvectors can change results at small/repeated spectra, without CPU fallback.
Validation:
Full contracts, timing tables, transfers and precision limits.