Repository navigation
Conversation
Build the PRM spatial index after planning and cover query equivalence, replanning and empty graphs. Benchmark real PRM and lattice graphs and document the pgraph periodic-angle failure that defers lattice indexing. Co-Authored-By: OpenAI Codex (GPT-6) <noreply@openai.com>
Not up to standards ⛔🔴 Issues
|
| Category | Results |
|---|---|
| Security | 1 medium |
🟢 Metrics 35 complexity · 0 duplication
Metric Results Complexity 35 Duplication 0
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #889 +/- ##
=====================================
Coverage 0.00% 0.00%
=====================================
Files 146 146
Lines 17295 17297 +2
=====================================
- Misses 17295 17297 +2 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This branch has not been deployed
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.
Summary
Follow up on the remaining roadmap-indexing item in #755 after #817 was merged.
PRMPlanner.plan()now builds pgraph's k-d tree once, after the roadmap is complete, to accelerate the two endpoint lookups inquery(). Empty roadmaps retain their existing query error. Roadmap construction and A* are unchanged.Add
examples/benchmark_roadmap.pyto compare complete queries, endpoint lookups and index construction on real PRM and lattice graphs. It alternates measurement order, checks paths and lattice costs, and reports index-construction failures separately from timings.Behaviour: nearest-vertex ties may select a different equally close vertex, and therefore a different route, than the previous scan. All sampled non-tied paths agreed exactly. The docstrings explain this and pgraph's coordinate-mutation/index-invalidation rules. No public signatures change.
Measurements and Lattice limitation
Windows, Python 3.12.14, NumPy 2.5.4, SciPy 1.18.1, spatialmath-python 1.1.18, pgraph-python 1.0.0. Medians of five repetitions, 20 fixed queries per repetition, seed 0; planning excluded. These are local measurements, not timing assertions.
Index construction pays for itself within one query in these cases. Reproduce with:
Automatic lattice indexing is deliberately deferred. With pgraph 1.0.0,
LatticePlanner().plan(iterations=5)already produces angles around-2.4492936e-16; wrapping them rounds to exactly2*pi, whichcKDTreerejects withValueError: Some input data are greater than the size of the periodic box.The 12-iteration benchmark (1,932 vertices) reproduces this. The script reportsindex_errorand leaves indexed timings unset. A four-iteration lattice (97 vertices) indexes successfully and its paths and costs agree. The lattice plan docstring records why its current scan is retained. This PR does not change pgraph or round lattice poses to hide that failure.Related issue
Refs #755, particularly #755 (comment). Leaving issue closure to the maintainer because the lattice dependency limitation remains.
Validation
test_graph_planners,test_mobile_planners_a,test_prm_constructor,test_planner_failure_contract,test_planner_cleanup,test_planner_unknown_keywords,test_planner_world_coordinates), with--timeout=50 --timeout_method=thread.mypy --platform linux: 165 source files passed. Native Windows mypy still reports six existing Unix-signal attribute errors in unchangedsymbolic_ik.py.git diff --checkpasses. Full test/platform matrix and Sphinx docs build were not run locally; Sphinx is not installed in this environment.Checklist
AI-assisted with OpenAI Codex (GPT-6).