Add kinematic wall follower for high-fidelity LiDAR simulation - #29
Merged
Conversation
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…llower RUF100: remove now-unused `# noqa: E402` comments (E402 isn't in ruff 0.16.0's default rule set, unlike the 0.15.x used locally during development). I001: split two `from neoracer_mujoco import a, b as c` statements into separate import lines. RUF046: drop a redundant `int(...)` around `round(...)`, which already returns int with no ndigits argument -- behaviorally identical. No controller logic, trajectory planning, collision checking, steering, speed scheduling, or state-machine behavior changed. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
bmabsout
reviewed
Aug 30, 2026
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XXPAdTCDL5V3JL3FsPWLqi
Collaborator
Author
|
While addressing review feedback, found that Fixed without touching Reran the full N=1080 Stage D validation from a clean checkout: 100/100 success, 0 stuck, 0 rollovers, 0 contacts. All 123 validation tests pass. |
Aeh961
marked this pull request as ready for review
September 2, 2026 22:25
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 a vehicle-space wall-following controller for NeoRacer MuJoCo that supports dense, high-fidelity LiDAR input while planning physically achievable steering trajectories.
This work remains separate from the racecar_core adapter work and does not modify the canonical Ultimate Wall Follower.
Motivation
Testing against a higher-fidelity Lakibeam L1-style LiDAR model exposed limitations in the earlier wall-following approach.
Target sensor configuration:
The previous approach treated LiDAR directions too directly as steering candidates. At high resolution this created resolution-dependent behavior and caused the vehicle to commit to some turns too late, resulting in wall contact or wedging.
Approach
The new controller separates sensor resolution from vehicle actions.
Dense LiDAR measurements are converted into obstacle geometry while the planner evaluates a fixed set of physically achievable steering trajectories based on the NeoRacer vehicle model.
The trajectory model uses:
This allows the planner to account for the car's actual turning radius instead of assuming the vehicle can immediately travel along an arbitrary LiDAR heading.
Validation
The frozen controller was validated on
loop_corridor.xmlusing the 1080-point LiDAR configuration.100 randomized full-lap trials
Lap time from the original published Stage D run:
Brief
NO_PATHstates occurred in many trials near the first-corner entry, but all self-recovered and none caused contact or failure.After Bassel's review cleanup and the reproducibility fixes, the full N=1080 Stage D validation was rerun and again achieved:
The controller itself was not changed.
Reproducibility
During review cleanup, the loop validation harness was found to depend on
load_scene(track)behavior andloop_corridor.xmlfrom an unmerged experimental branch.PR #29 is now self-contained:
scene_utils.pycontains the required track-loading/spawn logicassets/tracks/loop_corridor.xmlis included as the exact byte-identical asset used by the validated runs(0.0, -2.5, 0.0)vehicle_space_controller.pyandrun_racecar_core.pyremain untouched.Performance
Across the original Stage D run:
The post-review rerun showed the same controller behavior; small wall-clock timing differences were consistent with machine/runtime variability rather than a change in the controller.
Review cleanup
Bassel's review feedback was addressed by:
.pklignore rulemath_utils.pyreport_utils.pyAll 8 review threads are resolved.
Checks
pytest validation/: 123 passedruff check .: cleanruff format --check .: cleanScope
This PR does not modify:
vehicle_space_controller.pyafter Stage D validationrun_racecar_core.py🤖 Generated with Claude Code
https://claude.ai/code/session_01XXPAdTCDL5V3JL3FsPWLqi