feat(unitree_g1): make SONIC token interface implicit

Drop the ``sonic_token_action`` config flag; the 64-D latent-token
action/observation interface now switches on automatically whenever the
SONIC whole-body controller is selected (``controller == "SonicWholeBodyController"``).
Keyed via a ``_sonic_token`` property so client, onboard and sim roles agree.
This commit is contained in:
Martino Russi
2026-07-30 11:28:59 +02:00
parent 0c57cd03f2
commit bbfc4ff443
5 changed files with 39 additions and 51 deletions
+2 -3
View File
@@ -320,8 +320,8 @@ cd ~/lerobot
python src/lerobot/robots/unitree_g1/run_g1_server.py --handshake --camera
```
**From your laptop** — run the token policy; `--robot.sonic_token_action=true` switches the
robot to the 64-D latent-token action/observation interface:
**From your laptop** — run the token policy; selecting `--robot.controller=SonicWholeBodyController`
implicitly switches the robot to the 64-D latent-token action/observation interface:
```bash
lerobot-rollout \
@@ -331,7 +331,6 @@ lerobot-rollout \
--robot.is_simulation=false \
--robot.robot_ip=<ROBOT_IP> \
--robot.controller=SonicWholeBodyController \
--robot.sonic_token_action=true \
--robot.cameras='{"ego_view": {"type": "zmq", "server_address": "<ROBOT_IP>", "port": 5555, "camera_name": "head_camera", "width": 640, "height": 480, "fps": 30}}' \
--task="walk back and forth" \
--duration=1000 \