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

Metadrive sim #27892

Closed
wants to merge 12 commits into from
Closed

Metadrive sim #27892

wants to merge 12 commits into from

Conversation

MoreTore
Copy link
Contributor

@MoreTore MoreTore commented Apr 13, 2023

resolve #27284

pip install torch in order to engage (see onnx_runner.py).

After you build openpilot, run ./tools/streamer/launch_sim.sh

Press h on the game widow for control description.

I - ignition
E - Enable
T - Takeover (WASD control). Takeover is on by default so you need to press t to allow OP to drive.
up/down arrow - +/-5km/h cruise set point

This creates a simple simulator car port in openpilot. This uses wide + road camera. This makes it easy to tune and i guess it could also be easier to test new OP features without knowing the intricacies of the various brand ports. This uses metadrive game window for user input. Starts 2 new processes, streamer.py and gamerunner.py. Metadrive sends the games render window over zmq to the streamer.py where the frames are processed and sent to openpilot. I feel that this is the best way to do a simulator in openpilot as far as debugging and user experience goes but I am biased! I spent a good amount of time on this so your consideration is appreciated and I think its good alternative to the way the sim is currently handled in openpilot. I believe there is also a pathway forward to running this on comma 3 with some changes to the camerad function (PC runs the game and streams frames to C3).

@MoreTore MoreTore deleted the metadrive-sim branch December 12, 2024 23:17
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.

[$2,000 Bounty] High quality simulator entry point
2 participants