Capstone: A Simulated Pick-and-Place Policy with an Evaluation Report
You'll be able to:
You can take a tabletop task from environment choice to a written evaluation: build a scripted baseline, train a learned policy, evaluate both with seeded episodes and a failure taxonomy, test robustness to one perturbation, and state what would still block deployment on a real arm.
The evaluation is the deliverable
Anyone can train a policy that works in a video. The capstone asks for the thing employers actually want: a policy and an evaluation report that a sceptical colleague can read and believe. This lesson is the procedure.
Step 1: pick a task you can evaluate
FetchReach in Gymnasium-Robotics (a MuJoCo arm that must move its gripper to a goal point) or PandaReach in panda-gym are deliberately simple. Reaching has a clean success criterion (gripper within a few centimetres of the goal), a short horizon, and runs fast on a laptop. If you are comfortable, FetchPush or PandaPickAndPlace add contact, and with it the failure modes that make the report interesting. Choose the simplest task on which your evaluation will still find failures.
Both families are goal-conditioned: the observation includes the goal, and the reward is sparse by default (−1 on every step the gripper is more than 5 cm from the goal, 0 on steps within it; the episode does not end on success). Read the environment page before you write a line; the observation is a dictionary with observation, achieved_goal and desired_goal keys, and that structure matters for the learning method.
Step 2: build the baseline first
Write a scripted controller: compute the vector from the gripper to the goal and command a proportional step along it, clipped to the action bounds. It will succeed most of the time and fail in instructive ways (the clip saturates, the proportional gain overshoots at the end, the gripper is already at the goal when the episode begins). Evaluate it with the same protocol as the learned policy. Without a baseline, a 75% learned success rate means nothing; with one, it is either an improvement or a regression.
Step 3: train the learned policy
Two routes, pick one. Behaviour cloning from the script: record a few hundred scripted episodes (module 5's recorder), fit a small MLP from observation to action with the imitation library (built on Stable-Baselines3) or plain PyTorch, and apply one DAgger round from module 4. This trains in minutes. Reinforcement learning: SAC or TD3 in Stable-Baselines3 with hindsight experience replay (HER). HER is the piece that makes sparse goal-conditioned rewards learnable: after a failed episode it relabels the goal as whatever the gripper actually reached, turning every failure into a success for a different goal. SB3's HER replay buffer plugs into its off-policy algorithms directly. Keep the budget modest; a short run with an honest result beats a long one you cannot finish.
Step 4: an evaluation protocol worth believing
- Fix a list of seeds (for example 0–49) and use the same seeds for every policy and every condition.
- Define success precisely, including the timeout, and record steps to success for successful episodes.
- Run n episodes. Report success rate with an uncertainty. With n = 50 and 41 successes, p̂ = 0.82 and the standard error is √(0.82·0.18/50) ≈ 0.054, so a rough 95% interval is 0.82 ± 0.11. That width is why 50 episodes cannot distinguish 82% from 90%, and why the SIMPLER paper argues for evaluating in simulation where thousands of trials are cheap.
- Classify every failure: timeout while converging, overshoot oscillation, saturated action, goal outside reach, and so on. Count each class.
- Run one perturbation sweep: goal-position noise, Gaussian action noise, or a change in control gain. Plot success rate against perturbation magnitude for both policies. The slope is the robustness result.
Step 5: the report
One page, in this order: task and success definition; the two policies and their training budget; the main table (success rate with interval, mean steps to success, failure counts by class) for baseline and learned policy; one plot (the perturbation sweep); and a closing paragraph titled "not yet safe to deploy because". That paragraph should name concrete gaps: no safety envelope (module 7), no latency in the evaluation loop (module 1), simulation contact that has not been validated against a real arm, and the width of your confidence interval.
Worked example of what the table looks like
Baseline: 50 episodes, 44 successes (88% ± 9%), mean 18 steps, failures: 4 overshoot oscillation, 2 goal near workspace edge. BC policy: 50 episodes, 41 successes (82% ± 11%), mean 15 steps, failures: 6 timeout drifting away from goal, 3 overshoot. Under goal noise of 2 cm the baseline drops to 80%, the BC policy to 60%. The honest conclusion is that the clone is faster when it works and less robust when the goal distribution shifts, which is exactly the compounding-error signature from module 4, and that the baseline is the one you would run tomorrow.
Sim-to-real caveat
A simulated reach is not a real reach. SIMPLER showed that simulated evaluations can correlate well with real-robot results when the visual and control gaps are deliberately matched, and poorly otherwise. Your report should say which gaps you did not close. Reporting what you did not test is a professional strength, not a weakness.
What is unsettled across the field: there is no agreed evaluation standard for learned robot policies. Papers choose their tasks, their trial counts and their success definitions. Writing an evaluation that states all three, with seeds and intervals, already puts you ahead of much of the published literature.
What to remember
- Baseline first; a learned number without a baseline is noise.
- HER is what makes sparse goal-conditioned RL learnable.
- Fixed seeds, a precise success definition, a confidence interval and a failure taxonomy are the minimum protocol.
- One perturbation sweep turns a success rate into a robustness claim.
- End with "not yet safe to deploy because", and mean it.
Curated Materials
1.5hThe deep work happens here — the lesson is your briefing.
Live on aiqbench
This lesson's subject on the rest of the site, today.
In the news, last 30 days
- Robotics underwriter Cenotian raises $48M to de-risk factory deploymentsDealroom.co ·
- Cenotian raises $48M to underwrite robotics deployments and cut factory riskDealroom.co ·
- DeepSeek Officially Posts Job for Talent in Embodied Intelligence36Kr ·
Test your knowledge
5 questions in 100 seconds, on a page of its own. Read everything above first.
Test your knowledge →Module Mission
60–90 minIn Gymnasium-Robotics FetchReach-v4 (or panda-gym's PandaReach), write a scripted controller that moves the gripper toward the goal, then train a learned policy (behaviour cloning from the script, or SAC with hindsight experience replay for a short budget). Evaluate both over 50 seeded episodes: success rate, mean steps to success, and a failure taxonomy. Add one perturbation sweep (goal-position noise or action noise) and write a one-page evaluation report with a table, one plot, and a 'not yet safe to deploy because' paragraph.
Loading your work…