Same teacher, same data, 85% against 14%: what a robot needs to see to learn a pick

We trained two neural network policies to pick up a cube and place it, on a robot arm with a parallel-jaw gripper and two cameras. Both learned from the same teacher, on the same demonstrations, with the same network. One of them succeeds in 85% of attempts on conditions it never trained on. The other succeeds in 14%.

Left: the arm. Right: the robot's belief map, in step. Simulation.

The only difference is one extra input: a map of where the part probably is.

All results in this post are in simulation, scored on 512 held-out episodes the policies never saw during training.

The camera setup a factory would actually install

A real work cell does not have a perfect view of every part. We set the simulation up the way an automation team would set up a cell:

Neither camera alone is good enough to place a part to a few millimetres. The two together are, if something combines them properly.

A map of what the robot believes

Most robot software acts on the latest sensor reading as if it were the truth. Ours keeps a belief instead: a map of where the part probably is, how sure the robot is, and where it could be wrong. The video at the top of this post is that map, not a camera feed. Bright cells are where the robot believes the part is; dark cells are where it has ruled the part out. The ring marks where the part really is, which we can only show because this is a simulation. The robot never sees the ring. Everything it does, it does from the map.

The teacher plans on the map, not on a camera reading

Our teacher is a scripted expert that our pipeline writes and checks before any training. On this setup it does not act on the latest camera reading. It keeps a probability map of where the part is: a grid of 6,400 cells, each 1.5 mm wide, covering a 12 cm square around the part.

Every step, each camera adds its evidence to the map in its own terms. The wrist camera's reading is sharp. The fixed camera's reading is a long, thin streak along its line of sight, because it knows the direction to the part much better than the distance. Where a camera looked and saw nothing, the map lowers those cells. When the gripper is holding the part, the map rides with the gripper.

The expert only closes the jaws when most of the map's probability sits inside them. With the map, the expert places the part in more than 95% of attempts.

Teaching a network to copy it

A network learns by watching the expert and copying its actions, then correcting itself on its own mistakes. We trained two networks this way:

Held-out settingWith the mapWithout the map
B90.8%0.0%
C190.4%16.8%
C (hardest: arm base moved and turned every episode)85.0%14.5%
Same start, same teacher. One policy sees the map, the other does not. Simulation.

The network without the map has every camera reading the expert had. It cannot learn to copy the expert anyway, because the expert's decisions depend on evidence it gathered over many steps: the far camera's rough guess early on, the wrist camera's close look, what it did not see. From single readings, the expert's choices look arbitrary. The map is the expert's memory in a form a network can read.

On the hardest setting, the network with the map also beats our previous single-camera policy (82.4%), on a setup with a much worse camera.

A bug worth telling

While filming this result, our episode viewer showed the map's estimate jumping 3 cm off the held part on some steps and snapping back on the next. The cause was a correction written for the old one-camera setup: at the moment of the grasp, it compared the last camera reading with the gripper's position and treated the difference as the camera's fixed error. On the two-camera setup that last reading was sometimes the fixed camera's rough one, so a 3 cm error was "corrected" into every sharp wrist reading afterwards.

The fix was one line: on two cameras, each camera's error is already modelled in the map, so the old correction is switched off. We re-ran the episode and the largest error while holding the part dropped from 34 mm to 7.5 mm. On the fixed code, the expert placed the part in 100% of the scored attempts.

What this means

If you want a robot to learn a task from demonstrations, the demonstrations are only half of it. The learner needs to see what the teacher based its decisions on. For tasks where perception is uncertain, which is most real work cells, that means giving the learner the teacher's belief, not only the raw sensors.

Next we are taking this setup onto a real arm in a real cell.