Commit Graph

2819 Commits

Author SHA1 Message Date
Kyle Bayes 995bbf0f0f Refactor and fold in code into Process in mjCMesh for caching.
PiperOrigin-RevId: 736052216
Change-Id: Ia0e055fd99ce429b9dee97f3f9effbf2fa1aa4f9
2025-03-12 02:12:53 -07:00
Copybara-Service b9a23e8d0c Merge pull request #2475 from lyd405121:main
PiperOrigin-RevId: 735789711
Change-Id: Iad5a52a0ba29baad31ba60f0243e3b88553e6e96
2025-03-11 09:48:23 -07:00
Yuval Tassa c5473d9923 Print compilation time in sample/compile, allow compilation with no output.
PiperOrigin-RevId: 735692355
Change-Id: I4371f800ec150f8d665cf164b50a0e5a0b5ac082
2025-03-11 03:25:51 -07:00
Yuval Tassa de48f4178f Add missing term in mj_jacDot
PiperOrigin-RevId: 735686836
Change-Id: I813ca46f71e368ddc97a6d2e540102137b31dbcf
2025-03-11 03:01:29 -07:00
Yuval Tassa 3b27f30827 Added comment regarding numpy slices.
PiperOrigin-RevId: 735681812
Change-Id: I832219bb63c83ecd5115ac1d5755cd35b4362478
2025-03-11 02:36:51 -07:00
Yuval Tassa bd9d30adc7 Improve documentation of mj_saveLastXML fixes #2075
PiperOrigin-RevId: 735672207
Change-Id: I951b8be9cf12a2a4965a40bb8db4de4ddda18570
2025-03-11 01:57:46 -07:00
Alessio Quaglino 019e0a806c Throw an error if a child attached by reference to a parent is compiled.
Fixes #2482.

PiperOrigin-RevId: 735665098
Change-Id: Ia3436fdd2ff572f8f0c1ded434742a4a9186f2f7
2025-03-11 01:24:17 -07:00
Alessio Quaglino 14dc6fd33b Do not use inertia during mesh compilation.
Fixes #2479.

PiperOrigin-RevId: 735387473
Change-Id: Ib241f2a0efc100bbe2cec24e0399bfcc87268094
2025-03-10 08:35:33 -07:00
Tom Power e7a715497e Write mesh inertia to defaults when exporting to xml. Fixes #2478
PiperOrigin-RevId: 735338748
Change-Id: Id0b71d06c77baef417f7968ae8a14154243a1f83
2025-03-10 05:31:55 -07:00
Alessio Quaglino adc3cc06fa Change private->public spec for error checking in mjCSkin recompilation.
Fixes #2485.

PiperOrigin-RevId: 735323174
Change-Id: Ifcc2055f6a74afaa18ad5228633f36f760adcffd
2025-03-10 04:19:40 -07:00
Kyle Bayes 4d024f9421 Convert internal representation of vertices to double. Also replace remove duplicate vertices with fast hash implementation.
PiperOrigin-RevId: 734516595
Change-Id: Ic78556688d5f2b75d69cd286b8d060e2cdeb7c48
2025-03-07 05:17:49 -08:00
Yuval Tassa e4ee00e695 Link to Onshape to robot converter in top level README.
PiperOrigin-RevId: 734426561
Change-Id: I1e5005c97d111204b2277c4b4d1fca9b162d0628
2025-03-06 23:16:22 -08:00
Yuval Tassa a816ca6dd5 Use qLDiagInv instead of qLD in engine_vis_interact.c
PiperOrigin-RevId: 734399015
Change-Id: I97c80a8b25dbd40e86560c328cc786a0bed6a2d1
2025-03-06 21:15:36 -08:00
Yuval Tassa 109a223cf6 Narrow some includes in src/user/
PiperOrigin-RevId: 734389490
Change-Id: I2834aadbbb38b396536e467c0dfea11dcc21972f
2025-03-06 20:45:18 -08:00
Alessio Quaglino e04e0e5c3d Rename "facetexcoord" to "elemtexcoord" in mjsFlex element for consistency.
PiperOrigin-RevId: 734153759
Change-Id: Ic17d7c8a6e53fba04da511d405c815a723c5e55b
2025-03-06 08:28:36 -08:00
Kyle Bayes 37d6d7792a Fix bug with handling of invalid maxhullvert values (smaller than 4).
PiperOrigin-RevId: 734136442
Change-Id: I531e5a5b9244e026a9368e0d6a83d2b559c1b58d
2025-03-06 07:33:41 -08:00
Jake Harmon a0fc6b18b5 Update references to JAX's GitHub repo
JAX has moved from https://github.com/google/jax to https://github.com/jax-ml/jax

PiperOrigin-RevId: 733951719
Change-Id: Iee4a7bf4bcc9fc3108ca9d30b6b98f5df20c79c7
2025-03-05 19:25:00 -08:00
Yuval Tassa 0f563ecf31 Switch mjData.{qH,qLD} from reduced ("C") to full ("M") inertia matrix structure. No performance impact of extra zeros because of existing "simple dof" skipping mechanism.
PiperOrigin-RevId: 733523931
Change-Id: Ic8d8a152dda5532331c239cb6b4ce7d8d09b7fff
2025-03-04 17:34:35 -08:00
Alessio Quaglino 51f6aa8b43 Store assets by address instead of value in MjSpec.
PiperOrigin-RevId: 733343350
Change-Id: I42ee2a184ebff37a080dace0422bb61e1ba53527
2025-03-04 08:43:27 -08:00
Yuval Tassa 7d9df8c9a9 Fill-in qM CSR matrix structure on mjData (currently unused).
PiperOrigin-RevId: 733258529
Change-Id: I903548ae60139e4858550194e1aedf0efa2f3033
2025-03-04 03:20:11 -08:00
Yuval Tassa c72c83aa3b Allocate qM CSR matrix structure on mjData (currently empty).
PiperOrigin-RevId: 733247419
Change-Id: I814e574e3161875e89433a6e03f2c9e200d8b1d6
2025-03-04 02:37:47 -08:00
Yuval Tassa 8f37ae1bf2 Add missing fields in mj_printData, don't print integration-related fields if identically zero.
PiperOrigin-RevId: 732917127
Change-Id: Ia5fe8e4b6c2485fcf4336847535c1cc72b9d6d62
2025-03-03 07:34:14 -08:00
蕉太狼 56dda2b4de [Add Model] Make a flex with textured bunny
- Make a flex with textured bunny from disscution(https://github.com/google-deepmind/mujoco/discussions/2442)
2025-03-03 16:45:43 +08:00
蕉太狼 e16354a527 [New Model] Add a bunny with uv coordinate
- Using [UVAtlas](https://github.com/Microsoft/UVAtlas) to unwrap and generate from the [origin bunny](https://github.com/google-deepmind/mujoco/blob/main/model/flex/asset/bunny.obj)
2025-03-03 16:44:03 +08:00
Yuval Tassa 010f9bacbb Fix typo in Python API docs.
PiperOrigin-RevId: 732600862
Change-Id: Ie9a8db9555ac3e233d29a10d289b71745d644cb2
2025-03-02 01:20:25 -08:00
Yuval Tassa 6c8cf82f27 Docs: fix mixed-up forward dynamics stages.
PiperOrigin-RevId: 732465925
Change-Id: I8d350e398d749076cc5f24cd33fa1ee87876e426
2025-03-01 09:34:23 -08:00
Alessio Quaglino 7651cb1b33 Copy texture coordinates from OBJ into flex. Fixes #2464.
PiperOrigin-RevId: 732109960
Change-Id: I506b3540ab5d489ce8f10d0c473919611ccb654a
2025-02-28 06:04:19 -08:00
Kevin Sayed 06e217df7e [MJ3.3.1] Bumping internal version number.
PiperOrigin-RevId: 731876412
Change-Id: I1c0f4a18bbc2e0bf80e01512ea196841848220af
2025-02-27 14:53:28 -08:00
Copybara-Service 8de9b4e4e3 Merge pull request #2462 from jjyyxx:main
PiperOrigin-RevId: 731710330
Change-Id: If87dd2c06123bd9ddfc62b63370c8fedf320e721
2025-02-27 06:58:24 -08:00
Alessio Quaglino 2abb2e2d5d Add further MJX bind tests to clarify dimensions.
Fixes #2463.

PiperOrigin-RevId: 731674489
Change-Id: I9e21a2dd0b0636c94b2b917615889b9d721d542d
2025-02-27 04:34:08 -08:00
Yuval Tassa 9c31494fa1 Add MjSpec example for procedural meshes.
PiperOrigin-RevId: 731635686
Change-Id: I310b802966755f627c4ec2cbdcd2ce7b14921c57
2025-02-27 01:57:56 -08:00
Yuval Tassa 7fdee13874 Fix typo.
PiperOrigin-RevId: 731484375
Change-Id: I63859249dc60ca065a94996b52530b57fd975d0b
2025-02-26 15:50:47 -08:00
Yuval Tassa 929e94cf59 Fix bullet indentation in changelog.
PiperOrigin-RevId: 731477093
Change-Id: Idece8a4f8db05546b878006fc22290896dc01182
2025-02-26 15:27:17 -08:00
Kevin Sayed e1f18a747e Update dependencies and the changelog ahead of the 3.3.0 release.
PiperOrigin-RevId: 731406295
Change-Id: I05027722a9681f71549b7e022dfe13fc381b8564
2025-02-26 12:07:55 -08:00
Kevin Sayed 9996500de9 update the version number to 3.3.0 instead of 3.2.8
PiperOrigin-RevId: 731397143
Change-Id: I54089f1678097acf7e4998958effb396da1e47be
2025-02-26 11:42:55 -08:00
Alessio Quaglino 1c240d8bad Raise error if trying to bind with a spec with an empty name.
PiperOrigin-RevId: 731360983
Change-Id: I00365d158c1cae1cd912962ef453f43e93701080
2025-02-26 10:07:46 -08:00
Kyle Bayes ed16f2daf2 Set nativeccd as default.
PiperOrigin-RevId: 731343200
Change-Id: I315779017b676f3d118e0d38ee53a515272f50b8
2025-02-26 09:15:15 -08:00
Kyle Bayes 4f691eeae4 Fix minor issues in EPA in nativeccd.
PiperOrigin-RevId: 731327356
Change-Id: Iba8215b7991ef74bf890c8da7e9332474e19e9c3
2025-02-26 08:28:35 -08:00
Yuxuan Jiang 2039629457 Expose MjSpec raw pointer via _address 2025-02-26 10:25:55 +08:00
Alessio Quaglino d1d61925da Do not delete the world child when doing spec.attach.
PiperOrigin-RevId: 730976077
Change-Id: I9aa8133241b45883e605ec80d64ae28af2962680
2025-02-25 12:02:13 -08:00
Kyle Bayes bd66fbd046 Fix return value in mesh edge contact in nativeccd.
PiperOrigin-RevId: 730924994
Change-Id: Iab4f26da126713bae6629eef502bb2aad690c595
2025-02-25 09:54:05 -08:00
Alessio Quaglino 441b5c6082 Change MjSpec.default from method to attribute.
PiperOrigin-RevId: 730912407
Change-Id: I0147acbd257ecc8b72752a2992a7d4ea6e1b4c07
2025-02-25 09:17:45 -08:00
Alessio Quaglino ed7adf3d17 Do not namespace the body that contains the frame during mjs_attachFrame.
PiperOrigin-RevId: 730912252
Change-Id: I026993af648766c09d569709d268430207d83169
2025-02-25 09:16:44 -08:00
Kyle Bayes fbe0990b17 Fix bugs in nativeccd with collisions with margin.
PiperOrigin-RevId: 730903745
Change-Id: I45ddb674f32cb1f28ff37c587ea953ec595241b3
2025-02-25 08:51:21 -08:00
Yuval Tassa dc98ae978d Publicize the rollout notebook, small improvements to plotting.
PiperOrigin-RevId: 730841667
Change-Id: Id365f21cee078f28cb3fa797701c3c5a409607cd
2025-02-25 05:20:41 -08:00
Alessio Quaglino ce82b63155 Add mjs_attachFrameToSite.
This is required in preparation of changing the spec.attach behavior in the Python bindings.

PiperOrigin-RevId: 730810198
Change-Id: I095808f0afe62b5bbd27201ed5c75804e0e9c4bf
2025-02-25 03:21:05 -08:00
Copybara-Service 6b11f2b88e Merge pull request #2456 from aftersomemath:rollout-notebook-fixups
PiperOrigin-RevId: 730789232
Change-Id: Id3001497bae70d4a41640992e115fa6483d42720
2025-02-25 02:02:02 -08:00
Levi Burner cfc59164eb rollout notebook: fixups to benchmarks, plots, text
1. MJX benchmarks use jax.lax.scan and block_until_ready
2. Benchmark parameters updated to match RL use case
3. humanoid benchmarks are warmstarted by 2 seconds, humanoid100 by 4 seconds
4. benchmarks use skip_checks and preallocated threadpools
5. Improved advanced usage plots
6. Benchmark no longer includes model initialization in timed section
7. Update notebook text as needed
2025-02-25 03:25:51 -05:00
Alessio Quaglino 14c8dc62f0 Add termination character to flattened plugin attributes if empty.
Fixes #2450.

PiperOrigin-RevId: 730521722
Change-Id: Iec3fa377c65693d782eeb766a144a1c89096d1f3
2025-02-24 11:07:18 -08:00
Kyle Bayes 024616345d Support edge contacts with multiccd in nativeccd.
PiperOrigin-RevId: 730489114
Change-Id: I02847d84bbc15a1526391d5e1b7109ab83ea4a59
2025-02-24 09:48:43 -08:00