Quick Start
Deployment Sources
rfx supports three ways to load policies:1. Saved Checkpoints
Load from a local directory containingrfx_config.json and weights:
2. HuggingFace Hub
Load directly from Hub using thehf:// prefix:
snapshot_download.
3. Python Functions
Deploy a policy function directly from a.py file:
Python API
Therfx.deploy() function provides full programmatic control:
Robot Configuration
rfx resolves the robot configuration automatically:Bundled config (recommended)
If the policy was saved with
robot_config=..., it’s loaded automatically:Built-in Robot Types
| Robot Type | Description | Interface |
|---|---|---|
so101 | SO-101 6-DOF arm | USB serial |
go2 | Unitree Go2 quadruped | Ethernet (Zenoh) |
g1 | Unitree G1 humanoid | Ethernet (Zenoh) |
innate | Innate robot | Custom |
Deployment Options
Control Loop Frequency
Set the control rate in Hz:control_freq_hz.
Timed Runs
Run for a specific duration:--duration, the policy runs until you press Ctrl+C.
Hardware Overrides
Override the robot’s port or IP address:Mock Deployment
Test without hardware usingMockRobot:
- Testing policy loading
- Verifying control loop timing
- CI/CD pipelines
- Development without hardware access
Loading Policies
Use the lower-levelrfx.load_policy() API for inspection or custom deployment:
Policy Inspection
Quickly inspect a saved policy without loading weights:Self-Describing Models
Every rfx policy is a self-describing directory:Deployment Statistics
After deployment, inspect timing and performance:Custom Deployment Loops
For advanced use cases, build your own deployment loop:Graceful Shutdown
The deploy command handles Ctrl+C gracefully:- First Ctrl+C: Stops the control loop cleanly
- Second Ctrl+C: Force exits immediately
Best Practices
Test in Mock Mode First
Test in Mock Mode First
Always verify deployment works with
--mock before connecting to real hardware.Monitor Jitter
Monitor Jitter
Check P99 jitter after deployment. High jitter (>10ms for 50Hz) indicates the policy is too slow or the system is overloaded.
Use Warmup Time
Use Warmup Time
The default 0.5s warmup allows the robot to stabilize after reset. Increase for heavier robots.
Start Slow
Start Slow
Begin with short durations (10-30s) to verify behavior before long runs.
Troubleshooting
Cannot determine robot type
Cannot determine robot type
Either pass
--robot, --config, or ensure the policy was saved with robot_config=....High jitter / overruns
High jitter / overruns
- Reduce
--rate-hz - Use a faster device (
--device cuda) - Simplify the policy architecture
- Check system load (close other applications)
Connection failed
Connection failed
- Verify hardware is powered and connected
- Check
--portmatches actual device - For Go2/G1, verify network connectivity with
ping <robot-ip>
Next Steps
Hub Integration
Push your policies to HuggingFace Hub for easy sharing
Collect Demos
Record more demonstrations to improve your policy
