openpi openpi holds open-source models and packages for robotics, published by the Physical Intelligence team. Currently, this repo contain…
openpi openpi holds open-source models and packages for robotics, published by the Physical Intelligence team. Currently, this repo contain…
openpi holds open-source models and packages for robotics, published by the Physical Intelligence team.
Currently, this repo contains three types of models:
For all models, we provide base model checkpoints, pre-trained on 10k+ hours of robot data, and examples for using them out of the box or fine-tuning them to your own datasets.
This is an experiment: $\pi_0$ was developed for our own robots, which differ from the widely used platforms such as ALOHA and DROID, and though we are optimistic that researchers and practitioners will be able to run creative new experiments adapting $\pi_0$ to their own platforms, we do not expect every such attempt to be successful. All this is to say: $\pi_0$ may or may not work for you, but you are welcome to try it and see!
openpi to train VLAs on the full DROID dataset. This is an approximate open-source implementation of the training pipeline used to train pi0-FAST-DROID.To run the models in this repository, you will need an NVIDIA GPU with at least the following specifications. These estimations assume a single GPU, but you can also use multiple GPUs with model parallelism to reduce per-GPU memory requirements by configuring fsdp_devices in the training config. Please also note that the current training script does not yet support multi-node training.
| Mode | Memory Required | Example GPU |
|---|---|---|
| Inference | > 8 GB | RTX 4090 |
| Fine-Tuning (LoRA) | > 22.5 GB | RTX 4090 |
| Fine-Tuning (Full) | > 70 GB | A100 (80GB) / H100 |
The repo has been tested with Ubuntu 22.04, we do not currently support other operating systems.
When cloning this repo, make sure to update submodules:
git clone --recurse-submodules [email protected]:Physical-Intelligence/openpi.git
# Or if you already cloned the repo:
git submodule update --init --recursiveWe use uv to manage Python dependencies. See the uv installation instructions to set it up. Once uv is installed, run the following to set up the environment:
GIT_LFS_SKIP_SMUDGE=1 uv sync
GIT_LFS_SKIP_SMUDGE=1 uv pip install -e .NOTE: GIT_LFS_SKIP_SMUDGE=1 is needed to pull LeRobot as a dependency.
Docker: As an alternative to uv installation, we provide instructions for installing openpi using Docker. If you encounter issues with your system setup, consider using Docker to simplify installation. See Docker Setup for more details.
We provide multiple base VLA model checkpoints. These checkpoints have been pre-trained on 10k+ hours of robot data, and can be used for fine-tuning.
| Model | Use Case | Description | Checkpoint Path |
|---|---|---|---|
| $\pi_0$ | Fine-Tuning | Base π₀ model for fine-tuning | gs://openpi-assets/checkpoints/pi0_base |
| $\pi_0$-FAST | Fine-Tuning | Base autoregressive π₀-FAST model for fine-tuning | gs://openpi-assets/checkpoints/pi0_fast_base |
| $\pi_{0.5}$ | Fine-Tuning | Base π₀.₅ model for fine-tuning | gs://openpi-assets/checkpoints/pi05_base |
We also provide "expert" checkpoints for various robot platforms and tasks. These models are fine-tuned from the base models above and intended to run directly on the target robot. These may or may not work on your particular robot. Since these checkpoints were fine-tuned on relatively small datasets collected with more widely available robots, such as ALOHA and the DROID Franka setup, they might not generalize to your particular setup, though we found some of these, especially the DROID checkpoint, to generalize quite broadly in practice.
| Model | Use Case | Description | Checkpoint Path |
|---|---|---|---|
| $\pi_0$-FAST-DROID | Inference | $\pi_0$-FAST model fine-tuned on the DROID dataset: can perform a wide range of simple table-top manipulation tasks 0-shot in new scenes on the DROID robot platform | gs://openpi-assets/checkpoints/pi0_fast_droid |
| $\pi_0$-DROID | Fine-Tuning | $\pi_0$ model fine-tuned on the DROID dataset: faster inference than $\pi_0$-FAST-DROID, but may not follow language commands as well | gs://openpi-assets/checkpoints/pi0_droid |
| $\pi_0$-ALOHA-towel | Inference | $\pi_0$ model fine-tuned on internal ALOHA data: can fold diverse towels 0-shot on ALOHA robot platforms | gs://openpi-assets/checkpoints/pi0_aloha_towel |
| $\pi_0$-ALOHA-tupperware | Inference | $\pi_0$ model fine-tuned on internal ALOHA data: can unpack food from a tupperware container | gs://openpi-assets/checkpoints/pi0_aloha_tupperware |
| $\pi_0$-ALOHA-pen-uncap | Inference | $\pi_0$ model fine-tuned on public ALOHA data: can uncap a pen | gs://openpi-assets/checkpoints/pi0_aloha_pen_uncap |
| $\pi_{0.5}$-LIBERO | Inference | $\pi_{0.5}$ model fine-tuned for the LIBERO benchmark: gets state-of-the-art performance (see LIBERO README) | gs://openpi-assets/checkpoints/pi05_libero |
| $\pi_{0.5}$-DROID | Inference / Fine-Tuning | $\pi_{0.5}$ model fine-tuned on the DROID dataset with knowledge insulation: fast inference and good language-following | gs://openpi-assets/checkpoints/pi05_droid |
By default, checkpoints are automatically downloaded from gs://openpi-assets and are cached in ~/.cache/openpi when needed. You can overwrite the download path by setting the OPENPI_DATA_HOME environment variable.
Our pre-trained model checkpoints can be run with a few lines of code (here our $\pi_0$-FAST-DROID model):
from openpi.training import config as _config
from openpi.policies import policy_config
from openpi.shared import download
config = _config.get_config("pi05_droid")
checkpoint_dir = download.maybe_download("gs://openpi-assets/checkpoints/pi05_droid")
# Create a trained policy.
policy = policy_config.create_trained_policy(config, checkpoint_dir)
# Run inference on a dummy example.
example = {
"observation/exterior_image_1_left": ...,
"observation/wrist_image_left": ...,
...
"prompt": "pick up the fork"
}
action_chunk = policy.infer(example)["actions"]You can also test this out in the example notebook.
We provide detailed step-by-step examples for running inference of our pre-trained checkpoints on DROID and ALOHA robots.
Remote Inference: We provide examples and code for running inference of our models remotely: the model can run on a different server and stream actions to the robot via a websocket connection. This makes it easy to use more powerful GPUs off-robot and keep robot and policy environments separate.
Test inference without a robot: We provide a script for testing inference without a robot. This script will generate a random observation and run inference with the model. See here for more details.
We will fine-tune the $\pi_{0.5}$ model on the LIBERO dataset as a running example for how to fine-tune a base model on your own data. We will explain three steps:
We provide a minimal example script for converting LIBERO data to a LeRobot dataset in examples/libero/convert_libero_data_to_lerobot.py. You can easily modify it to convert your own data! You can download the raw LIBERO dataset from here, and run the script with:
uv run examples/libero/convert_libero_data_to_lerobot.py --data_dir /path/to/your/libero/dataNote: If you just want to fine-tune on LIBERO, you can skip this step, because our LIBERO fine-tuning configs point to a pre-converted LIBERO dataset. This step is merely an example that you can adapt to your own data.
To fine-tune a base model on your own data, you need to define configs for data processing and training. We provide example configs with detailed comments for LIBERO below, which you can modify for your own dataset:
LiberoInputs and LiberoOutputs: Defines the data mapping from the LIBERO environment to the model and vice versa. Will be used for both, training and inference.LeRobotLiberoDataConfig: Defines how to process raw LIBERO data from LeRobot dataset for training.TrainConfig: Defines fine-tuning hyperparamExclude frozen parameters from EMA state when freeze_filter is set
pi0-FAST reaches ~85% on LIBERO-10 with a config-only fine-tuning change, up from the widely cited 60.2% baseline
serve_policy exposes the websocket policy server on 0.0.0.0 with no --host flag and returns tracebacks to the client
[Feature Proposal] Add LoRA training support for pi0.5 (PyTorch backend)
scripts/train_pytorch.py debug crashes: image layout conversion is gated on uint8, and the vision projection width is hardcoded
Why is extra_delta_action=True in 'pi0_libero' config?
websocket_policy_server sets max_size=None, allowing unbounded message size (resource-exhaustion DoS)
Request: support non-root user execution in Docker container
no error train stop? wandb crashed, The run stopped sending data or did not successfully start.
Feature: add a read-only normalization compatibility report