Skip to content

perf(collision): certify collision-free motion intervals - #86

Open
HiroIshida wants to merge 10 commits into
masterfrom
hi/perf/certificate
Open

HiroIshida wants to merge 10 commits into
masterfrom
hi/perf/certificate

Conversation

@HiroIshida

Copy link
Copy Markdown
Owner

No description provided.

@HiroIshida
HiroIshida force-pushed the hi/perf/certificate branch 3 times, most recently from 3bb59f6 to 3b64f29 Compare September 26, 2026 18:36
Use URDF-derived motion bounds and analytic primitive clearance to skip covered discrete motion samples. Preserve sample order and logical query counts, and fall back to point checks when certification is unavailable.

Keep the feature behind PLAINMP_ENABLE_INTERVAL_PRUNING, disabled by default. Include the scalar input and floating-point predicate fixes needed by the certificate path.
Eligible motions previously prepared movement bounds and attempted a
certificate before checking whether the endpoint or midpoint collided.
This pays certificate overhead even for motions that can be rejected by
one or two ordinary point queries.

Check the endpoint and the first interior sample (near the midpoint) with
ordinary validity queries before preparing certificates. If both pass,
attempt certificates at the remaining samples in the original order.
Resume after the probes when preparation is unsupported, avoiding repeated
queries. Motions with no remaining samples require no certificate setup;
very long motions retain the existing ordinary validation path.

Preserve the discrete query set, logical query budget, and final kinematic
state, including restoration when the last sample is skipped. Keep the
existing movement-bound coefficients and interval radii; this change
defers certificate work and does not introduce posture-dependent bounds.
Interval pruning remains opt-in via enable_interval_pruning.

Update coverage and query-count tests for the two ordinary probes. Add
regressions for early collisions avoiding preparation, unsupported
preparation continuing without duplicate queries, later collisions, and
short/long motions with a zero certificate threshold.

Validation:
- Incremental _plainmp build, linked into .venv.
- C++ certificate and motion-validator tests: 21 passed.
- Python certificate integration tests: 3 passed.
- Python OMPL solver tests: 25 passed.

Local planning benchmark: euclidean validation, resolution 1/20 (0.05),
certificate threshold 16, seed 456, 50 warmup solves and 2,000 measured
solves per condition. Each process used the same CPU, with sequential
OFF / new / old runs. Median planning times in milliseconds:

                   OFF       Old       New       Reduction vs old
Fetch              0.739     0.628     0.618       1.5%
Panda easy         0.230     0.207     0.200       3.6%
Panda difficult    0.852     0.870     0.805       7.5%

All three modes produced identical trajectory and logical query-count
hashes for each scene. Timings are a single local benchmark run, not a
statistical guarantee.
Turn on interval pruning for newly constructed C++ ValidatorConfig and
Python OMPLSolverConfig instances, and for simplify_path calls that omit
the option. Keep enable_interval_pruning=False as an explicit opt-out.
Certificates still apply only to supported SphereCollisionCst motions,
with the existing minimum test count of 16.

Check the new defaults in C++ and Python tests, and update the existing
runtime-option README and simplify_path parameter description.

Validation: incrementally built and linked _plainmp; all 21 C++
certificate tests and all 29 Python certificate/OMPL tests passed.
One unseeded KPIECE replan-count assertion failed in the initial run;
the targeted test and full Python rerun both 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