Add regression tests for lap S-crossover, lattice boundaries, and collision precompute glue - #25
Draft
cursor[bot] wants to merge 1 commit into
Draft
Add regression tests for lap S-crossover, lattice boundaries, and collision precompute glue#25cursor[bot] wants to merge 1 commit into
cursor[bot] wants to merge 1 commit into
Conversation
…lision precompute glue. Cover race lap detection via track_end_s, Lattice._check_boundary_violation clearance rules, generate_lattice_from_nodes obstacle_polygons plumbing, and Frenet orientation composition on the cursor segment. Co-authored-by: Majid Khonji <majid-khonji@users.noreply.github.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.
Summary
Adds focused regression coverage for high-risk planning/tracker paths left thinly tested after recent closed-loop
track_end_s/ lattice work. Complements (does not duplicate) open drafts #17/#20/#22/#23/#24.Risky behavior now covered
LocalPlanningStrategy.step): lap increments only when previoussis past0.8 * track_end_sand newsis near start; does not treat the stalepath_s[-2]band as near-end; mid-track andrace_mode=Falsedo not incrementLattice._check_boundary_violation: left(+)/right(−) boundary convention with clearance inset; missing parent Frenet path returns Falsegenerate_lattice_from_nodeshot-path glue: with agents, everycheck_collisioncall receives precomputedobstacle_polygons; without agents the kwarg staysNoneconvert_sd_orientation_to_xy_orientation: world yaw = Frenet theta + heading of the cursorcurrent_wp→next_wpsegmentTest files added/updated
test/c20_planning/test_c23_local_planning_pipeline.pytest/c20_planning/test_c28_local_lattice_planners.pytest/c50_common/test_c54_trajectory_waypoint_update.pyWhy these tests materially reduce regression risk
Lap counting and lattice feasibility gate race sessions and overtaking. Silently reverting to
path_s[-2], weakening boundary clearance, or dropping precomputed polygons would mis-count laps, accept off-road edges, or fall back to the slow collision path with different CV-sweep semantics. Orientation composition feeds spawn/teleport helpers that already depend on in-boundsnext_wp.Validation
All 59 tests passed. No production code changes.