Orchestra-Research/AI-Research-SKILLs / 18-multimodal/openpi
fine-tuning-serving-openpi
VerifiedFine-tune and serve Physical Intelligence OpenPI models (pi0, pi0-fast, pi0.5) using JAX or PyTorch backends for robot policy inference across ALOHA, DROID, and LIBERO environments. Use when adapting pi0 models to custom datasets, converting JAX checkpoints to PyTorch, running policy inference servers, or debugging norm stats and GPU memory issues.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 13.9 KB |
| references/checkpoints-and-env-map.md | markdown | 2.5 KB |
| references/config-recipes.md | markdown | 1.7 KB |
| references/pytorch-gotchas.md | markdown | 1.4 KB |
| references/remote-client-pattern.md | markdown | 1.2 KB |
| references/training-debugging.md | markdown | 1.2 KB |
references/training-debugging.md
View on GitHub# Training Debugging
Use this quick loop during iteration:
1. Confirm config exists and resolves: `src/openpi/training/config.py`.
2. Recompute norm stats after transform or dataset changes.
3. Run short training smoke test.
4. Serve a recent checkpoint and run inference sanity check.
## Common failures and fixes
**Issue: `Config '<name>' not found`**
Fix: use exact config name from `_CONFIGS` in `src/openpi/training/config.py`.
**Issue: Missing normalization stats**
Fix: run `uv run scripts/compute_norm_stats.py --config-name <name>` before training.
**Issue: OOM on JAX startup or training**
Fix:
- Set `XLA_PYTHON_CLIENT_MEM_FRACTION=0.9`
- Lower batch size
- Use `fsdp_devices` for model sharding
**Issue: No progress after resume request**
Fix: ensure checkpoint directory exists and includes numeric step folders.
**Issue: Incompatible resume and overwrite settings**
Fix: do not set both simultaneously.
## Validation commands
```bash
# Quick serve validation
uv run scripts/serve_policy.py policy:checkpoint \
--policy.config=<config_name> \
--policy.dir=checkpoints/<config_name>/<exp_name>/<step>
# Quick client test
uv run examples/simple_client/main.py --env DROID
```
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| receiving-code-reviewobra/superpowersUse when receiving code review feedback, before implementing suggestions, especially if feedback seems unclear or technically questionable - requires technical rigor and verification, not performative agreement or blind implementation | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| requesting-code-reviewobra/superpowersUse when completing tasks, implementing major features, or before merging to verify work meets requirements | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| using-git-worktreesobra/superpowersUse when starting feature work that needs isolation from current workspace or before executing implementation plans - ensures an isolated workspace exists via native tools or git worktree fallback | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| verification-before-completionobra/superpowersUse when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |