Principle:Google deepmind Mujoco CPU Model Loading
| Knowledge Sources | |
|---|---|
| Domains | Physics_Simulation, Python_API, Model_IO |
| Last Updated | 2026-02-15 06:00 GMT |
Overview
Mechanism for loading MuJoCo physics models into Python using the official Python bindings as the first step in an MJX GPU simulation pipeline.
Description
CPU Model Loading uses the mujoco Python package to parse and compile an MJCF XML model into a Python-wrapped MjModel object. This is the standard entry point for MJX workflows: the model is first loaded on CPU using the Python bindings, then transferred to GPU using mjx.put_model. The Python MjModel wraps the C mjModel struct and provides attribute access to all model fields.
Usage
Use this as the first step in any MJX GPU simulation pipeline. Load the model on CPU, then transfer to GPU with mjx.put_model.
Theoretical Basis
The Python bindings wrap the C API:
# Abstract loading pipeline (not real code)
python_model = python_bindings.load_xml(path) # wraps mj_loadXML
mjx_model = mjx.put_model(python_model) # transfer to GPU