Experiment 2: teaching an arm to pick up a Lego
A low-cost leader and follower arm pair, 125 recorded episodes and ACT policies that pick a red Lego into a bowl on some placements. After a move to a new room the best policy scored 2 of 9 on a fixed test. The next one froze at rest, which led to trimming idle frames and auditing data before every run.
- Status
- Running
- Hypothesis
- Adding demonstrations that cover the placements a policy misses (vertical and rotated blocks) raises its grasp success on those placements, without losing the ones it already gets.
- Hardware
- Seeed SO-ARM101 Pro (leader and follower)
- Overhead Logitech C920 webcam
- Wrist camera
- ID
- exp002-so-arm-bench
Why#
Experiments 0 and 1 proved the harness on a toy: one gated path to hardware, one event log, and a camera that judges the result. A toy with two buttons cannot learn anything, though. This experiment moves to a real manipulator and a learned policy, and asks the question every robot-learning project runs into: when the policy fails, is more data the fix, and which data?
The task is deliberately small. A red Lego block sits somewhere on a mat, two other blocks sit nearby as distractors, and the arm has to put the red one in a bowl and return to rest.
Setup#
- Arms. A Seeed SO-ARM101 Pro pair. The black leader arm is moved by hand and only read; the white follower arm copies it during teleoperation and runs the policy afterwards.
- Cameras. An overhead webcam and a wrist camera, both recorded at 640x480 and 30 fps.
- Software. LeRobot 0.7.1 (Seeed's fork), kept outside the lab's own Python workspace.
- Policy. ACT (Action Chunking with Transformers), about 52M parameters. ACT does not read the task text, so the distractor blocks are what teach it to pick by colour.
- Speed cap. Every follower step is capped (
max_relative_target=5) during teleoperation and rollouts. The policy often asks for bigger steps, and the logs record each clamp.
Data#
125
recorded episodes
124 used for training
109,245
frames at 30 fps
68,254 after trimming idle frames
~52M
policy parameters (ACT)
50 to 60 ms
inference per step
spikes near 200 ms
Every episode so far is 30 seconds with a 15 second reset, and starts and ends with the arm at rest. That last part turned out to matter (see "The policy that waited" below).
| Dataset | exp002-bowl-p32, 125 episodes, 109,245 frames at 30 fps |
| Bowl batch | 40 episodes, the Lego moved each time (episode 0 excluded as a failure) |
| Orientation batch | 25 episodes on 15 November: 6 flat, 6 vertical, 6 rotated, 4 stacked, 3 near the bowl or an edge |
| New-room batch | 30 episodes on 16 November after the bench moved, three blocks with the bowl and lighting changed per block |
| Rotation batch | 30 episodes on 16 November: per block 6 angled, 2 vertical, 2 flat, with a slow final approach |
| Follower gain | 32. At the default 16 the shoulder lagged the leader by up to 100 to 155 degrees; at 32 the mean lag was about 3 |
The orientation batch exists because of what the first policy got wrong.
First policy and what it did#
The first policy trained for 50,000 steps on episodes 1 to 39, on the Mac's GPU (MPS), in 7 hours 44 minutes. These nine rollouts were exploratory, run to learn what to test next. They were not a fixed protocol, so they are not a success rate.
| # | Settings | Lego placement | Outcome | Attempts | Notes |
|---|---|---|---|---|---|
| 1 | default | not recorded | grasped after a retry | 2 | bumped it, regrasped, into the bowl |
| 2 | default | flat, horizontal | missed | about 2 | |
| 3 | default | flat, horizontal | grasped first try | 1 | |
| 4 | default | vertical | missed | 3 | |
| 5 | default | stacked on the other blocks | grasped first try | 1 | |
| 6 | default | rotated to 12 o'clock | missed | 3 | the wrist did not rotate |
| 7 | default | flat, horizontal | missed | about 4 | overshot left twice |
| 8 | 10-step chunks | not recorded | missed | 0 | barely moved, shook |
| 9 | temporal ensembling | not recorded | missed | 3 | held 30 Hz, wrist under-rolled |
"Default" is ACT's 100-action chunks. Where the placement was recorded, the grasps came on flat and stacked blocks. Every vertical and rotated block was missed, and those placements were rare in the training data.
What it taught#
- The misses look like a data problem. The policy works on placements it saw often and fails where the wrist has to roll. Rollout settings change how a policy runs, not what it learned, so better grasps need more of the right data and a retrain.
- Smoother is not better. Temporal ensembling held the control loop at 30 Hz (100-action chunks dip to about 16 Hz) and moved more smoothly, but grasped nothing.
- Inference is fast enough. About 50 to 60 ms per step on the Mac, with spikes near 200 ms.
- The jerkiness has a likely cause. The speed cap clamps many steps. A higher cap has not been tested.
A new room#
On 15 November the bench moved: new room, new lighting, and the cameras, arms and bowl all in new places. The second policy, trained only on the old setup, failed all 4 tries there. 30 demonstrations in the new room and a better overhead camera went into a third policy (v3).
On a fixed test of 9 runs (three bowl spots, each with the Lego flat-horizontal, vertical and rotated to about 1 o'clock) v3 placed 2 of 9 in the bowl and grasped 3. Rotated blocks went 0 of 3: the wrist didn't turn far enough. Most other misses had the height right and landed 2 to 4 inches off. Nine trials only show direction: the 95% interval on 2 of 9 is roughly 3% to 60%.
The policy that waited#
A fourth policy (v4) added 30 demonstrations weighted toward rotated blocks. It trained cleanly and then never left the rest pose on the arm, while v3 moved on the same setup.
Offline, from the first frame of every recorded demo, v4 planned to stay put on 63 of 125. The demos explained it: a median 3.2 seconds of stillness before the first move and 7 seconds at rest after the return, about 37% of all frames. ACT sees only the current frame, so a scene that often meant "wait" makes it wait, and the next frame looks the same.
What the freeze taught#
- Audit the data before training. A check that measures idle time, and a checkpoint check that measures planned motion from every recorded start, would have caught v4 before an 8-hour run. Both now run before every training run and every robot session.
- Trim, don't re-record. Idle starts and ends are cut from a copy of the dataset, with the videos left byte-identical. The recorder now cuts them as it goes, and ends each episode once the arm is back at rest.
- Coverage beats count. 125 demos is well past the usual 50 for one task. What fails (rotated blocks) needs coverage of those angles, not more of the same.
- Loss doesn't pick checkpoints. v3 ended at a higher training loss than v2 and did better. Behavioural checks and fixed trials decide.
Next#
- Train v5: v4's demos with idle frames trimmed, nothing else changed, so any difference has one cause.
- Before it touches the arm: the checkpoint audit and a live-frame probe. Then the same 9-run test against v3's 2 of 9, with v3 re-run as a control.
- One change per run after that: image augmentation, longer training, correction demos taken over mid-run with the leader arm, and fine-tuning a pretrained model (SmolVLA) on a rented GPU.
- Log rollouts through the harness, so results on this page are computed from runs instead of typed in.
Bench notes, every calibration gotcha and the scripts are in the experiment folder.
From the lab log
The arm that waited
The fourth policy trained cleanly and then never moved. The cause was in the data: every demonstration began with 3 seconds of stillness, and the policy learned to wait. Now idle frames are trimmed, data and checkpoints are audited before robot time, and the recorder cuts dead time as it goes.
A new room, and 2 of 9
The bench moved and the policy failed all four tries. 30 demonstrations in the new room, a better overhead camera and a retrain got it to 2 of 9 on a fixed test. Rotated blocks went 0 of 3, so the next batch targets them.
Teaching it the hard placements
25 new demonstrations with the Lego vertical, rotated, stacked and near the edges, and a fresh 50,000-step training run on all 64 good episodes. The question: does covering more orientations raise grasp success?
Fifty thousand steps: the first grasp
40 demonstrations and an overnight training run produced a policy that picks up the Lego and drops it in the bowl, sometimes. It grasps flat placements and misses rotated and vertical ones. Changing how it runs didn't fix that.
Two cameras, and a shoulder that lagged 150 degrees
An overhead camera and a wrist camera went on the bench. The follower's shoulder trailed the leader by up to 155 degrees until the motor gain doubled, and a new bowl dataset started with every episode beginning and ending at rest.
Matching two arms, and a policy that never reached down
The leader and follower grippers faced 90 degrees apart until both wrist rolls were set the same way. The first learned policy moved, then stalled above the Lego, because it had learned targets the follower can't reach.
Bench day one: a leader arm that stopped answering
Setting up a LeRobot SO-ARM101 Pro bench. Calibration rewrote the wrong file, the leader's joints went quiet, and the first teleop worked once the ranges were fixed.