Skip to content

The first exam for code agents in the physical world: frozen robot tasks from many benchmark suites, each answered with a program and verified in a separate sandbox. Runs on Harbor.

22.1 KB
Raw Blame

embodied-olympics goalkeeper-save — instance i00 — REALTIME MODE (robot as a service; time does not stop)

You control a simulated Unitree H1-2 humanoid robot (27 joints, 1.78 m tall, 67 kg; the Embodied Olympics simulator on MuJoCo) as if it were real hardware: the simulator runs in a service you cannot open, you reach it only through a client, and like a real venue it does not wait for you: once an attempt is running, the robot, the ball and the venue move while you think. Task: Keep goal: three penalty kicks are shot at the official goal you stand in; keep every ball out, with a foot on the goal line at each kick.

Slowdown: S = 1. The world runs at 1/S of real speed: one control step (10 ms of robot time) every S x 10 ms of wall-clock time (real time). spec()["timing"]["slowdown"] states it.

The venue

You stand on the goal line in the middle of the official goal, facing the field (+x); the goal and its net are behind you. Three two-wheel ball machines stand 11 m in front of you around the penalty mark, their heads at about knee height, each turned towards its stated aim; the goal area and the penalty area are painted on the grass. At 20.0 m/s a shot needs a little over half a second to reach the goal line.

Directions are from the robot at the start: +x is the way you face, +y is to your left, +z is up; the floor is level.

The rules

