Skip to content

Conversation

@mhpanah
Copy link

@mhpanah mhpanah commented Nov 3, 2025

This PR adds a new tutorial notebook act_to_openvino.ipynb that demonstrates converting a Unitree Action Chunking Transformer (ACT) policy (from the LeRobot format) into OpenVINO IR (FP32). It walks through dependency verification, checkpoint preparation, ONNX export, OpenVINO Model Optimizer invocation, and artifact validation.

Conversion Flow

  1. Verify dependencies (torch, openvino, nncf, etc.).
  2. Confirm presence of LeRobot
  3. Load and reconstruct model (feature wrapping + config filtering).
  4. Build ordered dummy inputs matching model signature.
  5. Export ONNX
  6. Run Model Optimizer to generate FP32 IR.
  7. Confirm IR artifacts exist and report sizes.

Core Dependencies:

  • openvino-dev[pot]>=2024.4.0
  • torch>=2.1, torchvision, accelerate
  • nncf>=2.14.0 (future quantization integration)
  • safetensors, onnx, onnxruntime
  • Utility: numpy, pandas, matplotlib, tqdm, h5py, rich

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@@ -0,0 +1,598 @@
{
Copy link
Collaborator

@openvino-dev-samples openvino-dev-samples Nov 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line #1.    # Export ACT Model to ONNX

Can we skip this step, and convert it to OV IR directly ?https://docs.openvino.ai/2025/openvino-workflow/model-preparation/convert-model-pytorch.html


Reply via ReviewNB

@@ -0,0 +1,598 @@
{
Copy link
Collaborator

@openvino-dev-samples openvino-dev-samples Nov 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we need an example to teach developer how to deploy this IR with OpenVINO


Reply via ReviewNB


ENV_NAME="unitree_lerobot"
LEROBOT_DIR="unitree_IL_lerobot"
PY_VERSION="3.10"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why should we limit the version of python and force developer to use Conda.
For user experience, a notebook should be run across different OS and python virtual environment.

python -m pip install --upgrade pip wheel setuptools
}

install_openvino_requirements() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please, add link to the quide https://github.com/openvinotoolkit/openvino_notebooks/blob/latest/README.md#-installation-guide to the README instead of processing it here

@@ -0,0 +1,598 @@
{
Copy link
Collaborator

@sbalandi sbalandi Nov 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line #38.    def pip_install(*packages):

we have such function in utils, please, check example in Prerequisites here https://github.com/openvinotoolkit/openvino_notebooks/blob/latest/notebooks/llm-native-agent-react/llm-native-agent-react.ipynb and use it


Reply via ReviewNB

@@ -0,0 +1,598 @@
{
Copy link
Collaborator

@sbalandi sbalandi Nov 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where model.safetensors are originally placed ? On which step and from where should we download it ?


Reply via ReviewNB

@@ -0,0 +1,598 @@
{
Copy link
Collaborator

@sbalandi sbalandi Nov 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to load the model directly into act_checkpoint ?


Reply via ReviewNB

@@ -0,0 +1,598 @@
{
Copy link
Collaborator

@sbalandi sbalandi Nov 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mo is deprecated, could you please convert model via ov.convert_model(model) https://docs.openvino.ai/2025/openvino-workflow/model-preparation/convert-model-pytorch.html ?


Reply via ReviewNB

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.

3 participants