-
Notifications
You must be signed in to change notification settings - Fork 112
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
Add ONNX Model Export Support #306
Conversation
Thank you for pushing these! |
Conflict and syntax errors on python3.8 should be fixed. Also, support for the action mask was added in the ONNX export. EDIT: investigating test errors |
This reverts commit bc28dbc.
@alex-petrenko I think it's ready to get review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks amazing! 🔥
* support onnx export * add doc for onnx export * fix for action_mask * fix TypeError on python 3.8 * install onnx on ci for mac * add debug info * Revert "add debug info" This reverts commit bc28dbc. * fix tests
This PR introduces support for exporting trained models to the ONNX format in Sample Factory. The feature will be useful in many cases, including for people who want to use their trained models on a different platform or language. It's nice to build the functionality into Sample Factory, since usually, the underlying architecture is something that users don't need to know about.
It's implemented using TorchScript-based ONNX Exporter for now. I tried TorchDynamo as well but couldn’t get it to work.
The usage is described in the added documentation.