Learn / Practice

MuJoCo braking and sustained low speed after observation loss

EMBODIED-AI / EXPLORE · Engineering cases

Three rounds compare filtering, staged braking, and a guard on position force. The guard fixes the retained counterexample, and both policies pass the same 60 new trials.

INTERMEDIATE · 9 MIN · FOCUSED READING

What was published after this article?

The original conclusions and next-step proposals are retained. These published follow-ups do not imply that every limitation has been resolved.

Related content

  1. Engineering cases

    MuJoCo mass transfer: can the same gains still work?

    Compare fixed and mass-scaled gains in 36 episodes, including lower mean error without a velocity-contract pass.

    10 MINPublished
On this page 4

Download the study bundle · Run the study and redraw the figures

A frictionless slider can pass a stop check and speed up again while its position channel is still offline. Under high velocity noise, every permanent-loss trial in the previous study did exactly that. Three follow-up rounds tested sustained stopping, then introduced staged braking and limited the position force used in low-speed hold. The limit prevented the retained seed 2017 from crossing the threshold again. On a separate set of 60 new seeds, both the guarded policy and its unguarded baseline passed all 60 permanent-loss trials. The guarded policy reduced travel after confirmation, with a slight increase in speed just before recovery under temporary loss. Previous experiment · Lab record

Confirming a stop and staying below the threshold

All three rounds use the same 1 kg frictionless planar slider, 2 ms physics step, 20 ms control period and 4 s episode. The position channel becomes stale at simulation time 0.500 s. Under temporary loss, fresh position observations resume control at 1.040 s. Local velocity arrives without delay or missing samples. In the high-noise condition, Gaussian measurement noise has a standard deviation of 0.08 m/s on each axis.

The audit confirms a stop after 0.300 s of actual planar speed at or below 0.04 m/s. The joint criterion requires that confirmation within 1.200 s of detecting loss, followed by two full seconds at or below the speed threshold. Stopping distance is the accumulated path from loss detection to the start of the 0.300 s window. Post-confirmation travel starts at the physical state that completes it. The two distance budgets are 15 cm and 5 cm at P95. Each P95 uses the nearest rank and reports its valid sample count. Trials without a full follow-up window lack a two-second path measurement and still count in the joint result.

The first round replayed all 12 high-noise baseline cases and matched the published traces. At the next control update after confirmation, the simulation branched into continuing noisy feedback, removing noise while keeping velocity damping, and commanding zero force. Among the ten cases still below the threshold at the branch point, continuing noisy feedback led to ten new crossings. The other branches had zero crossings in their observed intervals. For those ten cases, median travel after the branch was 0.232 cm with noiseless damping and 3.098 cm with zero force, which allowed the slider to coast.

The first round selected a velocity gain of 4 with 80 ms exponential smoothing. On seeds 1000–1059, all 60 permanent-loss trials confirmed a stop on time, and 26 crossed the threshold again within two seconds. The resulting 34/60 joint passes and P95 values of 15.0195 cm for stopping distance and 5.1371 cm for post-confirmation travel missed all three thresholds. The archived failures include seed 1035, which crossed again 10 ms after confirmation, seed 1038, which accumulated 5.3945 cm of travel in two seconds, and seed 1059, which took 16.4332 cm to reach the low-speed window. Sustained stopping data

Staged braking and active low-speed hold

The second round paired staged braking with an observer that compensates for known changes in velocity. For each local measurement, it subtracts the velocity increment from previously issued force commands, averages the residuals, then adds the current increment back. The conversion uses impulse divided by the fixed mass. The observer receives noisy velocity samples, and the independent audit scores actual speed from the simulation.

The staged controller brakes with a velocity gain of 10 until three consecutive estimates have a speed at or below 0.08 m/s. In low-speed hold, it integrates the estimated velocity relative to the entry point and applies −4 × estimated velocity − 8 × relative displacement, clipped to ±0.6 N per axis. Two consecutive estimated speeds at or above 0.12 m/s return it to braking. Fresh position observations immediately restore the position controller.

On new seeds 2000–2059, the selected hold policy confirmed on time in all 60 permanent-loss trials. Stopping distance P95 was 11.2090 cm and follow-up travel P95 was 3.6412 cm. Seed 2017 crossed the threshold again, leaving the joint result at 59/60. In the paired comparison with the same observer and initial braking, removing force on entry left the slider coasting. Over the common two seconds following low-speed entry, median accumulated travel was 9.216 cm with zero force and 2.817 cm with active hold. Active hold reduced travel in 59 of the 60 pairs. Staged braking data

Limiting the position force near the speed threshold

