Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

puffer_enduro racing env initial pr #130

Open
wants to merge 46 commits into
base: dev
Choose a base branch
from
Open

Conversation

xinpw8
Copy link
Contributor

@xinpw8 xinpw8 commented Nov 30, 2024

Completed as discussed.

xinpw8 and others added 30 commits October 16, 2024 00:31
…e --vec native hangs on the cython call to the c env step. and continues to do so. added a ton of useless prints, though.
…cars now spawn in center(ish) of road, staying in their respective spawn lanes (0-2). TODO: collision is broken. Fix collision (speed decrease no longer applied??).
…roperly offset, TODO: make collision drift logic work, add collisions with road edges, player y loc start->end scale, improve road edge wiggle, clip cars to visible area without removing them, add scenery, add day/night, add winter, acceleration scaling, ascertain exact atari enemy car spawn freq per each day, ascertain lane choice per atari original, twisting road logic, twisting road render, implement RL, make sure it trains.
… largely accurate, but road is turning wrong way for L vs R.
…ific rendering details itemized. none of it is properly implemented yet.
…sorry ray-san), rendering logic implemented into enduro_clone.h, quadratic bezier updated and control points modified to smooth out sides of road, scoreboard and background now all render properly with cars racing, left, right, and straight roads all work.
… move in tandem, anti player car movement.
…12, 62, 113; mid: 35, 86, 136; right: 60, 110, 161. this is added onto vanishing point offset during curves..left curve dosen't quite work right. right curve looks great.
…, player car png transparent, wheels animation, day/winter/night/dawn cycle added w/ timings, original player car sprite
…, down, fireleft, fireright, downleft, downright), fixed enemy car spawning logic to match original when player speed <0
…ooth transitions from curve to straight to curve, mostly fixed janky init, collected some accel logic from og enduro, some playtesting
…transition to player speed. need t otune player speed so it matches og env.
…djustments based on distance from road edge, 0.25f good value for env->player_x drift adjustment
…interval, drift direction tested, night and fog rendering implemented, background update logic moved to step(), tuned player acceleration to match original game.
… speed: Day 1: 90 cars/min; Day 2: 166 cars/min; Day 3: 111 cars/min; spawn frequency varies from min to this max depending on player speed, top spawn lane choice logic per atari original, terminal logic for defeat and victory, play testing.
…d color of snow stage updated, post-crash speed fixed, snow handling implemented, several acceleration vars tuned
xinpw8 and others added 16 commits November 16, 2024 07:33
…need to find coherent policy as it doesn't properly train. possibly have bad observations...
…s, like player vs enemy speed, curve transitions, some other stuff that i already fixed...rip
…ly..compiles locally w/ ./build_ocean.sh puffer_enduro local at least.
…ightly changed TODOs to do. still need to engineer a policy that actually trains. but everything runs again with env and gameState separated. also massive debugging added w/ debugging compile mode.
…cally; tried to train a policy but it thus far has not worked..added many more TODOs to get ready for pufferlib 1.1
…hmetic high jinks Speed out of range: 7.528630 (min: -2.500000, max: 7.500000). of note: it now properly trains, passes cars, evalsgit add pufferlib/environments/ocean/puffer_enduro/
 w/ types. some other things cleaned up. collision bug is fixed. inv
uln is removed as well. player and enemy car collision boundary boxe
s added for rendering clarity. a new reward added that effectively spreads out reward from isolated within a single passed car step to be stepwise; reward ends if player collides with wall or car and doesn't resume until player passes another car. add_enemy_car logic reworked to make sure enemies never spawn behind player if player is going slower than them. now passes cars with rapidity, achieving day completions briskly. still probably needs some tuning.
…model_000400.pt added to resources/trained_models/puffer_enduro-afda4b76-beats_day_1
… tweaked L/R movement speed of player car. Added curving road at random, for random duration. Cleaned up code. Fixed car passing logic so it increments carsToPass when car passes player. Day 2 crashes fixed? Agent can learn on curvy and straight roads. Lots of comments edited/removed. Most debug prints removed.
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