You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
uv run python -m vlagents start-server lerobot --port 20000 --host 0.0.0.0 --kwargs '{"policy_name": "act", "checkpoint_path": "<path to pretrained_model>"}'
22
21
```
23
22
24
23
For other policies such as `pi05` or `xvla`, use the matching startup command from the `vlagents` README and make sure the values in `franka.json` point at that server.
@@ -31,12 +30,13 @@ For other policies such as `pi05` or `xvla`, use the matching startup command fr
31
30
-`vlagents_port`: Port exposed by the policy server.
32
31
-`vlagents_model`: Agent id passed to `vlagents`, for example `lerobot`.
33
32
-`instruction`: Natural-language task instruction sent to the policy on reset.
34
-
-`robot_keys`: Robot ordering used to pack observations and unpack actions. The script assumes one 8-value action block perrobot in this order: `7` joint values plus `1` gripper value.
33
+
-`robot_keys`: Robot names expected in each returned action dictionary and used to construct per-robot observations.
35
34
-`jpeg_encoding`: Whether observations are sent to the policy server using JPEG-compressed images.
36
35
-`on_same_machine`: Set this according to whether the policy server runs on the same machine as the control process.
36
+
-`image_size`: Client-side `(width, height)` resize applied before JPEG or shared-memory transport; defaults to `[224, 224]`. Set it to `null` to retain native resolution.
37
37
-`fps`: Control loop target frequency used by the local rate limiter.
38
38
-`record_path`: Output directory used when recording episodes.
39
-
-`n_action_steps`: If `null`, the script requests one action per control step. If set to an integer greater than `0`, the script buffers that many actions from each policy response chunk.
39
+
-`n_action_steps`: Local action-chunk execution horizon. If `null`, the script requests and executes one action per control step. If set to a positive integer, it buffers up to that many actions from each policy response chunk.
40
40
-`max_rel_mov_joints`: Maximum allowed relative joint movement per step when running in joint control mode.
41
41
-`max_rel_mov_cart`: Maximum allowed relative Cartesian translation and rotation per step when running in Cartesian modes.
42
42
@@ -57,23 +57,17 @@ When [franka.py](franka.py) is running, it waits for keyboard input on stdin. Th
57
57
58
58
The script translates RCS observations to the `vlagents``Obs` format as follows:
59
59
60
-
-Every camera frame in `obs["frames"]` is converted to RGB and resized to `224x224`.
61
-
-State is built by iterating through `robot_keys` in order and concatenating each robot's `joints` and `gripper` values.
60
+
-Camera frames are passed to `RemoteAgent` at native resolution; the client resizes them to `image_size` before JPEG or shared-memory transport.
61
+
-Each robot gets a `SingleObs` containing the shared camera set plus its own joints and gripper state.
62
62
63
-
Action decoding is also order-dependent:
64
-
65
-
- For each robot in `robot_keys`, the script reads `8` values from the policy action vector.
66
-
- Values `0:7` become the robot joint command.
67
-
- Value `7:8` becomes the robot gripper command.
68
-
69
-
That means `robot_keys` must match the policy's expected robot ordering exactly.
63
+
Action chunks contain one action dictionary per environment step. For each robot, the script forwards `SingleAct.action` as the joint command and `SingleAct.gripper` as the gripper command. The action dictionary must include every configured `robot_key`.
70
64
71
65
## Running
72
66
73
67
After the policy server is up and `franka.json` is configured, run:
74
68
75
69
```shell
76
-
python examples/inference/franka.py
70
+
uv run python examples/inference/franka.py
77
71
```
78
72
79
73
If the policy server is unreachable, the script will keep retrying connection until it becomes available or you exit.
0 commit comments