In seed 2017, at simulation time 1.320 s, the slider's actual speed was 0.039577 m/s and its estimated speed was 0.009620 m/s. Damping contributed −1.523 mW of instantaneous power along the actual velocity. The position term contributed +2.531 mW, leaving net power at +1.009 mW. The slider crossed 0.04 m/s at 1.338 s, 0.282 s after confirmation.

X-axis damping and position forces, with net planar power along each policy's own trajectory. At 1.320 s the original hold supplies +1.009 mW and the combined guard supplies +0.523 mW.

The final round limited the magnitude of the position term, tapered it near the speed threshold, or combined both. The selected policy caps the position force at 50% of the damping force magnitude. It then tapers the position term linearly from full strength at 0.020 m/s to zero at 0.040 m/s, using estimated speed plus 2.45 × σ / √n as the taper input. Here σ is the configured noise standard deviation per axis and n is the number of local measurements. The margin relies on the experiment's noise and plant assumptions.

Four speed traces for seed 2017 share the same confirmation at 1.056 s. Original hold and estimate-only taper cross 0.04 m/s again. The relative cap and the combined guard stay below the threshold during follow-up.

Seed 2017 was a development case in this round. The four traces in the figure all confirmed at 1.056 s. Both figures use absolute simulation time, with loss detected at 0.500 s. Tapering based on the estimate alone produced another crossing at 1.332 s. Relative capping alone kept the two-second peak at 0.03014 m/s. The combined guard reduced that peak from the original 0.04116 to 0.02950 m/s and reduced two-second travel from 5.086 to 4.448 cm. The guarded trajectory can still receive positive net power. The original, failed taper, and guarded traces are available alongside the earlier counterexamples. Raw counterexample traces

The policy was frozen before both controllers ran on the same new seeds 3000–3059. These are the high-noise permanent-loss results.

Metric Unguarded active hold Guarded active hold
Confirmed on time and stayed within the threshold for two seconds 60/60 60/60
Stopping distance P95 11.1761 cm 11.2505 cm
Two-second travel after confirmation P95 3.8419 cm 3.6095 cm
Median positive work from the position term 0.3080 mJ 0.0181 mJ

Because both policies passed the joint criterion on this set, the paired holdout shows differences in movement and work. Under temporary loss, neither policy confirmed a stop before recovery. Speed P95 just before recovery rose from 0.03344 to 0.03564 m/s, and path P95 over the 0.54 s loss interval rose from 11.57 to 11.62 cm. The 60 normal-communication pairs had byte-identical compressed traces. Guarded braking data

Reproduce the three rounds

Start from an empty working directory and keep the output directory new. The script writes raw gzip trajectories, manifests, independent audit results and frozen selections. Study bundle · Pinned scene and controller

curl -fL https://huhohoo.com/research/mujoco-sustained-stopping/study.zip -o study.zip
unzip study.zip -d study
git clone https://github.com/VirtualSelect/hohoo-embodied-agent.git hohoo-embodied-agent-study
git -C hohoo-embodied-agent-study checkout --detach 335e756bb7e86ded9128b7c9b978636a4069fa61
python3.12 -m venv .venv
.venv/bin/python -m pip install 'mujoco==3.3.7' 'numpy==2.2.6'
PYTHON="$PWD/.venv/bin/python" sh study/reproduce.sh hohoo-embodied-agent-study braking-replay

To redraw both figures from the guarded development matrix, install Matplotlib in the same environment.

.venv/bin/python -m pip install 'matplotlib==3.10.8'
.venv/bin/python -B study/scripts/research/mujoco-dropout-braking/plot_guarded.py \
  --run braking-replay/guarded/matrix --out braking-figures

Codex ran the simulations and independent audits and helped draft this article. The recorded runs used macOS arm64 and Python 3.12.14. The observer relies on a known mass and on the applied force exactly matching the clipped command. The results cover this frictionless, contact-free model and the simulated noise. Physical sensors and actuators require separate tests.

A note to your future selfBefore you move on, keep one thought of your own.

Your private reading note stays in this browser; it is never uploaded or published. Clearing browser data removes it, so export a copy to keep. This article’s translations share the same note.

Recommended next reading:MuJoCo mass transfer: can the same gains still work? →

Related study material

EXPLORE / Getting started with embodied AI

Focused reading. Use the prerequisites and published follow-ups above to choose what to read next.

Related content

  1. LAB / 044

    Planar control tuning, observation loss and transfer

    153 episodes and 306000 physics steps. The selected controller passes 7/18 holdouts; zero force coasts, and mass scaling lowers mean error without passing the velocity contract.

    Completed
  2. PROJECT / 003

    Hohoo Embodied Experiments

    Two MuJoCo teaching scenes—pick-and-place and planar force control—record contracts, tuning, clearance and delayed-feedback outcomes, including failures.

    Experiment

Return to core and focused reading →

View count unavailable

← All writing

Use actual size to read small chart labels.