Skip to content

perf(metrics): bound parallel Chamfer and Hausdorff queries - #150

Merged
rsasaki0109 merged 1 commit into
mainfrom
codex/parallel-cloud-distances
Oct 12, 2026
Merged

rsasaki0109 merged 1 commit into
mainfrom
codex/parallel-cloud-distances

Conversation

@rsasaki0109

@rsasaki0109 rsasaki0109 commented Oct 12, 2026 •

Copy link
Copy Markdown
Owner

Chamfer/Hausdorff metrics previously queried and accumulated every point on the caller. metrics-distance now shares each target KD-tree across bounded scoped CPU workers, reuses a score window of at most 16,384 optional distances per worker and reuses each band's one-neighbor query buffer. Window joins precede original-order f64 accumulation, preserving exact metric words without regrouped worker sums. Small/one-worker directions retain the unchanged serial loop. Public signatures, metric definitions and empty/nonfinite behavior are preserved, with no dependency or device-transfer change.

Validation: 660 frozen f64 output words across staging thresholds, asymmetric clouds and forced 1/2/6 workers; independent asymmetric statistics/ties; a multi-window accumulation case that detects reassociation; NaN/None/infinity/empty behavior; renamed schema and concurrent calls. Eight native tests plus one facade smoke pass. Strict crate/facade Clippy, disabled-feature compilation, crate/facade WASM compilation, formatting and diff checks pass.

Completed two-direction API measurements include both KD-tree builds and use twelve conditions, two warmups and twenty rotating paired rounds. Final large-condition paired speedups are 1.14–1.85x, with all six intervals favoring public staging. The complete initial allocation-per-query survey and its adverse/uncertain controls are retained alongside the final survey. Small-input neutrality and fixed cross-machine speedups are not claimed. Optional-distance scratch is 128 KiB per worker on the measurement host; the two directions' windows are not live together.

Execution boundary and all measurements.

@rsasaki0109
rsasaki0109 changed the base branch from codex/parallel-iss-keypoints to main October 12, 2026 02:51
@rsasaki0109
rsasaki0109 merged commit 48df475 into main Oct 12, 2026
115 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant