Commit Graph

4095 Commits

Author SHA1 Message Date
Taylor Howell 94e834bf4f Import google-deepmind/mujoco_warp from GitHub.
PiperOrigin-RevId: 868759523
Change-Id: I83a9f014840e66d7775a3684aa2e59ec5a077191
2026-02-11 11:14:24 -08:00
Yuval Tassa 883ba2134d Add System Identification toolbox to changelog.
PiperOrigin-RevId: 868759286
Change-Id: I7845c0858a9ba8188f02b84259306f2638823267
2026-02-11 11:13:27 -08:00
Adrian Collister d881e9e374 Change tex_adr type to mjtSize.
Adds a test which verifies that we can index into the texture buffer at offsets larger than can be represented by a 32-bit signed int.

PiperOrigin-RevId: 868756646
Change-Id: Ibc1a2b269fce41aec370611b0aab77803837e7a8
2026-02-11 11:09:36 -08:00
Yuval Tassa 2b5afce4aa Fix island graph construction for multi-tree constraints, fixes #3073
Replace dynamically-sized edge list with a dense ntree×ntree adjacency matrix for deduplication and a flat CSR representation.

PiperOrigin-RevId: 868728432
Change-Id: Iebe97a0870740e5465549b967bbde0c81e658269
2026-02-11 10:05:32 -08:00
Google DeepMind cc5d544d15 Update typos in sysid/README.md
PiperOrigin-RevId: 868690171
Change-Id: Iffc71fb7bad73e18be767429600936014095ed9e
2026-02-11 08:25:56 -08:00
Copybara-Service e9de358bfc Merge pull request #3076 from yurekami:fix/plugin-symlink-loading
PiperOrigin-RevId: 868602117
Change-Id: Ice4d7991f46dad45736864baebd7378cc24e9d4f
2026-02-11 04:13:41 -08:00
Copybara-Service 91751a506b Merge pull request #3082 from aftersomemath:sysid-pr2
PiperOrigin-RevId: 868599752
Change-Id: Ifb57f34857d542b542b8ac9f047397c651f8008b
2026-02-11 04:06:44 -08:00
Yuval Tassa 7f74487a26 Fix implicit integrator derivatives for actearly actuators.
The derivative calculation for actuator velocity in implicit integrators now correctly accounts for the `actearly` flag, using the next activation value when `actearly` is true.

PiperOrigin-RevId: 868598722
Change-Id: Ia180afb15b31a718170aeaf9d4ac514bb9e6073b
2026-02-11 04:03:46 -08:00
Levi Burner e89dae359e sysid: named ic construction, bug fixes, docstrings, README, more tests
Co-authored-by: Kevin Zakka <kevinarmandzakka@gmail.com>
2026-02-11 00:22:56 -05:00
Haroon Qureshi 730d494b7f Focus default camera on the model if available.
PiperOrigin-RevId: 868407477
Change-Id: Iac37bcfe8657dededeeecc70db3e4ac18f8ef151
2026-02-10 18:17:33 -08:00
Sam Haves 6715a0ceaa Expose mju resource functions to public header.
Many of these functions are useful when writing a custom decoder.

PiperOrigin-RevId: 868321921
Change-Id: I7e0dd285e0559b6f486acf8cbf4376ff8d91943d
2026-02-10 14:31:41 -08:00
Baruch Tabanpour 210cf86486 Use kernel cache dir per mjx-warp test fixture.
PiperOrigin-RevId: 868259579
Change-Id: I9f1346899591ca603ad2e34949d22b78c464c2ad
2026-02-10 12:10:28 -08:00
Alessio Quaglino 419b96cb91 Reduce simulation steps in MjCollisionTest.PinchingSucceeds.
PiperOrigin-RevId: 868229821
Change-Id: I781955a8f06ca2338baa713ff6a3448b4743b35e
2026-02-10 11:05:10 -08:00
Copybara-Service 3ec09f7296 Merge pull request #3079 from aftersomemath:sysid-pr
PiperOrigin-RevId: 868229512
Change-Id: I790bc08fc8b0745583a2f92d9ee2c5a19ba558ea
2026-02-10 11:04:12 -08:00
Baruch Tabanpour 3c107b3047 Add stage_in and stage_out for MJX-Warp.
PiperOrigin-RevId: 868180029
Change-Id: I0d1b17b6023d32498766b5d1d9e5624bd31cda3d
2026-02-10 09:19:09 -08:00
Copybara-Service 7ef3ae6ad1 Merge pull request #3061 from LouRohanNV:fixUsdMaterialInterfaces
PiperOrigin-RevId: 868177637
Change-Id: I2de8f2af3b5fc126d103256b1ea00c5f8c7a8955
2026-02-10 09:12:10 -08:00
Yuval Tassa 4fa062c7e5 Update unreleased MuJoCo version from 3.4.1 to 3.5.0.
PiperOrigin-RevId: 868169291
Change-Id: I8041842811f5f664c80116993315f50d549b5575
2026-02-10 08:52:04 -08:00
Alessio Quaglino e16ee4fcb4 Fix flex-parent coupling in implicit integrator.
The implicit integrator was not correctly accounting for the off-diagonal coupling terms between flex and non-flex (parent) degrees of freedom in the mass matrix. This change extracts these coupling terms during the factorization step and applies a correction to the flex forces before solving for the flex accelerations, ensuring that the parent accelerations influence the flex dynamics. A new test verifies that the implicit integrator now matches Euler for small timesteps in a model with flex-parent coupling.

PiperOrigin-RevId: 868098126
Change-Id: Ia8cccd7dd428cd0c0898e1663a7e41017a2311b2
2026-02-10 05:35:48 -08:00
Sam Haves e93a69ea01 Add MjcPhysicsEqualityConnectAPI to MjcPhysics for equality/connect parsing.
PiperOrigin-RevId: 867736241
Change-Id: I2d4e9abcb14280dcfbbf63ff5f888fb57350cfb6
2026-02-09 13:02:42 -08:00
Alessio Quaglino 0041fdcbb0 Add implicit stiffness for flex_interp to mj_implicitSkip.
PiperOrigin-RevId: 867706885
Change-Id: Ic94c65b618a415609bffe3d69a86f9034f2d2400
2026-02-09 11:54:27 -08:00
Yuval Tassa c1b3b3063e Fix gravcomp being ignored for movable bodies without joints. Fixes #3066
PiperOrigin-RevId: 867679545
Change-Id: I8c16d3a4c93d121fcc30cab5179ba44fe49aaa19
2026-02-09 10:55:07 -08:00
Google DeepMind b637d7eb76 Call kinematics in case of state mismatch in get_data_into with CPP backend.
PiperOrigin-RevId: 867667583
Change-Id: Ieec5ff86f6768c11459795068abf17f69bd26f3c
2026-02-09 10:29:27 -08:00
Kevin Zakka a1f2b87548 Ignore sysid tests. 2026-02-09 09:58:34 -08:00
Kevin Zakka 146a5c08f7 System identification toolbox for MuJoCo.
This resulted from a lengthy collaboration with @kevinzakka, @jonathanembleyriches, @nimrod-gileadi, @gizemozd, @quagla, and @yuval.
2026-02-09 12:12:24 -05:00
Haroon Qureshi be93e8eeb2 Give Resource Providers a chance to load files.
File resolution only checks local file system. Resource providers may still
be able to load from a path even if it is not resolved.

PiperOrigin-RevId: 867534134
Change-Id: I802566136b965ad839393f56a4d4924dda2e1973
2026-02-09 04:23:44 -08:00
Haroon Qureshi 8557cf201b Allow root models to be in a subfolder.
PiperOrigin-RevId: 867217045
Change-Id: Iae6f7c7f137c2b229b52d93aacea1a4c9e06003e
2026-02-08 08:08:09 -08:00
Yuval Tassa ed15493aef Reorganize changelog
PiperOrigin-RevId: 867201472
Change-Id: I5841bd10656546db7c544ff910ed2983ce88415e
2026-02-08 06:48:14 -08:00
Yuval Tassa d680b3d234 Rename "delay" buffer functions to "history" buffers.
The functions and associated tests related to managing time-stamped data buffers have been renamed from `mju_delay*` to `mju_history*` to better reflect their general purpose beyond just handling delays.

PiperOrigin-RevId: 866978339
Change-Id: I8655e91bce783287ad2adc412d13a1c39aa2c322
2026-02-07 14:10:16 -08:00
yurekami 3497b7658c fix: resolve symlinks when loading plugin libraries
Use stat() instead of d_type to check if a file is a regular file
when scanning for plugin libraries. This allows symlinked plugins
to be loaded, which is common in ROS 2 workspaces built with
colcon build --symlink-install.

The stat() approach also handles filesystems that report DT_UNKNOWN
for d_type (e.g., NFS, XFS), making the code more robust.

Fixes #3072
2026-02-07 02:45:22 -08:00
Alessio Quaglino e6639f1e29 Apply prefix/suffix to flex material names.
PiperOrigin-RevId: 866518766
Change-Id: I5f042f52a27d2a6c66fe9642bccc73328fe14603
2026-02-06 10:32:32 -08:00
Saran Tunyasuvunakool 74d657a777 Add X macros for mjVisual and mjStatistic.
PiperOrigin-RevId: 866502731
Change-Id: I7cfaf3cd96512d93c801b7611eedb71689e21a5b
2026-02-06 09:53:22 -08:00
Yuval Tassa 6419534bad Add actuator and sensor delays. Fixes #1004
PiperOrigin-RevId: 866478839
Change-Id: Id21a6da0f98454c8fa39ea5af8a5e213d6eae497
2026-02-06 08:47:36 -08:00
Yuval Tassa 84fa527723 Add delay buffer utilities to engine_util_misc.
PiperOrigin-RevId: 866450284
Change-Id: I86d6dd6a6f7519640f75ca405fb60a12e8619c86
2026-02-06 07:22:34 -08:00
Haroon Qureshi 60b5b1d59d Fix include path.
PiperOrigin-RevId: 866348008
Change-Id: Ie67fc38ac108810c1ecbefbb8d26c394d988956b
2026-02-06 01:52:03 -08:00
Haroon Qureshi 3e8a81383a Move mjSpec/mjModel/mjData management into a separate class.
PiperOrigin-RevId: 866327584
Change-Id: I72f6ec656e193f67dee22214fe01c517432f87e5
2026-02-06 00:51:15 -08:00
Haroon Qureshi eb7aaa2868 Internal changes.
PiperOrigin-RevId: 866317956
Change-Id: Ic92c0f9b7005198025e388f83dff630253240b3b
2026-02-06 00:22:31 -08:00
Sam Haves c63ba211e5 Refactor MjcPhysics EqualityJointAPI polynomial coefficients.
The single array attribute `mjc:polycoef` has been replaced by five individual double attributes: `mjc:coef0`, `mjc:coef1`, `mjc:coef2`, `mjc:coef3`, and `mjc:coef4`.

PiperOrigin-RevId: 865947359
Change-Id: If9d14a77b0a06e5dc712eeadd6e9402411570706
2026-02-05 07:56:11 -08:00
Sam Haves 7b0b3cf8e3 Set CMAKE_INSTALL_RPATH for USD decoder plugin.
PiperOrigin-RevId: 865918418
Change-Id: If56b83925301b8d02411c35ae5906901a8dd97f8
2026-02-05 06:37:18 -08:00
Alessio Quaglino 6afd742f43 Fix trilinear flexcomp with unused vertices.
Fix a crash and dimension mismatch issue in user_flexcomp when dealing with interpolated="true" meshes that contain unused vertices. Previously, vertbody would correspond only to used vertices while vert included all vertices, leading to assertions or out-of-bounds access. Also enable node pinning for interpolated meshes.

PiperOrigin-RevId: 865881995
Change-Id: Id150f00f22b5f48896ffbffddf03c57b252de8c0
2026-02-05 04:41:02 -08:00
Taylor Howell a52180069c MuJoCo Warp documentation: Options update
PiperOrigin-RevId: 865820928
Change-Id: I36fd4c52ad8bcb9cc8ecae7c93410023a4e56ed0
2026-02-05 01:47:51 -08:00
Sam Haves a6a639003f Fix number of textures in BM_CompileManyTextures to 100.
PiperOrigin-RevId: 865475996
Change-Id: I63fd1e8b9aaff9536a9609d8f8390f8c9473785e
2026-02-04 10:35:20 -08:00
Baruch Tabanpour d07f39b4a0 Add graph mode to MJX, in preparation of supporting staged graph capture.
PiperOrigin-RevId: 865380826
Change-Id: I840b48027e1142f87eb745d0d19b0cd3e87904b2
2026-02-04 06:38:13 -08:00
Haroon Qureshi b37caf6d0c Show save dialog (instead of open dialog) as needed.
PiperOrigin-RevId: 865374467
Change-Id: I599333659b12b05b7c779115fa397302f4978751
2026-02-04 06:20:01 -08:00
Haroon Qureshi 1a0fe29c41 Make missing decoder non-failing.
Otherwise, if you try to open a random file in studio, it will crash.

PiperOrigin-RevId: 865372002
Change-Id: I96d3121b6de792daaff53155ea2436ac3f6668db
2026-02-04 06:12:54 -08:00
Kyle Bayes 1a9ca3239a Replace comma operator with semi-colon.
PiperOrigin-RevId: 865353927
Change-Id: I3498d8dc17f96caf8fa1975613ed6a815d2f20e7
2026-02-04 05:14:17 -08:00
Haroon Qureshi c2ede20d08 Move model_, data_, and spec_ into private accessors.
This is in preparation for an upcoming change.

PiperOrigin-RevId: 865332731
Change-Id: I74041b3caf5de841f583f76682e1ced049557202
2026-02-04 04:02:52 -08:00
Haroon Qureshi 0add985a15 Handle null camera and vis_option.
PiperOrigin-RevId: 865088406
Change-Id: I4a3bf7f6cb696de1461bc53fd5d77b941ea0c0c5
2026-02-03 16:06:06 -08:00
Haroon Qureshi 1bd72428f1 Perform ImGui calls only when a context is available.
PiperOrigin-RevId: 865072901
Change-Id: I4b35d953df2f686d2f02f8e0aede7109729b5e04
2026-02-03 15:29:44 -08:00
Haroon Qureshi 144a8a9e85 Make EGL utils conditional on EGL.h.
PiperOrigin-RevId: 865064686
Change-Id: I3728de6e49e4c36d76b410c2458767f74df069c9
2026-02-03 15:09:51 -08:00
Haroon Qureshi feb3abcccf Fix paths.
PiperOrigin-RevId: 864933655
Change-Id: I44f34b47fe4f6725de59c6565f6b2b557b80eaa6
2026-02-03 10:16:19 -08:00