Commit Graph

2 Commits

Author SHA1 Message Date
Paul Huliganga 0d1acf8cdc feat(exp24): road regeneration between segments + fix Car.cs raycast
exp24: reconnect to sim after each 10k-step checkpoint.  Reconnecting reloads
the scene → sdsandbox generates a new random road.  Each training segment and
each checkpoint eval now runs on a different road layout, preventing overfitting
to a single road and giving meaningful generalization metrics in the eval logs.

Car.cs: add a short forward raycast in FixedUpdate to detect barriers the front
wheels are pressing against.  WheelColliders do not fire OnCollisionEnter/Stay on
the car's MonoBehaviour, so nose-first barrier contact was invisible to Car.cs
collision callbacks.  The raycast fires when throttle > 0.05 and a collider is
within 0.8m forward — registers the collision the same way OnCollisionStay does.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-05 17:58:33 -04:00
Paul Huliganga 924615ca60 feat(exp24): discrete steering + speed-based stuck detection
StuckTerminationWrapper: add low_speed_threshold + max_low_speed_seconds params.
Car pinned against a barrier has speed≈0 even while sliding laterally — lateral
drift was resetting the position-based displacement timer, leaving the car stuck
for up to max_episode_seconds. Speed-based check terminates after 2s at speed<0.5.

Exp24: 7-bin discrete steering (DiscretizedActionWrapper) eliminates Gaussian policy
noise that caused rapid oscillation in exp23. max_episode_seconds reduced to 30s
since speed-based stuck detection now handles the barrier-contact cases.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-05 17:41:42 -04:00