Package to connect with OpenRacer application.
Project description
OpenRacer
Overview
The OpenRacer WebSocket interface facilitates communication between the Unity-based simulator and Python-based machine learning models. The simulator sends input data for each frame, and the ML model processes it before sending a response back.
This package provides a server interface that manages WebSocket connections and ensures seamless real-time data exchange.
Installation
pip install OpenRacer
Usage
Creating a Custom Model
To integrate an ML model, create a class that inherits from ModelBase in the OpenRacer package and implement following methonds
preProcess(optional) : used for processing input before passing totrainEvalortestEvaltrainEval: will be called each frame for trainingtestEval: will be called each frame for testing/Race/evalrewardFn: will be called in each eval to monitor model performancebackprop: will be called for each step in training. Use this to update model based on eval.
from OpenRacer.Model import ModelBase
class MyModel(ModelBase):
# implement the required functions
Starting the Interface
The Interface is responsible for handling connections between the simulator and the ML model and Dashboard.
from OpenRacer.Interface import Interface
# Create and start the server
Interface(model=modelInterface).start()
API Reference
Will be updated in some time
Notes
- Ensure that the WebSocket server is running before launching the simulator.
License
This package is open-source under the MIT License.
Contributing
Contributions are welcome! Feel free to submit issues or pull requests on GitHub.
Contact
For questions, reach out to the OpenRacer team via GitHub.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file openracer-0.6.6.tar.gz.
File metadata
- Download URL: openracer-0.6.6.tar.gz
- Upload date:
- Size: 918.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.7.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b801e40238a4b1fc725b19b1ad731e45d4ca0d0c9455156d8ae9a68d72005ab3
|
|
| MD5 |
99124452c926eca583a7a648bbddfdf7
|
|
| BLAKE2b-256 |
9fcaa8d595bf27e47bcc9890de06aec5177ca39897a19b7d20f119cddab51a36
|
File details
Details for the file openracer-0.6.6-py3-none-any.whl.
File metadata
- Download URL: openracer-0.6.6-py3-none-any.whl
- Upload date:
- Size: 948.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.7.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3861a2336373cecb3c77e719af104fdbbfc491a1720f4671d9a85091ab6e441f
|
|
| MD5 |
79110afa612d5d1735212c63d5a9162a
|
|
| BLAKE2b-256 |
b031a0508694ea287086b83ae20fb8b1a3f93889de2bdaa2443b114f3332df87
|