From b60609d2a1335b7c6d5d81f36469bb55ffd10a58 Mon Sep 17 00:00:00 2001 From: Yuval Tassa Date: Wed, 15 Jul 2026 04:34:00 -0700 Subject: [PATCH] Add links to numbered changelog entries. PiperOrigin-RevId: 948257078 Change-Id: I7c9747debade178a94020cdf43ad1c3613a5c29a --- doc/changelog.rst | 2403 ++++++++++++++++++++++++--------------------- doc/conf.py | 1 + 2 files changed, 1267 insertions(+), 1137 deletions(-) diff --git a/doc/changelog.rst b/doc/changelog.rst index d12ad6c9..d6bf60f8 100644 --- a/doc/changelog.rst +++ b/doc/changelog.rst @@ -58,10 +58,10 @@ Version 3.10.0 (June 22, 2026) General ^^^^^^^ -1. Added :ref:`mju_threadpool`, a new function for creating a thread pool on an ``mjData`` instance. When a thread pool - is initialized, parts of the simulation pipeline, such as collision detection and constraint solving across islands, - are parallelized. The thread pool is automatically destroyed when the ``mjData`` is freed. -2. Added a unified :ref:`logging API`: +1. :commit:`b935d415` Added :ref:`mju_threadpool`, a new function for creating a thread pool on an ``mjData`` instance. + When a thread pool is initialized, parts of the simulation pipeline, such as collision detection and constraint + solving across islands, are parallelized. The thread pool is automatically destroyed when the ``mjData`` is freed. +2. :commit:`58f6d524` Added a unified :ref:`logging API`: - All errors, warnings, and informational messages are now routed through a single :ref:`mjfLogHandler` callback receiving a structured :ref:`mjLogMessage`. @@ -71,11 +71,11 @@ General - New types: :ref:`mjtLogLevel`, :ref:`mjtLogTopic`, :ref:`mjLogMessage`, :ref:`mjLogConfig`. - The legacy callbacks :ref:`mju_user_error` and :ref:`mju_user_warning` are deprecated but remain functional. -3. Added :ref:`mjs_numWarnings` and :ref:`mjs_getWarning` for retrieving all warnings accumulated during model - compilation and attachment. Deprecated :ref:`mjs_isWarning` in favor of ``mjs_numWarnings(s) > 0``. -4. Added the :ref:`compiler/conflict` attribute for controlling how conflicting global attributes - are resolved during :ref:`attachment`. Possible values are "warning" (default: parent values take - precedence, warnings emitted on conflicts), "merge" (per-field min/max/error strategy), and "error" (any +3. :commit:`6f8bb5ef` Added :ref:`mjs_numWarnings` and :ref:`mjs_getWarning` for retrieving all warnings accumulated + during model compilation and attachment. Deprecated :ref:`mjs_isWarning` in favor of ``mjs_numWarnings(s) > 0``. +4. :commit:`410c7316` Added the :ref:`compiler/conflict` attribute for controlling how conflicting + global attributes are resolved during :ref:`attachment`. Possible values are "warning" (default: parent + values take precedence, warnings emitted on conflicts), "merge" (per-field min/max/error strategy), and "error" (any conflict raises an error). See :ref:`Attribute Merging ` for details. .. admonition:: Future breaking API changes @@ -84,72 +84,76 @@ General The current default conflict resolution policy "warn" (ignore the child model) is backward compatible. However, the default policy will change to "merge" in a future release. -5. Improved primal solver convergence under float32. Improvements initially proposed by :github:user:`n3b` in - :issue:`2313` and :github:user:`adenzler-nvidia` in :doc:`MJWarp ` pull request +5. :commit:`cd6db9eb` Improved primal solver convergence under float32. Improvements initially proposed by + :github:user:`n3b` in :issue:`2313` and :github:user:`adenzler-nvidia` in :doc:`MJWarp ` pull request `1374 `__. -6. The :ref:`CG solver` now uses the Hager-Zhang conjugate direction update instead of the - Polak-Ribiere-Plus formula. This improves convergence and leads to a significant speedup under float32. -7. Added :ref:`mjs_makeFlex`, a new C API function equivalent to the :ref:`flexcomp` element for - programmatically creating flex objects with auto-generated bodies, joints, and equality constraints. Exposed as - ``body.make_flex()`` in Python. -8. Added support for loading 1D flex components from OBJ line segments -9. Significantly improved the quality of coarse convex hulls produced by the :ref:`maxhullvert` - attribute by invoking Qhull's `Q9 `__ option. +6. :commit:`828052e6` The :ref:`CG solver` now uses the Hager-Zhang conjugate direction update instead of + the Polak-Ribiere-Plus formula. This improves convergence and leads to a significant speedup under float32. +7. :commit:`4c381635` Added :ref:`mjs_makeFlex`, a new C API function equivalent to the :ref:`flexcomp` + element for programmatically creating flex objects with auto-generated bodies, joints, and equality constraints. + Exposed as ``body.make_flex()`` in Python. +8. :commit:`7a7dc7cc` Added support for loading 1D flex components from OBJ line segments +9. :commit:`ea2d785e` Significantly improved the quality of coarse convex hulls produced by the + :ref:`maxhullvert` attribute by invoking Qhull's + `Q9 `__ option. .. admonition:: Breaking API changes :class: attention - 10. The header file ``mjthread.h`` was removed along with the old engine threading API. + 10. :commit:`cd6db9eb` The header file ``mjthread.h`` was removed along with the old engine threading API. |br| **Migration:** Use :ref:`mju_threadpool` to set number of worker threads for the engine. - 11. Moved island sparse matrix construction from :ref:`mj_island` (single threaded) into :ref:`mj_fwdConstraint` - (multi-threaded). The island-specific matrices ``iM, iLD, iefc_J`` were removed from the arena and are now - allocated on the stack. - 12. Following the introduction of the :ref:`diagexact` flag, the ``mjData`` field - ``efc_diagApprox`` was renamed to ``efc_diagA``, as it can now be either the exact or approximate diagonal of - the :math:`A` ("Delassus") matrix. - 13. The deprecated functions ``mju_{error,warning}_{i,s}`` have been removed. + 11. :commit:`96bf8aea` Moved island sparse matrix construction from :ref:`mj_island` (single threaded) into + :ref:`mj_fwdConstraint` (multi-threaded). The island-specific matrices ``iM, iLD, iefc_J`` were removed from + the arena and are now allocated on the stack. + 12. :commit:`4548e81e` Following the introduction of the :ref:`diagexact` flag, the + ``mjData`` field ``efc_diagApprox`` was renamed to ``efc_diagA``, as it can now be either the exact or + approximate diagonal of the :math:`A` ("Delassus") matrix. + 13. :commit:`062b0f1e` The deprecated functions ``mju_{error,warning}_{i,s}`` have been removed. - 14. Changed the signature of :ref:`mj_fullM` from ``mj_fullM(m, dst, M)`` to ``mj_fullM(m, d, dst)`` as part of - the planned deprecation of ``mjData.qM`` in favor of the CSR-format ``mjData.M``. + 14. :commit:`7b9b8806` Changed the signature of :ref:`mj_fullM` from ``mj_fullM(m, dst, M)`` to + ``mj_fullM(m, d, dst)`` as part of the planned deprecation of ``mjData.qM`` in favor of the CSR-format + ``mjData.M``. **Migration:** For inertia matrix conversion, replace ``mj_fullM(m, dst, d->qM)`` with ``mj_fullM(m, d, dst)`` or ``mju_sym2dense(dst, d->M, m->nv, m->M_rownnz, m->M_rowadr, m->M_colind)``. Bug fixes ^^^^^^^^^ -15. Fixed a vulnerability in the System Identification toolbox where loading a trajectory or time series called - ``np.load`` with ``allow_pickle=True``, allowing arbitrary code execution from a malicious ``.npz`` file. Signal - metadata is now serialized as JSON and loaded with ``allow_pickle=False``. -16. Fixed a bug in the ``mjz`` :ref:`decoder ` where unnormalized paths would fail to be read. -17. Fixed a bug where the mesh compiler would produce non-unit convex hull polygon normals. +15. :commit:`a8eaccd2` Fixed a vulnerability in the System Identification toolbox where loading a trajectory or time + series called ``np.load`` with ``allow_pickle=True``, allowing arbitrary code execution from a malicious ``.npz`` + file. Signal metadata is now serialized as JSON and loaded with ``allow_pickle=False``. +16. :commit:`b9fb817a` Fixed a bug in the ``mjz`` :ref:`decoder ` where unnormalized paths would fail to be + read. +17. :commit:`986d73c0` Fixed a bug where the mesh compiler would produce non-unit convex hull polygon normals. Version 3.9.0 (May 27, 2026) ---------------------------- General ^^^^^^^ -1. Added ``mjData.efc_Y``, the whitened constraint Jacobian :math:`Y = J M^{-1/2}`, allocated in the arena when - dual solvers (PGS or NoSlip) are used or when :ref:`diagexact` is enabled. -2. Added the :ref:`diagexact` enable flag, which computes the exact diagonal of the - constraint-space inertia matrix at the current configuration, replacing the default compile-time approximation. - This improves solver quality for models with anisotropic inertias or complex kinematic coupling. See +1. :commit:`71d1014e` Added ``mjData.efc_Y``, the whitened constraint Jacobian :math:`Y = J M^{-1/2}`, allocated in the + arena when dual solvers (PGS or NoSlip) are used or when :ref:`diagexact` is enabled. +2. :commit:`71d1014e` Added the :ref:`diagexact` enable flag, which computes the exact diagonal + of the constraint-space inertia matrix at the current configuration, replacing the default compile-time + approximation. This improves solver quality for models with anisotropic inertias or complex kinematic coupling. See :ref:`Exact diagonal ` for details. -3. The pseudo-random constraint visitation order in the :ref:`PGS solver`, introduced in the previous - release, now uses a fixed seed. The previous implementation seeded with ``mjData.time``, which introduced subtle yet - undesirable time dependence. -4. Flexes are now allowed to sleep, with the exception of completely passive (constraint-free) flexes. -5. Added compiler timing diagnostics via the new :ref:`mjtCTimer` enum and the :ref:`mjs_getTimer` C API. After - :ref:`mj_compile`, per-category timings (total, assets, mesh loading, convex hull, normals, inertia, BVH, octree, - textures) are available via ``mjs_getTimer(spec)``. The :ref:`compile` sample prints a detailed timing - breakdown when run without an output file. -6. Added :ref:`mjtBool` to represent boolean variables, replacing :ref:`mjtByte` across all boolean fields in - :ref:`mjModel`, :ref:`mjData`, and public C API function signatures. +3. :commit:`7bfdbad8` The pseudo-random constraint visitation order in the :ref:`PGS solver`, introduced + in the previous release, now uses a fixed seed. The previous implementation seeded with ``mjData.time``, which + introduced subtle yet undesirable time dependence. +4. :commit:`f712eed4` Flexes are now allowed to sleep, with the exception of completely passive (constraint-free) + flexes. +5. :commit:`bdf00966` Added compiler timing diagnostics via the new :ref:`mjtCTimer` enum and the :ref:`mjs_getTimer` C + API. After :ref:`mj_compile`, per-category timings (total, assets, mesh loading, convex hull, normals, inertia, BVH, + octree, textures) are available via ``mjs_getTimer(spec)``. The :ref:`compile` sample prints a detailed + timing breakdown when run without an output file. +6. :commit:`393c1e42` Added :ref:`mjtBool` to represent boolean variables, replacing :ref:`mjtByte` across all boolean + fields in :ref:`mjModel`, :ref:`mjData`, and public C API function signatures. .. admonition:: Breaking API changes :class: attention - 7. The semantics of the contact ``margin`` and ``gap`` parameters have been redesigned for conceptual clarity and - consistency with `Newton `__. See the new + 7. :commit:`a4e49f2d` The semantics of the contact ``margin`` and ``gap`` parameters have been redesigned for + conceptual clarity and consistency with `Newton `__. See the new :ref:`margin and gap` documentation section for details. Previously, ``margin`` controlled the *detection threshold* (contacts exist when ``dist < margin``) and ``gap`` @@ -193,23 +197,25 @@ General Negative ``margin`` values are now permitted (corresponding to ``gap > margin`` under the old semantics). The constraint ``margin + gap >= 0`` should be maintained to ensure valid collision detection. - 8. The :ref:`mjfCollision` functions now populate the :ref:`mjPreContact` struct instead of the :ref:`mjContact` - struct. The :ref:`mjPreContact` only contains the necessary fields needed for the narrowphase collision detection. + 8. :commit:`7174d33f` The :ref:`mjfCollision` functions now populate the :ref:`mjPreContact` struct instead of the + :ref:`mjContact` struct. The :ref:`mjPreContact` only contains the necessary fields needed for the narrowphase + collision detection. - 9. The header file ``mjtnum.h`` was renamed to + 9. :commit:`2810edd2` The header file ``mjtnum.h`` was renamed to `mjtype.h ` and now includes all enum type definitions. - 10. The :ref:`tactile` sensor now reports raw depth instead of an estimated pressure. + 10. :commit:`f6cd0234` The :ref:`tactile` sensor now reports raw depth instead of an estimated + pressure. - 11. MJX: Removed the deprecated ``nconmax`` argument from ``mjx.make_data`` and ``mjx.put_data`` in favor of - ``naconmax``. + 11. :commit:`072125c4` MJX: Removed the deprecated ``nconmax`` argument from ``mjx.make_data`` and ``mjx.put_data`` + in favor of ``naconmax``. - 12. Maybe-breaking: Added `mjassert.h + 12. :commit:`15d27b36` Maybe-breaking: Added `mjassert.h `__, a new header containing compile-time assertions that verify the sizes of MuJoCo's public types for ABI stability. This is a first step - towards replacing ``int`` with strongly-typed enums in the public API. If these assertions fail on your compiler or - platform, please report the issue on GitHub. + towards replacing ``int`` with strongly-typed enums in the public API. If these assertions fail on your compiler + or platform, please report the issue on GitHub. Version 3.8.1 (May 11, 2026) @@ -217,43 +223,43 @@ Version 3.8.1 (May 11, 2026) General ^^^^^^^ -1. Added island support for the :ref:`PGS solver`. -2. The :ref:`PGS solver` now iterates over constraints in pseudo-random order, improving performance by - ~20%. -3. Added support for :ref:`elastic2d` for trilinear and quadratic flex +1. :commit:`647af382` Added island support for the :ref:`PGS solver`. +2. :commit:`4ed69b5c` The :ref:`PGS solver` now iterates over constraints in pseudo-random order, + improving performance by ~20%. +3. :commit:`b9c1877e` Added support for :ref:`elastic2d` for trilinear and quadratic flex :ref:`dofs`. -4. :ref:`Midpoint integration` is now restricted to the ``implicitfast`` +4. :commit:`910b3336` :ref:`Midpoint integration` is now restricted to the ``implicitfast`` :ref:`integrator` and is disabled when fluid forces are active (nonzero :ref:`density` or :ref:`viscosity`). Midpoint integration treats external forces as zero-order-hold constants, which causes energy gain in the presence of contacts and in fluid media. -5. Added :ref:`mjs_getOriginSpec`, returning the spec that originally defined an element, prior to attachment. This is - in contrast to :ref:`mjs_getSpec` which returns the spec currently owning the element. If the element is not the - result of an attach operation, the functions are identical. -6. Added :ref:`mju_sym2dense`, converting a lower-triangular, implicitly symmetric CSR matrix to a dense symmetric - matrix. The inertia matrix ``mjData.M`` is an example of such a matrix. +5. :commit:`68820957` Added :ref:`mjs_getOriginSpec`, returning the spec that originally defined an element, prior to + attachment. This is in contrast to :ref:`mjs_getSpec` which returns the spec currently owning the element. If the + element is not the result of an attach operation, the functions are identical. +6. :commit:`68820957` Added :ref:`mju_sym2dense`, converting a lower-triangular, implicitly symmetric CSR matrix to a + dense symmetric matrix. The inertia matrix ``mjData.M`` is an example of such a matrix. .. admonition:: Future breaking API changes :class: warning - 7. The introduction of :ref:`mju_sym2dense` is a step towards the removal of the legacy-format ``mjData.qM`` in favor - of the CSR-format ``mjData.M``. This removal will involve a future breaking change to :ref:`mj_fullM` (which - currently accepts a ``qM``-like matrix as an argument). To prevent a future breakage, replace - ``mj_fullM(m, dst, d->qM)`` with + 7. :commit:`767c607f` The introduction of :ref:`mju_sym2dense` is a step towards the removal of the legacy-format + ``mjData.qM`` in favor of the CSR-format ``mjData.M``. This removal will involve a future breaking change to + :ref:`mj_fullM` (which currently accepts a ``qM``-like matrix as an argument). To prevent a future breakage, + replace ``mj_fullM(m, dst, d->qM)`` with |br| ``mju_sym2dense(dst, d->M, m->nv, m->M_rownnz, m->M_rowadr, m->M_colind)``. Bug fixes ^^^^^^^^^ -8. Fixed default for multiccd in :doc:`mjcPhysics `. +8. :commit:`3e960ba3` Fixed default for multiccd in :doc:`mjcPhysics `. Python ^^^^^^ -9. Added ``MjSpec.encode`` method, wrapping :ref:`mj_encode`. -10. Added ``mujoco.MjVfs`` Python binding to interact with the Virtual File System directly from Python. - See :ref:`Virtual File System ` for usage details. +9. :commit:`d92fe081` Added ``MjSpec.encode`` method, wrapping :ref:`mj_encode`. +10. :commit:`723b8b1e` Added ``mujoco.MjVfs`` Python binding to interact with the Virtual File System directly from + Python. See :ref:`Virtual File System ` for usage details. .. warning:: The previous way of passing assets via a dictionary mapping asset names to bytes is **deprecated** and will be @@ -266,36 +272,38 @@ Version 3.8.0 (April 24, 2026) General ^^^^^^^ -1. Added support for Python 3.14. -2. Added :ref:`multi-cell support` for trilinear and quadratic flexes. Note that the implicit - integrator uses a dense solver for the flex degrees of freedom, which can be slow for multi-cell flexes. -3. Refactored ``strain`` flex :ref:`equality constraints` to be instantiated per cell instead of - per flex object, reducing the number of degrees of freedom per constraint row. The equality can be associated with a - specific cell with the new attribute :ref:`cell ` -4. Added new :ref:`mj_maxContact` function to get the maximum number of possible contacts returned by - colliding two geoms. -5. Added ``mj_containsBufferVFS`` and ``mj_containsFileVFS`` to check for existence of buffers and files in VFS. +1. :commit:`a04cf1b2` Added support for Python 3.14. +2. :commit:`2f2d00da` Added :ref:`multi-cell support` for trilinear and quadratic flexes. Note + that the implicit integrator uses a dense solver for the flex degrees of freedom, which can be slow for multi-cell + flexes. +3. :commit:`34d69ad4` Refactored ``strain`` flex :ref:`equality constraints` to be instantiated + per cell instead of per flex object, reducing the number of degrees of freedom per constraint row. The equality can + be associated with a specific cell with the new attribute :ref:`cell ` +4. :commit:`33259718` Added new :ref:`mj_maxContact` function to get the maximum number of possible + contacts returned by colliding two geoms. +5. :commit:`4cfebcc3` Added ``mj_containsBufferVFS`` and ``mj_containsFileVFS`` to check for existence of buffers and + files in VFS. .. admonition:: Breaking API changes :class: attention - 6. The :ref:`multiccd` option (multiple contacts returned from the convex collision detection pipeline) - is now enabled by default. The new implementation (as opposed to the legacy pipeline) has little performance - overhead and improves stability. + 6. :commit:`34d69ad4` The :ref:`multiccd` option (multiple contacts returned from the convex collision + detection pipeline) is now enabled by default. The new implementation (as opposed to the legacy pipeline) has + little performance overhead and improves stability. **Migration:** Disable :ref:`multiccd` to recover the previous behavior. Documentation ^^^^^^^^^^^^^ -7. Added :ref:`documentation` for :ref:`mjpDecoder` plugins. +7. :commit:`2f5e5d3d` Added :ref:`documentation` for :ref:`mjpDecoder` plugins. Bug fixes ^^^^^^^^^ -8. Asset paths in attached child specs are now resolved relative to the model file directory of the child spec, rather - than the parent spec. This prevents the origin of the parent spec to affect the resolution of asset paths in the - child spec. +8. :commit:`da01bd37` Asset paths in attached child specs are now resolved relative to the model file directory of the + child spec, rather than the parent spec. This prevents the origin of the parent spec to affect the resolution of + asset paths in the child spec. Version 3.7.0 (April 14, 2026) ------------------------------ @@ -303,10 +311,10 @@ Version 3.7.0 (April 14, 2026) General ^^^^^^^ -1. Added the :ref:`dcmotor` actuator for modeling DC motors. Supports optional +1. :commit:`70a7647a` Added the :ref:`dcmotor` actuator for modeling DC motors. Supports optional electrical dynamics (inductance), cogging torque, thermal resistance variation, and LuGre friction. See the `technical note <_static/dcmotor.pdf>`__ for more details. -2. Actuators with joint or tendon transmissions can now contribute +2. :commit:`510d75f4` Actuators with joint or tendon transmissions can now contribute :ref:`damping` and :ref:`armature` to their transmission target. These are applied during the passive force and inertia computations, respectively, and are scaled by gear\ :sup:`2` ("reflected" damping/inertia). @@ -315,49 +323,51 @@ General :align: right :width: 35% -3. Stiffness in :ref:`joints` and :ref:`tendons` and damping in - :ref:`joints` and :ref:`tendons` now support nonlinear polynomial - :ref:`force profiles`. New ``mjModel`` arrays (``jnt_stiffnesspoly``, ``tendon_stiffnesspoly``, - ``dof_dampingpoly``, ``tendon_dampingpoly``) hold higher-order coefficients. The existing scalar arrays - (``jnt_stiffness``, ``dof_damping``, etc.) continue to hold the linear coefficient and are unchanged. +3. :commit:`efae9157` Stiffness in :ref:`joints` and :ref:`tendons` and + damping in :ref:`joints` and :ref:`tendons` now support nonlinear + polynomial :ref:`force profiles`. New ``mjModel`` arrays (``jnt_stiffnesspoly``, + ``tendon_stiffnesspoly``, ``dof_dampingpoly``, ``tendon_dampingpoly``) hold higher-order coefficients. The existing + scalar arrays (``jnt_stiffness``, ``dof_damping``, etc.) continue to hold the linear coefficient and are unchanged. The polynomial order is defined by the new constant :ref:`mjNPOLY`. A future breaking C-API change may unify the linear and higher-order coefficients into a single array. -4. Added :ref:`midpoint integration` for standalone free bodies in ``implicit`` and ``implicitfast`` - :ref:`integrators`. This applies the implicit midpoint rule to the rotational dynamics of free bodies - with no children, conserving kinetic energy to machine precision in the absence of external torques. The - :ref:`invdiscrete` flag now also disables midpoint integration, providing an opt-out - mechanism. -5. Added the centripetal/Coriolis acceleration term :math:`\dot{J}v` to the constraint solver bias for - :ref:`connect` and :ref:`weld` equality constaints. This significantly improves the - stability of constrained mechanisms like four-bar linkages. See :ref:`Dual problem` for details. +4. :commit:`0c337799` Added :ref:`midpoint integration` for standalone free bodies in ``implicit`` and + ``implicitfast`` :ref:`integrators`. This applies the implicit midpoint rule to the rotational + dynamics of free bodies with no children, conserving kinetic energy to machine precision in the absence of external + torques. The :ref:`invdiscrete` flag now also disables midpoint integration, providing an + opt-out mechanism. +5. :commit:`412cee20` Added the centripetal/Coriolis acceleration term :math:`\dot{J}v` to the constraint solver bias + for :ref:`connect` and :ref:`weld` equality constaints. This significantly improves + the stability of constrained mechanisms like four-bar linkages. See :ref:`Dual problem` for details. -6. Introduced :ref:`mjpEncoder`, the counterpart to :ref:`mjpDecoder` for encoding of :ref:`mjSpec` and :ref:`mjModel` - into :ref:`mjResource`. +6. :commit:`0c337799` Introduced :ref:`mjpEncoder`, the counterpart to :ref:`mjpDecoder` for encoding of :ref:`mjSpec` + and :ref:`mjModel` into :ref:`mjResource`. -7. Added :ref:`mj_encode`, :ref:`mjp_registerEncoder`, :ref:`mjp_defaultEncoder`, and :ref:`mjp_findEncoder`. +7. :commit:`f5d3ce34` Added :ref:`mj_encode`, :ref:`mjp_registerEncoder`, :ref:`mjp_defaultEncoder`, and + :ref:`mjp_findEncoder`. .. admonition:: Breaking API changes :class: attention - 8. The ``mjs`` layer fields ``stiffness`` and ``damping`` in :ref:`mjsJoint` and :ref:`mjsTendon` have - been widened from ``mjtNum`` scalars to ``mjtNum[mjNPOLY+1]`` arrays. The first element is the linear coefficient - (previously the scalar), and subsequent elements are the higher-order :ref:`polynomial` coefficients. + 8. :commit:`efae9157` The ``mjs`` layer fields ``stiffness`` and ``damping`` in :ref:`mjsJoint` and :ref:`mjsTendon` + have been widened from ``mjtNum`` scalars to ``mjtNum[mjNPOLY+1]`` arrays. The first element is the linear + coefficient (previously the scalar), and subsequent elements are the higher-order :ref:`polynomial` + coefficients. **Migration:** Replace assignments like ``joint.stiffness = val`` with ``joint.stiffness[0] = val``. - 9. ``.obj`` and ``.stl`` decoders are now included as source when building MuJoCo with CMake. This fixes the - behaviour from the previous release where it required downstream code to load these plugins explicitly. + 9. :commit:`15ca42ff` ``.obj`` and ``.stl`` decoders are now included as source when building MuJoCo with CMake. This + fixes the behaviour from the previous release where it required downstream code to load these plugins explicitly. - 10. The ``vertcollide`` field in :ref:`mjsFlex` has been removed. It is no longer required since + 10. :commit:`4b1667e4` The ``vertcollide`` field in :ref:`mjsFlex` has been removed. It is no longer required since :doc:`MuJoCo Warp ` supports native flex collisions. - 11. :ref:`mjPLUGIN_LIB_INIT` macro now requires a name argument to avoid initialization function name collisions. - When building with MSVC, we now use the C runtime initialization section to initialize plugins instead of - ``DllMain``. See :ref:`plugin registration` for more details. + 11. :commit:`f2461f9c` :ref:`mjPLUGIN_LIB_INIT` macro now requires a name argument to avoid initialization function + name collisions. When building with MSVC, we now use the C runtime initialization section to initialize plugins + instead of ``DllMain``. See :ref:`plugin registration` for more details. - 12. The :ref:`mjtWarning` enum value ``mjWARN_VGEOMFULL`` is removed. Exhaustion of visual geoms is now handled - internally by the :ref:`mjvScene`. - 13. URDF parsing no longer hardcodes :ref:`strippath` to "true". The setting is now respected and - the default is "false". Setting this is attribute is now the responsibility of the user. + 12. :commit:`0e04436d` The :ref:`mjtWarning` enum value ``mjWARN_VGEOMFULL`` is removed. Exhaustion of visual geoms + is now handled internally by the :ref:`mjvScene`. + 13. :commit:`7ae07d81` URDF parsing no longer hardcodes :ref:`strippath` to "true". The setting + is now respected and the default is "false". Setting this is attribute is now the responsibility of the user. **Migration:** Set :ref:`strippath` to "true" in MJCF or programmatically using @@ -370,7 +380,7 @@ General Bug fixes ^^^^^^^^^ -14. The compiler now correctly accounts for negative scaling when loading user specified mesh data. +14. :commit:`efae9157` The compiler now correctly accounts for negative scaling when loading user specified mesh data. Version 3.6.0 (March 10, 2026) ------------------------------ @@ -381,32 +391,32 @@ General .. admonition:: Breaking API changes :class: attention - 1. The tendon Jacobian ``ten_J`` is now always sparse. The fields ``ten_J_rownnz``, ``ten_J_rowadr``, and - ``ten_J_colind`` have been moved from :ref:`mjData` to :ref:`mjModel` and are no longer computed at run time by - ``mj_tendon`` but at compile time. + 1. :commit:`1370a540` The tendon Jacobian ``ten_J`` is now always sparse. The fields ``ten_J_rownnz``, + ``ten_J_rowadr``, and ``ten_J_colind`` have been moved from :ref:`mjData` to :ref:`mjModel` and are no longer + computed at run time by ``mj_tendon`` but at compile time. -2. Added :ref:`mjs_getCompiler` C API function and a ``compiler`` read-only property to all Python spec element types. - This allows querying the compiler settings (e.g., ``meshdir``) from any element, with the correct originating spec's - compiler preserved after attachment. -3. Added a new ``strain`` :ref:`equality constraint` type for trilinear and quadratic - :ref:`dofs`. -4. Flexes now support collisions with SDF geoms. -5. Improved memory requirements for ``ten_J`` and ``ten_J_colind`` by reducing the upper bound for the number of - non-zeros ``nJten``. -6. Improved memory requirements for ``actuator_moment`` and ``moment_colind`` by reducing the upper bound for the number - of non-zeros ``nJmom``. +2. :commit:`6890e133` Added :ref:`mjs_getCompiler` C API function and a ``compiler`` read-only property to all Python + spec element types. This allows querying the compiler settings (e.g., ``meshdir``) from any element, with the correct + originating spec's compiler preserved after attachment. +3. :commit:`713b5524` Added a new ``strain`` :ref:`equality constraint` type for trilinear and + quadratic :ref:`dofs`. +4. :commit:`bf74d01d` Flexes now support collisions with SDF geoms. +5. :commit:`3cada28b` Improved memory requirements for ``ten_J`` and ``ten_J_colind`` by reducing the upper bound for + the number of non-zeros ``nJten``. +6. :commit:`1370a540` Improved memory requirements for ``actuator_moment`` and ``moment_colind`` by reducing the upper + bound for the number of non-zeros ``nJmom``. MJX ^^^ -7. Add batch rendering support for MJX-Warp. See the :ref:`MJX-Warp batch rendering` section for - details. +7. :commit:`3cada28b` Add batch rendering support for MJX-Warp. See the + :ref:`MJX-Warp batch rendering` section for details. Bug fixes ^^^^^^^^^ -8. Fixed a bug where :ref:`mjs_attach` silently dropped spatial tendons with wrapping geometries that had no - ``sidesite`` attribute (:issue:`3119`, reported by :github:user:`tomstewart89`). +8. :commit:`6ec808e2` Fixed a bug where :ref:`mjs_attach` silently dropped spatial tendons with wrapping geometries that + had no ``sidesite`` attribute (:issue:`3119`, reported by :github:user:`tomstewart89`). Version 3.5.0 (February 12, 2026) --------------------------------- @@ -414,8 +424,8 @@ Version 3.5.0 (February 12, 2026) Significant new features ^^^^^^^^^^^^^^^^^^^^^^^^ -1. :doc:`MuJoCo Warp ` is now officially released. -2. Added a new **System Identification** toolbox (Python), see +1. :commit:`54b8b68b` :doc:`MuJoCo Warp ` is now officially released. +2. :commit:`54b8b68b` Added a new **System Identification** toolbox (Python), see `README `__ for details. |br| A Colab notebook demonstrating the toolbox is available here: |sysid_colab| |br| Contribution by :github:user:`kevinzakka`, :github:user:`aftersomemath`, :github:user:`jonathanembleyriches`, @@ -425,34 +435,34 @@ Significant new features :target: https://colab.research.google.com/github/google-deepmind/mujoco/blob/main/python/mujoco/sysid/sysid.ipynb -3. Actuators and sensors now support arbitrary delays via history buffers, and sensor values can be computed at - intervals larger than the simulation timestep. Using a delay or interval introduces a new ``mjData.history`` variable - to the :ref:`Physics state`. See :ref:`Delays` for details. +3. :commit:`54b8b68b` Actuators and sensors now support arbitrary delays via history buffers, and sensor values can be + computed at intervals larger than the simulation timestep. Using a delay or interval introduces a new + ``mjData.history`` variable to the :ref:`Physics state`. See :ref:`Delays` for details. .. image:: images/changelog/poncho.png :width: 45% :align: right :target: https://github.com/google-deepmind/mujoco/blob/main/model/flex/poncho.xml -4. Added new :ref:`flexvert` equality constraints that enable cloth simulations with coarser meshes. - This adds a new attribute value ``vert`` to flexcomp edge :ref:`equality` and the new - equality type :ref:`flexvert`. Uses the method described in - `Chen, Kry and Vouga, 2019 `__. -5. Added implicit integration support for deformable objects (flex) in ``implicit`` and ``implicitfast`` - :ref:`integrators`. This method extracts the flex degrees of freedom and solves them as a dense block, - enabling increased stability for stiff flex objects without reducing the timestep. It is compatible with the - ``trilinear`` and ``quadratic`` :ref:`dof` types. +4. :commit:`7da271c6` Added new :ref:`flexvert` equality constraints that enable cloth simulations + with coarser meshes. This adds a new attribute value ``vert`` to flexcomp edge + :ref:`equality` and the new equality type :ref:`flexvert`. Uses the method + described in `Chen, Kry and Vouga, 2019 `__. +5. :commit:`0041fdcb` Added implicit integration support for deformable objects (flex) in ``implicit`` and + ``implicitfast`` :ref:`integrators`. This method extracts the flex degrees of freedom and solves them + as a dense block, enabling increased stability for stiff flex objects without reducing the timestep. It is compatible + with the ``trilinear`` and ``quadratic`` :ref:`dof` types. .. image:: images/XMLreference/rfcamera.png :width: 45% :align: right :target: https://github.com/google-deepmind/mujoco/blob/main/test/engine/testdata/sensor/rfcamera.xml -6. Rangefinder sensors can now be attached to a camera using the :ref:`rangefinder/camera` - attribute. In this case, the sensor respects the :ref:`camera/resolution` attribute and casts - multiple rays, one for each pixel. -7. :ref:`Rangefinders` can now report various kinds of information besides ray distances, - including surface normals and intersection points. +6. :commit:`54b8b68b` Rangefinder sensors can now be attached to a camera using the + :ref:`rangefinder/camera` attribute. In this case, the sensor respects the + :ref:`camera/resolution` attribute and casts multiple rays, one for each pixel. +7. :commit:`ed15493a` :ref:`Rangefinders` can now report various kinds of information besides ray + distances, including surface normals and intersection points. .. container:: custom-clear @@ -466,43 +476,45 @@ General .. admonition:: Breaking API changes :class: attention - 8. Ray-cast functions now optionally compute the surface normal at the ray intersection. This is a breaking change - due to the addition of the ``mjtNum normal[3]`` argument. The modified functions are :ref:`mj_ray`, - :ref:`mj_multiRay`, :ref:`mju_rayGeom`, :ref:`mj_rayFlex`, :ref:`mj_rayHfield` and :ref:`mj_rayMesh`. + 8. :commit:`54b8b68b` Ray-cast functions now optionally compute the surface normal at the ray intersection. This is a + breaking change due to the addition of the ``mjtNum normal[3]`` argument. The modified functions are + :ref:`mj_ray`, :ref:`mj_multiRay`, :ref:`mju_rayGeom`, :ref:`mj_rayFlex`, :ref:`mj_rayHfield` and + :ref:`mj_rayMesh`. **Migration:** In C/C++, pass ``NULL`` to the ``normal`` argument. In Python, in all functions except :ref:`mj_multiRay`, it defaults to ``None``, so no action is required. - 9. ``mju_rayFlex`` has been renamed to :ref:`mj_rayFlex` for consistency with other functions that take - ``mjModel*`` and ``mjData*`` arguments. + 9. :commit:`218226fc` ``mju_rayFlex`` has been renamed to :ref:`mj_rayFlex` for consistency with other functions that + take ``mjModel*`` and ``mjData*`` arguments. - 10. The ``mjModel.cam_orthographic`` field has been renamed to ``cam_projection``, with the semantic of a new enum - type :ref:`mjtProjection`. This will allow for more projection types in the future like fisheye cameras. - Relatedly, the ``camera/orthographic`` MJCF attribute for cameras has been renamed to + 10. :commit:`54b8b68b` The ``mjModel.cam_orthographic`` field has been renamed to ``cam_projection``, with the + semantic of a new enum type :ref:`mjtProjection`. This will allow for more projection types in the future like + fisheye cameras. Relatedly, the ``camera/orthographic`` MJCF attribute for cameras has been renamed to :ref:`camera/projection` and now accepts the values ``orthographic`` and ``perspective``. **Migration:** Replace ``orthographic = "false/true"`` with ``projection="perspective/orthographic"``, respectively. - 11. Removed ``getdir`` from the ``mjpResourceProvider`` struct. All Resource Providers now use the same shared - implementation. - 12. When combining the ``margin`` or ``gap`` :ref:`parameters` of two geoms to obtain the parameters - of a contact, the respective values are now **summed** rather than taking the maximum. This allows geom - margins to be a proper "inflation" of the geom. + 11. :commit:`cb9a9c15` Removed ``getdir`` from the ``mjpResourceProvider`` struct. All Resource Providers now use the + same shared implementation. + 12. :commit:`54b8b68b` When combining the ``margin`` or ``gap`` :ref:`parameters` of two geoms to obtain + the parameters of a contact, the respective values are now **summed** rather than taking the maximum. This allows + geom margins to be a proper "inflation" of the geom. -13. Camera frustum visualization is now triggered by setting :ref:`resolution` to values larger - than 1. Relatedly, frustum visualization also works for :ref:`orthographic` cameras. - See :ref:`rangefinder` for details. -14. Cameras now have an :ref:`output` attribute, parsed into the ``mjModel.cam_output`` bitfield. - Unused by the renderer, it serves as a convenient location to store a camera's supported output types. -15. Added :ref:`mj_mountVFS` and :ref:`mj_unmountVFS` functions for mounting a custom VFS provider. Mounting allows - providers to be used to open/read/close resources dynamically at arbitrary paths. -16. The optimization whereby sequential :ref:`collision sensors` with identical attributes shared - computation has been removed. This results in a (likely minor) performance regression for models which exploited - this optimization. To recover the performance, use the :ref:`fromto` and compute the other values - manually. If ``from = fromto[0:3]`` and ``to = fromto[3:6]`` then ``distance = norm(to-from)`` and +13. :commit:`c7f57663` Camera frustum visualization is now triggered by setting + :ref:`resolution` to values larger than 1. Relatedly, frustum visualization also works for + :ref:`orthographic` cameras. See :ref:`rangefinder` for details. +14. :commit:`608115ab` Cameras now have an :ref:`output` attribute, parsed into the + ``mjModel.cam_output`` bitfield. Unused by the renderer, it serves as a convenient location to store a camera's + supported output types. +15. :commit:`54b8b68b` Added :ref:`mj_mountVFS` and :ref:`mj_unmountVFS` functions for mounting a custom VFS provider. + Mounting allows providers to be used to open/read/close resources dynamically at arbitrary paths. +16. :commit:`1d2d0b1c` The optimization whereby sequential :ref:`collision sensors` with identical + attributes shared computation has been removed. This results in a (likely minor) performance regression for models + which exploited this optimization. To recover the performance, use the :ref:`fromto` and compute the + other values manually. If ``from = fromto[0:3]`` and ``to = fromto[3:6]`` then ``distance = norm(to-from)`` and ``normal = normalize(to-from)``. -17. :doc:`OpenUSD `: +17. :commit:`a5dc57c0` :doc:`OpenUSD `: - Parsing has been moved out of experimental into a mjpDecoder plugin. (documentation pending) - OpenUSD can now be built with the @@ -512,7 +524,7 @@ General library. - Users no longer have to set ``PXR_PLUGINPATH_NAME`` environment variable, MuJoCo should load USD plugins automatically. -18. Non-breaking ABI changes: +18. :commit:`1ff74ba8` Non-breaking ABI changes: - The type of the ``sig`` (signature) argument of :ref:`mj_stateSize` and related functions has been changed from ``unsigned int`` to ``int``. Before this change, invalid negative arguments passed to this function would result @@ -523,33 +535,33 @@ General MJX ^^^ -19. Added ``actuator_length``, ``cdof`` and ``cdof_dof`` fields to ``mjx.Data``. -20. Add ``graph_mode`` argument to ``put_model`` to support multiple Warp graph capture modes. +19. :commit:`1483aefe` Added ``actuator_length``, ``cdof`` and ``cdof_dof`` fields to ``mjx.Data``. +20. :commit:`d07f39b4` Add ``graph_mode`` argument to ``put_model`` to support multiple Warp graph capture modes. Documentation ^^^^^^^^^^^^^ -21. General improvements to the :ref:`Programming/Simulation` chapter. Notably, the main discussion of - :ref:`state` has been moved there, and the section on :ref:`mjModel changes` has been - expanded. -22. The usability of the :ref:`MJCF schema` is improved with a collapsible dropdown menu with links to elements - and attributes. -23. MuJoCo version numbering is now based on Semantic Versioning, see +21. :commit:`b77977a9` General improvements to the :ref:`Programming/Simulation` chapter. Notably, the main + discussion of :ref:`state` has been moved there, and the section on :ref:`mjModel changes` + has been expanded. +22. :commit:`c5925e7b` The usability of the :ref:`MJCF schema` is improved with a collapsible dropdown menu + with links to elements and attributes. +23. :commit:`54b8b68b` MuJoCo version numbering is now based on Semantic Versioning, see `VERSIONING.md `__. Bug fixes ^^^^^^^^^ -24. Fixed a bug in :ref:`implicit integrator` derivatives where actuator velocity derivatives were - incorrectly computed when the force was clamped by :ref:`forcerange`. -25. Fixed a bug in :ref:`implicit integrator` derivatives where actuator velocity derivatives did not - account for the :ref:`actearly` flag. -26. Multi-threaded mesh processing, enabled by the :ref:`usethread` compiler flag (on by default), - was in fact disabled by the flag. Fixing this bug speeds up compilation of mesh-heavy models by (up to) the number - of available cores. -27. The ``vertid`` argument of :ref:`mj_rayFlex` and :ref:`mju_raySkin` was marked as nullable but was not; it is now - nullable. -28. Fixed :ref:`gravcomp` being ignored for bodies with no joints nested inside jointed parent bodies - (:issue:`3066`, reported by :github:user:`Alex108306`). +24. :commit:`b4668294` Fixed a bug in :ref:`implicit integrator` derivatives where actuator velocity + derivatives were incorrectly computed when the force was clamped by :ref:`forcerange`. +25. :commit:`7f74487a` Fixed a bug in :ref:`implicit integrator` derivatives where actuator velocity + derivatives did not account for the :ref:`actearly` flag. +26. :commit:`54b8b68b` Multi-threaded mesh processing, enabled by the :ref:`usethread` compiler flag + (on by default), was in fact disabled by the flag. Fixing this bug speeds up compilation of mesh-heavy models by (up + to) the number of available cores. +27. :commit:`218226fc` The ``vertid`` argument of :ref:`mj_rayFlex` and :ref:`mju_raySkin` was marked as nullable but + was not; it is now nullable. +28. :commit:`c1b3b306` Fixed :ref:`gravcomp` being ignored for bodies with no joints nested inside + jointed parent bodies (:issue:`3066`, reported by :github:user:`Alex108306`). Version 3.4.0 (December 5, 2025) -------------------------------- @@ -562,20 +574,21 @@ General :align: right :width: 35% -1. Introduced a major new feature: :ref:`sleeping islands`. Preliminary release for early testing, see - documentation for details. -2. Added "quadratic" option to :ref:`flexcomp/dof`. This type of fast :ref:`deformable` - flex object is similar to the "trilinear" option, but it includes curved deformations. -3. Raise an error if there are name collisions also during parsing. -4. Increase Windows stack size to 16MB to enable models with deep nested body hierarchies. -5. Added a new pipeline component function :ref:`mj_fwdKinematics` that combines all kinematics-like sub-components. - Relatedly, added a clarifying table at the top of the :ref:`Simulation Pipeline` chapter. -6. Added a new :ref:`mj_extractState` function that allows a subset of a state that was previously returned by - :ref:`mj_getState` to be extracted without having to be written back into ``mjData`` first. -7. Added a new :ref:`mj_copyState` function that copies state components from one ``mjData`` to another. -8. Tendon paths can now be queried from Python via ``MjsTendon.path``, the returned object +1. :commit:`8734cab3` Introduced a major new feature: :ref:`sleeping islands`. Preliminary release for early + testing, see documentation for details. +2. :commit:`3a7aa84e` Added "quadratic" option to :ref:`flexcomp/dof`. This type of fast + :ref:`deformable` flex object is similar to the "trilinear" option, but it includes curved deformations. +3. :commit:`b6f25ca6` Raise an error if there are name collisions also during parsing. +4. :commit:`b6f25ca6` Increase Windows stack size to 16MB to enable models with deep nested body hierarchies. +5. :commit:`19e2d0ae` Added a new pipeline component function :ref:`mj_fwdKinematics` that combines all kinematics-like + sub-components. Relatedly, added a clarifying table at the top of the :ref:`Simulation Pipeline` chapter. +6. :commit:`2f65e237` Added a new :ref:`mj_extractState` function that allows a subset of a state that was previously + returned by :ref:`mj_getState` to be extracted without having to be written back into ``mjData`` first. +7. :commit:`888d3a7b` Added a new :ref:`mj_copyState` function that copies state components from one ``mjData`` to + another. +8. :commit:`ac2cd5df` Tendon paths can now be queried from Python via ``MjsTendon.path``, the returned object is iterable and indexing it will give the ``MjsWrap`` at the given index in the path. -9. ``MjsWrap`` now exposes: +9. :commit:`ac2cd5df` ``MjsWrap`` now exposes: - ``type -> mujoco.mjtWrap`` - ``target -> MjsSite|MjsJoint|MjsGeom|None`` @@ -583,7 +596,7 @@ General - ``coef -> real`` - ``divisor -> real`` -10. Non-breaking ABI changes: +10. :commit:`86a77ff8` Non-breaking ABI changes: - :ref:`mjtSize` is now defined as ``int64_t`` rather than ``uint64_t`` to avoid future type-promotion bugs. - :ref:`mj_sizeModel` now returns an :ref:`mjtSize` rather than an ``int``. @@ -591,20 +604,21 @@ General MJX ^^^ -11. ``warp-lang`` optional dependency is updated to 1.10.0. ``pmap`` now works with MuJoCo Warp from MJX. +11. :commit:`c34ac712` ``warp-lang`` optional dependency is updated to 1.10.0. ``pmap`` now works with MuJoCo Warp from + MJX. .. admonition:: Breaking ABI changes :class: attention - 12. ``mjx.Model.tex_data`` is now a numpy ndarray instead of a jax.Array, to avoid vmapping over this potentially - large array. This may break certain use-cases with Madrona MJX, but we are no longer supporting this codepath. - We will be migrating users to a Warp-based batch renderer. + 12. :commit:`d0f32a7f` ``mjx.Model.tex_data`` is now a numpy ndarray instead of a jax.Array, to avoid vmapping over + this potentially large array. This may break certain use-cases with Madrona MJX, but we are no longer supporting + this codepath. We will be migrating users to a Warp-based batch renderer. Bug fixes ^^^^^^^^^ -13. Fixed a bug in the box-box distance computation. Reported by :github:user:`nvtw`. +13. :commit:`88383684` Fixed a bug in the box-box distance computation. Reported by :github:user:`nvtw`. Version 3.3.7 (October 13, 2025) -------------------------------- @@ -615,42 +629,48 @@ General .. admonition:: Breaking API changes :class: attention - 1. The mjSpec C API fields :ref:`meshdir` and :ref:`texturedir` have been - moved to `compiler.meshdir `__ - and `compiler.texturedir `__ + 1. :commit:`f7708954` The mjSpec C API fields :ref:`meshdir` and + :ref:`texturedir` have been moved to + `compiler.meshdir `__ + and + `compiler.texturedir `__ respectively. For backwards compatibility, the old fields are still available in the Python API but will be removed in a future release. **Migration:** Replace ``meshdir`` and ``texturedir`` with ``compiler.meshdir`` and ``compiler.texturedir``. - 2. Remove ``_full_compat`` from ``mjx.put_data`` and ``mjx.put_model``. - 3. ``nconmax`` and ``njmax`` fields in ``mjx.make_data`` now default to ``None`` instead of -1. ``nconmax`` will be deprecated - in favor of ``naconmax`` in a future release. + 2. :commit:`192da874` Remove ``_full_compat`` from ``mjx.put_data`` and ``mjx.put_model``. + 3. :commit:`b56cf98e` ``nconmax`` and ``njmax`` fields in ``mjx.make_data`` now default to ``None`` instead of -1. + ``nconmax`` will be deprecated in favor of ``naconmax`` in a future release. -4. Joint decorators and spatial tendons which have limits defined and whose current value (angle or length) exceeds the - limit, are recolored by using the :ref:`constraint impedance` :math:`d` to mix the existing color with - :ref:`visual/rgba/constraint`. For spatial tendons, this visualization aid is active only if - no :ref:`material` is set and :ref:`rgba` is default. -5. Added :ref:`mju_getXMLDependencies` for computing a list of unique asset dependencies from an MJCF file. -6. Added the code sample ``dependencies`` which provides command line utility for printing the result of :ref:`mju_getXMLDependencies`. -7. The minimum C++ standard required to compile MuJoCo is now C++20, this has been the case within Google since 2023 - but the CMake update was forgotten. +4. :commit:`fe8384b6` Joint decorators and spatial tendons which have limits defined and whose current value (angle or + length) exceeds the limit, are recolored by using the :ref:`constraint impedance` :math:`d` to mix the + existing color with :ref:`visual/rgba/constraint`. For spatial tendons, this visualization + aid is active only if no :ref:`material` is set and :ref:`rgba` is + default. +5. :commit:`e4704cd2` Added :ref:`mju_getXMLDependencies` for computing a list of unique asset dependencies from an MJCF + file. +6. :commit:`e4704cd2` Added the code sample ``dependencies`` which provides command line utility for printing the result + of :ref:`mju_getXMLDependencies`. +7. :commit:`f7708954` The minimum C++ standard required to compile MuJoCo is now C++20, this has been the case within + Google since 2023 but the CMake update was forgotten. .. admonition:: Breaking ABI changes :class: attention - 8. The attribute ``mjOption.apirate`` was unused and has been removed. - 9. MJX ``nconmax`` and ``njmax`` fields in ``mjx.make_data`` now default to ``None`` instead of -1. + 8. :commit:`431f9657` The attribute ``mjOption.apirate`` was unused and has been removed. + 9. :commit:`b56cf98e` MJX ``nconmax`` and ``njmax`` fields in ``mjx.make_data`` now default to ``None`` instead of + -1. MJX ^^^ -10. Fix :issue:`2508`, ``qLD`` shapes mismatched mjModel during ``get_data_into``. -11. Pull in MuJoCo Warp update to ``io.py``, and use ``naconmax`` instead of ``nconmax`` to set the maximum number - of contacts over all environments. +10. :commit:`6ae9cc80` Fix :issue:`2508`, ``qLD`` shapes mismatched mjModel during ``get_data_into``. +11. :commit:`f7708954` Pull in MuJoCo Warp update to ``io.py``, and use ``naconmax`` instead of ``nconmax`` to set the + maximum number of contacts over all environments. Bug fixes ^^^^^^^^^ -12. Fix :issue:`2881`, :at:`fitaabb` was adding an offset to the mesh and applying an incorrect frame +12. :commit:`98682ae2` Fix :issue:`2881`, :at:`fitaabb` was adding an offset to the mesh and applying an incorrect frame transformation. Also, unify the meaning of fitting a geom to a mesh AABB: it now means to find the smallest geom such that its AABB contains the mesh AABB. @@ -659,18 +679,19 @@ Version 3.3.6 (September 15, 2025) General ^^^^^^^ -1. Constraint island discovery and construction, previously an experimental feature, is now :ref:`documented` - and promoted to default; disable it with :ref:`option/flag/island `. We expect islanding to be - a strict improvement over the monolithic constraint solver, please let us know if you experience any issues. -2. :ref:`Contact sensor` :at-val:`subtree1/subtree2` specification is now available for any body, not - just direct children of the world. +1. :commit:`ec94bb49` Constraint island discovery and construction, previously an experimental feature, is now + :ref:`documented` and promoted to default; disable it with :ref:`option/flag/island `. + We expect islanding to be a strict improvement over the monolithic constraint solver, please let us know if you + experience any issues. +2. :commit:`7443e685` :ref:`Contact sensor` :at-val:`subtree1/subtree2` specification is now available + for any body, not just direct children of the world. .. admonition:: Breaking API changes :class: attention - 3. The update of ``mjData.qacc_warmstart`` was moved from the end of the solver call (:ref:`mj_fwdConstraint`) to - the end of :ref:`mj_step`, and is now updated with all other state variables. This change makes :ref:`mj_forward` - fully idempotent. + 3. :commit:`6ec5f8b9` The update of ``mjData.qacc_warmstart`` was moved from the end of the solver call + (:ref:`mj_fwdConstraint`) to the end of :ref:`mj_step`, and is now updated with all other state variables. This + change makes :ref:`mj_forward` fully idempotent. Before this change, calling :ref:`mj_forward` repeatedly would make the constraint solver converge, since each subsequent call would start from the previously updated ``qacc_warmstart`` value. @@ -686,7 +707,7 @@ General integration principled and well-defined. Since this change to RK4 is effectively a bug fix, migration to the previous behavior is not provided. - 4. The ``mjDSBL_PASSIVE`` flag for disabling passive forces was removed and replaced by + 4. :commit:`b092563c` The ``mjDSBL_PASSIVE`` flag for disabling passive forces was removed and replaced by :ref:`mjDSBL_SPRING` and :ref:`mjDSBL_DAMPER` with corresponding :ref:`mjcf` :ref:`attributes`. Each flag disables only joint and tendon springs or dampers, respectively. When both flags are set, **all** passive forces are disabled, including gravity @@ -699,31 +720,32 @@ General .. admonition:: Breaking ABI changes :class: attention - 5. Removed ``mjMOUSE_SELECT`` flag for :ref:`mjtMouse` as it is no longer in use. + 5. :commit:`ed6fa7fe` Removed ``mjMOUSE_SELECT`` flag for :ref:`mjtMouse` as it is no longer in use. - 6. The promotion of islanding to default involved removing the enable flag ``mjENBL_ISLAND`` and + 6. :commit:`ec94bb49` The promotion of islanding to default involved removing the enable flag ``mjENBL_ISLAND`` and converting it to a disable flag :ref:`mjDSBL_ISLAND `. -7. Added support for shells with a curved reference configuration. See this `example +7. :commit:`b66175eb` Added support for shells with a curved reference configuration. See this `example `__. -8. Added experimental option for :ref:`passive` contacts involving flexes. +8. :commit:`8acd83f3` Added experimental option for :ref:`passive` contacts involving flexes. -9. Added support for assigning a default material to a mesh asset using the :ref:`mesh/material ` - attribute. +9. :commit:`1fb1810b` Added support for assigning a default material to a mesh asset using the + :ref:`mesh/material ` attribute. MJX ^^^ -10. Promote ``ten_length`` to the public MJX API. Add Warp support for ``mjx.tendon``. +10. :commit:`d7e925bd` Promote ``ten_length`` to the public MJX API. Add Warp support for ``mjx.tendon``. .. admonition:: Breaking API changes :class: attention - 11. ``ten_length`` was moved from ``mjx.Data._impl.ten_length`` to a public field ``mjx.Data.ten_length``. + 11. :commit:`d7e925bd` ``ten_length`` was moved from ``mjx.Data._impl.ten_length`` to a public field + ``mjx.Data.ten_length``. Bug fixes ^^^^^^^^^ -12. Fixed a latent bug where MjData objects were not serialized correctly by the Python bindings when islanding was - enabled. +12. :commit:`ec94bb49` Fixed a latent bug where MjData objects were not serialized correctly by the Python bindings when + islanding was enabled. Version 3.3.5 (August 8, 2025) @@ -731,45 +753,46 @@ Version 3.3.5 (August 8, 2025) General ^^^^^^^ -1. Added the :ref:`insidesite` sensor, for checking if an object is inside the volume of a site. - It is useful for triggering events in surrounding environment logic. -2. Added the :ref:`contact` sensor, for reporting contact information according to user-defined - criteria. +1. :commit:`e6c57159` Added the :ref:`insidesite` sensor, for checking if an object is inside the + volume of a site. It is useful for triggering events in surrounding environment logic. +2. :commit:`3152458a` Added the :ref:`contact` sensor, for reporting contact information according to + user-defined criteria. The purpose of the :el:`contact` sensor is to report contact-related information in a fixed-size array. This is useful as input to learning-based agents and in environment logic. -3. Added the :ref:`tactile` sensor, for measuring the penetration depth between two objects at given - points and the sliding velocities in the tangent frame. The sensor reports tactile data only when colliding with - SDFs. -4. Removed the SdfLib plugin and the dependency on `SdfLib `__. SDFs are now - supported natively in mjModel. -5. Removed ``oct_depth`` from :ref:`mjvOption` (unused). -6. Added the functionality to create a builtin meshes, see :ref:`mesh/builtin`. -7. Inertia computation in MuJoCo C is now performed by a new :ref:`pipeline` function :ref:`mj_makeM`, which - combines the Composite Rigid Body algorithm in :ref:`mj_crb` and additional terms related to +3. :commit:`51babec9` Added the :ref:`tactile` sensor, for measuring the penetration depth between two + objects at given points and the sliding velocities in the tangent frame. The sensor reports tactile data only when + colliding with SDFs. +4. :commit:`0b11e3e3` Removed the SdfLib plugin and the dependency on `SdfLib `__. + SDFs are now supported natively in mjModel. +5. :commit:`5e666635` Removed ``oct_depth`` from :ref:`mjvOption` (unused). +6. :commit:`89f47890` Added the functionality to create a builtin meshes, see :ref:`mesh/builtin`. +7. :commit:`ad0dc0de` Inertia computation in MuJoCo C is now performed by a new :ref:`pipeline` function + :ref:`mj_makeM`, which combines the Composite Rigid Body algorithm in :ref:`mj_crb` and additional terms related to :ref:`tendon armature`. Code that uses :ref:`mj_crb` to compute the inertia should now use :ref:`mj_makeM` instead. .. admonition:: Breaking API changes :class: attention - 8. Removed the ``mjVIS_FLEXBVH`` enum value, its functionality is now provided by :ref:`mjVIS_MESHBVH`. + 8. :commit:`5e666635` Removed the ``mjVIS_FLEXBVH`` enum value, its functionality is now provided by + :ref:`mjVIS_MESHBVH`. Bug fixes ^^^^^^^^^ -9. Fixed a bug that caused object lists in the child to have missing elements after attaching an mjSpec. This was - caused by adding to the lists only the objects that belong to the tree of the requested body, but this causes to - skip objects that were attached, since they belong to the tree of the parent. -10. Fixed a bug where the convex hull of a collision mesh was not being computed if the mesh could only collide via a - :ref:`contact pair`. +9. :commit:`3152458a` Fixed a bug that caused object lists in the child to have missing elements after attaching an + mjSpec. This was caused by adding to the lists only the objects that belong to the tree of the requested body, but + this causes to skip objects that were attached, since they belong to the tree of the parent. +10. :commit:`3434f5d9` Fixed a bug where the convex hull of a collision mesh was not being computed if the mesh could + only collide via a :ref:`contact pair`. Python ^^^^^^ -11. On Linux, built distribution packages (wheels) now target the ``manylinux_2_28`` platform tag. Previously MuJoCo - wheels targeted ``manylinux2014`` based on CentOS 7, which reached end-of-life in June 2024. +11. :commit:`2e60d058` On Linux, built distribution packages (wheels) now target the ``manylinux_2_28`` platform tag. + Previously MuJoCo wheels targeted ``manylinux2014`` based on CentOS 7, which reached end-of-life in June 2024. MJX ^^^ -12. Add Warp as a backend implementation for MJX. The implementation can be specified via +12. :commit:`47bc16a3` Add Warp as a backend implementation for MJX. The implementation can be specified via ``mjx.put_model(m, impl='warp')`` and ``mjx.make_data(m, impl='warp')``. The warp implementation requires a CUDA device and ``warp-lang`` to be installed (``pip install mujoco-mjx[warp]``). This feature is available in "beta" and some bugs are expected. @@ -780,72 +803,78 @@ Version 3.3.4 (July 8, 2025) .. admonition:: Breaking API changes :class: attention - 1. The functions ``mjs_detachBody`` and ``mjs_detachDefault`` have been replaced by :ref:`mjs_delete`. - 2. The Python functions ``element.delete`` have been replaced by ``spec.delete(element)``. - 3. In the mjSpec C API, directly setting an element's name using :ref:`mjs_setString` has been replaced with a new - function :ref:`mjs_setName` which allows checking for naming collisions at set-time rather than compile-time, for - earlier catching of errors. Relatedly, the ``name`` attribute has been removed from all mjs elements. Known issue: - the error is not raised during parsing. - 4. For MJX, the ``mjx.Option`` dataclass now has private and public fields similar to ``mjx.Model`` and - ``mjx.Data``. Some fields are no longer publicly available due to differences in the + 1. :commit:`18d5d5d0` The functions ``mjs_detachBody`` and ``mjs_detachDefault`` have been replaced by + :ref:`mjs_delete`. + 2. :commit:`0488d9f4` The Python functions ``element.delete`` have been replaced by ``spec.delete(element)``. + 3. :commit:`564c51dd` In the mjSpec C API, directly setting an element's name using :ref:`mjs_setString` has been + replaced with a new function :ref:`mjs_setName` which allows checking for naming collisions at set-time rather + than compile-time, for earlier catching of errors. Relatedly, the ``name`` attribute has been removed from all mjs + elements. Known issue: the error is not raised during parsing. + 4. :commit:`47bc16a3` For MJX, the ``mjx.Option`` dataclass now has private and public fields similar to + ``mjx.Model`` and ``mjx.Data``. Some fields are no longer publicly available due to differences in the underlying implementations of this data structure. General ^^^^^^^ -5. Added support for setting the initial camera in the viewer using +5. :commit:`14dc7c2a` Added support for setting the initial camera in the viewer using :ref:`visual/global/cameraid`. -6. Added support to only sync the state in the Python :ref:`passive viewer`'s ``Sync`` method, this is - useful to improve performance. The default behavior is unchanged and copies the entire model and data. +6. :commit:`09f7154e` Added support to only sync the state in the Python :ref:`passive viewer`'s + ``Sync`` method, this is useful to improve performance. The default behavior is unchanged and copies the entire model + and data. Bug fixes ^^^^^^^^^ -7. Inverse dynamics were not being computed correctly when :ref:`tendon armature` was present, - now fixed. -8. Fix bug in ``mjx.put_data`` where ``actuator_moment`` was not being copied correctly for the C implementation. +7. :commit:`4ce62932` Inverse dynamics were not being computed correctly when + :ref:`tendon armature` was present, now fixed. +8. :commit:`45d4cacc` Fix bug in ``mjx.put_data`` where ``actuator_moment`` was not being copied correctly for the C + implementation. Documentation ^^^^^^^^^^^^^ -9. Added missing item documentation and clarified the nature of breaking changes in the 3.3.3 changelog. - See items 3 and 4 below. +9. :commit:`7548d370` Added missing item documentation and clarified the nature of breaking changes in the 3.3.3 + changelog. See items 3 and 4 below. Version 3.3.3 (June 10, 2025) ----------------------------- General ^^^^^^^ -1. Refactored island implementation so that island data is memory-contiguous. This speeds up island processing in the - solver and clears the way for the addition of the Newton and PGS solvers (currently only CG is supported). -2. Removed the :at:`shell` plugin. This is now supported by :ref:`flexcomp` and is active depending on - the :ref:`elastic2d` attribute (off by default). +1. :commit:`ecb769fc` Refactored island implementation so that island data is memory-contiguous. This speeds up island + processing in the solver and clears the way for the addition of the Newton and PGS solvers (currently only CG is + supported). +2. :commit:`7edbdd0a` Removed the :at:`shell` plugin. This is now supported by :ref:`flexcomp` and is + active depending on the :ref:`elastic2d` attribute (off by default). .. admonition:: Breaking API changes :class: attention - 3. Replaced the :ref:`directional` (boolean) field for lights with a + 3. :commit:`74cc904e` Replaced the :ref:`directional` (boolean) field for lights with a :ref:`type` field (of type :ref:`mjtLightType`) to allow for additional lighting types. **Migration:** Replace light/directional="false/true" with light/type="spot/directional", respectively. - 4. Added :ref:`mjtColorSpace` enum and associated :ref:`colorspace` attribute that allows - to specify the color space of textures (either linear or `sRGB `__). Since - this property is now read correctly from PNG files, textures files which use sRGB will now be rendered - differently. + 4. :commit:`7548d370` Added :ref:`mjtColorSpace` enum and associated :ref:`colorspace` + attribute that allows to specify the color space of textures (either linear or + `sRGB `__). Since this property is now read correctly from PNG files, textures + files which use sRGB will now be rendered differently. **Migration:** Set :ref:`colorspace` to "linear" for all textures that should look like they did before this change. -5. Added new sub-component :ref:`mj_makeM` which combines the :ref:`mj_crb` call with additional logic to support the - introduction in 3.3.1 of :ref:`tendon armature`. In addition to the traditional - ``mjData.qM``, :ref:`mj_makeM` also computes ``mjData.M``, a CSR representation of the same matrix. -6. Added a new function :ref:`mj_copyBack` to copy real-valued arrays in an mjModel to a compatible mjSpec. -7. Removed the limitation of :ref:`fusestatic` to models which contain no references. The - fusestatic flag will now fuse all bodies which are not referenced and ignore bodies which are referenced. +5. :commit:`89e39dc0` Added new sub-component :ref:`mj_makeM` which combines the :ref:`mj_crb` call with additional + logic to support the introduction in 3.3.1 of :ref:`tendon armature`. In addition to the + traditional ``mjData.qM``, :ref:`mj_makeM` also computes ``mjData.M``, a CSR representation of the same matrix. +6. :commit:`84ad22a5` Added a new function :ref:`mj_copyBack` to copy real-valued arrays in an mjModel to a compatible + mjSpec. +7. :commit:`b8768aa1` Removed the limitation of :ref:`fusestatic` to models which contain no + references. The fusestatic flag will now fuse all bodies which are not referenced and ignore bodies which are + referenced. Simulate ^^^^^^^^ -8. The struct ``mjv_sceneState`` has been removed. This struct was used for partial synchronization of ``mjModel`` and - ``mjData`` when the Python viewer is used in passive mode. This functionality is now provided by +8. :commit:`ced63018` The struct ``mjv_sceneState`` has been removed. This struct was used for partial synchronization + of ``mjModel`` and ``mjData`` when the Python viewer is used in passive mode. This functionality is now provided by :ref:`mjv_copyModel` and :ref:`mjv_copyData`, which don't copy arrays which are not required for visualization. .. image:: images/changelog/procedural_terrain_generation.png @@ -855,20 +884,20 @@ Simulate Python bindings ^^^^^^^^^^^^^^^ -9. Added examples of procedural terrain generation to the Model Editing tutorial: |mjspec_colab| +9. :commit:`3a4b6e6c` Added examples of procedural terrain generation to the Model Editing tutorial: |mjspec_colab| MJX ^^^ -10. Added tendon armature. +10. :commit:`caaf7b3a` Added tendon armature. Version 3.3.2 (April 28, 2025) ------------------------------ MJX ^^^ -1. Added inverse dynamics. -2. Added tendon actuator force sensor. -3. Fix :issue:`2606` such that ``make_data`` copies over ``mocap_pos`` and ``mocap_quat`` +1. :commit:`51c489fc` Added inverse dynamics. +2. :commit:`f317bd17` Added tendon actuator force sensor. +3. :commit:`421c487d` Fix :issue:`2606` such that ``make_data`` copies over ``mocap_pos`` and ``mocap_quat`` from ``body_pos`` and ``body_quat``. Version 3.3.1 (Apr 9, 2025) @@ -877,33 +906,34 @@ Version 3.3.1 (Apr 9, 2025) .. admonition:: Breaking API changes :class: attention - 1. The default value of the flag for toggling :ref:`internal flex contacts` was changed from - "true" to "false". This feature has proven to be counterintuitive for users. - 2. All of the attach functions (``mjs_attachBody``, ``mjs_attachFrame``, ``mjs_attachToSite``, + 1. :commit:`f25fc63f` The default value of the flag for toggling :ref:`internal flex contacts` + was changed from "true" to "false". This feature has proven to be counterintuitive for users. + 2. :commit:`a02a27d4` All of the attach functions (``mjs_attachBody``, ``mjs_attachFrame``, ``mjs_attachToSite``, ``mjs_attachFrameToSite``) have been removed and replaced by a single function :ref:`mjs_attach`. General ^^^^^^^ -3. Added :ref:`tendon armature`: inertia associated with changes in tendon length. -4. Added the :ref:`compiler/saveinertial` flag, writing explicit inertial clauses for all - bodies when saving to XML. -5. Added :ref:`orientation` attribute to :ref:`composite`. Moreover, allow the - composite to be the direct child of a frame. -6. Added :ref:`tendon actuator force limits` and +3. :commit:`d05251af` Added :ref:`tendon armature`: inertia associated with changes in tendon + length. +4. :commit:`f96f3e1c` Added the :ref:`compiler/saveinertial` flag, writing explicit inertial + clauses for all bodies when saving to XML. +5. :commit:`f96f3e1c` Added :ref:`orientation` attribute to :ref:`composite`. + Moreover, allow the composite to be the direct child of a frame. +6. :commit:`96dda6ea` Added :ref:`tendon actuator force limits` and :ref:`tendon actuator force sensor`. MJX ^^^ -7. Added tendon actuator force limits. +7. :commit:`8fc616bf` Added tendon actuator force limits. Bug fixes ^^^^^^^^^ -8. :ref:`mj_jacDot` was missing a term that accounts for the motion of the point with respect to +8. :commit:`de48f417` :ref:`mj_jacDot` was missing a term that accounts for the motion of the point with respect to which the Jacobian is computed, now fixed. -9. Fixed a bug that caused the parent frame of elements in the child worldbody to be incorrectly set when attaching an - mjSpec to a frame or a site. -10. Fixed a bug that caused shadow rendering to flicker on platforms (e.g., MacOS) that do not support - ARB_clip_control. Fixed in collaboration with :github:user:`aftersomemath`. +9. :commit:`1bf24e9f` Fixed a bug that caused the parent frame of elements in the child worldbody to be incorrectly set + when attaching an mjSpec to a frame or a site. +10. :commit:`006c18b1` Fixed a bug that caused shadow rendering to flicker on platforms (e.g., MacOS) that do not + support ARB_clip_control. Fixed in collaboration with :github:user:`aftersomemath`. Python bindings ^^^^^^^^^^^^^^^ @@ -913,8 +943,8 @@ Python bindings :align: right :width: 240px -11. Added examples of procedural model creation to the Model Editing tutorial: |mjspec_colab| -12. Added support for nameless :ref:`mjSpec` objects in the ``bind`` method, see the corresponding +11. :commit:`16e49f27` Added examples of procedural model creation to the Model Editing tutorial: |mjspec_colab| +12. :commit:`006c18b1` Added support for nameless :ref:`mjSpec` objects in the ``bind`` method, see the corresponding :ref:`section` in the documentation. .. |mjspec_colab| image:: https://colab.research.google.com/assets/colab-badge.png @@ -930,15 +960,16 @@ Feature promotion :align: right :width: 240px -1. Introduced a new kind of **fast deformable body**, activated by setting :ref:`flexcomp/dof` to - "trilinear". This type of :ref:`deformable` flex object has the same collision geometry as a regular - flex, but has far fewer degrees of freedom. Instead of 3 dofs per vertex, only the corners of the bounding box are - free to move, with the positions of the interior vertices computed with trilinear interpolation of the 8 corners, for - a total of 24 dofs for the entire flex object (or less, if some of the corners are pinned). This limits the types of - deformation achievable by the flex, but allows for much faster simulation. For example, see the video on the right - comparing `full `__ and `trilinear - `__ flexes for modeling - deformable gripper pads. +1. :commit:`7cdf1806` Introduced a new kind of **fast deformable body**, activated by setting + :ref:`flexcomp/dof` to "trilinear". This type of :ref:`deformable` flex object has + the same collision geometry as a regular flex, but has far fewer degrees of freedom. Instead of 3 dofs per vertex, + only the corners of the bounding box are free to move, with the positions of the interior vertices computed with + trilinear interpolation of the 8 corners, for a total of 24 dofs for the entire flex object (or less, if some of the + corners are pinned). This limits the types of deformation achievable by the flex, but allows for much faster + simulation. For example, see the video on the right comparing + `full `__ and + `trilinear `__ flexes for + modeling deformable gripper pads. .. image:: images/computation/ccd_light.gif @@ -951,7 +982,7 @@ Feature promotion :align: right :class: only-dark -2. The native convex collision detection pipeline introduced in 3.2.3 and enabled by the +2. :commit:`ed16f2da` The native convex collision detection pipeline introduced in 3.2.3 and enabled by the :ref:`nativeccd` flag, is now the default. See the section on :ref:`Convex Collision Detection` for more details. @@ -959,24 +990,25 @@ Feature promotion General ^^^^^^^ -3. Add support for custom plots in the MuJoCo viewer by exposing a ``viewport`` property, a ``set_figures`` method, - and a ``clear_figures`` method. -4. Separate collision and deformation meshes for :ref:`flex`. This enables a fixed cost for the soft - body computations, while preserving the fidelity of high-resolution collisions. -5. Added :ref:`potential` and :ref:`kinetic` energy sensors. -6. Improved shadow rendering in the native renderer. -7. Moved ``introspect`` to ``python/introspect``. +3. :commit:`37d7591c` Add support for custom plots in the MuJoCo viewer by exposing a ``viewport`` property, a + ``set_figures`` method, and a ``clear_figures`` method. +4. :commit:`7cdf1806` Separate collision and deformation meshes for :ref:`flex`. This enables a fixed + cost for the soft body computations, while preserving the fidelity of high-resolution collisions. +5. :commit:`240a7afd` Added :ref:`potential` and :ref:`kinetic` energy sensors. +6. :commit:`ac2a324f` Improved shadow rendering in the native renderer. +7. :commit:`b0e9d086` Moved ``introspect`` to ``python/introspect``. .. admonition:: Breaking API changes :class: attention - 8. As mentioned above, the native convex collision detection pipeline is now the default, which may break some - workflows. In this case, set :ref:`nativeccd` to "disable" to restore the old behavior. - 9. Added :ref:`mjs_setDeepCopy` API function. When the deep copy flag is 0, attaching a model will not copy it to the - parent, so the original references to the child can be used to modify the parent after attachment. The default - behavior is to perform such a shallow copy. The old behavior of creating a deep copy of the child model while - attaching can be restored by setting the deep copy flag to 1. - 10. Changes to inertia inference from meshes: + 8. :commit:`ed16f2da` As mentioned above, the native convex collision detection pipeline is now the default, which + may break some workflows. In this case, set :ref:`nativeccd` to "disable" to restore the + old behavior. + 9. :commit:`240a7afd` Added :ref:`mjs_setDeepCopy` API function. When the deep copy flag is 0, attaching a model will + not copy it to the parent, so the original references to the child can be used to modify the parent after + attachment. The default behavior is to perform such a shallow copy. The old behavior of creating a deep copy of + the child model while attaching can be restored by setting the deep copy flag to 1. + 10. :commit:`89253d95` Changes to inertia inference from meshes: Previously, in order to specify that the mass lies on the surface, :ref:`geom/shellinertia` could be used for any geom type. Now this attribute is ignored if the geom is a mesh; instead, inertia inference @@ -984,21 +1016,21 @@ General Previously, if the volumetric inertia computation failed (for example due to a very flat mesh), the compiler would silently fall back to surface inertia computation. Now, the compiler will throw an informative error. - 11. Removed the composite type ``grid``. Users should instead use :ref:`flexcomp`. - 12. Removed the ``particle`` composite type. It is recommended to use the more generic :ref:`replicate` - instead, see for example `this model + 11. :commit:`0fcd20f0` Removed the composite type ``grid``. Users should instead use :ref:`flexcomp`. + 12. :commit:`c52d1b39` Removed the ``particle`` composite type. It is recommended to use the more generic + :ref:`replicate` instead, see for example `this model `__. MJX ^^^ -13. Added support for spatial tendons with internal sphere and cylinder wrapping. -14. Fix a bug with box-box collisions :issue:`2356`. +13. :commit:`f4096bca` Added support for spatial tendons with internal sphere and cylinder wrapping. +14. :commit:`e0664b1b` Fix a bug with box-box collisions :issue:`2356`. Python bindings ^^^^^^^^^^^^^^^ -15. Added a pedagogical colab notebook for ``mujoco.rollout``, a Python module for multithreaded simulation rollouts. - It is available here |rollout_colab|. +15. :commit:`7a2ad8fd` Added a pedagogical colab notebook for ``mujoco.rollout``, a Python module for multithreaded + simulation rollouts. It is available here |rollout_colab|. |br| Contribution by :github:user:`aftersomemath`. .. |rollout_colab| image:: https://colab.research.google.com/assets/colab-badge.png @@ -1009,12 +1041,12 @@ Version 3.2.7 (Jan 14, 2025) Python bindings ^^^^^^^^^^^^^^^ -1. :ref:`rollout` now features native multi-threading. If a sequence of ``MjData`` instances - of length ``nthread`` is passed in, ``rollout`` will automatically create a thread pool and parallelize +1. :commit:`a7eb6efd` :ref:`rollout` now features native multi-threading. If a sequence of ``MjData`` + instances of length ``nthread`` is passed in, ``rollout`` will automatically create a thread pool and parallelize the computation. The thread pool can be reused across calls, but then the function cannot be called simultaneously from multiple threads. To run multiple threaded rollouts simultaneously, use the new class ``Rollout`` which encapsulates the thread pool. Contribution by :github:user:`aftersomemath`. -2. Fix global namespace pollution when using ``mjpython`` (:issue:`2265`). +2. :commit:`40ef08c8` Fix global namespace pollution when using ``mjpython`` (:issue:`2265`). General ^^^^^^^ @@ -1022,90 +1054,94 @@ General .. admonition:: Breaking API changes (minor) :class: attention - 3. The field ``mjData.qLDiagSqrtInv`` has been removed. This field is only required for the dual solvers. It is now - computed as-needed rather than unconditionally. Relatedly, added the corresponding argument to :ref:`mj_solveM2`. + 3. :commit:`69c9ac07` The field ``mjData.qLDiagSqrtInv`` has been removed. This field is only required for the dual + solvers. It is now computed as-needed rather than unconditionally. Relatedly, added the corresponding argument to + :ref:`mj_solveM2`. -4. Reduced the memory footprint of the PGS solver's :ref:`A matrix`. This was the last remaining dense-memory - allocation in MuJoCo, allowing for a significant reduction of the :ref:`dynamic memory allocation heuristic`. +4. :commit:`d4ca66a4` Reduced the memory footprint of the PGS solver's :ref:`A matrix`. This was the last + remaining dense-memory allocation in MuJoCo, allowing for a significant reduction of the + :ref:`dynamic memory allocation heuristic`. Bug fixes ^^^^^^^^^ -5. Fixed a bug in the box-sphere collider, depth was incorrect for deep penetrations (:issue:`2206`). -6. Fixed a bug in :ref:`mj_mulM2` and added a test. +5. :commit:`0e7d2ef6` Fixed a bug in the box-sphere collider, depth was incorrect for deep penetrations (:issue:`2206`). +6. :commit:`ec322641` Fixed a bug in :ref:`mj_mulM2` and added a test. Version 3.2.6 (Dec 2, 2024) --------------------------- General ^^^^^^^ -1. Removed rope and loop from :ref:`composite`. The user is encouraged to instead use the :at:`cable` - plugin or :ref:`flexcomp`, respectively. +1. :commit:`300450f8` Removed rope and loop from :ref:`composite`. The user is encouraged to instead use + the :at:`cable` plugin or :ref:`flexcomp`, respectively. MJX ^^^ -2. Added muscle actuators. +2. :commit:`0f381a9e` Added muscle actuators. Python bindings ^^^^^^^^^^^^^^^ -3. Provide prebuilt wheels for Python 3.13. -4. Added ``bind`` method and removed id attribute from :ref:`mjSpec` objects. Using ids is error prone in scenarios of - repeated attachment and detachment. Python users are encouraged to use names for unique identification of model - elements. -5. :ref:`rollout` can now accept sequences of MjModel of length ``nroll``. Also removed the ``nroll`` - argument because its value can always be inferred. +3. :commit:`74dcd51d` Provide prebuilt wheels for Python 3.13. +4. :commit:`ec9986dc` Added ``bind`` method and removed id attribute from :ref:`mjSpec` objects. Using ids is error + prone in scenarios of repeated attachment and detachment. Python users are encouraged to use names for unique + identification of model elements. +5. :commit:`ec9986dc` :ref:`rollout` can now accept sequences of MjModel of length ``nroll``. Also removed + the ``nroll`` argument because its value can always be inferred. Bug fixes ^^^^^^^^^ -6. Fixed :issue:`2212`, type error in ``mjx.get_data``. -7. Fixed bug introduced in 3.2.0 in handling of :ref:`texrepeat` attribute, was mistakenly - cast from ``float`` to ``int``, (fixed :issue:`2223`). +6. :commit:`f9569cda` Fixed :issue:`2212`, type error in ``mjx.get_data``. +7. :commit:`ec9986dc` Fixed bug introduced in 3.2.0 in handling of :ref:`texrepeat` attribute, + was mistakenly cast from ``float`` to ``int``, (fixed :issue:`2223`). Version 3.2.5 (Nov 4, 2024) --------------------------- Feature promotion ^^^^^^^^^^^^^^^^^ -1. The :doc:`Model Editing` framework afforded by :ref:`mjSpec`, introduced in 3.2.0 as an - in-development feature, is now stable and recommended for general use. -2. The native convex collision detection pipeline introduced in 3.2.3 and enabled by the +1. :commit:`b6037d17` The :doc:`Model Editing` framework afforded by :ref:`mjSpec`, introduced in + 3.2.0 as an in-development feature, is now stable and recommended for general use. +2. :commit:`298ce31e` The native convex collision detection pipeline introduced in 3.2.3 and enabled by the :ref:`nativeccd` flag, is not yet the default but is already recommended for general use. Please try it when encountering collision-related problems and report any issues you encounter. General ^^^^^^^ -3. The global compiler flag ``exactmeshinertia`` has been removed and replaced with the mesh-specific +3. :commit:`b598d79b` The global compiler flag ``exactmeshinertia`` has been removed and replaced with the mesh-specific :ref:`inertia` attribute. -4. The not-useful ``convexhull`` compiler option (to disable computation of mesh convex hulls) has been removed. -5. Removed the deprecated ``mju_rotVecMat``, ``mju_rotVecMatT`` and ``mjv_makeConnector`` functions. -6. Sorting now uses a faster, native sort function (fixes :issue:`1638`). -7. The PBR texture layers introduced in 3.2.1 were refactored from separate sub-elements to a single +4. :commit:`7dc8aef8` The not-useful ``convexhull`` compiler option (to disable computation of mesh convex hulls) has + been removed. +5. :commit:`d8494fef` Removed the deprecated ``mju_rotVecMat``, ``mju_rotVecMatT`` and ``mjv_makeConnector`` functions. +6. :commit:`61cb552f` Sorting now uses a faster, native sort function (fixes :issue:`1638`). +7. :commit:`61cb552f` The PBR texture layers introduced in 3.2.1 were refactored from separate sub-elements to a single :ref:`layer` sub-element. -8. The composite types box, cylinder, and sphere have been removed. Users should instead use the equivalent types - available in :ref:`flexcomp`. +8. :commit:`831d9881` The composite types box, cylinder, and sphere have been removed. Users should instead use the + equivalent types available in :ref:`flexcomp`. MJX ^^^ -9. Added ``apply_ft``, ``jac``, and ``xfrc_accumulate`` as public functions. -10. Added ``TOUCH`` sensor. -11. Added support for ``eq_active``. Fixes :issue:`2173`. -12. Added ray intersection with ellipsoid. +9. :commit:`680fb3e5` Added ``apply_ft``, ``jac``, and ``xfrc_accumulate`` as public functions. +10. :commit:`b00a7c67` Added ``TOUCH`` sensor. +11. :commit:`f24de91c` Added support for ``eq_active``. Fixes :issue:`2173`. +12. :commit:`3c21abc0` Added ray intersection with ellipsoid. Bug fixes ^^^^^^^^^ -13. Fixed several bugs related to connect and weld constraints with site semantics (fixes :issue:`2179`, reported - by :github:user:`yinfanyi`). The introduction of site specification to connects and welds in 3.2.3 conditionally - changed the semantics of `mjData.eq_obj1id` and `mjData.eq_obj2id`, but these changes were not properly propagated - in several places leading to incorrect computations of constraint inertia, readings of affected force/torque sensors - and runtime enabling/disabling of such constraints. -14. Fixed a bug in slider-crank :ref:`transmission`. The bug was introduced in 3.0.0. -15. Fixed a bug in flex texture coordinates that prevented the correct allocation of textures in mjModel. +13. :commit:`864b805a` Fixed several bugs related to connect and weld constraints with site semantics (fixes + :issue:`2179`, reported by :github:user:`yinfanyi`). The introduction of site specification to connects and welds in + 3.2.3 conditionally changed the semantics of `mjData.eq_obj1id` and `mjData.eq_obj2id`, but these changes were not + properly propagated in several places leading to incorrect computations of constraint inertia, readings of affected + force/torque sensors and runtime enabling/disabling of such constraints. +14. :commit:`7620aef5` Fixed a bug in slider-crank :ref:`transmission`. The bug was introduced in 3.0.0. +15. :commit:`831d9881` Fixed a bug in flex texture coordinates that prevented the correct allocation of textures in + mjModel. Documentation ^^^^^^^^^^^^^ -16. Function headers in the :doc:`API reference <../APIreference/APIfunctions>` now link to their source definitions - in GitHub. +16. :commit:`1d58576d` Function headers in the :doc:`API reference <../APIreference/APIfunctions>` now link to their + source definitions in GitHub. Version 3.2.4 (Oct 15, 2024) ---------------------------- @@ -1118,36 +1154,39 @@ General :align: right :width: 240px -1. The Newton solver no longer requires ``nv*nv`` memory allocation, allowing for much larger models. See e.g., - `100_humanoids.xml `__. - Two quadratic-memory allocations still remain to be fully sparsified: ``mjData.actuator_moment`` and the matrices - used by the PGS solver. -2. Removed the :at:`solid` and :at:`membrane` plugins and moved the associated computations into the engine. See `3D - example model `__ and `2D example model - `__ for examples of flex objects - that previously required these plugins. -3. Replaced the function ``mjs_setActivePlugins`` with :ref:`mjs_activatePlugin`. +1. :commit:`2dd51873` The Newton solver no longer requires ``nv*nv`` memory allocation, allowing for much larger models. + See e.g., + `100_humanoids.xml `__. Two + quadratic-memory allocations still remain to be fully sparsified: ``mjData.actuator_moment`` and the matrices used by + the PGS solver. +2. :commit:`4998e7b3` Removed the :at:`solid` and :at:`membrane` plugins and moved the associated computations into the + engine. See `3D example model `__ and `2D + example model `__ for examples of flex + objects that previously required these plugins. +3. :commit:`6832df30` Replaced the function ``mjs_setActivePlugins`` with :ref:`mjs_activatePlugin`. MJX ^^^ -4. Added ``mocap_pos`` and ``mocap_quat`` in kinematics. -5. Added support for :ref:`spatial tendons ` with pulleys and external sphere and cylinder wrapping. -6. Added sphere-cylinder and sphere-ellipsoid collision functions (:issue:`2126`). -7. Fixed a bug with frictionloss constraints. -8. Added ``TENDONPOS`` and ``TENDONVEL`` sensors. -9. Fixed a bug with the computation of tangential contact forces in ``_decode_pyramid``. -10. Added ``JOINTINPARENT`` actuator transmission type. +4. :commit:`1a9d3070` Added ``mocap_pos`` and ``mocap_quat`` in kinematics. +5. :commit:`160ed9bf` Added support for :ref:`spatial tendons ` with pulleys and external sphere and + cylinder wrapping. +6. :commit:`fa22e6d0` Added sphere-cylinder and sphere-ellipsoid collision functions (:issue:`2126`). +7. :commit:`22e4f7fc` Fixed a bug with frictionloss constraints. +8. :commit:`ac91a763` Added ``TENDONPOS`` and ``TENDONVEL`` sensors. +9. :commit:`19459263` Fixed a bug with the computation of tangential contact forces in ``_decode_pyramid``. +10. :commit:`096853e1` Added ``JOINTINPARENT`` actuator transmission type. Python bindings ^^^^^^^^^^^^^^^ -11. Removed support for Python 3.8, now that it's `deprecated upstream `__. +11. :commit:`6881ce24` Removed support for Python 3.8, now that it's + `deprecated upstream `__. Bug fixes ^^^^^^^^^ -12. Fixed a bug where ``actuator_force`` was not set in MJX (:issue:`2068`). -13. Fixed bug where MJX data tendon fields were incorrect after calling ``mjx.put_data``. -14. The compiler now returns an error if height fields are used with :ref:`collision sensors` as they - are not yet supported. +12. :commit:`ab3954d8` Fixed a bug where ``actuator_force`` was not set in MJX (:issue:`2068`). +13. :commit:`5838f847` Fixed bug where MJX data tendon fields were incorrect after calling ``mjx.put_data``. +14. :commit:`8d84b5f6` The compiler now returns an error if height fields are used with + :ref:`collision sensors` as they are not yet supported. Version 3.2.3 (Sep 16, 2024) @@ -1159,85 +1198,87 @@ General .. admonition:: Breaking API changes :class: attention - 1. The runtime options ``mpr_tolerance`` and ``mpr_iterations`` were renamed to + 1. :commit:`088079ef` The runtime options ``mpr_tolerance`` and ``mpr_iterations`` were renamed to :ref:`ccd_tolerance` and :ref:`ccd_iterations`, both in XML and in the :ref:`mjOption` struct. This is because the new convex collision detection pipeline (see below) does not use the MPR algorithm. The semantics of these options remain identical. - 2. The functions ``mjs_findMesh`` and ``mjs_findKeyframe`` were replaced by ``mjs_findElement``, which allows to look - for any object type. - 3. The experimental use of 2D/3D elasticity plugins with :ref:`composite` has been removed. Users - should instead use :ref:`flexcomp`, which provides the correct collision behavior. + 2. :commit:`d3dfa6f9` The functions ``mjs_findMesh`` and ``mjs_findKeyframe`` were replaced by ``mjs_findElement``, + which allows to look for any object type. + 3. :commit:`4862b9e7` The experimental use of 2D/3D elasticity plugins with :ref:`composite` has been + removed. Users should instead use :ref:`flexcomp`, which provides the correct collision behavior. -4. Added the :ref:`nativeccd` flag. When this flag is enabled, general convex collision - detection is handled with a new native code path, rather than `libccd `__. - This feature is in early stages of testing, but users who've experienced issues related to collision detection are - welcome to experiment with it and report any issues. +4. :commit:`0bffd744` Added the :ref:`nativeccd` flag. When this flag is enabled, general convex + collision detection is handled with a new native code path, rather than + `libccd `__. This feature is in early stages of testing, but users who've + experienced issues related to collision detection are welcome to experiment with it and report any issues. .. youtube:: kcM_oauk3ZA :aspect: 16:7 :align: right :width: 240px -5. Added a new way of defining :ref:`connect` and :ref:`weld` equality constraints, - using two sites. The new semantic is useful when the assumption that the constraint is satisfied - in the base configuration does not hold. In this case the sites will "snap together" at the beginning of the - simulation. Additionally, changing the site positions (``mjModel.site_pos``) and orientations +5. :commit:`60a1921b` Added a new way of defining :ref:`connect` and :ref:`weld` + equality constraints, using two sites. The new semantic is useful when the assumption that the constraint is + satisfied in the base configuration does not hold. In this case the sites will "snap together" at the beginning of + the simulation. Additionally, changing the site positions (``mjModel.site_pos``) and orientations ( ``mjModel.site_quat``) at runtime will correctly modify the constraint definition. This `example model `__ using the new semantic is shown in the video on the right. -6. Introduced **free joint alignment**, an optimization that applies to bodies with a free joint and no child bodies - (simple free-floating bodies): automatically aligning the body frame with the inertial frame. This feature can be - toggled individually using the :ref:`freejoint/align` attribute or globally using the compiler - :ref:`alignfree` attribute. The alignment diagonalizes the related 6x6 inertia sub-matrix, - leading to both faster and more stable simulation of free bodies. +6. :commit:`577afd1e` Introduced **free joint alignment**, an optimization that applies to bodies with a free joint and + no child bodies (simple free-floating bodies): automatically aligning the body frame with the inertial frame. This + feature can be toggled individually using the :ref:`freejoint/align` attribute or globally + using the compiler :ref:`alignfree` attribute. The alignment diagonalizes the related 6x6 inertia + sub-matrix, leading to both faster and more stable simulation of free bodies. While this optimization is a strict improvement, it changes the semantics of the joint's degrees-of-freedom. Therefore, ``qpos`` and ``qvel`` values saved in older versions (for example, in :ref:`keyframes`) will become invalid. The global compiler attribute currently defaults to "false" due to this potential breakage, but could be changed to "true" in a future release. Aligned free joints are recommended for all new models. -7. Added an :ref:`mjSpec` option for creating a texture directly from a buffer. -8. :ref:`shell (surface) inertia ` is now supported by all geom types. -9. When :ref:`attaching` sub-models, :ref:`keyframes` will now be correctly merged into the - parent model, but only on the first attachment. -10. Added the :ref:`mjtSameFrame` enum which contains the possible frame alignments of bodies and their children. These - alignments are used for computation shortcuts in :ref:`mj_kinematics`. -11. Added :ref:`mj_jacDot` for computing time-derivatives of kinematic Jacobians. Fixes :issue:`411`. +7. :commit:`577afd1e` Added an :ref:`mjSpec` option for creating a texture directly from a buffer. +8. :commit:`577afd1e` :ref:`shell (surface) inertia ` is now supported by all geom types. +9. :commit:`8b03daa0` When :ref:`attaching` sub-models, :ref:`keyframes` will now be correctly + merged into the parent model, but only on the first attachment. +10. :commit:`8b03daa0` Added the :ref:`mjtSameFrame` enum which contains the possible frame alignments of bodies and + their children. These alignments are used for computation shortcuts in :ref:`mj_kinematics`. +11. :commit:`2d3d5415` Added :ref:`mj_jacDot` for computing time-derivatives of kinematic Jacobians. Fixes :issue:`411`. MJX ^^^ -12. Added ``efc_pos`` to ``mjx.Data`` (:issue:`1388`). -13. Added position-dependent sensors: ``MAGNETOMETER``, ``CAMPROJECTION``, ``RANGEFINDER``, ``JOINTPOS``, - ``ACTUATORPOS``, ``BALLQUAT``, ``FRAMEPOS``, ``FRAMEXAXIS``, ``FRAMEYAXIS``, ``FRAMEZAXIS``, ``FRAMEQUAT``, - ``SUBTREECOM``, ``CLOCK``. -14. Added velocity-dependent sensors: ``VELOCIMETER``, ``GYRO``, ``JOINTVEL``, ``ACTUATORVEL``, ``BALLANGVEL``, - ``FRAMELINVEL``, ``FRAMEANGVEL``, ``SUBTREELINVEL``, ``SUBTREEANGMOM``. -15. Added acceleration/force-dependent sensors: ``ACCELEROMETER``, ``FORCE``, ``TORQUE``, ``ACTUATORFRC``, - ``JOINTACTFRC``, ``FRAMELINACC``, ``FRAMEANGACC``. -16. Changed default policy to avoid placing unused (MuJoCo-only) arrays on device. -17. Added ``device`` parameter to ``mjx.make_data`` to bring it to parity with ``mjx.put_model`` and ``mjx.put_data``. -18. Added support for :ref:`implicitfast integration` for all cases except +12. :commit:`a74c184f` Added ``efc_pos`` to ``mjx.Data`` (:issue:`1388`). +13. :commit:`6a12787a` Added position-dependent sensors: ``MAGNETOMETER``, ``CAMPROJECTION``, ``RANGEFINDER``, + ``JOINTPOS``, ``ACTUATORPOS``, ``BALLQUAT``, ``FRAMEPOS``, ``FRAMEXAXIS``, ``FRAMEYAXIS``, ``FRAMEZAXIS``, + ``FRAMEQUAT``, ``SUBTREECOM``, ``CLOCK``. +14. :commit:`9805df61` Added velocity-dependent sensors: ``VELOCIMETER``, ``GYRO``, ``JOINTVEL``, ``ACTUATORVEL``, + ``BALLANGVEL``, ``FRAMELINVEL``, ``FRAMEANGVEL``, ``SUBTREELINVEL``, ``SUBTREEANGMOM``. +15. :commit:`9d732117` Added acceleration/force-dependent sensors: ``ACCELEROMETER``, ``FORCE``, ``TORQUE``, + ``ACTUATORFRC``, ``JOINTACTFRC``, ``FRAMELINACC``, ``FRAMEANGACC``. +16. :commit:`390bce23` Changed default policy to avoid placing unused (MuJoCo-only) arrays on device. +17. :commit:`390bce23` Added ``device`` parameter to ``mjx.make_data`` to bring it to parity with ``mjx.put_model`` and + ``mjx.put_data``. +18. :commit:`a68141ee` Added support for :ref:`implicitfast integration` for all cases except :doc:`fluid drag `. -19. Fixed a bug where ``qLDiagInv`` had the wrong size for sparse mass matrices. -20. Added support for joint and tendon :ref:`frictionloss `. -21. Added support for :ref:`connect` equality constraints using two sites. -22. Added support for :ref:`spatial tendons ` with site wrapping. +19. :commit:`494e166f` Fixed a bug where ``qLDiagInv`` had the wrong size for sparse mass matrices. +20. :commit:`49711fa1` Added support for joint and tendon :ref:`frictionloss `. +21. :commit:`cd8ff440` Added support for :ref:`connect` equality constraints using two sites. +22. :commit:`e3d3a24b` Added support for :ref:`spatial tendons ` with site wrapping. Bug fixes ^^^^^^^^^ -23. Fixed a performance regression introduced in 3.1.7 in mesh Bounding Volume Hierarchies (:issue:`1875`, - contribution by :github:user:`michael-ahn`). -24. Fixed a bug wherein, for models that have both muscles and stateless actuators and used one of the implicit - integrators, wrong derivatives would be computed. -25. Fixed a bug in tendon wrapping around spheres. Before this fix, tendons that wrapped around spheres with an - externally-placed :ref:`sidesite` could jump inside the sphere instead of wrapping around it. -26. Fixed a bug that caused :at:`meshdir` and :at:`texturedir` to be overwritten during model +23. :commit:`0bcaa856` Fixed a performance regression introduced in 3.1.7 in mesh Bounding Volume Hierarchies + (:issue:`1875`, contribution by :github:user:`michael-ahn`). +24. :commit:`0bcaa856` Fixed a bug wherein, for models that have both muscles and stateless actuators and used one of + the implicit integrators, wrong derivatives would be computed. +25. :commit:`3e701b21` Fixed a bug in tendon wrapping around spheres. Before this fix, tendons that wrapped around + spheres with an externally-placed :ref:`sidesite` could jump inside the sphere instead of + wrapping around it. +26. :commit:`567793c2` Fixed a bug that caused :at:`meshdir` and :at:`texturedir` to be overwritten during model :ref:`attachment`, preventing model attachment for models with assets in different directories. Python bindings ^^^^^^^^^^^^^^^ -27. Added support for engine plugins in :ref:`mjSpec` (:issue:`1903`). -28. Better error reporting for issues with the assets dictionary, when loading models. +27. :commit:`cfc7dc98` Added support for engine plugins in :ref:`mjSpec` (:issue:`1903`). +28. :commit:`9a27fc14` Better error reporting for issues with the assets dictionary, when loading models. Version 3.2.2 (Aug 8, 2024) @@ -1245,39 +1286,41 @@ Version 3.2.2 (Aug 8, 2024) General ^^^^^^^ -1. Increase texture and material limit back to 1000. 3.2.0 inadvertently reduced this limit to 100, breaking some - existing models (:issue:`1877`). +1. :commit:`9db9df73` Increase texture and material limit back to 1000. 3.2.0 inadvertently reduced this limit to 100, + breaking some existing models (:issue:`1877`). Version 3.2.1 (Aug 5, 2024) --------------------------- General ^^^^^^^ -1. Renamed ``mjModel.tex_rgb`` to ``mjModel.tex_data``. -2. Added a new :ref:`autoreset` flag to disable automatic reset when NaNs or infinities are - detected. -3. Added sub-elements to the MJCF :ref:`material` element, to allow specification of multiple textures - for rendering (e.g., ``occlusion, roughness, metallic``). Note that the MuJoCo renderer doesn't +1. :commit:`e92af73c` Renamed ``mjModel.tex_rgb`` to ``mjModel.tex_data``. +2. :commit:`24a55506` Added a new :ref:`autoreset` flag to disable automatic reset when NaNs or + infinities are detected. +3. :commit:`33e59606` Added sub-elements to the MJCF :ref:`material` element, to allow specification of + multiple textures for rendering (e.g., ``occlusion, roughness, metallic``). Note that the MuJoCo renderer doesn't support these new features, and they are made available for use with external renderers. -4. Sorting (``mjQUICKSORT``) now calls ``std::sort`` when building with C++ (:issue:`1638`). +4. :commit:`82c27165` Sorting (``mjQUICKSORT``) now calls ``std::sort`` when building with C++ (:issue:`1638`). MJX ^^^ -5. Added more fields to ``mjx.Model`` and ``mjx.Data`` for further compatibility with the corresponding MuJoCo structs. -6. Added support for :ref:`fixed tendons `. -7. Added support for tendon length limits (``mjCNSTR_LIMIT_TENDON`` in :ref:`mjtConstraint`). -8. Added support for tendon equality constraints (``mjEQ_TENDON`` in :ref:`mjtEq`). -9. Added support for tendon actuator transmission (``mjTRN_TENDON`` in :ref:`mjtTrn`). +5. :commit:`dbe18f57` Added more fields to ``mjx.Model`` and ``mjx.Data`` for further compatibility with the + corresponding MuJoCo structs. +6. :commit:`2d24c588` Added support for :ref:`fixed tendons `. +7. :commit:`2d24c588` Added support for tendon length limits (``mjCNSTR_LIMIT_TENDON`` in :ref:`mjtConstraint`). +8. :commit:`2d24c588` Added support for tendon equality constraints (``mjEQ_TENDON`` in :ref:`mjtEq`). +9. :commit:`2d24c588` Added support for tendon actuator transmission (``mjTRN_TENDON`` in :ref:`mjtTrn`). Python bindings ^^^^^^^^^^^^^^^ -10. Added support for asset dictionary argument in ``mujoco.spec.from_file``, ``mujoco.spec.from_string`` and - ``mujoco.spec.compile``. +10. :commit:`70ac76bb` Added support for asset dictionary argument in ``mujoco.spec.from_file``, + ``mujoco.spec.from_string`` and ``mujoco.spec.compile``. Bug fixes ^^^^^^^^^ -11. Fixed a bug where implicit integrators did not take into account disabled actuators (:issue:`1838`). +11. :commit:`a4bd2bec` Fixed a bug where implicit integrators did not take into account disabled actuators + (:issue:`1838`). Version 3.2.0 (Jul 15, 2024) ---------------------------- @@ -1285,8 +1328,8 @@ Version 3.2.0 (Jul 15, 2024) New features ^^^^^^^^^^^^ -1. Introduced a major new feature: **procedural model creation and editing**, using a new top-level data-structure - :ref:`mjSpec`. See the :doc:`Model Editing` chapter for details. +1. :commit:`e13ddfa2` Introduced a major new feature: **procedural model creation and editing**, using a new top-level + data-structure :ref:`mjSpec`. See the :doc:`Model Editing` chapter for details. Note that as of this release this feature is still in testing and subject to future breaking changes. Fixes :issue:`364`. @@ -1296,55 +1339,58 @@ General .. admonition:: Breaking API changes :class: attention - 2. Removed deprecated ``mj_makeEmptyFileVFS`` and ``mj_findFileVFS`` functions. The constants ``mjMAXVFS`` and - ``mjMAXVFSNAME`` are also removed as they are no longer needed. + 2. :commit:`57e6760e` Removed deprecated ``mj_makeEmptyFileVFS`` and ``mj_findFileVFS`` functions. The constants + ``mjMAXVFS`` and ``mjMAXVFSNAME`` are also removed as they are no longer needed. **Migration:** Use :ref:`mj_addBufferVFS` to copy a buffer into a VFS file directly. - 3. Calls to :ref:`mj_defaultVFS` may allocate memory inside VFS, and the corresponding + 3. :commit:`57e6760e` Calls to :ref:`mj_defaultVFS` may allocate memory inside VFS, and the corresponding :ref:`mj_deleteVFS` must be called to deallocate any internal allocated memory. - 4. Deprecated ``mju_rotVecMat`` and ``mju_rotVecMatT`` in favor of :ref:`mju_mulMatVec3` and + 4. :commit:`60670485` Deprecated ``mju_rotVecMat`` and ``mju_rotVecMatT`` in favor of :ref:`mju_mulMatVec3` and :ref:`mju_mulMatTVec3`. These function names and argument order are more consistent with the rest of the API. The older functions have been removed from the Python bindings and will be removed from the C API in the next release. - 5. Removed the ``actuator_actdim`` callback from actuator plugins. They now have the ``actdim`` attribute, which - must be used with actuators that write state to the ``act`` array. This fixed a crash which happened when - keyframes were used in a model with stateful actuator plugins. The PID plugin will give an error when the wrong - value of actdim is provided. + 5. :commit:`393895bb` Removed the ``actuator_actdim`` callback from actuator plugins. They now have the ``actdim`` + attribute, which must be used with actuators that write state to the ``act`` array. This fixed a crash which + happened when keyframes were used in a model with stateful actuator plugins. The PID plugin will give an error + when the wrong value of actdim is provided. -6. Added :ref:`attach` meta-element to MJCF, which allows :ref:`attaching` a subtree from a - different model to a body in the current model. -7. The :ref:`VFS` implementation has been rewritten in C++ and is now considerably more efficient in - speed and memory footprint. +6. :commit:`e13ddfa2` Added :ref:`attach` meta-element to MJCF, which allows :ref:`attaching` + a subtree from a different model to a body in the current model. +7. :commit:`57e6760e` The :ref:`VFS` implementation has been rewritten in C++ and is now considerably + more efficient in speed and memory footprint. .. youtube:: ZXBTEIDWHhs :aspect: 16:7 :align: right :width: 240px -8. Added support for orthographic cameras. This is available for both fixed cameras and the free camera, using the - ``camera/orthographic`` and :ref:`global/orthographic` +8. :commit:`07fc95ca` Added support for orthographic cameras. This is available for both fixed cameras and the free + camera, using the ``camera/orthographic`` and :ref:`global/orthographic` attributes, respectively. -9. Added :ref:`maxhullvert`, the maximum number of vertices in a mesh's convex hull. -10. Added :ref:`mj_setKeyframe` for saving the current state into a model keyframe. -11. Added support for ``ball`` joints in the URDF parser ("spherical" in URDF). -12. Replaced ``mjUSEDOUBLE`` which was previously hard-coded in +9. :commit:`ace0c8f0` Added :ref:`maxhullvert`, the maximum number of vertices in a mesh's + convex hull. +10. :commit:`c9bcf837` Added :ref:`mj_setKeyframe` for saving the current state into a model keyframe. +11. :commit:`c9bcf837` Added support for ``ball`` joints in the URDF parser ("spherical" in URDF). +12. :commit:`3f3b39bb` Replaced ``mjUSEDOUBLE`` which was previously hard-coded in `mjtnum.h `__ with the build-time flag ``mjUSESINGLE``. If this symbol is not defined, MuJoCo will use double-precision floating point, as usual. If ``mjUSESINGLE`` is defined, MuJoCo will use single-precision floating point. See :ref:`mjtNum`. Relatedly, fixed various type errors that prevented building with single-precision. -13. Quaternions in ``mjData.qpos`` and ``mjData.mocap_quat`` are no longer normalized in-place by +13. :commit:`22a10fd2` Quaternions in ``mjData.qpos`` and ``mjData.mocap_quat`` are no longer normalized in-place by :ref:`mj_kinematics`. Instead they are normalized when they are used. After the first step, quaternions in ``mjData.qpos`` will be normalized. -14. Mesh loading in the compiler, which is usually the slowest part of the loading process, is now multi-threaded. +14. :commit:`3d1d1d07` Mesh loading in the compiler, which is usually the slowest part of the loading process, is now + multi-threaded. MJX ~~~ -15. Added support for :ref:`elliptic friction cones`. -16. Fixed a bug that resulted in less-optimal linesearch solutions for some difficult constraint settings. -17. Fixed a bug in the Newton solver that sometimes resulted in less-optimal gradients. +15. :commit:`4c3d9461` Added support for :ref:`elliptic friction cones`. +16. :commit:`4c3d9461` Fixed a bug that resulted in less-optimal linesearch solutions for some difficult constraint + settings. +17. :commit:`4c3d9461` Fixed a bug in the Newton solver that sometimes resulted in less-optimal gradients. .. youtube:: P83tKA1iz2Y @@ -1353,19 +1399,20 @@ MJX Simulate ^^^^^^^^ -18. Added improved tutorial video. -19. Improved the Brownian noise generator. -20. Now displaying model load times if they are longer than 0.25 seconds. +18. :commit:`1eb70864` Added improved tutorial video. +19. :commit:`1eb70864` Improved the Brownian noise generator. +20. :commit:`3d1d1d07` Now displaying model load times if they are longer than 0.25 seconds. Python bindings ^^^^^^^^^^^^^^^ -21. Fixed a memory leak when using ``copy.deepcopy()`` on a ``mujoco.MjData`` instance (:issue:`1572`). +21. :commit:`2188cba4` Fixed a memory leak when using ``copy.deepcopy()`` on a ``mujoco.MjData`` instance + (:issue:`1572`). Bug fixes ^^^^^^^^^ -22. Fix an issue where ``mj_copyData`` (or ``copy.copy()`` in the Python bindings) was not copying contact information - correctly (:issue:`1710`). -23. Fix an issue with saving to XML that caused frames to be written multiple times (:issue:`1802`). +22. :commit:`e7301edd` Fix an issue where ``mj_copyData`` (or ``copy.copy()`` in the Python bindings) was not copying + contact information correctly (:issue:`1710`). +23. :commit:`8e827d0d` Fix an issue with saving to XML that caused frames to be written multiple times (:issue:`1802`). Version 3.1.6 (Jun 3, 2024) --------------------------- @@ -1373,10 +1420,11 @@ Version 3.1.6 (Jun 3, 2024) General ^^^^^^^ -1. Added :ref:`mj_geomDistance` for computing the shortest signed distance between two geoms and optionally a segment - connecting them. Relatedly, added the 3 sensors: :ref:`distance`, :ref:`normal`, - :ref:`fromto`. See the function and sensor documentation for details. Fixes :issue:`51`. -2. Improvements to position actuators: +1. :commit:`02d01545` Added :ref:`mj_geomDistance` for computing the shortest signed distance between two geoms and + optionally a segment connecting them. Relatedly, added the 3 sensors: :ref:`distance`, + :ref:`normal`, :ref:`fromto`. See the function and sensor documentation for details. + Fixes :issue:`51`. +2. :commit:`2830a407` Improvements to position actuators: - Added :ref:`timeconst` attribute to the :ref:`position actuator`. When set to a positive value, the actuator is made stateful with :at:`filterexact` dynamics. @@ -1387,19 +1435,19 @@ General MJX ^^^ -3. Add height-field collision support. Fixes :issue:`1491`. -4. Add a pre-compiled field ``mesh_convex`` to ``mjx.Model`` so that mesh properties can be vmapped over. - Fixes :issue:`1655`. -5. Fix a bug in convex mesh collisions, where erroneous edge contacts were being created even though face - separating axes were found. Fixes :issue:`1695`. +3. :commit:`c511d022` Add height-field collision support. Fixes :issue:`1491`. +4. :commit:`c511d022` Add a pre-compiled field ``mesh_convex`` to ``mjx.Model`` so that mesh properties can be vmapped + over. Fixes :issue:`1655`. +5. :commit:`c511d022` Fix a bug in convex mesh collisions, where erroneous edge contacts were being created even though + face separating axes were found. Fixes :issue:`1695`. Bug fixes ^^^^^^^^^ -6. Fixed a bug the could cause collisions to be missed when :ref:`fusestatic` is enabled, as is - often the case for URDF imports. Fixes :issue:`1069`, :issue:`1577`. -7. Fixed a bug that was causing the visualization of SDF iterations to write outside the size of the vector storing - them. Fixes :issue:`1539`. +6. :commit:`96844db9` Fixed a bug the could cause collisions to be missed when :ref:`fusestatic` is + enabled, as is often the case for URDF imports. Fixes :issue:`1069`, :issue:`1577`. +7. :commit:`1d181786` Fixed a bug that was causing the visualization of SDF iterations to write outside the size of the + vector storing them. Fixes :issue:`1539`. Version 3.1.5 (May 7, 2024) --------------------------- @@ -1412,56 +1460,62 @@ General :align: right :width: 240px -1. Added the :ref:`replicate` to MJCF, a :ref:`meta-element` which permits to repeat a subtree - with incremental translational and rotational offsets. -2. Enabled an internal cache in the MuJoCo compiler resulting in recompilation speedup. Currently, processed - textures, hfields, and OBJ meshes are cached. Support for Unity environments is not yet available. -3. Added ``mjModel.mesh_scale``: the scaling applied to asset vertices, as specified in the +1. :commit:`26f23066` Added the :ref:`replicate` to MJCF, a :ref:`meta-element` which permits + to repeat a subtree with incremental translational and rotational offsets. +2. :commit:`ad045968` Enabled an internal cache in the MuJoCo compiler resulting in recompilation speedup. Currently, + processed textures, hfields, and OBJ meshes are cached. Support for Unity environments is not yet available. +3. :commit:`6481a838` Added ``mjModel.mesh_scale``: the scaling applied to asset vertices, as specified in the :ref:`scale` attribute. -4. Added visual properties which are ignored by the native renderer, but can be used by external renderers: +4. :commit:`caf215e3` Added visual properties which are ignored by the native renderer, but can be used by external + renderers: - :ref:`light/bulbradius` attribute and corresponding ``mjModel.light_bulbradius`` field. - :ref:`material/metallic` attribute and corresponding ``mjModel.material_metallic`` field. - :ref:`material/roughness` attribute and corresponding ``mjModel.material_roughness`` field. -5. The type of the ``size`` argument of :ref:`mj_stackAllocNum` and :ref:`mj_stackAllocInt` was changed from ``int`` - to ``size_t``. -6. Added support for gmsh format version 2.2 surface meshes in :ref:`flexcomp`. +5. :commit:`546a27ca` The type of the ``size`` argument of :ref:`mj_stackAllocNum` and :ref:`mj_stackAllocInt` was + changed from ``int`` to ``size_t``. +6. :commit:`131b1745` Added support for gmsh format version 2.2 surface meshes in :ref:`flexcomp`. MJX ^^^ .. admonition:: Breaking API changes :class: attention - 7. Removed deprecated ``mjx.device_get_into`` and ``mjx.device_put`` functions as they lack critical new - functionality. + 7. :commit:`718e079c` Removed deprecated ``mjx.device_get_into`` and ``mjx.device_put`` functions as they lack + critical new functionality. **Migration:** Use ``mjx.get_data_into`` instead of ``mjx.device_get_into``, and ``mjx.put_data`` instead of ``mjx.device_put``. -8. Added cylinder plane collisions. -9. Added ``efc_type`` to ``mjx.Data`` and ``dim``, ``efc_address`` to ``mjx.Contact``. -10. Added ``geom`` to ``mjx.Contact`` and marked ``geom1``, ``geom2`` deprecated. -11. Added ``ne``, ``nf``, ``nl``, ``nefc``, and ``ncon`` to ``mjx.Data`` to match ``mujoco.MjData``. -12. Given the above added fields, removed ``mjx.get_params``, ``mjx.ncon``, and ``mjx.count_constraints``. -13. Changed the way meshes are organized on device to speed up collision detection when a mesh is replicated for many - geoms. -14. Fixed a bug where capsules might be ignored in broadphase colliision checking. -15. Added cylinder collisions using SDFs. -16. Added support for all :ref:`condim `: 1, 3, 4, 6. -17. Add support functions for ``id2name`` and ``name2id``, MJX versions of :ref:`mj_id2name` and :ref:`mj_name2id`. -18. Added support for :ref:`gravcomp` and :ref:`actuatorgravcomp`. -19. Fixed a bug in ``mjx.ray`` for sometimes allowed negative distances for ray-mesh tests. -20. Added a new `differentiable physics tutorial `__ that demonstrates training locomotion policies with analytical gradients - automatically derived from the MJX physics step. Contribution by :github:user:`Andrew-Luo1`. +8. :commit:`0cd28d24` Added cylinder plane collisions. +9. :commit:`a4df9120` Added ``efc_type`` to ``mjx.Data`` and ``dim``, ``efc_address`` to ``mjx.Contact``. +10. :commit:`a4df9120` Added ``geom`` to ``mjx.Contact`` and marked ``geom1``, ``geom2`` deprecated. +11. :commit:`a4df9120` Added ``ne``, ``nf``, ``nl``, ``nefc``, and ``ncon`` to ``mjx.Data`` to match ``mujoco.MjData``. +12. :commit:`a4df9120` Given the above added fields, removed ``mjx.get_params``, ``mjx.ncon``, and + ``mjx.count_constraints``. +13. :commit:`a4df9120` Changed the way meshes are organized on device to speed up collision detection when a mesh is + replicated for many geoms. +14. :commit:`a4df9120` Fixed a bug where capsules might be ignored in broadphase colliision checking. +15. :commit:`c2d0c5dd` Added cylinder collisions using SDFs. +16. :commit:`71333938` Added support for all :ref:`condim `: 1, 3, 4, 6. +17. :commit:`d15db545` Add support functions for ``id2name`` and ``name2id``, MJX versions of :ref:`mj_id2name` and + :ref:`mj_name2id`. +18. :commit:`e9709900` Added support for :ref:`gravcomp` and + :ref:`actuatorgravcomp`. +19. :commit:`719476c2` Fixed a bug in ``mjx.ray`` for sometimes allowed negative distances for ray-mesh tests. +20. :commit:`24bc1c8b` Added a new + `differentiable physics tutorial `__ + that demonstrates training locomotion policies with analytical gradients automatically derived from the MJX physics + step. Contribution by :github:user:`Andrew-Luo1`. Bug fixes ^^^^^^^^^ -21. Defaults of lights were not being saved, now fixed. -22. Prevent overwriting of frame names by body names when saving an XML. Bug introduced in 3.1.4. -23. Fixed bug in Python binding of :ref:`mj_saveModel`: ``buffer`` argument was documented as optional but was actually - not optional. -24. Fixed bug that prevented memory allocations larger than 2.15 GB. Fixes :issue:`1606`. +21. :commit:`0cd28d24` Defaults of lights were not being saved, now fixed. +22. :commit:`4b6c07cd` Prevent overwriting of frame names by body names when saving an XML. Bug introduced in 3.1.4. +23. :commit:`2b497581` Fixed bug in Python binding of :ref:`mj_saveModel`: ``buffer`` argument was documented as + optional but was actually not optional. +24. :commit:`546a27ca` Fixed bug that prevented memory allocations larger than 2.15 GB. Fixes :issue:`1606`. Version 3.1.4 (April 10th, 2024) @@ -1472,9 +1526,9 @@ General .. admonition:: Breaking API changes :class: attention - 1. Removed the ability to natively add noise to sensors. Note that the ``mjModel.sensor_noise`` field and - :ref:`corresponding attribute` are kept and now function as a convenient location for the user to save - standard-deviation information for their own use. This feature was removed because: + 1. :commit:`5d26b50f` Removed the ability to natively add noise to sensors. Note that the ``mjModel.sensor_noise`` + field and :ref:`corresponding attribute` are kept and now function as a convenient location for the user + to save standard-deviation information for their own use. This feature was removed because: - There was no mechanism to seed the random noise generator. - It was not thread-safe, even if seeding would have been provided, sampling on multiple threads would lead to @@ -1484,29 +1538,32 @@ General **Migration:** Add noise to sensor values yourself. -2. Added the :ref:`actuatorgravcomp` joint attribute. When enabled, gravity compensation - forces on the joint are treated as applied by actuators. See attribute documentation for more details. The example - model +2. :commit:`47ba72ea` Added the :ref:`actuatorgravcomp` joint attribute. When enabled, + gravity compensation forces on the joint are treated as applied by actuators. See attribute documentation for more + details. The example model `refsite.xml `__, which demonstrates Cartesian actuation of an arm, has been updated to use this attribute. -3. Added support for gmsh format 2.2 , tetrahedral mesh, as generated by e.g. `fTetwild `__. +3. :commit:`4f0293c6` Added support for gmsh format 2.2 , tetrahedral mesh, as generated by e.g. + `fTetwild `__. -4. Added :ref:`mju_euler2Quat` for converting an Euler-angle sequence to quaternion. +4. :commit:`5a365603` Added :ref:`mju_euler2Quat` for converting an Euler-angle sequence to quaternion. MJX ^^^ -5. Improved performance of SAT for convex collisions. -6. Fixed bug for sphere/capsule-convex deep penetration. -7. Fixed bug where ``mjx.Data`` produced by ``mjx.put_data`` had different treedef than ``mjx.make_data``. -8. Throw an error for margin/gap for convex mesh collisions, since they are not supported. -9. Added ellipsoid plane collisions. -10. Added support for userdata. -11. Added ellipsoid-ellipsoid and ellipsoid-capsule collisions using signed distance functions (SDFs). +5. :commit:`22cd96fb` Improved performance of SAT for convex collisions. +6. :commit:`f2e107f7` Fixed bug for sphere/capsule-convex deep penetration. +7. :commit:`02c62c11` Fixed bug where ``mjx.Data`` produced by ``mjx.put_data`` had different treedef than + ``mjx.make_data``. +8. :commit:`2386353b` Throw an error for margin/gap for convex mesh collisions, since they are not supported. +9. :commit:`2b3f336b` Added ellipsoid plane collisions. +10. :commit:`b4419235` Added support for userdata. +11. :commit:`2b3f336b` Added ellipsoid-ellipsoid and ellipsoid-capsule collisions using signed distance functions + (SDFs). Simulate ^^^^^^^^ -12. Fixed bug in order of enable flag strings. Before this change, using the simulate UI to toggle the - :ref:`invdiscrete` or the (now removed) ``sensornoise`` flags would actually toggle the +12. :commit:`bb42ff16` Fixed bug in order of enable flag strings. Before this change, using the simulate UI to toggle + the :ref:`invdiscrete` or the (now removed) ``sensornoise`` flags would actually toggle the other flag. Python bindings @@ -1517,9 +1574,9 @@ Python bindings :align: right :width: 240px -13. Added the ``mujoco.minimize`` Python module for nonlinear least-squares, designed for System Identification (sysID). - The sysID tutorial is work in progress, but a pedagogical colab notebook with examples, including Inverse - Kinematics, is available here: |ls_colab| +13. :commit:`adc4b92c` Added the ``mujoco.minimize`` Python module for nonlinear least-squares, designed for System + Identification (sysID). The sysID tutorial is work in progress, but a pedagogical colab notebook with examples, + including Inverse Kinematics, is available here: |ls_colab| |br| The video on the right shows example clips from the tutorial. .. |ls_colab| image:: https://colab.research.google.com/assets/colab-badge.png @@ -1531,87 +1588,89 @@ Version 3.1.3 (March 5th, 2024) General ^^^^^^^ -1. Added the :at:`inheritrange` attribute to :ref:`position` and +1. :commit:`05150546` Added the :at:`inheritrange` attribute to :ref:`position` and :ref:`intvelocity` actuators, allowing convenient setting of the actuator's :at:`ctrlrange` or :at:`actrange` (respectively), according to the range of the transmission target (joint or tendon). See :ref:`position/inheritrange` for details. -2. Deprecated ``mj_makeEmptyFileVFS`` in favor of :ref:`mj_addBufferVFS`. :ref:`mjVFS` now computes checksums of - its internal file buffers. :ref:`mj_addBufferVFS` allocates an empty buffer with a given name in an mjVFS and - copies the data buffer into it, combining and replacing the deprecated two-step process of calling +2. :commit:`a4a621f6` Deprecated ``mj_makeEmptyFileVFS`` in favor of :ref:`mj_addBufferVFS`. :ref:`mjVFS` now computes + checksums of its internal file buffers. :ref:`mj_addBufferVFS` allocates an empty buffer with a given name in an + mjVFS and copies the data buffer into it, combining and replacing the deprecated two-step process of calling ``mj_makeEmptyFileVFS`` followed by a direct copy into the given mjVFS internal file buffer. -3. Added :ref:`mj_angmomMat` which computes the ``3 x nv`` angular momentum matrix :math:`H(q)`, providing the linear - mapping from generalized velocities to subtree angular momentum :math:`h = H \dot q`. Contribution by - :github:user:`v-r-a`. +3. :commit:`6b7d7142` Added :ref:`mj_angmomMat` which computes the ``3 x nv`` angular momentum matrix :math:`H(q)`, + providing the linear mapping from generalized velocities to subtree angular momentum :math:`h = H \dot q`. + Contribution by :github:user:`v-r-a`. MJX ^^^ -4. Improved performance of getting and putting device data. +4. :commit:`4933a2c7` Improved performance of getting and putting device data. - Use ``tobytes()`` for numpy array serialization, which is orders of magnitude faster than converting to tuples. - Avoid reallocating host ``mjData`` arrays when array shapes are unchanged. - Speed up calculation of ``mjx.ncon`` for models with many geoms. - Avoid calling ``mjx.ncon`` in ``mjx.get_data_into`` when ``nc`` can be derived from ``mjx.Data``. -5. Fixed a bug in ``mjx-viewer`` that prevented it from running. Updated ``mjx-viewer`` to use newer +5. :commit:`e77c3cb2` Fixed a bug in ``mjx-viewer`` that prevented it from running. Updated ``mjx-viewer`` to use newer ``mjx.get_data_into`` function call. -6. Fixed a bug in ``mjx.euler`` that applied incorrect damping when using dense mass matrices. -7. Fixed a bug in ``mjx.solve`` that was causing slow convergence when using ``mjSOL_NEWTON`` in :ref:`mjtSolver`. -8. Added support for :ref:`mjOption.impratio` to ``mjx.Model``. -9. Added support for cameras in ``mjx.Model`` and ``mjx.Data``. Fixes :issue:`1422`. -10. Added an implementation of broadphase using `top_k` and bounding spheres. +6. :commit:`47bb4a82` Fixed a bug in ``mjx.euler`` that applied incorrect damping when using dense mass matrices. +7. :commit:`47bb4a82` Fixed a bug in ``mjx.solve`` that was causing slow convergence when using ``mjSOL_NEWTON`` in + :ref:`mjtSolver`. +8. :commit:`6a346c42` Added support for :ref:`mjOption.impratio` to ``mjx.Model``. +9. :commit:`2067e208` Added support for cameras in ``mjx.Model`` and ``mjx.Data``. Fixes :issue:`1422`. +10. :commit:`419be4c6` Added an implementation of broadphase using `top_k` and bounding spheres. Python bindings ^^^^^^^^^^^^^^^ -11. Fixed incorrect data types in the bindings for the ``geom``, ``vert``, ``elem``, and ``flex`` array members - of the ``mjContact`` struct, and all array members of the ``mjrContext`` struct. +11. :commit:`abf6d41b` Fixed incorrect data types in the bindings for the ``geom``, ``vert``, ``elem``, and ``flex`` + array members of the ``mjContact`` struct, and all array members of the ``mjrContext`` struct. Version 3.1.2 (February 05, 2024) --------------------------------- General ^^^^^^^ -1. Improved the :ref:`discardvisual` compiler flag, which now discards all visual-only assets. - See :ref:`discardvisual` for details. -2. Removed the :ref:`timer` for midphase colllision detection, it is now folded in with the narrowphase - timer. This is because timing the two phases separately required fine-grained timers inside the collision +1. :commit:`e0864ab7` Improved the :ref:`discardvisual` compiler flag, which now discards all + visual-only assets. See :ref:`discardvisual` for details. +2. :commit:`2feefbc5` Removed the :ref:`timer` for midphase colllision detection, it is now folded in with the + narrowphase timer. This is because timing the two phases separately required fine-grained timers inside the collision functions; these functions are so small and fast that the timer itself was incurring a measurable cost. -3. Added the flag :ref:`bvactive` to ``visual/global``, allowing users to turn off - visualisation of active bounding volumes (the red/green boxes in this :ref:`this changelog item`). For - models with very high-resolution meshes, the computation required for this visualization can slow down simulation +3. :commit:`fea7c10b` Added the flag :ref:`bvactive` to ``visual/global``, allowing users to + turn off visualisation of active bounding volumes (the red/green boxes in this :ref:`this changelog item`). + For models with very high-resolution meshes, the computation required for this visualization can slow down simulation speed. Fixes :issue:`1279`. - Added color of :ref:`bounding volumes` and :ref:`active bounding volumes` to :ref:`visual/rgba`. -4. Height-field elevation data can now be specified directly in XML with the :ref:`elevation` - attribute (and not only with PNG files). +4. :commit:`e143b3db` Height-field elevation data can now be specified directly in XML with the + :ref:`elevation` attribute (and not only with PNG files). See `example model `__. MJX ^^^ -5. Added :ref:`dyntype` ``filterexact``. -6. Added :at:`site` transmission. -7. Updated MJX colab tutorial with more stable quadruped environment. -8. Added ``mjx.ray`` which mirrors :ref:`mj_ray` for planes, spheres, capsules, boxes, and meshes. -9. Added ``mjx.is_sparse`` which mirrors :ref:`mj_isSparse` and ``mjx.full_m`` which mirrors :ref:`mj_fullM`. -10. Added support for specifying sparse or dense mass matrices via :ref:`option-jacobian`. -11. Raise a not implemented error when nonzero frictionloss is present. Fixes :issue:`1344`. +5. :commit:`63ec34f9` Added :ref:`dyntype` ``filterexact``. +6. :commit:`63ec34f9` Added :at:`site` transmission. +7. :commit:`feb92bf5` Updated MJX colab tutorial with more stable quadruped environment. +8. :commit:`a02fc405` Added ``mjx.ray`` which mirrors :ref:`mj_ray` for planes, spheres, capsules, boxes, and meshes. +9. :commit:`0a7be173` Added ``mjx.is_sparse`` which mirrors :ref:`mj_isSparse` and ``mjx.full_m`` which mirrors + :ref:`mj_fullM`. +10. :commit:`0a7be173` Added support for specifying sparse or dense mass matrices via :ref:`option-jacobian`. +11. :commit:`508669a9` Raise a not implemented error when nonzero frictionloss is present. Fixes :issue:`1344`. Python bindings ^^^^^^^^^^^^^^^ -12. Improved the implementation of the :ref:`rollout` module. Note the changes below are breaking, dependent - code will require modification. +12. :commit:`aceb52bd` Improved the implementation of the :ref:`rollout` module. Note the changes below are + breaking, dependent code will require modification. - Uses :ref:`mjSTATE_FULLPHYSICS` as state spec, enabling divergence detection by inspecting time. - Allows user-defined control spec for any combination of :ref:`user input` fields as controls. - Outputs are no longer squeezed and always have dim=3. -13. The ``sync`` function for the :ref:`passive viewer` can now pick up changes to rendering flags in - ``user_scn``, as requested in :issue:`1190`. +13. :commit:`7bb0ce42` The ``sync`` function for the :ref:`passive viewer` can now pick up changes to + rendering flags in ``user_scn``, as requested in :issue:`1190`. Bug fixes ^^^^^^^^^ -14. Fixed a bug that prevented the use of pins with plugins if flexes are not in the worldbody. Fixes +14. :commit:`1e2e0b30` Fixed a bug that prevented the use of pins with plugins if flexes are not in the worldbody. Fixes :issue:`1270`. -15. Fixed a bug in the :ref:`muscle model` that led to non-zero values outside the lower +15. :commit:`a14a584f` Fixed a bug in the :ref:`muscle model` that led to non-zero values outside the lower bound of the length range. Fixes :issue:`1342`. @@ -1620,12 +1679,14 @@ Version 3.1.1 (December 18, 2023) Bug fixes ^^^^^^^^^ -1. Fixed a bug (introduced in 3.1.0) where box-box collisions produced no contacts if one box was deeply embedded in the - other. -2. Fixed a bug in :ref:`simulate` where the "LOADING..." message was not showing correctly. -3. Fixed a crash in the Python :ref:`passive viewer`, when used with models containing Flex objects. -4. Fixed a bug in MJX where ``site_xmat`` was ignored in ``get_data`` and ``put_data`` -5. Fixed a bug in MJX where ``efc_address`` was sometimes incorrectly calculated in ``get_data``. +1. :commit:`d39ed1d3` Fixed a bug (introduced in 3.1.0) where box-box collisions produced no contacts if one box was + deeply embedded in the other. +2. :commit:`d39ed1d3` Fixed a bug in :ref:`simulate` where the "LOADING..." message was not showing + correctly. +3. :commit:`d39ed1d3` Fixed a crash in the Python :ref:`passive viewer`, when used with models + containing Flex objects. +4. :commit:`d39ed1d3` Fixed a bug in MJX where ``site_xmat`` was ignored in ``get_data`` and ``put_data`` +5. :commit:`d39ed1d3` Fixed a bug in MJX where ``efc_address`` was sometimes incorrectly calculated in ``get_data``. Version 3.1.0 (December 12, 2023) @@ -1633,48 +1694,50 @@ Version 3.1.0 (December 12, 2023) General ^^^^^^^ -1. Improved convergence of Signed Distance Function (SDF) collisions by using line search and a new objective function - for the optimization. This allows to decrease the number of initial points needed for finding the contacts and is - more robust for very small or large geom sizes. -2. Added :ref:`frame` to MJCF, a :ref:`meta-element` which defines a pure coordinate transformation - on its direct children, without requiring a :ref:`body`. -3. Added the :at:`kv` attribute to the :ref:`position` and :ref:`intvelocity` - actuators, for specifying actuator-applied damping. This can be used to implement a PD controller with 0 reference - velocity. When using this attribute, it is recommended to use the implicitfast or implicit - :ref:`integrators`. +1. :commit:`8ca51b53` Improved convergence of Signed Distance Function (SDF) collisions by using line search and a new + objective function for the optimization. This allows to decrease the number of initial points needed for finding the + contacts and is more robust for very small or large geom sizes. +2. :commit:`eb9568a4` Added :ref:`frame` to MJCF, a :ref:`meta-element` which defines a pure + coordinate transformation on its direct children, without requiring a :ref:`body`. +3. :commit:`762371c3` Added the :at:`kv` attribute to the :ref:`position` and + :ref:`intvelocity` actuators, for specifying actuator-applied damping. This can be used to + implement a PD controller with 0 reference velocity. When using this attribute, it is recommended to use the + implicitfast or implicit :ref:`integrators`. Plugins ^^^^^^^ -4. Allow actuator plugins to use activation variables in ``mjData.act`` as their internal state, rather than - ``mjData.plugin_state``. Actuator plugins can now specify :ref:`callbacks` that compute activation - variables, and they can be used with built-in :ref:`dyntype` actuator dynamics. -5. Added the `pid `__ actuator plugin, a - configurable PID controller that implements the Integral term, which is not available with native MuJoCo actuators. +4. :commit:`f2025c6a` Allow actuator plugins to use activation variables in ``mjData.act`` as their internal state, + rather than ``mjData.plugin_state``. Actuator plugins can now specify :ref:`callbacks` that compute + activation variables, and they can be used with built-in :ref:`dyntype` actuator dynamics. +5. :commit:`ca046cbf` Added the `pid `__ + actuator plugin, a configurable PID controller that implements the Integral term, which is not available with native + MuJoCo actuators. MJX ^^^ -6. Added ``site_xpos`` and ``site_xmat`` to MJX. -7. Added ``put_data``, ``put_model``, ``get_data`` to replace ``device_put`` and ``device_get_into``, which will be - deprecated. These new functions correctly translate fields that are the result of intermediate calculations such as - ``efc_J``. +6. :commit:`35c90844` Added ``site_xpos`` and ``site_xmat`` to MJX. +7. :commit:`67fa7c1d` Added ``put_data``, ``put_model``, ``get_data`` to replace ``device_put`` and ``device_get_into``, + which will be deprecated. These new functions correctly translate fields that are the result of intermediate + calculations such as ``efc_J``. Bug fixes ^^^^^^^^^ -8. Fix bug in Cartesian actuation with movable refsite, as when using body-centric Cartesian actuators on a quadruped. - Before this fix such actuators could lead to non-conservation of momentum. -9. Fix bug that prevented using flex with :ref:`simulate`. -10. Fix bug that prevented the use of elasticity plugins in combination with pinned flex vertices. -11. Release Python wheels targeting macOS 10.16 to support x86_64 systems where ``SYSTEM_VERSION_COMPAT`` is set. - The minimum supported version is still 11.0, but we release these wheels to fix compatibility for those users. See - :issue:`1213`. -12. Fixed mass computation of meshes: Use the correct mesh volume instead of approximating it using the inertia box. +8. :commit:`cd56a41f` Fix bug in Cartesian actuation with movable refsite, as when using body-centric Cartesian + actuators on a quadruped. Before this fix such actuators could lead to non-conservation of momentum. +9. :commit:`d39ed1d3` Fix bug that prevented using flex with :ref:`simulate`. +10. :commit:`7d8d4d39` Fix bug that prevented the use of elasticity plugins in combination with pinned flex vertices. +11. :commit:`3c05f9fa` Release Python wheels targeting macOS 10.16 to support x86_64 systems where + ``SYSTEM_VERSION_COMPAT`` is set. The minimum supported version is still 11.0, but we release these wheels to fix + compatibility for those users. See :issue:`1213`. +12. :commit:`49ddb7ca` Fixed mass computation of meshes: Use the correct mesh volume instead of approximating it using + the inertia box. Version 3.0.1 (November 15, 2023) --------------------------------- General ^^^^^^^ -1. Added sub-terms of total passive forces in ``mjData.qfrc_passive`` to :ref:`mjData`: +1. :commit:`a89412bb` Added sub-terms of total passive forces in ``mjData.qfrc_passive`` to :ref:`mjData`: ``qfrc_{spring, damper, gravcomp, fluid}``. The sum of these vectors equals ``qfrc_passive``. .. youtube:: H9qG9Zf2W44 @@ -1682,7 +1745,7 @@ General :align: right :width: 240px -2. Added :ref:`actuatorgroupdisable` attribute and associated +2. :commit:`893c4042` Added :ref:`actuatorgroupdisable` attribute and associated :ref:`mjOption.disableactuator` integer bitfield, which can be used to disable sets of actuators at runtime according to their :ref:`group`. Fixes :issue:`1092`. See :ref:`CActDisable`. @@ -1690,12 +1753,12 @@ General `__ and associated screen-capture on the right. -3. Increased ``mjMAXUIITEM`` (maximum number of UI elements per section in Simulate) to 200. +3. :commit:`7e419276` Increased ``mjMAXUIITEM`` (maximum number of UI elements per section in Simulate) to 200. MJX ^^^ -4. Added support for Newton solver (``mjSOL_NEWTON`` in :ref:`mjtSolver`). The Newton solver significantly speeds up - simulation on GPU: +4. :commit:`3c0a56c1` Added support for Newton solver (``mjSOL_NEWTON`` in :ref:`mjtSolver`). The Newton solver + significantly speeds up simulation on GPU: .. list-table:: Steps-per-second, Conjugate Gradient vs. Newton on A100 :header-rows: 1 @@ -1721,22 +1784,26 @@ MJX Humanoid is the standard MuJoCo humanoid, `Google Barkour `__ and the Shadow Hand are both available in the :ref:`MuJoCo Menagerie`. -5. Added support for joint equality constraints (``mjEQ_JOINT`` in :ref:`mjtEq`). -6. Fixed bug where mixed ``jnt_limited`` joints were not being constrained correctly. -7. Made ``device_put`` type validation more verbose (fixes :issue:`1113`). -8. Removed empty EFC rows from ``MJX``, for joints with no limits (fixes :issue:`1117`). -9. Fixed bug in ``scan.body_tree`` that led to incorrect smooth dynamics for some kinematic tree layouts. +5. :commit:`70699765` Added support for joint equality constraints (``mjEQ_JOINT`` in :ref:`mjtEq`). +6. :commit:`f6ed57e9` Fixed bug where mixed ``jnt_limited`` joints were not being constrained correctly. +7. :commit:`e4a9f535` Made ``device_put`` type validation more verbose (fixes :issue:`1113`). +8. :commit:`843360b7` Removed empty EFC rows from ``MJX``, for joints with no limits (fixes :issue:`1117`). +9. :commit:`c8146372` Fixed bug in ``scan.body_tree`` that led to incorrect smooth dynamics for some kinematic tree + layouts. Python bindings ^^^^^^^^^^^^^^^ -10. Fix the macOS ``mjpython`` launcher to work with the Python interpreter from Apple Command Line Tools. -11. Fixed a crash when copying instances of ``mujoco.MjData`` for models that use plugins. Introduced a ``model`` - attribute to ``MjData`` which is reference to the model that was used to create that ``MjData`` instance. +10. :commit:`893c4042` Fix the macOS ``mjpython`` launcher to work with the Python interpreter from Apple Command Line + Tools. +11. :commit:`084facc9` Fixed a crash when copying instances of ``mujoco.MjData`` for models that use plugins. Introduced + a ``model`` attribute to ``MjData`` which is reference to the model that was used to create that ``MjData`` + instance. Simulate ^^^^^^^^ -12. :ref:`simulate`: correct handling of "Pause update", "Fullscreen" and "VSync" buttons. +12. :commit:`f6ed57e9` :ref:`simulate`: correct handling of "Pause update", "Fullscreen" and "VSync" + buttons. Documentation ^^^^^^^^^^^^^ @@ -1746,15 +1813,15 @@ Documentation :align: right :width: 240px -13. Added cell to the `tutorial colab `__ providing an - example of procedural camera control: -14. Added documentation for the :ref:`UI` framework. -15. Fixed typos and supported fields in docs (fixes :issue:`1105` and :issue:`1106`). +13. :commit:`8d5966ee` Added cell to the `tutorial colab `__ + providing an example of procedural camera control: +14. :commit:`2bb8652b` Added documentation for the :ref:`UI` framework. +15. :commit:`dc8bac2f` Fixed typos and supported fields in docs (fixes :issue:`1105` and :issue:`1106`). Bug fixes ^^^^^^^^^ -16. Fixed bug relating to welds modified with :ref:`torquescale`. +16. :commit:`86d9c84e` Fixed bug relating to welds modified with :ref:`torquescale`. Version 3.0.0 (October 18, 2023) -------------------------------- @@ -1762,7 +1829,7 @@ Version 3.0.0 (October 18, 2023) New features ^^^^^^^^^^^^ -1. Added simulation on GPU and TPU via the new :doc:`mjx` (MJX) Python module. Python users can now +1. :commit:`8f9c690c` Added simulation on GPU and TPU via the new :doc:`mjx` (MJX) Python module. Python users can now natively run MuJoCo simulations at millions of steps per second on Google TPU or their own accelerator hardware. - MJX is designed to work with on-device reinforcement learning algorithms. This Colab notebook demonstrates using @@ -1778,8 +1845,9 @@ New features :align: right :width: 240px -2. Added new signed distance field (SDF) collision primitive. SDFs can take any shape and are not constrained to be - convex. Collision points are found by minimizing the maximum of the two colliding SDFs via gradient descent. +2. :commit:`fdb04158` Added new signed distance field (SDF) collision primitive. SDFs can take any shape and are not + constrained to be convex. Collision points are found by minimizing the maximum of the two colliding SDFs via gradient + descent. - Added new SDF plugin for defining implicit geometries. The plugin must define methods computing an SDF and its gradient at query points. See the :ref:`documentation` for more details. @@ -1789,7 +1857,7 @@ New features :align: right :width: 240px -3. Added new low-level model element called ``flex``, used to define deformable objects. These +3. :commit:`139a8ae2` Added new low-level model element called ``flex``, used to define deformable objects. These `simplicial complexes `__ can be of dimension 1, 2 or 3, corresponding to stretchable lines, triangles or tetrahedra. Two new MJCF elements are used to define flexes. The top-level :ref:`deformable` section contains the low-level flex definition. @@ -1810,14 +1878,14 @@ New features :align: right :width: 240px -4. Added constraint island discovery with :ref:`mj_island`. Constraint islands are disjoint sets of constraints - and degrees-of-freedom that do not interact. The only solver which currently supports islands is +4. :commit:`2cc12054` Added constraint island discovery with :ref:`mj_island`. Constraint islands are disjoint sets of + constraints and degrees-of-freedom that do not interact. The only solver which currently supports islands is :ref:`CG`. Island discovery can be activated using a new :ref:`enable flag`. If island discovery is enabled, geoms, contacts and tendons will be colored according to the corresponding island, see video. Island discovery is currently disabled for models that have deformable objects (see previous item). -5. Added ``mjThreadPool`` and ``mjTask`` which allow for multi-threaded operations within the MuJoCo engine - pipeline. If engine-internal threading is enabled, the following operations will be multi-threaded: +5. :commit:`62251869` Added ``mjThreadPool`` and ``mjTask`` which allow for multi-threaded operations within the MuJoCo + engine pipeline. If engine-internal threading is enabled, the following operations will be multi-threaded: - Island constraint resolution, if island discovery is :ref:`enabled` and the :ref:`CG solver` is selected. The @@ -1828,8 +1896,8 @@ New features Engine-internal threading is a work in progress and currently only available in first-party code via the :ref:`testspeed` utility, exposed with the ``npoolthread`` flag. -6. Added capability to initialize :ref:`composite` particles from OBJ files. Fixes :issue:`642` - and :issue:`674`. +6. :commit:`139a8ae2` Added capability to initialize :ref:`composite` particles from OBJ files. Fixes + :issue:`642` and :issue:`674`. General ^^^^^^^ @@ -1837,21 +1905,22 @@ General .. admonition:: Breaking API changes :class: attention - 7. Removed the macros ``mjMARKSTACK`` and ``mjFREESTACK``. + 7. :commit:`ba66bd4f` Removed the macros ``mjMARKSTACK`` and ``mjFREESTACK``. **Migration:** These macros have been replaced by new functions :ref:`mj_markStack` and :ref:`mj_freeStack`. These functions manage the :ref:`mjData stack` in a fully encapsulated way (i.e., without introducing a local variable at the call site). - 8. Renamed ``mj_stackAlloc`` to :ref:`mj_stackAllocNum`. The new function :ref:`mj_stackAllocByte` allocates an - arbitrary number of bytes and has an additional argument for specifying the alignment of the returned pointer. + 8. :commit:`9902b735` Renamed ``mj_stackAlloc`` to :ref:`mj_stackAllocNum`. The new function :ref:`mj_stackAllocByte` + allocates an arbitrary number of bytes and has an additional argument for specifying the alignment of the returned + pointer. **Migration:** The functionality for allocating ``mjtNum`` arrays is now available via :ref:`mj_stackAllocNum`. - 9. Renamed the ``nstack`` field in :ref:`mjModel` and :ref:`mjData` to ``narena``. Changed ``narena``, ``pstack``, - and ``maxuse_stack`` to count number of bytes rather than number of :ref:`mjtNum` |-| s. + 9. :commit:`49290772` Renamed the ``nstack`` field in :ref:`mjModel` and :ref:`mjData` to ``narena``. Changed + ``narena``, ``pstack``, and ``maxuse_stack`` to count number of bytes rather than number of :ref:`mjtNum` |-| s. - 10. Changed :ref:`mjData.solver`, the array used to collect solver diagnostic information. + 10. :commit:`86d8b912` Changed :ref:`mjData.solver`, the array used to collect solver diagnostic information. This array of :ref:`mjSolverStat` structs is now of length ``mjNISLAND * mjNSOLVER``, interpreted as as a matrix. Each row of length ``mjNSOLVER`` contains separate solver statistics for each constraint island. If the solver does not use islands, only row 0 is filled. @@ -1862,7 +1931,7 @@ General - Renamed ``mjData.solver_iter`` to ``solver_niter``. Both this member and ``mjData.solver_nnz`` are now integer vectors of length ``mjNISLAND``. - 11. Removed ``mjOption.collision`` and the associated ``option/collision`` attribute. + 11. :commit:`9cf1f6eb` Removed ``mjOption.collision`` and the associated ``option/collision`` attribute. **Migration:** @@ -1873,39 +1942,41 @@ General :ref:`conaffinity` attributes in the model and then setting them globally to ``0`` using |br| `` ``. - 12. Removed the :at:`rope` and :at:`cloth` composite objects. + 12. :commit:`d3d46e16` Removed the :at:`rope` and :at:`cloth` composite objects. **Migration:** Users should use the :at:`cable` and :at:`shell` elasticity plugins. - 13. Added :ref:`mjData.eq_active` user input variable, for enabling/disabling the state of equality - constraints. Renamed ``mjModel.eq_active`` to :ref:`mjModel.eq_active0`, which now has the semantic of - "initial value of ``mjData.eq_active``". Fixes :issue:`876`. + 13. :commit:`ee78b8f7` Added :ref:`mjData.eq_active` user input variable, for enabling/disabling the state of + equality constraints. Renamed ``mjModel.eq_active`` to :ref:`mjModel.eq_active0`, which now has the + semantic of "initial value of ``mjData.eq_active``". Fixes :issue:`876`. **Migration:** Replace uses of ``mjModel.eq_active`` with ``mjData.eq_active``. - 14. Changed the default of :ref:`autolimits` from "false" to "true". This is a minor breaking - change. The potential breakage applies to models which have elements with "range" defined and "limited" not set. - Such models cannot be loaded since version 2.2.2 (July 2022). + 14. :commit:`d88675a0` Changed the default of :ref:`autolimits` from "false" to "true". This is + a minor breaking change. The potential breakage applies to models which have elements with "range" defined and + "limited" not set. Such models cannot be loaded since version 2.2.2 (July 2022). -15. Added a new :ref:`dyntype`, ``filterexact``, which updates first-order filter states with - the exact formula rather than with Euler integration. -16. Added an actuator attribute, :ref:`actearly`, which uses semi-implicit integration for - actuator forces: using the next step's actuator state to compute the current actuator forces. -17. Renamed ``actuatorforcerange`` and ``actuatorforcelimited``, introduced in the previous version to - :ref:`actuatorfrcrange` and +15. :commit:`2c3297b3` Added a new :ref:`dyntype`, ``filterexact``, which updates first-order + filter states with the exact formula rather than with Euler integration. +16. :commit:`2c3297b3` Added an actuator attribute, :ref:`actearly`, which uses semi-implicit + integration for actuator forces: using the next step's actuator state to compute the current actuator forces. +17. :commit:`a276c49c` Renamed ``actuatorforcerange`` and ``actuatorforcelimited``, introduced in the previous version + to :ref:`actuatorfrcrange` and :ref:`actuatorfrclimited`, respectively. -18. Added the flag :ref:`eulerdamp`, which disables implicit integration of joint damping in the - Euler integrator. See the :ref:`Numerical Integration` section for more details. -19. Added the flag :ref:`invdiscrete`, which enables discrete-time inverse dynamics for all - :ref:`integrators` other than ``RK4``. See the flag documentation for more details. -20. Added :ref:`ls_iterations` and :ref:`ls_tolerance` options for adjusting - linesearch stopping criteria in CG and Newton solvers. These can be useful for performance tuning. -21. Added ``mesh_pos`` and ``mesh_quat`` fields to :ref:`mjModel` to store the normalizing transformation applied to - mesh assets. Fixes :issue:`409`. -22. Added camera :ref:`resolution` attribute and :ref:`camprojection` - sensor. If camera resolution is set to positive values, the camera projection sensor will report the location of a - target site, projected onto the camera image, in pixel coordinates. -23. Added :ref:`camera` calibration attributes: +18. :commit:`b7cf479a` Added the flag :ref:`eulerdamp`, which disables implicit integration of + joint damping in the Euler integrator. See the :ref:`Numerical Integration` section for more details. +19. :commit:`819b5cb9` Added the flag :ref:`invdiscrete`, which enables discrete-time inverse + dynamics for all :ref:`integrators` other than ``RK4``. See the flag documentation for more + details. +20. :commit:`1a3215e3` Added :ref:`ls_iterations` and :ref:`ls_tolerance` + options for adjusting linesearch stopping criteria in CG and Newton solvers. These can be useful for performance + tuning. +21. :commit:`2cc12054` Added ``mesh_pos`` and ``mesh_quat`` fields to :ref:`mjModel` to store the normalizing + transformation applied to mesh assets. Fixes :issue:`409`. +22. :commit:`8064ad59` Added camera :ref:`resolution` attribute and + :ref:`camprojection` sensor. If camera resolution is set to positive values, the camera + projection sensor will report the location of a target site, projected onto the camera image, in pixel coordinates. +23. :commit:`36d2ffe4` Added :ref:`camera` calibration attributes: - The new attributes are :ref:`resolution`, :ref:`focal`, :ref:`focalpixel`, :ref:`principal`, @@ -1914,22 +1985,24 @@ General attributes are specified. See the following `example model `__. - Note that these attributes only take effect for offline rendering and do not affect interactive visualisation. -24. Implemented reversed Z rendering for better depth precision. An enum :ref:`mjtDepthMap` was added with values - ``mjDEPTH_ZERONEAR`` and ``mjDEPTH_ZEROFAR``, which can be used to set the new ``readDepthMap`` attribute in - :ref:`mjrContext` to control how the depth returned by :ref:`mjr_readPixels` is mapped from ``znear`` to ``zfar``. - Contribution :pr:`978` by `Levi Burner `__. -25. Deleted the code sample ``testxml``. The functionality provided by this utility is implemented in the - `WriteReadCompare `__ test. -26. Deleted the code sample ``derivative``. Functionality provided by :ref:`mjd_transitionFD`. +24. :commit:`59164702` Implemented reversed Z rendering for better depth precision. An enum :ref:`mjtDepthMap` was added + with values ``mjDEPTH_ZERONEAR`` and ``mjDEPTH_ZEROFAR``, which can be used to set the new ``readDepthMap`` + attribute in :ref:`mjrContext` to control how the depth returned by :ref:`mjr_readPixels` is mapped from ``znear`` + to ``zfar``. Contribution :pr:`978` by `Levi Burner `__. +25. :commit:`fb4cf472` Deleted the code sample ``testxml``. The functionality provided by this utility is implemented in + the `WriteReadCompare `__ + test. +26. :commit:`a1b6026b` Deleted the code sample ``derivative``. Functionality provided by :ref:`mjd_transitionFD`. Python bindings ^^^^^^^^^^^^^^^ -27. Fixed :issue:`870` where calling ``update_scene`` with an invalid camera name used the default camera. -28. Added ``user_scn`` to the :ref:`passive viewer` handle, which allows users to add custom - visualization geoms (:issue:`1023`). -29. Added optional boolean keyword arguments ``show_left_ui`` and ``show_right_ui`` to the functions ``viewer.launch`` - and ``viewer.launch_passive``, which allow users to launch a viewer with UI panels hidden. +27. :commit:`631b16e7` Fixed :issue:`870` where calling ``update_scene`` with an invalid camera name used the default + camera. +28. :commit:`2e15574b` Added ``user_scn`` to the :ref:`passive viewer` handle, which allows users to + add custom visualization geoms (:issue:`1023`). +29. :commit:`a1d0cbd6` Added optional boolean keyword arguments ``show_left_ui`` and ``show_right_ui`` to the functions + ``viewer.launch`` and ``viewer.launch_passive``, which allow users to launch a viewer with UI panels hidden. Simulate ^^^^^^^^ @@ -1939,11 +2012,11 @@ Simulate :align: right :width: 240px -30. Added **state history** mechanism to :ref:`simulate` and the managed +30. :commit:`3e12f0d5` Added **state history** mechanism to :ref:`simulate` and the managed :ref:`Python viewer`. State history can be viewed by scrubbing the History slider and (more precisely) with the left and right arrow keys. See screen capture: -31. The ``LOADING...`` label is now shown correctly. Contribution :pr:`1070` by +31. :commit:`93d1c3c9` The ``LOADING...`` label is now shown correctly. Contribution :pr:`1070` by `Levi Burner `__. Documentation @@ -1954,17 +2027,19 @@ Documentation :align: right :width: 240px -32. Added :doc:`detailed documentation ` of fluid force modeling, and an illustrative example model - showing `tumbling cards `__ using the +32. :commit:`18e4e101` Added :doc:`detailed documentation ` of fluid force modeling, and an + illustrative example model showing + `tumbling cards `__ using the ellipsoid-based fluid model. Bug fixes ^^^^^^^^^ -33. Fixed a bug that was causing :ref:`geom margin` to be ignored during the construction of - midphase collision trees. +33. :commit:`2cc12054` Fixed a bug that was causing :ref:`geom margin` to be ignored during the + construction of midphase collision trees. -34. Fixed a bug that was generating incorrect values in ``efc_diagApprox`` for weld equality constraints. +34. :commit:`1bd6c94e` Fixed a bug that was generating incorrect values in ``efc_diagApprox`` for weld equality + constraints. Version 2.3.7 (July 20, 2023) @@ -1973,35 +2048,39 @@ Version 2.3.7 (July 20, 2023) General ^^^^^^^ -1. Added primitive collider for sphere-cylinder contacts, previously this pair used the generic convex-convex collider. -#. Added :ref:`joint-actuatorforcerange` for clamping total actuator force at joints and - :ref:`sensor-jointactuatorfrc` for measuring total actuation force applied at a joint. The - most important use case for joint-level actuator force clamping is to ensure that +1. :commit:`a7021df6` Added primitive collider for sphere-cylinder contacts, previously this pair used the generic + convex-convex collider. +#. :commit:`51aa375a` Added :ref:`joint-actuatorforcerange` for clamping total actuator + force at joints and :ref:`sensor-jointactuatorfrc` for measuring total actuation force + applied at a joint. The most important use case for joint-level actuator force clamping is to ensure that :ref:`Cartesian actuator` forces are realizable by individual motors at the joints. See :ref:`CForceRange` for details. -#. Added an optional ``content_type`` attribute to hfield, texture, and mesh assets. This attribute supports a formatted - `Media Type `_ (previously known as MIME type) string - used to determine the type of the asset file without resorting to pulling the type from the file extension. -#. Added analytic derivatives for quaternion :ref:`subtraction` and :ref:`integration` - (rotation with an angular velocity). Derivatives are in the 3D tangent space. -#. Added :ref:`mjv_connector` which has identical functionality to ``mjv_makeConnector``, but with more convenient - "from-to" argument parametrization. ``mjv_makeConnector`` is now deprecated. -#. Bumped oldest supported MacOS from version 10.12 to 11. MacOS 11 is the oldest version still maintained by Apple. +#. :commit:`5fcdae77` Added an optional ``content_type`` attribute to hfield, texture, and mesh assets. This attribute + supports a formatted `Media Type `_ (previously known + as MIME type) string used to determine the type of the asset file without resorting to pulling the type from the file + extension. +#. :commit:`5cfbb6ac` Added analytic derivatives for quaternion :ref:`subtraction` and + :ref:`integration` (rotation with an angular velocity). Derivatives are in the 3D tangent space. +#. :commit:`c50c92cc` Added :ref:`mjv_connector` which has identical functionality to ``mjv_makeConnector``, but with + more convenient "from-to" argument parametrization. ``mjv_makeConnector`` is now deprecated. +#. :commit:`5fcdae77` Bumped oldest supported MacOS from version 10.12 to 11. MacOS 11 is the oldest version still + maintained by Apple. Python bindings ^^^^^^^^^^^^^^^ -7. The :ref:`passive viewer` handle now exposes ``update_hfield``, ``update_mesh``, and - ``update_texture`` methods to allow users to update renderable assets. +7. :commit:`0ccfef73` The :ref:`passive viewer` handle now exposes ``update_hfield``, ``update_mesh``, + and ``update_texture`` methods to allow users to update renderable assets. (Issues :issue:`812`, :issue:`958`, :issue:`965`). -#. Allow a custom keyboard event callback to be specified in the :ref:`passive viewer` - (:issue:`766`). -#. Fix GLFW crash when Python exits while the passive viewer is running (:issue:`790`). +#. :commit:`06b70832` Allow a custom keyboard event callback to be specified in the + :ref:`passive viewer` (:issue:`766`). +#. :commit:`f7847ba7` Fix GLFW crash when Python exits while the passive viewer is running (:issue:`790`). Models ^^^^^^ -10. Added simple `car `__ example model. +10. :commit:`51aa375a` Added simple `car `__ + example model. Version 2.3.6 (June 20, 2023) @@ -2017,18 +2096,20 @@ Version 2.3.6 (June 20, 2023) Models ^^^^^^ -1. Added `3x3x3 cube `__ example model. - See `README `__ for details. +1. :commit:`3d71b160` Added + `3x3x3 cube `__ example model. See + `README `__ for details. Bug fixes ^^^^^^^^^ -2. Fixed a bug that was causing an incorrect computation of the mesh bounding box and coordinate frame if the volume was - invalid. In such case, now MuJoCo only accepts a non-watertight geometry if +2. :commit:`41a70499` Fixed a bug that was causing an incorrect computation of the mesh bounding box and coordinate + frame if the volume was invalid. In such case, now MuJoCo only accepts a non-watertight geometry if :ref:`shellinertia` is equal to ``true``. -#. Fixed the sparse Jacobian multiplication logic that is used to compute derivatives for tendon damping and fluid - force, which affects the behaviour of the :ref:`implicit and implicitfast integrators`. -#. Fixes to :ref:`mj_ray`, in line with geom visualisation conventions: +#. :commit:`55c7f45d` Fixed the sparse Jacobian multiplication logic that is used to compute derivatives for tendon + damping and fluid force, which affects the behaviour of the + :ref:`implicit and implicitfast integrators`. +#. :commit:`c66d7940` Fixes to :ref:`mj_ray`, in line with geom visualisation conventions: - Planes and height-fields respect the ``geom_group`` and ``flg_static`` arguments. Before this change, rays would intersect planes and height-fields unconditionally. @@ -2041,9 +2122,11 @@ Bug fixes Plugins ^^^^^^^ -5. Added touch-grid sensor plugin. See `documentation `__ - for details, and associated `touch_grid.xml `__ - example model. The plugin includes `in-scene visualisation `__. +5. :commit:`b397b312` Added touch-grid sensor plugin. See + `documentation `__ for details, and + associated + `touch_grid.xml `__ example + model. The plugin includes `in-scene visualisation `__. Simulate ^^^^^^^^ @@ -2053,8 +2136,8 @@ Simulate :align: right :width: 240px -6. Added Visualization tab to simulate UI, corresponding to elements of the :ref:`visual` MJCF element. After - modifying values in the GUI, a saved XML will contain the new values. The modifiable members of +6. :commit:`d40c3959` Added Visualization tab to simulate UI, corresponding to elements of the :ref:`visual` + MJCF element. After modifying values in the GUI, a saved XML will contain the new values. The modifiable members of :ref:`mjStatistic` (:ref:`extent`, :ref:`meansize` and :ref:`center`) are computed by the compiler and therefore do not have defaults. In order for these attributes to appear in the saved XML, a value must be specified in the loaded XML. @@ -2064,31 +2147,32 @@ Simulate :width: 380px :alt: Before / After -7. Increased text width for UI elements in the default spacing. [before / after]: +7. :commit:`d40c3959` Increased text width for UI elements in the default spacing. [before / after]: General ^^^^^^^ -8. Added :ref:`mj_getState` and :ref:`mj_setState` for getting and setting the simulation state as a concatenated vector - of floating point numbers. See the :ref:`State` section for details. -#. Added :ref:`mjContact.solreffriction`, allowing different :ref:`solref` parameters for the normal - and frictional axes of contacts when using :ref:`elliptic friction cones`. This attribute is required - for elastic frictional collisions, see associated +8. :commit:`f67e3595` Added :ref:`mj_getState` and :ref:`mj_setState` for getting and setting the simulation state as a + concatenated vector of floating point numbers. See the :ref:`State` section for details. +#. :commit:`d82f5ce5` Added :ref:`mjContact.solreffriction`, allowing different :ref:`solref` + parameters for the normal and frictional axes of contacts when using :ref:`elliptic friction cones`. + This attribute is required for elastic frictional collisions, see associated `example model `__ - mimicking the spin-bounce recoil behaviour of `elastic rubber balls `__. - This is an advanced option currently only supported by explicit :ref:`contact pairs`, using the + mimicking the spin-bounce recoil behaviour of + `elastic rubber balls `__. This is an advanced option currently + only supported by explicit :ref:`contact pairs`, using the :ref:`solreffriction` attribute. -#. Added :ref:`mjd_inverseFD` for finite-differenced inverse-dynamics derivatives. -#. Added functions for operations on banded-then-dense "arrowhead" matrices. Such matrices are common when doing direct - trajectory optimization. See :ref:`mju_cholFactorBand` documentation for details. -#. Added :ref:`mj_multiRay` function for intersecting multiple rays emanating from a single point. +#. :commit:`b0bc330b` Added :ref:`mjd_inverseFD` for finite-differenced inverse-dynamics derivatives. +#. :commit:`49efa9cc` Added functions for operations on banded-then-dense "arrowhead" matrices. Such matrices are common + when doing direct trajectory optimization. See :ref:`mju_cholFactorBand` documentation for details. +#. :commit:`b0bc330b` Added :ref:`mj_multiRay` function for intersecting multiple rays emanating from a single point. This is significantly faster than calling :ref:`mj_ray` multiple times. -#. Ray-mesh collisions are now up to 10x faster, using a bounding volume hierarchy of mesh faces. -#. Increased ``mjMAXUIITEM`` (maximum number of UI elements per section in Simulate) to 100. -#. Added :ref:`documentation` for resource providers. -#. Changed the formula for :ref:`mju_sigmoid`, a finite-support sigmoid :math:`s \colon \mathbf R \rightarrow [0, 1]`. - Previously, the smooth part consisted of two stitched quadratics, once continuously differentiable. - It is now a single quintic, twice continuously differentiable: +#. :commit:`9d1a21f9` Ray-mesh collisions are now up to 10x faster, using a bounding volume hierarchy of mesh faces. +#. :commit:`3d82d2a4` Increased ``mjMAXUIITEM`` (maximum number of UI elements per section in Simulate) to 100. +#. :commit:`67f0f515` Added :ref:`documentation` for resource providers. +#. :commit:`49efa9cc` Changed the formula for :ref:`mju_sigmoid`, a finite-support sigmoid + :math:`s \colon \mathbf R \rightarrow [0, 1]`. Previously, the smooth part consisted of two stitched quadratics, once + continuously differentiable. It is now a single quintic, twice continuously differentiable: .. math:: s(x) = @@ -2098,21 +2182,23 @@ General 1, & 1 \le & x \qquad \end{cases} -17. Added optional :ref:`tausmooth` attribute to muscle actuators. When positive, the - time-constant :math:`\tau` of muscle activation/deactivation uses :ref:`mju_sigmoid` to transition smoothly - between the two extremal values given by the `Millard et al. (2013) `__ muscle - model, within a range of width tausmooth. See :ref:`Muscle actuators` for more details. +17. :commit:`770b4b36` Added optional :ref:`tausmooth` attribute to muscle actuators. When + positive, the time-constant :math:`\tau` of muscle activation/deactivation uses :ref:`mju_sigmoid` to transition + smoothly between the two extremal values given by the `Millard et al. (2013) `__ + muscle model, within a range of width tausmooth. See :ref:`Muscle actuators` for more details. Relatedly, :ref:`mju_muscleDynamics` now takes 3 parameters instead of 2, adding the new smoothing-width parameter. -#. Moved public C macro definitions out of mujoco.h into a new public header file called +#. :commit:`f887c1e9` Moved public C macro definitions out of mujoco.h into a new public header file called `mjmacro.h `__. The new file is included by mujoco.h so this change does not break existing user code. -#. Added instrumentation for the `Address Sanitizer (ASAN) `__ and +#. :commit:`f887c1e9` Added instrumentation for the + `Address Sanitizer (ASAN) `__ and `Memory Sanitizer (MSAN) `__ to detect memory bugs when allocating from the ``mjData`` stack and arena. -#. Removed ``pstack`` and ``parena`` from the output of ``mj_printData``, since these are implementation details of the - ``mjData`` allocators that are affected by diagnostic paddings in instrumented builds. -#. Removed the ``mj_activate`` and ``mj_deactivate`` functions. These had been kept around for compatibility with old - user code from when MuJoCo was closed source, but have been no-op functions since open sourcing. +#. :commit:`f887c1e9` Removed ``pstack`` and ``parena`` from the output of ``mj_printData``, since these are + implementation details of the ``mjData`` allocators that are affected by diagnostic paddings in instrumented builds. +#. :commit:`466c9aca` Removed the ``mj_activate`` and ``mj_deactivate`` functions. These had been kept around for + compatibility with old user code from when MuJoCo was closed source, but have been no-op functions since open + sourcing. Version 2.3.5 (April 25, 2023) @@ -2121,13 +2207,16 @@ Version 2.3.5 (April 25, 2023) Bug fixes ^^^^^^^^^ -1. Fix asset loading bug that prevented OBJ and PNG files from being read from disk when :ref:`mjVFS` is used. -#. Fix occasional segmentation faults on macOS when mouse perturbations are applied in the Python passive viewer. +1. :commit:`d23c5e78` Fix asset loading bug that prevented OBJ and PNG files from being read from disk when :ref:`mjVFS` + is used. +#. :commit:`d23c5e78` Fix occasional segmentation faults on macOS when mouse perturbations are applied in the Python + passive viewer. Plugins ^^^^^^^ -3. The ``visualize`` callback in :ref:`mjpPlugin` now receives an :ref:`mjvOption` as an input argument. +3. :commit:`d23c5e78` The ``visualize`` callback in :ref:`mjpPlugin` now receives an :ref:`mjvOption` as an input + argument. Version 2.3.4 (April 20, 2023) @@ -2141,48 +2230,51 @@ Version 2.3.4 (April 20, 2023) General ^^^^^^^ -1. Removed the "global" setting of the :ref:`compiler/coordinate` attribute. This rarely-used - setting complicates the compiler logic and is blocking future improvements. In order to convert older models which - used this option, load and save them in MuJoCo 2.3.3 or older. +1. :commit:`7cc42ecf` Removed the "global" setting of the :ref:`compiler/coordinate` attribute. + This rarely-used setting complicates the compiler logic and is blocking future improvements. In order to convert + older models which used this option, load and save them in MuJoCo 2.3.3 or older. .. image:: images/changelog/ellipsoidinertia.gif :align: right :width: 240px -2. Added :ref:`visual-global` flag :ref:`ellipsoidinertia` to visualize - equivalent body inertias with ellipsoids instead of the default boxes. -#. Added midphase and broadphase collision statistics to :ref:`mjData`. -#. Added documentation for :ref:`engine plugins`. -#. Added struct information to the ``introspect`` module. -#. Added a new extension mechanism called :ref:`resource providers`. This extensible mechanism allows MuJoCo - to read assets from data sources other than the local OS filesystem or +2. :commit:`7cc42ecf` Added :ref:`visual-global` flag + :ref:`ellipsoidinertia` to visualize equivalent body inertias with ellipsoids instead + of the default boxes. +#. :commit:`0db9a453` Added midphase and broadphase collision statistics to :ref:`mjData`. +#. :commit:`01b84089` Added documentation for :ref:`engine plugins`. +#. :commit:`2e23594f` Added struct information to the ``introspect`` module. +#. :commit:`fe3dccfd` Added a new extension mechanism called :ref:`resource providers`. This extensible + mechanism allows MuJoCo to read assets from data sources other than the local OS filesystem or the :ref:`Virtual file system`. Python bindings ^^^^^^^^^^^^^^^ -7. Offscreen rendering on macOS is no longer restricted to the main thread. This is achieved by using the low-level - Core OpenGL (CGL) API to create the OpenGL context, rather than going via GLFW which relies on Cocoa's NSOpenGL. - The resulting context is not tied to a Cocoa window, and is therefore not tied to the main thread. -#. Fixed a race condition in ``viewer.launch_passive`` and ``viewer.launch_repl``. These functions could previously - return before an internal call to ``mj_forward``. This allows user code to continue and potentially modify physics - state concurrently with the internal ``mj_forward``, resulting in e.g. +7. :commit:`6d63e046` Offscreen rendering on macOS is no longer restricted to the main thread. This is achieved by using + the low-level Core OpenGL (CGL) API to create the OpenGL context, rather than going via GLFW which relies on Cocoa's + NSOpenGL. The resulting context is not tied to a Cocoa window, and is therefore not tied to the main thread. +#. :commit:`34226bf5` Fixed a race condition in ``viewer.launch_passive`` and ``viewer.launch_repl``. These functions + could previously return before an internal call to ``mj_forward``. This allows user code to continue and potentially + modify physics state concurrently with the internal ``mj_forward``, resulting in e.g. `MuJoCo stack overflow error `__ or `segmentation fault `__. -#. The ``viewer.launch_passive`` function now returns a handle which can be used to interact with the viewer. The - passive viewer now also requires an explicit call to ``sync`` on its handle to pick up any update to the physics - state. This is to avoid race conditions that can result in visual artifacts. See +#. :commit:`0db9a453` The ``viewer.launch_passive`` function now returns a handle which can be used to interact with the + viewer. The passive viewer now also requires an explicit call to ``sync`` on its handle to pick up any update to the + physics state. This is to avoid race conditions that can result in visual artifacts. See :ref:`documentation` for details. -#. The ``viewer.launch_repl`` function has been removed since its functionality is superseded by ``launch_passive``. -#. Added a small number of missing struct fields discovered through the new ``introspect`` metadata. +#. :commit:`b362cb49` The ``viewer.launch_repl`` function has been removed since its functionality is superseded by + ``launch_passive``. +#. :commit:`2e23594f` Added a small number of missing struct fields discovered through the new ``introspect`` metadata. Bug fixes ^^^^^^^^^ -12. Fixed bug in the handling of ellipsoid-based fluid model forces in the new implicitfast integrator. -#. Removed spurious whole-arena copying in `mj_copyData`, which can considerably +12. :commit:`101c647a` Fixed bug in the handling of ellipsoid-based fluid model forces in the new implicitfast + integrator. +#. :commit:`0db9a453` Removed spurious whole-arena copying in `mj_copyData`, which can considerably `slow down `__ the copying operation. -#. Make :ref:`shellinertia` ignore ``exactmeshinertia``, which is +#. :commit:`2d69b158` Make :ref:`shellinertia` ignore ``exactmeshinertia``, which is only used for legacy volume computations (`#759 `__). @@ -2192,7 +2284,7 @@ Version 2.3.3 (March 20, 2023) General ^^^^^^^ -1. Improvements to implicit integration: +1. :commit:`8c7f6ce5` Improvements to implicit integration: - The derivatives of the RNE algorithm are now computed using sparse math, leading to significant speed improvements for large models when using the :ref:`implicit integrator`. @@ -2220,51 +2312,56 @@ General .. _midphase: -2. Added a collision mid-phase for pruning geoms in body pairs, see :ref:`documentation` for more details. - This is based on static AABB bounding volume hierarchy (a BVH binary tree) in the body inertial frame. The GIF on - the right is cut from `this longer video `__. -#. The ``mjd_transitionFD`` function no longer triggers sensor calculation unless explicitly requested. -#. Corrected the spelling of the ``inteval`` attribute to ``interval`` in the :ref:`mjLROpt` struct. -#. Mesh texture and normal mappings are now 3-per-triangle rather than 1-per-vertex. Mesh vertices are no longer - duplicated in order to circumvent this limitation as they previously were. -#. The non-zeros for the sparse constraint Jacobian matrix are now precounted and used for matrix memory allocation. - For instance, the constraint Jacobian matrix from the `humanoid100 +2. :commit:`70959c1a` Added a collision mid-phase for pruning geoms in body pairs, see :ref:`documentation` + for more details. This is based on static AABB bounding volume hierarchy (a BVH binary tree) in the body inertial + frame. The GIF on the right is cut from `this longer video `__. +#. :commit:`49c939ea` The ``mjd_transitionFD`` function no longer triggers sensor calculation unless explicitly + requested. +#. :commit:`c57a588a` Corrected the spelling of the ``inteval`` attribute to ``interval`` in the :ref:`mjLROpt` struct. +#. :commit:`9756ed0d` Mesh texture and normal mappings are now 3-per-triangle rather than 1-per-vertex. Mesh vertices + are no longer duplicated in order to circumvent this limitation as they previously were. +#. :commit:`50bebcb4` The non-zeros for the sparse constraint Jacobian matrix are now precounted and used for matrix + memory allocation. For instance, the constraint Jacobian matrix from the `humanoid100 `__ model, which previously required ~500,000 ``mjtNum``'s, now only requires ~6000. Very large models can now load and run with the CG solver. -#. Modified :ref:`mju_error` and :ref:`mju_warning` to be variadic functions (support for printf-like arguments). The - functions ``mju_error_i``, ``mju_error_s``, ``mju_warning_i``, and ``mju_warning_s`` are now deprecated. -#. Implemented a performant ``mju_sqrMatTDSparse`` function that doesn't require dense memory allocation. -#. Added ``mj_stackAllocInt`` to get correct size for allocating ints on mjData stack. Reducing stack memory usage - by 10% - 15%. +#. :commit:`d3d789cf` Modified :ref:`mju_error` and :ref:`mju_warning` to be variadic functions (support for printf-like + arguments). The functions ``mju_error_i``, ``mju_error_s``, ``mju_warning_i``, and ``mju_warning_s`` are now + deprecated. +#. :commit:`8c7f6ce5` Implemented a performant ``mju_sqrMatTDSparse`` function that doesn't require dense memory + allocation. +#. :commit:`8696247f` Added ``mj_stackAllocInt`` to get correct size for allocating ints on mjData stack. Reducing stack + memory usage by 10% - 15%. Python bindings ^^^^^^^^^^^^^^^ -10. Fixed IPython history corruption when using ``viewer.launch_repl``. The ``launch_repl`` function now provides - seamless continuation of an IPython interactive shell session, and is no longer considered experimental feature. -#. Added ``viewer.launch_passive`` which launches the interactive viewer in a passive, non-blocking mode. Calls to - ``launch_passive`` return immediately, allowing user code to continue execution, with the viewer automatically - reflecting any changes to the physics state. (Note that this functionality is currently in experimental/beta stage, - and is not yet described in our :ref:`viewer documentation`.) -#. Added the ``mjpython`` launcher for macOS, which is required for ``viewer.launch_passive`` to function there. -#. Removed ``efc_`` fields from joint indexers. Since the introduction of arena memory, these fields now have dynamic - sizes that change between time steps depending on the number of active constraints, breaking strict correspondence - between joints and ``efc_`` rows. -#. Added a number of missing fields to the bindings of ``mjVisual`` and ``mjvPerturb`` structs. +10. :commit:`e58d53e7` Fixed IPython history corruption when using ``viewer.launch_repl``. The ``launch_repl`` function + now provides seamless continuation of an IPython interactive shell session, and is no longer considered experimental + feature. +#. :commit:`7a0def97` Added ``viewer.launch_passive`` which launches the interactive viewer in a passive, non-blocking + mode. Calls to ``launch_passive`` return immediately, allowing user code to continue execution, with the viewer + automatically reflecting any changes to the physics state. (Note that this functionality is currently in + experimental/beta stage, and is not yet described in our :ref:`viewer documentation`.) +#. :commit:`7a0def97` Added the ``mjpython`` launcher for macOS, which is required for ``viewer.launch_passive`` to + function there. +#. :commit:`e20ab6c9` Removed ``efc_`` fields from joint indexers. Since the introduction of arena memory, these fields + now have dynamic sizes that change between time steps depending on the number of active constraints, breaking strict + correspondence between joints and ``efc_`` rows. +#. :commit:`e20ab6c9` Added a number of missing fields to the bindings of ``mjVisual`` and ``mjvPerturb`` structs. Simulate ^^^^^^^^ -15. Implemented a workaround for `broken VSync `__ on macOS so that the frame - rate is correctly capped when the Vertical Sync toggle is enabled. +15. :commit:`2f0fb1e4` Implemented a workaround for `broken VSync `__ on macOS + so that the frame rate is correctly capped when the Vertical Sync toggle is enabled. .. image:: images/changelog/contactlabel.png :align: right :width: 400px -16. Added optional labels to contact visualization, indicating which two geoms are contacting (names if defined, ids - otherwise). This can be useful in cluttered scenes. +16. :commit:`2607e67f` Added optional labels to contact visualization, indicating which two geoms are contacting (names + if defined, ids otherwise). This can be useful in cluttered scenes. |br| @@ -2275,49 +2372,52 @@ Version 2.3.2 (February 7, 2023) General ^^^^^^^ -1. A more performant mju_transposeSparse has been implemented that doesn't require dense memory allocation. - For a constraint Jacobian matrix from the +1. :commit:`c741dfce` A more performant mju_transposeSparse has been implemented that doesn't require dense memory + allocation. For a constraint Jacobian matrix from the `humanoid100.xml `__ model, this function is 35% faster. -#. The function :ref:`mj_name2id` is now implemented using a hash function instead of a linear search for better - performance. -#. Geom names are now parsed from URDF. Any duplicate names are ignored. +#. :commit:`f1007df0` The function :ref:`mj_name2id` is now implemented using a hash function instead of a linear search + for better performance. +#. :commit:`929e09f8` Geom names are now parsed from URDF. Any duplicate names are ignored. ``mj_printData`` output now contains contacting geom names. Bug fixes ^^^^^^^^^ -4. Fixed a bug that for :at:`shellinertia` equal to ``true`` caused the mesh orientation to be overwritten by the - principal components of the shell inertia, while the vertex coordinates are rotated using the volumetric inertia. - Now the volumetric inertia orientation is used also in the shell case. -#. Fixed misalignment bug in mesh-to-primitive fitting when using the bounding box fitting option :at:`fitaabb`. +4. :commit:`6ba4d6f0` Fixed a bug that for :at:`shellinertia` equal to ``true`` caused the mesh orientation to be + overwritten by the principal components of the shell inertia, while the vertex coordinates are rotated using the + volumetric inertia. Now the volumetric inertia orientation is used also in the shell case. +#. :commit:`19b6c70e` Fixed misalignment bug in mesh-to-primitive fitting when using the bounding box fitting option + :at:`fitaabb`. .. image:: images/changelog/meshfit.png :align: right :width: 300px -6. The ``launch_repl`` functionality in the Python viewer has been fixed. -#. Set ``time`` correctly in ``mjd_transitionFD``, to support time-dependent user code. -#. Fixed sensor data dimension validation when ``user`` type sensors are present. -#. Fixed incorrect plugin error message when a null ``nsensordata`` callback is encountered during model compilation. -#. Correctly end the timer (``TM_END``) ``mj_fwdConstraint`` returns early. -#. Fixed an infinite loop in ``mj_deleteFileVFS``. +6. :commit:`6b80b010` The ``launch_repl`` functionality in the Python viewer has been fixed. +#. :commit:`10c5d6a1` Set ``time`` correctly in ``mjd_transitionFD``, to support time-dependent user code. +#. :commit:`6b80b010` Fixed sensor data dimension validation when ``user`` type sensors are present. +#. :commit:`6b80b010` Fixed incorrect plugin error message when a null ``nsensordata`` callback is encountered during + model compilation. +#. :commit:`10c5d6a1` Correctly end the timer (``TM_END``) ``mj_fwdConstraint`` returns early. +#. :commit:`6b80b010` Fixed an infinite loop in ``mj_deleteFileVFS``. Simulate ^^^^^^^^ -12. Increased precision of simulate sensor plot y-axis by 1 digit +12. :commit:`6b80b010` Increased precision of simulate sensor plot y-axis by 1 digit (`#719 `_). -#. Body labels are now drawn at the body frame rather than inertial frame, unless inertia is being visualised. +#. :commit:`10c5d6a1` Body labels are now drawn at the body frame rather than inertial frame, unless inertia is being + visualised. Plugins ^^^^^^^ -14. The ``reset`` callback now receives instance-specific ``plugin_state`` and ``plugin_data`` as arguments, rather than - the entire ``mjData``. Since ``reset`` is called inside ``mj_resetData`` before any physics forwarding call has been - made, it is an error to read anything from ``mjData`` at this stage. -#. The ``capabilities`` field in ``mjpPlugin`` is renamed ``capabilityflags`` to more clearly indicate that this is a - bit field. +14. :commit:`10c5d6a1` The ``reset`` callback now receives instance-specific ``plugin_state`` and ``plugin_data`` as + arguments, rather than the entire ``mjData``. Since ``reset`` is called inside ``mj_resetData`` before any physics + forwarding call has been made, it is an error to read anything from ``mjData`` at this stage. +#. :commit:`10c5d6a1` The ``capabilities`` field in ``mjpPlugin`` is renamed ``capabilityflags`` to more clearly + indicate that this is a bit field. Version 2.3.1 (December 6, 2022) @@ -2326,18 +2426,20 @@ Version 2.3.1 (December 6, 2022) Python bindings ^^^^^^^^^^^^^^^ -1. The ``simulate`` GUI is now available through the ``mujoco`` Python package as ``mujoco.viewer``. +1. :commit:`0846f38c` The ``simulate`` GUI is now available through the ``mujoco`` Python package as ``mujoco.viewer``. See :ref:`documentation` for details. (Contribution by `Levi Burner `__.) -#. The ``Renderer`` class from the MuJoCo tutorial Colab is now available directly in the native Python bindings. +#. :commit:`ef695bb8` The ``Renderer`` class from the MuJoCo tutorial Colab is now available directly in the native + Python bindings. General ^^^^^^^ -3. The tendon :at:`springlength` attribute can now take two values. Given two non-decreasing values, `springlength` - specifies a `deadband `__ range for spring stiffness. If the tendon length is - between the two values, the force is 0. If length is outside this range, the force behaves like a regular spring, with - the spring resting length corresponding to the nearest :at:`springlength` value. This can be used to create tendons - whose limits are enforced by springs rather than constraints, which are cheaper and easier to analyse. See +3. :commit:`893942a7` The tendon :at:`springlength` attribute can now take two values. Given two non-decreasing values, + `springlength` specifies a `deadband `__ range for spring stiffness. If the + tendon length is between the two values, the force is 0. If length is outside this range, the force behaves like a + regular spring, with the spring resting length corresponding to the nearest :at:`springlength` value. This can be + used to create tendons whose limits are enforced by springs rather than constraints, which are cheaper and easier to + analyse. See `tendon_springlength.xml `__ example model. @@ -2349,26 +2451,27 @@ General :align: right :height: 150px -#. Removed the requirement that stateless actuators come before stateful actuators. -#. Added :ref:`mju_fill`, :ref:`mju_symmetrize` and :ref:`mju_eye` utility functions. -#. Added :at:`gravcomp` attribute to :ref:`body`, implementing gravity compensation and buoyancy. - See `balloons.xml `__ example model. -#. Renamed the ``cable`` plugin library to ``elasticity``. -#. Added :at:`actdim` attribute to :ref:`general actuators`. Values greater than 1 are only allowed - for dyntype :at-val:`user`, as native activation dynamics are all scalar. Added example test implementing 2nd-order - activation dynamics to +#. :commit:`0eb7f871` Removed the requirement that stateless actuators come before stateful actuators. +#. :commit:`f905c7fb` Added :ref:`mju_fill`, :ref:`mju_symmetrize` and :ref:`mju_eye` utility functions. +#. :commit:`60fbb77b` Added :at:`gravcomp` attribute to :ref:`body`, implementing gravity compensation and + buoyancy. See `balloons.xml `__ + example model. +#. :commit:`36b30e45` Renamed the ``cable`` plugin library to ``elasticity``. +#. :commit:`0b45129c` Added :at:`actdim` attribute to :ref:`general actuators`. Values greater than 1 + are only allowed for dyntype :at-val:`user`, as native activation dynamics are all scalar. Added example test + implementing 2nd-order activation dynamics to `engine_forward_test.cc `__. -#. Improved particle :ref:`composite` type, which now permits a user-specified geometry and multiple - joints. See the two new examples: +#. :commit:`3b89b0fd` Improved particle :ref:`composite` type, which now permits a user-specified + geometry and multiple joints. See the two new examples: `particle_free.xml `__ and `particle_free2d.xml `__. -#. Performance improvements for non-AVX configurations: +#. :commit:`7b0fbc63` Performance improvements for non-AVX configurations: - 14% faster ``mj_solveLD`` using `restrict `__. See `engine_core_smooth_benchmark_test `__. - 50% faster ``mju_dotSparse`` using manual loop unroll. See `engine_util_sparse_benchmark_test `__. -#. Added new :at:`solid` passive force plugin: +#. :commit:`d0b1a973` Added new :at:`solid` passive force plugin: .. youtube:: AGcTGHbbze4 :align: right @@ -2381,31 +2484,35 @@ General - Only suitable for small strains (large displacements but small deformations). Tetrahedra may invert if subject to large loads. -#. Added API functions ``mj_loadPluginLibrary`` and ``mj_loadAllPluginLibraries``. The first function is identical to - ``dlopen`` on a POSIX system, and to ``LoadLibraryA`` on Windows. The second function scans a specified directory for - all dynamic libraries file and loads each library found. Dynamic libraries opened by these functions are assumed to - register one or more MuJoCo plugins on load. -#. Added an optional ``visualize`` callback to plugins, which is called during ``mjv_updateScene``. This callback allows - custom plugin visualizations. Enable stress visualization for the Cable plugin as an example. -#. Sensors of type :ref:`user` no longer require :at:`objtype`, :at:`objname` and :at:`needstage`. If - unspecified, the objtype is now :ref:`mjOBJ_UNKNOWN`. ``user`` sensors :at:`datatype` default is now - :at-val:`"real"`, :at:`needstage` default is now :at-val:`"acc"`. -#. Added support for capsules in URDF import. -#. On macOS, issue an informative error message when run under `Rosetta 2 `__ - translation on an Apple Silicon machine. Pre-built MuJoCo binaries make use of - `AVX `__ instructions on x86-64 machines, which is not - supported by Rosetta 2. (Before this version, users only get a cryptic "Illegal instruction" message.) +#. :commit:`60fbb77b` Added API functions ``mj_loadPluginLibrary`` and ``mj_loadAllPluginLibraries``. The first function + is identical to ``dlopen`` on a POSIX system, and to ``LoadLibraryA`` on Windows. The second function scans a + specified directory for all dynamic libraries file and loads each library found. Dynamic libraries opened by these + functions are assumed to register one or more MuJoCo plugins on load. +#. :commit:`60fbb77b` Added an optional ``visualize`` callback to plugins, which is called during ``mjv_updateScene``. + This callback allows custom plugin visualizations. Enable stress visualization for the Cable plugin as an example. +#. :commit:`dee1d602` Sensors of type :ref:`user` no longer require :at:`objtype`, :at:`objname` and + :at:`needstage`. If unspecified, the objtype is now :ref:`mjOBJ_UNKNOWN`. ``user`` sensors :at:`datatype` + default is now :at-val:`"real"`, :at:`needstage` default is now :at-val:`"acc"`. +#. :commit:`60fbb77b` Added support for capsules in URDF import. +#. :commit:`df25d7d6` On macOS, issue an informative error message when run under + `Rosetta 2 `__ translation on an Apple Silicon machine. Pre-built MuJoCo + binaries make use of `AVX `__ instructions on x86-64 + machines, which is not supported by Rosetta 2. (Before this version, users only get a cryptic "Illegal instruction" + message.) Bug fixes ^^^^^^^^^ -17. Fixed bug in ``mj_addFileVFS`` that was causing the file path to be ignored (introduced in 2.1.4). +17. :commit:`89185b4a` Fixed bug in ``mj_addFileVFS`` that was causing the file path to be ignored (introduced in + 2.1.4). Simulate ^^^^^^^^ -18. Renamed the directory in which the ``simulate`` application searches for plugins from ``plugin`` to ``mujoco_plugin``. -#. Mouse force perturbations are now applied at the selection point rather than the body center of mass. +18. :commit:`2ebc5f09` Renamed the directory in which the ``simulate`` application searches for plugins from ``plugin`` + to ``mujoco_plugin``. +#. :commit:`165e72f7` Mouse force perturbations are now applied at the selection point rather than the body center of + mass. Version 2.3.0 (October 18, 2022) @@ -2414,9 +2521,9 @@ Version 2.3.0 (October 18, 2022) General ^^^^^^^ -1. The ``contact`` array and arrays prefixed with ``efc_`` in ``mjData`` were moved out of the ``buffer`` into a new - ``arena`` memory space. These arrays are no longer allocated with fixed sizes when ``mjData`` is created. - Instead, the exact memory requirement is determined during each call to :ref:`mj_forward` (specifically, +1. :commit:`58fd72f5` The ``contact`` array and arrays prefixed with ``efc_`` in ``mjData`` were moved out of the + ``buffer`` into a new ``arena`` memory space. These arrays are no longer allocated with fixed sizes when ``mjData`` + is created. Instead, the exact memory requirement is determined during each call to :ref:`mj_forward` (specifically, in :ref:`mj_collision` and :ref:`mj_makeConstraint`) and the arrays are allocated from the ``arena`` space. The ``stack`` now also shares its available memory with ``arena``. This change reduces the memory footprint of ``mjData`` in models that do not use the PGS solver, and will allow for significant memory reductions in the future. @@ -2427,21 +2534,21 @@ General :align: right :height: 150px -#. Added colab notebook tutorial showing how to balance the humanoid on one leg with a Linear Quadratic Regulator. The - notebook uses MuJoCo's native Python bindings, and includes a draft ``Renderer`` class, for easy rendering in Python. - |br| Try it yourself: |LQRopenincolab| +#. :commit:`f151e84a` Added colab notebook tutorial showing how to balance the humanoid on one leg with a Linear + Quadratic Regulator. The notebook uses MuJoCo's native Python bindings, and includes a draft ``Renderer`` class, for + easy rendering in Python. |br| Try it yourself: |LQRopenincolab| .. |LQRopenincolab| image:: https://colab.research.google.com/assets/colab-badge.png :target: https://colab.research.google.com/github/deepmind/mujoco/blob/main/python/LQR.ipynb -#. Updates to humanoid model: +#. :commit:`04d44e1e` Updates to humanoid model: - Added two keyframes (stand-on-one-leg and squat). - Increased maximum hip flexion angle. - Added hamstring tendons which couple the hip and knee at high hip flexion angles. - General cosmetic improvements, including improved use of defaults and better naming scheme. -#. Added :ref:`mju_boxQP` and allocation function :ref:`mju_boxQPmalloc` for solving the box-constrained - Quadratic Program: +#. :commit:`89579766` Added :ref:`mju_boxQP` and allocation function :ref:`mju_boxQPmalloc` for solving the + box-constrained Quadratic Program: .. math:: @@ -2450,22 +2557,22 @@ General The algorithm, introduced in `Tassa et al. 2014 `__, converges after 2-5 Cholesky factorisations, independent of problem size. -#. Added :ref:`mju_mulVecMatVec` to multiply a square matrix :math:`M` with vectors :math:`x` and :math:`y` on both - sides. The function returns :math:`x^TMy`. +#. :commit:`f4e7fa97` Added :ref:`mju_mulVecMatVec` to multiply a square matrix :math:`M` with vectors :math:`x` and + :math:`y` on both sides. The function returns :math:`x^TMy`. -#. Added new plugin API. Plugins allow developers to extend MuJoCo's capability without modifying core engine code. - The plugin mechanism is intended to replace the existing callbacks, though these will remain for the time being as an - option for simple use cases and backward compatibility. The new mechanism manages stateful plugins and supports - multiple plugins from different sources, allowing MuJoCo extensions to be introduced in a modular fashion, rather - than as global overrides. Note the new mechanism is currently undocumented except in code, as we test it internally. - If you are interested in using the plugin mechanism, please get in touch first. +#. :commit:`1e2a9a53` Added new plugin API. Plugins allow developers to extend MuJoCo's capability without modifying + core engine code. The plugin mechanism is intended to replace the existing callbacks, though these will remain for + the time being as an option for simple use cases and backward compatibility. The new mechanism manages stateful + plugins and supports multiple plugins from different sources, allowing MuJoCo extensions to be introduced in a + modular fashion, rather than as global overrides. Note the new mechanism is currently undocumented except in code, as + we test it internally. If you are interested in using the plugin mechanism, please get in touch first. -#. Added :at:`assetdir` compiler option, which sets the values of both :at:`meshdir` and :at:`texturedir`. Values in - the latter attributes take precedence over :at:`assetdir`. +#. :commit:`cce35e18` Added :at:`assetdir` compiler option, which sets the values of both :at:`meshdir` and + :at:`texturedir`. Values in the latter attributes take precedence over :at:`assetdir`. -#. Added :at:`realtime` option to :ref:`visual` for starting a simulation at a slower speed. +#. :commit:`84d16844` Added :at:`realtime` option to :ref:`visual` for starting a simulation at a slower speed. -#. Added new :at:`cable` composite type: +#. :commit:`e250ff0d` Added new :at:`cable` composite type: - Cable elements are connected with ball joints. - The `initial` parameter specifies the joint at the starting boundary: :at:`free`, :at:`ball`, or :at:`none`. @@ -2473,7 +2580,7 @@ General - The vertex initial positions can be specified directly in the XML with the parameter :at:`vertex`. - The orientation of the body frame **is** the orientation of the material frame of the curve. -#. Added new :at:`cable` passive force plugin: +#. :commit:`e250ff0d` Added new :at:`cable` passive force plugin: - Twist and bending stiffness can be set separately with the parameters :at:`twist` and :at:`bend`. - The stress-free configuration can be set to be the initial one or flat with the flag :at:`flat`. @@ -2493,14 +2600,14 @@ General Python bindings ^^^^^^^^^^^^^^^ -11. Added ``id`` and ``name`` properties to +11. :commit:`c13979cd` Added ``id`` and ``name`` properties to `named accessor `__ objects. These provide more Pythonic API access to ``mj_name2id`` and ``mj_id2name`` respectively. -#. The length of ``MjData.contact`` is now ``ncon`` rather than ``nconmax``, allowing it to be straightforwardly used as - an iterator without needing to check ``ncon``. +#. :commit:`58fd72f5` The length of ``MjData.contact`` is now ``ncon`` rather than ``nconmax``, allowing it to be + straightforwardly used as an iterator without needing to check ``ncon``. -#. Fix a memory leak when a Python callable is installed as callback +#. :commit:`ec6ea6a6` Fix a memory leak when a Python callable is installed as callback (`#527 `__). @@ -2515,31 +2622,37 @@ General :align: right :height: 150px -1. Added :ref:`adhesion actuators` mimicking vacuum grippers and adhesive biomechanical appendages. -#. Added related `example model `__ and video: -#. Added :ref:`mj_jacSubtreeCom` for computing the translational Jacobian of the center-of-mass of a subtree. -#. Added :at:`torquescale` and :at:`anchor` attributes to :el:`weld` constraints. :at:`torquescale` sets the - torque-to-force ratio exerted by the constraint, :at:`anchor` sets the point at which the weld wrench is +1. :commit:`0b2f19bb` Added :ref:`adhesion actuators` mimicking vacuum grippers and adhesive + biomechanical appendages. +#. :commit:`3d77eb1e` Added related + `example model `__ and video: +#. :commit:`fcf41317` Added :ref:`mj_jacSubtreeCom` for computing the translational Jacobian of the center-of-mass of a + subtree. +#. :commit:`d26501c0` Added :at:`torquescale` and :at:`anchor` attributes to :el:`weld` constraints. :at:`torquescale` + sets the torque-to-force ratio exerted by the constraint, :at:`anchor` sets the point at which the weld wrench is applied. See :ref:`weld ` for more details. -#. Increased ``mjNEQDATA``, the row length of equality constraint parameters in ``mjModel.eq_data``, from 7 to 11. -#. Added visualisation of anchor points for both :el:`connect` and :el:`weld` constraints (activated by the 'N' key in - ``simulate``). -#. Added `weld.xml `__ showing - different uses of new weld attributes. +#. :commit:`d26501c0` Increased ``mjNEQDATA``, the row length of equality constraint parameters in ``mjModel.eq_data``, + from 7 to 11. +#. :commit:`8ca5887c` Added visualisation of anchor points for both :el:`connect` and :el:`weld` constraints (activated + by the 'N' key in ``simulate``). +#. :commit:`8ca5887c` Added + `weld.xml `__ showing different + uses of new weld attributes. .. youtube:: s-0JHanqV1A :aspect: 16:7 :align: right :height: 150px -#. Cartesian 6D end-effector control is now possible by adding a reference site to actuators with :at:`site` - transmission. See description of new :at:`refsite` attribute in the :ref:`actuator` documentation - and `refsite.xml `__ +#. :commit:`46da1285` Cartesian 6D end-effector control is now possible by adding a reference site to actuators with + :at:`site` transmission. See description of new :at:`refsite` attribute in the :ref:`actuator` + documentation and + `refsite.xml `__ example model. -#. Added :at:`autolimits` compiler option. If ``true``, joint and tendon :at:`limited` attributes and actuator - :at:`ctrllimited`, :at:`forcelimited` and :at:`actlimited` attributes will automatically be set to ``true`` if the - corresponding range *is defined* and ``false`` otherwise. +#. :commit:`a693a2d9` Added :at:`autolimits` compiler option. If ``true``, joint and tendon :at:`limited` attributes and + actuator :at:`ctrllimited`, :at:`forcelimited` and :at:`actlimited` attributes will automatically be set to ``true`` + if the corresponding range *is defined* and ``false`` otherwise. If ``autolimits="false"`` (the default) models where a :at:`range` attribute is specified without the :at:`limited` attribute will fail to compile. A future release will change the default of :at:`autolimits` to ``true``, and this @@ -2549,40 +2662,42 @@ General This is a breaking change. In models where a range was defined but :at:`limited` was unspecified, explicitly set limited to ``false`` or remove the range to maintain the current behavior of your model. -#. Added moment of inertia computation for all well-formed meshes. This option is activated by setting the compiler - flag :at:`exactmeshinertia` to ``true`` (defaults to ``false``). This default may change in the future. -#. Added parameter :at:`shellinertia` to :at:`geom`, for locating the inferred inertia on the boundary (shell). - Currently only meshes are supported. -#. For meshes from which volumetric inertia is inferred, raise error if the orientation of mesh faces is not consistent. - If this occurs, fix the mesh in e.g., MeshLab or Blender. +#. :commit:`8ca5887c` Added moment of inertia computation for all well-formed meshes. This option is activated by + setting the compiler flag :at:`exactmeshinertia` to ``true`` (defaults to ``false``). This default may change in the + future. +#. :commit:`833dc740` Added parameter :at:`shellinertia` to :at:`geom`, for locating the inferred inertia on the + boundary (shell). Currently only meshes are supported. +#. :commit:`833dc740` For meshes from which volumetric inertia is inferred, raise error if the orientation of mesh faces + is not consistent. If this occurs, fix the mesh in e.g., MeshLab or Blender. .. youtube:: I2q7D0Vda-A :align: right :height: 150px -#. Added catenary visualisation for hanging tendons. The model seen in the video can be found +#. :commit:`ae0ac86e` Added catenary visualisation for hanging tendons. The model seen in the video can be found `here `__. -#. Added ``azimuth`` and ``elevation`` attributes to :ref:`visual/global`, defining the initial - orientation of the free camera at model load time. -#. Added ``mjv_defaultFreeCamera`` which sets the default free camera, respecting the above attributes. -#. ``simulate`` now supports taking a screenshot via a button in the File section or via ``Ctrl-P``. -#. Improvements to time synchronisation in `simulate`, in particular report actual real-time factor if different from - requested factor (if e.g., the timestep is so small that simulation cannot keep up with real-time). -#. Added a disable flag for sensors. -#. :ref:`mju_mulQuat` and :ref:`mju_mulQuatAxis` support in place computation. For example +#. :commit:`b966a378` Added ``azimuth`` and ``elevation`` attributes to :ref:`visual/global`, defining + the initial orientation of the free camera at model load time. +#. :commit:`b966a378` Added ``mjv_defaultFreeCamera`` which sets the default free camera, respecting the above + attributes. +#. :commit:`80b4ffdd` ``simulate`` now supports taking a screenshot via a button in the File section or via ``Ctrl-P``. +#. :commit:`834e8dd5` Improvements to time synchronisation in `simulate`, in particular report actual real-time factor + if different from requested factor (if e.g., the timestep is so small that simulation cannot keep up with real-time). +#. :commit:`090fe2db` Added a disable flag for sensors. +#. :commit:`fdbbc8bb` :ref:`mju_mulQuat` and :ref:`mju_mulQuatAxis` support in place computation. For example |br| ``mju_mulQuat(a, a, b);`` sets the quaternion ``a`` equal to the product of ``a`` and ``b``. -#. Added sensor matrices to ``mjd_transitionFD`` (note this is an API change). +#. :commit:`e3a82247` Added sensor matrices to ``mjd_transitionFD`` (note this is an API change). Deleted/deprecated features ^^^^^^^^^^^^^^^^^^^^^^^^^^^ -21. Removed ``distance`` constraints. +21. :commit:`c8ff7b3d` Removed ``distance`` constraints. Bug fixes ^^^^^^^^^ -22. Fixed rendering of some transparent geoms in reflection. -#. Fixed ``intvelocity`` defaults parsing. +22. :commit:`f71daed6` Fixed rendering of some transparent geoms in reflection. +#. :commit:`0b2f19bb` Fixed ``intvelocity`` defaults parsing. Version 2.2.1 (July 18, 2022) @@ -2591,47 +2706,54 @@ Version 2.2.1 (July 18, 2022) General ^^^^^^^ -1. Added ``mjd_transitionFD`` to compute efficient finite difference approximations of the state-transition and - control-transition matrices, :ref:`see here` for more details. -#. Added derivatives for the ellipsoid fluid model. -#. Added ``ctrl`` attribute to :ref:`keyframes`. -#. Added ``clock`` sensor which :ref:`measures time`. -#. Added visualisation groups to skins. -#. Added actuator visualisation for ``free`` and ``ball`` joints and for actuators with ``site`` transmission. -#. Added visualisation for actuator activations. -#. Added ```` actuator shortcut for "integrated velocity" actuators, documented +1. :commit:`d3a86bb7` Added ``mjd_transitionFD`` to compute efficient finite difference approximations of the + state-transition and control-transition matrices, :ref:`see here` for more details. +#. :commit:`373cc894` Added derivatives for the ellipsoid fluid model. +#. :commit:`d3a86bb7` Added ``ctrl`` attribute to :ref:`keyframes`. +#. :commit:`c14a7ef4` Added ``clock`` sensor which :ref:`measures time`. +#. :commit:`d3a86bb7` Added visualisation groups to skins. +#. :commit:`d3a86bb7` Added actuator visualisation for ``free`` and ``ball`` joints and for actuators with ``site`` + transmission. +#. :commit:`d3a86bb7` Added visualisation for actuator activations. +#. :commit:`d3a86bb7` Added ```` actuator shortcut for "integrated velocity" actuators, documented :ref:`here `. -#. Added ```` actuator shortcut for active-damping actuators, documented :ref:`here `. -#. ``mju_rotVecMat`` and ``mju_rotVecMatT`` now support in-place multiplication. -#. ``mjData.ctrl`` values are no longer clamped in-place, remain untouched by the engine. -#. Arrays in mjData's buffer now align to 64-byte boundaries rather than 8-byte. -#. Added memory poisoning when building with `Address Sanitizer (ASAN) `__ - and `Memory Sanitizer (MSAN) `__. This allows ASAN to - detect reads and writes to regions in ``mjModel.buffer`` and ``mjData.buffer`` that do not lie within an array, and - for MSAN to detect reads from uninitialised fields in ``mjData`` following ``mj_resetData``. -#. Added a `slider-crank example model `__. +#. :commit:`d3a86bb7` Added ```` actuator shortcut for active-damping actuators, documented + :ref:`here `. +#. :commit:`d3a86bb7` ``mju_rotVecMat`` and ``mju_rotVecMatT`` now support in-place multiplication. +#. :commit:`d3a86bb7` ``mjData.ctrl`` values are no longer clamped in-place, remain untouched by the engine. +#. :commit:`d3a86bb7` Arrays in mjData's buffer now align to 64-byte boundaries rather than 8-byte. +#. :commit:`f887c1e9` Added memory poisoning when building with + `Address Sanitizer (ASAN) `__ and + `Memory Sanitizer (MSAN) `__. This allows ASAN to detect reads and + writes to regions in ``mjModel.buffer`` and ``mjData.buffer`` that do not lie within an array, and for MSAN to detect + reads from uninitialised fields in ``mjData`` following ``mj_resetData``. +#. :commit:`373cc894` Added a + `slider-crank example model `__. Bug fixes ^^^^^^^^^ -15. :ref:`Activation clamping ` was not being applied in the :ref:`implicit integrator`. -#. Stricter parsing of orientation specifiers. Before this change, a specification that included both ``quat`` and an - :ref:`alternative specifier` e.g., ````, would lead to - the ``quat`` being ignored and only ``euler`` being used. After this change a parse error will be thrown. -#. Stricter parsing of XML attributes. Before this change an erroneous XML snippet like ```` would - have been parsed as ``size="1 0 0"`` and no error would have been thrown. Now throws an error. -#. Trying to load a ``NaN`` via XML like ````, while allowed for debugging purposes, will now print - a warning. -#. Fixed null pointer dereference in ``mj_loadModel``. -#. Fixed memory leaks when loading an invalid model from MJB. -#. Integer overflows are now avoided when computing ``mjModel`` buffer sizes. -#. Added missing warning string for ``mjWARN_BADCTRL``. +15. :commit:`d3a86bb7` :ref:`Activation clamping ` was not being applied in the + :ref:`implicit integrator`. +#. :commit:`d3a86bb7` Stricter parsing of orientation specifiers. Before this change, a specification that included both + ``quat`` and an :ref:`alternative specifier` e.g., ````, + would lead to the ``quat`` being ignored and only ``euler`` being used. After this change a parse error will be + thrown. +#. :commit:`d3a86bb7` Stricter parsing of XML attributes. Before this change an erroneous XML snippet like + ```` would have been parsed as ``size="1 0 0"`` and no error would have been thrown. Now throws + an error. +#. :commit:`d3a86bb7` Trying to load a ``NaN`` via XML like ````, while allowed for debugging + purposes, will now print a warning. +#. :commit:`d3a86bb7` Fixed null pointer dereference in ``mj_loadModel``. +#. :commit:`d3a86bb7` Fixed memory leaks when loading an invalid model from MJB. +#. :commit:`d3a86bb7` Integer overflows are now avoided when computing ``mjModel`` buffer sizes. +#. :commit:`d3a86bb7` Added missing warning string for ``mjWARN_BADCTRL``. Packaging ^^^^^^^^^ -23. Changed MacOS packaging so that the copy of ``mujoco.framework`` embedded in ``MuJoCo.app`` can be used to build - applications externally. +23. :commit:`d3a86bb7` Changed MacOS packaging so that the copy of ``mujoco.framework`` embedded in ``MuJoCo.app`` can + be used to build applications externally. Version 2.2.0 (May 23, 2022) @@ -2640,7 +2762,7 @@ Version 2.2.0 (May 23, 2022) Open Sourcing ^^^^^^^^^^^^^ -1. MuJoCo is now fully open-source software. Newly available top level directories are: +1. :commit:`1913a02b` MuJoCo is now fully open-source software. Newly available top level directories are: a. ``src/``: All source files. Subdirectories correspond to the modules described in the Programming chapter :ref:`introduction`: @@ -2655,53 +2777,54 @@ Open Sourcing c. ``dist/``: Files related to packaging and binary distribution. -#. Added `contributor's guide `__ and +#. :commit:`1913a02b` Added + `contributor's guide `__ and `style guide `__. General ^^^^^^^ -3. Added analytic derivatives of smooth (unconstrained) dynamics forces, with respect to velocities: +3. :commit:`64bc6d27` Added analytic derivatives of smooth (unconstrained) dynamics forces, with respect to velocities: - Centripetal and Coriolis forces computed by the Recursive Newton-Euler algorithm. - Damping and fluid-drag passive forces. - Actuation forces. -#. Added ``implicit`` integrator. Using the analytic derivatives above, a new implicit-in-velocity integrator was added. - This integrator lies between the Euler and Runge Kutta integrators in terms of both stability and computational - cost. It is most useful for models which use fluid drag (e.g. for flying or swimming) and for models which use - :ref:`velocity actuators`. For more details, see the :ref:`Numerical Integration` - section. +#. :commit:`64bc6d27` Added ``implicit`` integrator. Using the analytic derivatives above, a new implicit-in-velocity + integrator was added. This integrator lies between the Euler and Runge Kutta integrators in terms of both stability + and computational cost. It is most useful for models which use fluid drag (e.g. for flying or swimming) and for + models which use :ref:`velocity actuators`. For more details, see the + :ref:`Numerical Integration` section. -#. Added :at:`actlimited` and :at:`actrange` attributes to :ref:`general actuators`, for clamping - actuator internal states (activations). This clamping is useful for integrated-velocity actuators, see the - :ref:`Activation clamping ` section for details. +#. :commit:`1913a02b` Added :at:`actlimited` and :at:`actrange` attributes to + :ref:`general actuators`, for clamping actuator internal states (activations). This clamping is + useful for integrated-velocity actuators, see the :ref:`Activation clamping ` section for details. -#. ``mjData`` fields ``qfrc_unc`` (unconstrained forces) and ``qacc_unc`` (unconstrained accelerations) were renamed - ``qfrc_smooth`` and ``qacc_smooth``, respectively. While "unconstrained" is precise, "smooth" is more intelligible - than "unc". +#. :commit:`1913a02b` ``mjData`` fields ``qfrc_unc`` (unconstrained forces) and ``qacc_unc`` (unconstrained + accelerations) were renamed ``qfrc_smooth`` and ``qacc_smooth``, respectively. While "unconstrained" is precise, + "smooth" is more intelligible than "unc". -#. Public headers have been moved from ``/include`` to ``/include/mujoco/``, in line with the directory layout common in - other open source projects. Developers are encouraged to include MuJoCo public headers in their own codebase via - ``#include ``. +#. :commit:`1913a02b` Public headers have been moved from ``/include`` to ``/include/mujoco/``, in line with the + directory layout common in other open source projects. Developers are encouraged to include MuJoCo public headers in + their own codebase via ``#include ``. -#. The default shadow resolution specified by the :ref:`shadowsize` attribute was increased from 1024 to - 4096. +#. :commit:`1913a02b` The default shadow resolution specified by the :ref:`shadowsize` attribute was + increased from 1024 to 4096. -#. Saved XMLs now use 2-space indents. +#. :commit:`1913a02b` Saved XMLs now use 2-space indents. Bug fixes ^^^^^^^^^ -10. Antialiasing was disabled for segmentation rendering. Before this change, if the :ref:`offsamples` - attribute was greater than 0 (the default value is 4), pixels that overlapped with multiple geoms would receive - averaged segmentation IDs, leading to incorrect or non-existent IDs. After this change :at:`offsamples` is ignored - during segmentation rendering. +10. :commit:`1913a02b` Antialiasing was disabled for segmentation rendering. Before this change, if the + :ref:`offsamples` attribute was greater than 0 (the default value is 4), pixels that overlapped with + multiple geoms would receive averaged segmentation IDs, leading to incorrect or non-existent IDs. After this change + :at:`offsamples` is ignored during segmentation rendering. -#. The value of the enable flag for the experimental multiCCD feature was made sequential with other enable flags. - Sequentiality is assumed in the ``simulate`` UI and elsewhere. +#. :commit:`1913a02b` The value of the enable flag for the experimental multiCCD feature was made sequential with other + enable flags. Sequentiality is assumed in the ``simulate`` UI and elsewhere. -#. Fix issue of duplicated meshes when saving models with OBJ meshes using mj_saveLastXML. +#. :commit:`1913a02b` Fix issue of duplicated meshes when saving models with OBJ meshes using mj_saveLastXML. Version 2.1.5 (Apr. 13, 2022) @@ -2710,20 +2833,21 @@ Version 2.1.5 (Apr. 13, 2022) General ^^^^^^^ -1. Added an experimental feature: multi-contact convex collision detection, activated by an enable flag. See full - description :ref:`here `. +1. :commit:`87539dbd` Added an experimental feature: multi-contact convex collision detection, activated by an enable + flag. See full description :ref:`here `. Bug fixes ^^^^^^^^^ -2. GLAD initialization logic on Linux now calls ``dlopen`` to load a GL platform dynamic library if a +2. :commit:`87539dbd` GLAD initialization logic on Linux now calls ``dlopen`` to load a GL platform dynamic library if a ``*GetProcAddress`` function is not already present in the process' global symbol table. In particular, processes that use GLFW to set up a rendering context that are not explicitly linked against ``libGLX.so`` (this applies to the Python interpreter, for example) will now work correctly rather than fail with a ``gladLoadGL`` error when ``mjr_makeContext`` is called. -#. In the Python bindings, named indexers for scalar fields (e.g. the ``ctrl`` field for actuators) now return a NumPy - array of shape ``(1,)`` rather than ``()``. This allows values to be assigned to these fields more straightforwardly. +#. :commit:`87539dbd` In the Python bindings, named indexers for scalar fields (e.g. the ``ctrl`` field for actuators) + now return a NumPy array of shape ``(1,)`` rather than ``()``. This allows values to be assigned to these fields more + straightforwardly. Version 2.1.4 (Apr. 4, 2022) ---------------------------- @@ -2731,41 +2855,42 @@ Version 2.1.4 (Apr. 4, 2022) General ^^^^^^^ -1. MuJoCo now uses GLAD to manage OpenGL API access instead of GLEW. On Linux, there is no longer a need to link against - different GL wrangling libraries depending on whether GLX, EGL, or OSMesa is being used. Instead, users can simply - use GLX, EGL, or OSMesa to create a GL context and ``mjr_makeContext`` will detect which one is being used. +1. :commit:`90dea1bd` MuJoCo now uses GLAD to manage OpenGL API access instead of GLEW. On Linux, there is no longer a + need to link against different GL wrangling libraries depending on whether GLX, EGL, or OSMesa is being used. + Instead, users can simply use GLX, EGL, or OSMesa to create a GL context and ``mjr_makeContext`` will detect which + one is being used. -#. Added visualisation for contact frames. This is useful when writing or modifying collision functions, when the actual - direction of the x and y axes of a contact can be important. +#. :commit:`90dea1bd` Added visualisation for contact frames. This is useful when writing or modifying collision + functions, when the actual direction of the x and y axes of a contact can be important. Binary build ^^^^^^^^^^^^ -3. The ``_nogl`` dynamic library is no longer provided on Linux and Windows. The switch to GLAD allows us to resolve - OpenGL symbols when ``mjr_makeContext`` is called rather than when the library is loaded. As a result, the MuJoCo - library no longer has an explicit dynamic dependency on OpenGL, and can be used on system where OpenGL is not - present. +3. :commit:`90dea1bd` The ``_nogl`` dynamic library is no longer provided on Linux and Windows. The switch to GLAD + allows us to resolve OpenGL symbols when ``mjr_makeContext`` is called rather than when the library is loaded. As a + result, the MuJoCo library no longer has an explicit dynamic dependency on OpenGL, and can be used on system where + OpenGL is not present. Simulate ^^^^^^^^ -4. Fixed a bug in simulate where pressing '[' or ']' when a model is not loaded causes a crash. +4. :commit:`90dea1bd` Fixed a bug in simulate where pressing '[' or ']' when a model is not loaded causes a crash. -#. Contact frame visualisation was added to the Simulate GUI. +#. :commit:`90dea1bd` Contact frame visualisation was added to the Simulate GUI. -#. Renamed "set key", "reset to key" to "save key" and "load key", respectively. +#. :commit:`90dea1bd` Renamed "set key", "reset to key" to "save key" and "load key", respectively. -#. Changed bindings of F6 and F7 from the not very useful "vertical sync" and "busy wait" to the more useful cycling of - frames and labels. +#. :commit:`90dea1bd` Changed bindings of F6 and F7 from the not very useful "vertical sync" and "busy wait" to the more + useful cycling of frames and labels. Bug fixes ^^^^^^^^^ -8. ``mj_resetData`` zeroes out the ``solver_nnz`` field. +8. :commit:`90dea1bd` ``mj_resetData`` zeroes out the ``solver_nnz`` field. -#. Removed a special branch in ``mju_quat2mat`` for unit quaternions. Previously, ``mju_quat2mat`` skipped all - computation if the real part of the quaternion equals 1.0. For very small angles (e.g. when finite differencing), the - cosine can evaluate to exactly 1.0 at double precision while the sine is still nonzero. +#. :commit:`90dea1bd` Removed a special branch in ``mju_quat2mat`` for unit quaternions. Previously, ``mju_quat2mat`` + skipped all computation if the real part of the quaternion equals 1.0. For very small angles (e.g. when finite + differencing), the cosine can evaluate to exactly 1.0 at double precision while the sine is still nonzero. Version 2.1.3 (Mar. 23, 2022) @@ -2774,19 +2899,19 @@ Version 2.1.3 (Mar. 23, 2022) General ^^^^^^^ -1. ``simulate`` now supports cycling through cameras (with the ``[`` and ``]`` keys). -#. ``mjVIS_STATIC`` toggles all static bodies, not just direct children of the world. +1. :commit:`df048e54` ``simulate`` now supports cycling through cameras (with the ``[`` and ``]`` keys). +#. :commit:`df048e54` ``mjVIS_STATIC`` toggles all static bodies, not just direct children of the world. Python bindings ^^^^^^^^^^^^^^^ -3. Added a ``free()`` method to ``MjrContext``. -#. Enums now support arithmetic and bitwise operations with numbers. +3. :commit:`df048e54` Added a ``free()`` method to ``MjrContext``. +#. :commit:`df048e54` Enums now support arithmetic and bitwise operations with numbers. Bug fixes ^^^^^^^^^ -5. Fixed rendering bug for planes, introduced in 2.1.2. This broke maze environments in +5. :commit:`df048e54` Fixed rendering bug for planes, introduced in 2.1.2. This broke maze environments in `dm_control `__. @@ -2796,27 +2921,27 @@ Version 2.1.2 (Mar. 15, 2022) New modules ^^^^^^^^^^^ -1. Added new :doc:`Python bindings`, which can be installed via ``pip install mujoco``, +1. :commit:`3577e2cf` Added new :doc:`Python bindings`, which can be installed via ``pip install mujoco``, and imported as ``import mujoco``. -#. Added new :doc:`Unity plug-in`. -#. Added a new ``introspect`` module, which provides reflection-like capability for MuJoCo's public API, currently - describing functions and enums. While implemented in Python, this module is expected to be generally useful for - automatic code generation targeting multiple languages. (This is not shipped as part of the ``mujoco`` Python - bindings package.) +#. :commit:`3577e2cf` Added new :doc:`Unity plug-in`. +#. :commit:`3577e2cf` Added a new ``introspect`` module, which provides reflection-like capability for MuJoCo's public + API, currently describing functions and enums. While implemented in Python, this module is expected to be generally + useful for automatic code generation targeting multiple languages. (This is not shipped as part of the ``mujoco`` + Python bindings package.) API changes ^^^^^^^^^^^ -4. Moved definition of ``mjtNum`` floating point type into a new header +4. :commit:`3577e2cf` Moved definition of ``mjtNum`` floating point type into a new header `mjtnum.h `__. -#. Renamed header `mujoco_export.h` to :ref:`mjexport.h`. -#. Added ``mj_printFormattedData``, which accepts a format string for floating point numbers, for example to increase - precision. +#. :commit:`3577e2cf` Renamed header `mujoco_export.h` to :ref:`mjexport.h`. +#. :commit:`3577e2cf` Added ``mj_printFormattedData``, which accepts a format string for floating point numbers, for + example to increase precision. General ^^^^^^^ -7. MuJoCo can load `OBJ `__ mesh files. +7. :commit:`3577e2cf` MuJoCo can load `OBJ `__ mesh files. a. Meshes containing polygons with more than 4 vertices are not supported. #. In OBJ files containing multiple object groups, any groups after the first one will be ignored. @@ -2827,13 +2952,13 @@ General :width: 300px -#. Added optional frame-of-reference specification to :ref:`framepos`, +#. :commit:`3577e2cf` Added optional frame-of-reference specification to :ref:`framepos`, :ref:`framequat`, :ref:`framexaxis`, :ref:`frameyaxis`, :ref:`framezaxis`, :ref:`framelinvel`, and :ref:`frameangvel` sensors. The frame-of-reference is specified by new :at:`reftype` and :at:`refname` attributes. -#. Sizes of :ref:`user parameters ` are now automatically inferred. +#. :commit:`3577e2cf` Sizes of :ref:`user parameters ` are now automatically inferred. a. Declarations of user parameters in the top-level :ref:`size ` clause (e.g. :at:`nuser_body`, :at:`nuser_jnt`, etc.) now accept a value of -1, which is the default. This will automatically set the value to @@ -2842,43 +2967,44 @@ General #. Setting a value to a length smaller than some :at:`user` attribute defined in the model will lead to an error (previously additional values were ignored). -#. Increased the maximum number of lights in an :ref:`mjvScene` from 8 to 100. +#. :commit:`3577e2cf` Increased the maximum number of lights in an :ref:`mjvScene` from 8 to 100. -#. Saved XML files only contain explicit :ref:`inertial ` elements if the original XML included them. - Inertias that were automatically inferred by the compiler's :ref:`inertiafromgeom ` mechanism remain - unspecified. +#. :commit:`3577e2cf` Saved XML files only contain explicit :ref:`inertial ` elements if the original XML + included them. Inertias that were automatically inferred by the compiler's :ref:`inertiafromgeom ` + mechanism remain unspecified. -#. User-selected geoms are always rendered as opaque. This is useful in interactive visualizers. +#. :commit:`3577e2cf` User-selected geoms are always rendered as opaque. This is useful in interactive visualizers. -#. Static geoms now respect their :ref:`geom group` for visualisation. Until this change rendering of static - geoms could only be toggled using the :ref:`mjVIS_STATIC` visualisation flag . After this change, both - the geom group and the visualisation flag need to be enabled for the geom to be rendered. +#. :commit:`3577e2cf` Static geoms now respect their :ref:`geom group` for visualisation. Until this change + rendering of static geoms could only be toggled using the :ref:`mjVIS_STATIC` visualisation flag . After + this change, both the geom group and the visualisation flag need to be enabled for the geom to be rendered. -#. Pointer parameters in function declarations in :ref:`mujoco.h` that are supposed to represent fixed-length - arrays are now spelled as arrays with extents, e.g. ``mjtNum quat[4]`` rather than ``mjtNum* quat``. From the - perspective of C and C++, this is a non-change since array types in function signatures decay to pointer types. - However, it allows autogenerated code to be aware of expected input shapes. +#. :commit:`3577e2cf` Pointer parameters in function declarations in :ref:`mujoco.h` that are supposed to + represent fixed-length arrays are now spelled as arrays with extents, e.g. ``mjtNum quat[4]`` rather than + ``mjtNum* quat``. From the perspective of C and C++, this is a non-change since array types in function signatures + decay to pointer types. However, it allows autogenerated code to be aware of expected input shapes. -#. Experimental stateless fluid interaction model. As described :ref:`here `, fluid forces use sizes computed - from body inertia. While sometimes convenient, this is very rarely a good approximation. In the new model forces act - on geoms, rather than bodies, and have a several user-settable parameters. The model is activated by setting a new - attribute: ````. The parameters are described succinctly :ref:`here`, but we - leave a full description or the model and its parameters to when this feature leaves experimental status. +#. :commit:`147efb51` Experimental stateless fluid interaction model. As described :ref:`here `, fluid forces + use sizes computed from body inertia. While sometimes convenient, this is very rarely a good approximation. In the + new model forces act on geoms, rather than bodies, and have a several user-settable parameters. The model is + activated by setting a new attribute: ````. The parameters are described succinctly + :ref:`here`, but we leave a full description or the model and its parameters to when this feature leaves + experimental status. Bug fixes ^^^^^^^^^ -16. ``mj_loadXML`` and ``mj_saveLastXML`` are now locale-independent. The Unity plugin should now work correctly for - users whose system locales use commas as decimal separators. -#. XML assets in VFS no longer need to end in a null character. Instead, the file size is determined by the size - parameter of the corresponding VFS entry. -#. Fix a vertex buffer object memory leak in ``mjrContext`` when skins are used. -#. Camera quaternions are now normalized during XML compilation. +16. :commit:`3577e2cf` ``mj_loadXML`` and ``mj_saveLastXML`` are now locale-independent. The Unity plugin should now + work correctly for users whose system locales use commas as decimal separators. +#. :commit:`3577e2cf` XML assets in VFS no longer need to end in a null character. Instead, the file size is determined + by the size parameter of the corresponding VFS entry. +#. :commit:`3577e2cf` Fix a vertex buffer object memory leak in ``mjrContext`` when skins are used. +#. :commit:`3577e2cf` Camera quaternions are now normalized during XML compilation. Binary build ^^^^^^^^^^^^ -20. Windows binaries are now built with Clang. +20. :commit:`3577e2cf` Windows binaries are now built with Clang. Version 2.1.1 (Dec. 16, 2021) ----------------------------- @@ -2886,11 +3012,12 @@ Version 2.1.1 (Dec. 16, 2021) API changes ^^^^^^^^^^^ -1. Added ``mj_printFormattedModel``, which accepts a format string for floating point numbers, for example to increase - precision. -#. Added ``mj_versionString``, which returns human-readable string that represents the version of the MuJoCo binary. -#. Converted leading underscores to trailing underscores in private instances of API struct definitions, to conform to - reserved identifier directive, see +1. :commit:`a499b381` Added ``mj_printFormattedModel``, which accepts a format string for floating point numbers, for + example to increase precision. +#. :commit:`a499b381` Added ``mj_versionString``, which returns human-readable string that represents the version of the + MuJoCo binary. +#. :commit:`a499b381` Converted leading underscores to trailing underscores in private instances of API struct + definitions, to conform to reserved identifier directive, see `C standard: Section 7.1.3 `__. .. attention:: @@ -2900,16 +3027,17 @@ API changes General ^^^^^^^ -4. Safer string handling: replaced ``strcat``, ``strcpy``, and ``sprintf`` with ``strncat``, ``strncpy``, and - ``snprintf`` respectively. -#. Changed indentation from 4 spaces to 2 spaces, K&R bracing style, added braces to one-line conditionals. +4. :commit:`a499b381` Safer string handling: replaced ``strcat``, ``strcpy``, and ``sprintf`` with ``strncat``, + ``strncpy``, and ``snprintf`` respectively. +#. :commit:`ee39340a` Changed indentation from 4 spaces to 2 spaces, K&R bracing style, added braces to one-line + conditionals. Bug Fixes ^^^^^^^^^ -6. Fixed reading from uninitialized memory in PGS solver. -#. Computed capsule inertias are now exact. Until this change, capsule masses and inertias computed by the - :ref:`compiler `'s :at:`inertiafromgeom` mechanism were approximated by a cylinder, formed by the +6. :commit:`a499b381` Fixed reading from uninitialized memory in PGS solver. +#. :commit:`a499b381` Computed capsule inertias are now exact. Until this change, capsule masses and inertias computed + by the :ref:`compiler `'s :at:`inertiafromgeom` mechanism were approximated by a cylinder, formed by the capsule's cylindrical middle section, extended on both ends by half the capsule radius. Capsule inertias are now computed with the `Parallel Axis theorem `__, applied to the two hemispherical end-caps. @@ -2917,10 +3045,10 @@ Bug Fixes .. attention:: This is a minor breaking change. Simulation of a model with automatically-computed capsule inertias will be numerically different, leading to, for example, breakage of golden-value tests. -#. Fixed bug related to :ref:`force ` and :ref:`torque ` sensors. Until this change, forces - and torques reported by F/T sensors ignored out-of-tree constraint wrenches except those produced by contacts. Force - and torque sensors now correctly take into account the effects of :ref:`connect ` and - :ref:`weld ` constraints. +#. :commit:`a499b381` Fixed bug related to :ref:`force ` and :ref:`torque ` sensors. Until + this change, forces and torques reported by F/T sensors ignored out-of-tree constraint wrenches except those produced + by contacts. Force and torque sensors now correctly take into account the effects of + :ref:`connect ` and :ref:`weld ` constraints. .. note:: Forces generated by :ref:`spatial tendons ` which are outside the kinematic tree (i.e., between @@ -2930,9 +3058,9 @@ Bug Fixes Code samples ^^^^^^^^^^^^ -9. ``testspeed``: Added injection of pseudo-random control noise, turned on by default. This is to avoid settling into - some fixed contact configuration and providing an unrealistic timing measure. -#. ``simulate``: +9. :commit:`a499b381` ``testspeed``: Added injection of pseudo-random control noise, turned on by default. This is to + avoid settling into some fixed contact configuration and providing an unrealistic timing measure. +#. :commit:`a499b381` ``simulate``: a. Added slower-than-real-time functionality, which is controlled via the '+' and '-' keys. #. Added sliders for injecting Brownian noise into the controls. @@ -2942,15 +3070,16 @@ Code samples Updated dependencies ^^^^^^^^^^^^^^^^^^^^ -11. ``TinyXML`` was replaced with ``TinyXML2`` 6.2.0. -#. ``qhull`` was upgraded to version 8.0.2. -#. ``libCCD`` was upgraded to version 1.4. -#. On Linux, ``libstdc++`` was replaced with ``libc++``. +11. :commit:`a499b381` ``TinyXML`` was replaced with ``TinyXML2`` 6.2.0. +#. :commit:`a499b381` ``qhull`` was upgraded to version 8.0.2. +#. :commit:`a499b381` ``libCCD`` was upgraded to version 1.4. +#. :commit:`a499b381` On Linux, ``libstdc++`` was replaced with ``libc++``. Binary build ^^^^^^^^^^^^ -15. MacOS packaging. We now ship Universal binaries that natively support both Apple Silicon and Intel CPUs. +15. :commit:`a499b381` MacOS packaging. We now ship Universal binaries that natively support both Apple Silicon and + Intel CPUs. a. MuJoCo library is now packaged as a `Framework Bundle