Rule book: IFAB Laws of the Game 2025/26: Law 1 (the goal 7.32 m x 2.44 m with posts and crossbar 12 cm wide on the goal line, the penalty mark 11 m from the goal line, the goal area 5.5 m x 18.32 m), Law 2 (a size-5 ball: 68-70 cm round, 410-450 g), Law 10 (a goal: the whole ball over the goal line between the posts and under the crossbar), Law 12 (a goalkeeper may handle the ball in their own penalty area) and Law 14 (the penalty kick: the goalkeeper remains on the goal line, facing the kicker, between the goalposts, without touching the goalposts, crossbar or goal net, until the ball has been kicked; when the ball is kicked the goalkeeper must have at least part of one foot touching, or in line with, the goal line). Where this task departs from it:

  • Law 14 (the kicker): each penalty is shot by a two-wheel ball machine instead of a kicker: three machines, one ball each (a machine holds one ball per load), their exits 0.6 m above the ground on the penalty mark's line, 0.6 m apart across it (the middle one over the mark; the Law puts the ball on the mark). Each is aimed before the attempt at a point of the goal's plane that the rules state, and throws at 20.0 m/s, no spin: a real keeper reads a kicker; here the aim is stated instead. The elevation is computed for the ball's drag in air and trimmed by 0.45 degrees (measured in this venue: untrimmed, the shots crossed the line about 0.1 m low); a machine's own scatter (about 2 percent in speed and 2 degrees in direction, its maker's measurement) stays.
  • Law 10 (kicks from the penalty mark): three penalties against the same goalkeeper, 9.0 s apart, in one attempt; every one must be saved.
  • Law 14 (the goalkeeper between kicks): between the penalties the goalkeeper stays inside the goal area (only the moment of each kick is regulated by the Law).
  • Law 1: only the goal end of the field is there (the penalty area, the goal area and the mark are painted); the goal's net is a rigid cage 2.0 m deep.

You are the goalkeeper. You stand on the goal line, in the middle of the goal, facing the penalty mark 11.0 m in front of you (+x). The goal behind you is 7.32 m wide between the posts and 2.44 m high under the crossbar (posts and bar 0.12 m thick, on the goal line, the net 2.0 m deep). Three ball machines stand on the line through the penalty mark, 0.6 m apart (the middle one over the mark), their exits 0.6 m above the ground; each holds one size-5 football (0.22 m across, 0.43 kg, in air) and shoots it once, at 20.0 m/s with no spin: the first (on your right as you face them, at y = -0.6 m) is fed at 6.0 s and aimed at the point of the goal's plane -0.8 m to your left (negative: to your right) and 0.9 m above the ground; the middle one 9.0 s later, aimed at 0.8 m and 1.1 m; the third (on your left) 9.0 s after that, aimed at -0.5 m and 0.95 m. A shot is kicked when its ball leaves the machine's wheels (about 0.1 s after it is fed). At that moment (Law 14) you must be on your feet (nothing but the feet on the ground), with at least part of one foot touching or above the goal line between the posts, and touching neither the posts, the crossbar nor the net; otherwise you fail. After the kick you may move as you like and use any part of you: hands, arms, body, legs, no grip is needed, and you may go to ground. A goal is the whole ball over the goal line between the posts and under the crossbar; you fail at the first goal, by any of the three balls at any time (also a ball that comes back off you or the posts). A shot is saved when 2.5 s have passed since its kick without a goal; you succeed when all three are saved. You also fail if your pelvis leaves the goal area (5.5 m in front of the goal line, 9.16 m to each side of the goal's centre), if you touch a machine or a ball that has not yet been kicked, or after 27 s.

A referee in the service decides this from the simulator's state. The events that must happen, in order, are save 1 → save 2 → save 3. An attempt (an episode) ends at the success, at the first rule violation, or after 27 s (2700 control steps) of robot time.

Real-robot rules

  • Time does not stop. An attempt starts paused, on the frozen start, the robot holding its starting command. Its clock starts at your first submit (or get_obs(seconds=s)) and from then on the simulator runs at 100 Hz of robot time (S = 1), whether or not you send anything, until the attempt ends: the venue's timed events (the launch, the serve, the release) happen on that clock. Between your commands the robot executes what you planned, then holds the last command in force; nothing pauses for you, not your thinking, not your tool calls.
  • You are far too slow to steer it turn by turn. One turn of yours (a model response, a tool call) takes seconds; the decisive moment of an attempt takes a fraction of one. Drive the robot with a program: a controller of your own (Python in your container, with numpy and the client) that plans or streams the rows, started in the background (nohup python /app/output/gen.py > /app/output/run.log 2>&1 &) or in the foreground if it ends with the attempt. Use your turns to start attempts, read what happened, and improve the program.
  • Attempts. r.reset() abandons the running attempt (or follows one that has ended) and starts a new one from the same start, paused until your next submit; spec()["budget"]["reset"] says how many resets you have (5 here; authoritative: if it says 0, the one attempt is the run). Once an attempt has ended, submit raises EpisodeOver until you reset. Only your last attempt is graded, and a success ends the trial at once. The wall clock is the run's and never restarts.
  • No privileged state. You get what the robot's own sensors give: its two head cameras (head_left, head_right, RGB 270 × 480, a stereo pair 5 cm apart, tilted 20° down; depth on head_left), its joint encoders, motor torques and two IMUs (below), and the venue's fixed cameras (venue, behind_goal; spec()["cameras"] says where each is mounted). Not where you or any object is, not the referee's state. Once an attempt is over, every response carries the referee's call: meta["outcome"] ("success" or the rule that ended it) and meta["stages_reached"] of meta["stages_total"].
  • There is nothing to hand in: the service records every control step it ran and grades your last attempt as it ran live (the referee's call). Keep the program that drives the robot at /app/output/gen.py and a NOTES.md of at most 20 lines (your approach, what failed, what you downloaded or installed) for the record: save them early and keep them current.
  • Wall clock: the time limit (## Time limit). It ends without warning, and ending your session earlier ends the run the same way (and stops your background programs), so do not stop early: while you have attempts left, the run can still pass.

Time and streaming

  • submit answers at once, with the robot as it is now: the rows you sent have not run yet. They become the plan from control step at (an attempt step number; by default the next step), replacing whatever was planned from at on and keeping what is planned before it. When the plan runs out, the command in force is held. res.meta["control_steps"] is the number of steps run so far in this attempt (so the next step has that number), res.meta["proprio"]["now"] the proprioception now, res.meta["plan_end_step"] where the plan now ends.
  • Open loop: plan a whole movement at once (a chunk covers at most 10 s), with at = 0 for the attempt's start: r.submit(type, A, dt=0.01, interpolate="hold", at=0, cameras=[]) starts the clock and runs exactly those rows from the first step; at may be up to spec()["timing"]["max_ahead_steps"] steps ahead.
  • Closed loop: send one row per control step, r.submit(type, a[None], cameras=[]), computed from the proprioception the previous call returned. cameras=[] skips the images (the fastest call).
  • Latency: a reading is a few milliseconds old when it reaches you, and a row takes effect at the next control step at the earliest. A row whose step has already run when the request arrives is dropped (res.meta["late_steps"] counts them); the rest of its chunk applies from the next step.
  • get_obs() reads the robot now; get_obs(seconds=s) (at most 30) waits while s seconds of robot time run and returns what the cameras saw meanwhile. r.status() shows running and lag_s.

Client (/opt/tools/rcb_client.py, protocol eai-standard/2.3, realtime mode)

Your whole interface to the robot. Its docstring is the full reference (python -c "import rcb_client; help(rcb_client)"; it explains the protocol with another benchmark's example names: for this task spec() is authoritative).

call endpoint what it does
r = Robot() connects (http://sim:8000, then http://localhost:8000) and waits until the service is ready
r.spec() GET /spec the facts: action_types (each type's layout, lower, upper, meaning), control_dt (0.01 s), max_control_steps (2700), cameras (field of view, pose at the start), proprio_layout, robot_facts (joints, limits, default gains, the stance), rules, budget
r.status() GET /status calls, rows, control_steps, done, reason, elapsed_s, resets_left, running, planned_steps, lag_s
r.get_obs(cameras=None, seconds=0, video="frames", include_depth=False) POST /observe the robot now, or what the cameras saw over the next seconds (at most 30) of robot time
r.submit(type, A, dt=0.01, interpolate="linear", at=None, cameras=None) POST /submit plans A, rows of that action type dt seconds apart (a multiple of 0.01; a chunk covers at most 10 s), from step at; answers at once; the first one starts the attempt's clock
r.reset(cameras=None) POST /reset a new attempt from the same start, paused (see above)

One call returns at most 3000 images (max_frames_per_call, PROTOCOL §3 "Images per call"). A watch is refused with a 429 while the images in flight (pending watches and answers not read yet) would exceed it or 8 of them are outstanding; a submit or a get_obs() without seconds is never refused for its images: its answer then comes without its frames and meta["frames_skipped"] is set.

The answers are binary (RCB1) and come back decoded: res.meta (the counters, done, reason, proprio["now"], clipped), res.last[camera] (the last frame), res.frames or res.video (what the cameras saw during the call), res.depth, res.proprio (proprioception rows). Values outside the bounds are clipped and reported in meta["clipped"], never refused; a malformed request raises ValueError and runs nothing. cameras=None means every camera: a controller's call should ask for none (cameras=[]) and read res.meta["proprio"]["now"]; the cameras are rendered on the service's GPU. With interpolate="linear" (the default) each control step's command is a straight line from the command in force to the row; "hold" applies the row as it is.

from rcb_client import Robot
r = Robot()
res = r.submit("walk", A, dt=0.02, at=0, cameras=[])   # A: (T, 20) rows of the `walk` type, from step 0
while not r.status()["done"]:
    ...                                              # or stream one row per control step from the proprioception

Actions

One row is one control step (10 ms; the physics runs at 1 kHz) unless dt spreads it. Every row ends with grip_left, grip_right.

type row (then grip_left, grip_right) floats who drives what
stand waist 1 + arms 14 joint targets 17 the platform holds the legs in the stance; you give the waist's 1 and the arms' 14 joint targets (rad)
walk vx, vy, wz + waist 1 + arms 14 joint targets 20 Unitree's walking policy drives the legs from the velocity command (vx forward, vy to the left, m/s; wz turning left, rad/s; the robot's own frame); you give the waist and arm joint targets
joints all 27 joint targets 29 you give all 27 joint targets (rad); the default PD gains, no feed-forward
lowcmd all 27 joints × (q, dq, tau, kp, kd): 27 targets, then 27 velocities, 27 torques, 27 kp, 27 kd 137 Unitree's LowCmd for all 27 joints: position targets (rad), velocity targets (rad/s), feed-forward torques (N m), kp, kd; the motor torque is kp (q - q_measured) + kd (dq - dq_measured) + tau, evaluated at 1 kHz

Velocity commands are in the robot's own frame (vx forward, vy to its left, m/s; wz turning left, rad/s). Bounds: walk |vx| ≤ 0.8, |vy| ≤ 0.5, |wz| ≤ 1.57. Joint targets are absolute angles (rad). Values outside the bounds are clipped. grip_left, grip_right: ≥ 0.5 closes the hand's grip, < 0.5 opens it. At the start the robot stands in stand mode with the arms at rest: the stand row with the table's start angles and both grips open keeps it there.

Joint order everywhere (Unitree's SDK order), with each joint's range, speed limit, torque limit and default gains (also in spec()["robot_facts"]):

# joint range (rad) speed (rad/s) torque (N m) kp kd at the start (rad)
0 left_hip_yaw [-0.43, 0.43] 23 360 800 10 0
1 left_hip_pitch [-3.14, 2.5] 23 360 800 10 -0.16
2 left_hip_roll [-0.43, 3.14] 23 360 800 10 0
3 left_knee [-0.26, 2.05] 14 360 1200 16 0.36
4 left_ankle_pitch [-0.8973, 0.5236] 9 66.88 160 8 -0.2
5 left_ankle_roll [-0.2618, 0.2618] 9 40 160 8 0
6 right_hip_yaw [-0.43, 0.43] 23 360 800 10 0
7 right_hip_pitch [-3.14, 2.5] 23 360 800 10 -0.16
8 right_hip_roll [-3.14, 0.43] 23 360 800 10 0
9 right_knee [-0.26, 2.05] 14 360 1200 16 0.36
10 right_ankle_pitch [-0.8973, 0.5236] 9 66.88 160 8 -0.2
11 right_ankle_roll [-0.2618, 0.2618] 9 40 160 8 0
12 torso [-2.35, 2.35] 23 200 600 15 0
13 left_shoulder_pitch [-3.14, 1.57] 9 130 300 6 0
14 left_shoulder_roll [-0.38, 3.4] 9 60 300 6 0
15 left_shoulder_yaw [-2.66, 3.01] 20 60 200 4 0
16 left_elbow_pitch [-0.95, 3.18] 20 60 200 4 0
17 left_elbow_roll [-3.01, 2.75] 31.4 60 80 1.5 0
18 left_wrist_pitch [-0.47, 0.47] 31.4 19 60 1 0
19 left_wrist_yaw [-1.27, 1.27] 31.4 19 60 1 0
20 right_shoulder_pitch [-3.14, 1.57] 9 130 300 6 0
21 right_shoulder_roll [-3.4, 0.38] 9 60 300 6 0
22 right_shoulder_yaw [-3.01, 2.66] 20 60 200 4 0
23 right_elbow_pitch [-0.95, 3.18] 20 60 200 4 0
24 right_elbow_roll [-2.75, 3.01] 31.4 60 80 1.5 0
25 right_wrist_pitch [-0.47, 0.47] 31.4 19 60 1 0
26 right_wrist_yaw [-1.27, 1.27] 31.4 19 60 1 0

What the platform does and does not do for you:

  • stand holds the legs at the standing pose with stiff gains and a gravity-support torque. It is not a balance controller: it does not step and it has no feedback. After an arm movement the body sways a few centimetres for a few seconds; a hard or fast swing of the arms, a push or a load can tip the robot over within a second or two.
  • walk runs Unitree's own H1-2 walking policy (50 Hz) on the legs. At the largest forward command (0.8) it walks at about 0.6 m/s and its heading drifts (close the loop on the IMU); vy up to 0.5 and wz up to 1.57 rad/s. At a zero command it marks time on the spot and recovers from small disturbances, which stand does not. When the legs come to it from another mode it first blends them to the stance (0.3 s) and holds a zero command until the robot is steady (up to 2 s). It was trained with the arms at their zero pose (upper arms down, forearms forward): moving the arms disturbs it. This robot has no running policy: anything faster than a walk is yours to build or to find. The G1's two other walking policies (FALCON, AGILE) are not offered for it: driven on this robot (joints matched by name) they keep it upright but do not walk it.
  • joints / lowcmd are yours: each motor's torque is kp (q − q_measured) + kd (dq − dq_measured) + tau, evaluated at 1 kHz with your row held for its 10 ms, then limited by the motor's torque-speed curve and torque limit. joints uses the default gains of the table and zero dq and tau; lowcmd takes yours (kp up to 1500 / 800 / 400 and kd up to 30 / 20 / 10 for legs / waist / arms). Nothing balances the robot in these modes but your own targets.
  • Every joint target is clipped into the joint's range and moves at most the joint's speed limit × 10 ms per step from the target in force. Joints a type does not name keep their targets. The speed limit is a limit on targets; what bounds the joint itself is the motor's torque-speed curve (a lowcmd feed-forward torque can turn a joint up to about 1.15 times that speed, where the motor's torque has fallen to zero).
  • The hands have no working fingers here; each carries a fist pad (a box of 4.4 × 8 × 10 cm beyond the wrist, the 10 cm along the forearm). Nothing in this task is grippable: grip_left and grip_right have no effect.
  • A tool on a hand (a racket, a paddle, a club; where the task has one) is fixed to the wrist in place of the pad. It collides with the world, the ball and the rest of your own body.
  • The air is real: balls and implements feel drag and, when they spin, lift.
  • If the physics diverges (a numerical blow-up, typically from a violent joint command), the attempt ends as a failure: "the simulation became unstable".

Proprioception

Each row (meta["proprio"]["now"], res.proprio) has, in spec()["proprio_layout"] order: the 27 joint positions (*_pos, rad), their velocities (*_vel, rad/s), the motor torques applied (*_torque, N m), the joint targets in force (*_target, rad), the pelvis IMU and the torso IMU (each: orientation quaternion qw, qx, qy, qz, world from sensor; angular velocity gx, gy, gz, rad/s; acceleration ax, ay, az, m/s², gravity included; in the sensor's frame), holding_left, holding_right (1 while that hand grips something), mode (0 stand, 1 walk, 2 run, 3 run_arms, 4 joints / lowcmd; the G1 also 5 walk_falcon, 6 walk_agile), the velocity command in force (cmd_vx, cmd_vy, cmd_wz) and time_s, the attempt's time. A real H1-2 has no sensor for its position in the venue, and neither do you: that is what the cameras are for.

External material

The network is open. You may install packages (pip, apt), and you may search for, download and use public tools, robot models and pretrained controllers (for example a published Unitree G1 walking, jumping or whole-body policy): finding existing work and adapting it to this robot is encouraged. Say in your notes what you used. You may read anything installed in your container, this benchmark's own source code included. The one thing not to look up is a ready-made solution to this exact task, such as this benchmark's reference solutions. This is an honour rule; trials are reviewed.

Resources

Your container: 4 CPUs, 10 GiB of memory, 8192 processes and threads and 20 GiB of disk (new files under /app, /tmp and /root). Your container has no GPU. The simulator runs in its own container and does not count against these. CPU only slows you down; a process that goes over any other cap can be killed. Usage and caps: /run/rcb-limits/usage.json.

Time limit

You have 7200 seconds to complete this task. Do not cheat by using online solutions or hints specific to this task.

This is wall-clock time from the start of your session; the time you wait for the simulator service counts. When it is up you are stopped without warning and the episode is graded as it stands at that moment. The service's time_left_s counts the same limit from your first request to the service, so it never runs out before your time does: your real time left is time_left_s minus the time you spent before that request. Plan by it. Your session started when you received this task. /run/rcb-limits/usage.json, rewritten every few seconds, gives the time left on this limit (time_left_s) and its end (deadline_utc), counted from a little before your session started, so it never gives you more time than you have: read it (or run date) before you decide that time is short, never guess. Waiting counts too: a tool call that sends input to a process that keeps running (an interactive interpreter, a simulator loop, a server) can wait for the whole wait or yield time you give it even when the answer is printed at once, so give such calls a short wait and poll again if the output is not complete, or run one-shot scripts that exit when they are done. Installing packages is not cheating (## External material above).