TECHNOLOGY

MuJoCo disturbances: an applied force is not cleared after one step

In this article
THE QUICK TAKE

Applied force arrays are persistent inputs owned by the caller; a one-step disturbance needs an explicit removal or replacement boundary.

A proposed tap can become a sustained push

A robustness experiment writes a disturbance into an applied-force array, advances the twin and then resumes ordinary policy commands. The report calls this a brief tap, but the external force remains present in later steps. Returning to normal ctrl values does not necessarily remove an independently stored force input. Define the disturbance’s start and end at explicit simulation boundaries before interpreting recovery behavior, work or the strength of a perturbation used for policy evaluation.

Read the persistence contract

The MuJoCo simulation guide distinguishes actuator controls from directly applied generalized and Cartesian forces. It explicitly assigns their end-of-step clearing to the user. A step computes dynamics from the supplied arrays; it is not a message queue that consumes and removes each force entry. Leaving a nonzero value in qfrc_applied or xfrc_applied therefore continues supplying that input until application logic changes it. An installed callback can also alter inputs and must be included in the lifetime analysis.

Separate force ownership from total force

In the inspected forward engine, generalized applied force is added alongside passive and actuator contributions, and Cartesian applied forces are accumulated into the same acceleration computation. Clearing a disturbance array is consequently not equivalent to removing every force on the robot. Springs, gravity-related terms, actuator commands and constraints can still influence motion. Assign each writer ownership of particular external inputs so that one cleanup does not accidentally erase another intended disturbance or environmental load.

Propose a bounded disturbance fixture

A proposed fixture should compare a force retained across subsequent steps with the same force explicitly removed at the intended boundary. Hold initial state, controller and other inputs fixed. Record the force arrays before each dynamics evaluation and label the interval over which they act. Do not infer an impulse from a single logged amplitude: duration and integration convention also matter. This comparison is a suggested numerical diagnostic, not an executed robustness benchmark.

Accept the intended lifetime with a trace

Retain disturbance identity, affected bodies or degrees of freedom, coordinate convention, amplitude schedule and removal evidence. Inspect the actual simulation input after callbacks and wrapper logic have run, rather than only the request that asked for a tap. A reset may define another removal boundary, but it should not substitute for explicit per-trial scheduling. Distinguish an intentionally held external load from an accidental retained force so both experiments remain interpretable.

Keep disturbance accounting separate from physical realism

Correct force lifetime does not calibrate an impact, contact compliance or measured hardware response. The ManiSkill replay guide explains related action-interpretation evidence; software reproducibility supports preserving wrapper behavior. Here the concrete result is a declared applied-force schedule that matches the simulator inputs. Any later claim about real-world robustness needs an independently justified disturbance model and an observed evaluation under those conditions.

Earn rental income from GPUs

Have idle GPUs or looking to fund AI infrastructure? Retrivium finds a rental platform, sets up the server and helps you assess income and costs with a pilot.

Explore GPU hosting
← All articles