Commit Graph

2536 Commits

Author SHA1 Message Date
Taylor Howell cd8ff4401d Add eq_objtype to mjx.Model and support for connect constraint using sites in MJX.
PiperOrigin-RevId: 671225109
Change-Id: I8e2e6eb4c539d318658d3d7dfe0a7f03b411aabc
2024-09-04 22:00:36 -07:00
Abhishek Joshi fe1d6dad02 Using temp directory for usd exporter test 2024-09-04 18:18:37 -04:00
Kyle Bayes 81618f95f9 Update doc for mj_addFileVFS and mj_addBufferVFS as VFS is no longer memory limited.
PiperOrigin-RevId: 671087960
Change-Id: I0b022554f4f47fe2e64c8201cd855b63d514c344
2024-09-04 13:51:43 -07:00
Yuval Tassa 621ea29382 Improve error message for keyframe size mismatch. Fixes #2041
PiperOrigin-RevId: 671069582
Change-Id: Ie63d3bf2b543f7bb5e3c123093095e76a95b7b48
2024-09-04 12:58:31 -07:00
Yuval Tassa 4a4db13eba Update documentation to reflect that multi-threading is now used when loading meshes.
PiperOrigin-RevId: 671063740
Change-Id: I77f2e028c3e9e9801c03e8e107eb6d8830becf22
2024-09-04 12:38:29 -07:00
Kyle Bayes b9822e4347 Check hexahedron in polytope3 to make sure it contains the origin. Otherwise, EPA can return invalid results.
PiperOrigin-RevId: 671057312
Change-Id: Ieb21a77ea679ee5c18972d3a0375578d9a98405e
2024-09-04 12:17:54 -07:00
Yuval Tassa b502ceef00 Add note that XML saving requires that the spec first be compiled. Fixes #1832
PiperOrigin-RevId: 671046666
Change-Id: If5885545d5316537147d293fbe854caa568558b2
2024-09-04 11:47:34 -07:00
Kyle Bayes 79a5bd0915 Add better boundary tests in polytope3 for EPA.
PiperOrigin-RevId: 671038835
Change-Id: I259260a7b40e825678b52187bee4791266ae10c4
2024-09-04 11:25:44 -07:00
Yuval Tassa 8954a088ce Add automatic free-joint alignment.
PiperOrigin-RevId: 671010083
Change-Id: Ib7d60f75c7f545b1886703715663db8de77feeef
2024-09-04 10:07:33 -07:00
Alessio Quaglino ae4987026c Add tree element support to mjs_firstElement() and mjs_nextElement().
PiperOrigin-RevId: 671003046
Change-Id: I9e07d7c85c7218e9bded0f50af9db62d0f1e21e1
2024-09-04 09:46:24 -07:00
Alessio Quaglino d3dfa6f970 Add mjs_findElement() to find any element in a spec by name.
Also, remove mjs_findMesh() and mjs_findKeyframe().

PiperOrigin-RevId: 670978980
Change-Id: Id88b800eb8a4c5efc40866f72a4442bf1d1437d0
2024-09-04 08:24:22 -07:00
Alessio Quaglino 0e8c0b80eb add content_type to model in the XML schema.
PiperOrigin-RevId: 670961443
Change-Id: I98cd6bb61b50029cdd4f5b31e23d268989d136da
2024-09-04 07:25:55 -07:00
Nimrod Gileadi 9a27fc14c2 Raise appropriate errors for mj_addBufferVFS in Python bindings.
When loading models in the XML bindings, different issues with the asset dictionary were all reported as "assets dict is too big".

PiperOrigin-RevId: 670960339
Change-Id: I2e47d91a6b433fd90ebdf9960a9b5b47413af410
2024-09-04 07:20:25 -07:00
Kyle Bayes e9a85764ea Native CCD: Replace mju_malloc with C standard malloc, fix bug in computing v5 in polytope3, and add another warning in EPA.
PiperOrigin-RevId: 670939250
Change-Id: Ia0d8b7c78ed2ef7019f2a691c066b20e98dc1889
2024-09-04 05:53:31 -07:00
Yuval Tassa 3437361bfb Add reduced sparse dof-dof matrix structures to mjData.
PiperOrigin-RevId: 670919263
Change-Id: I3592de802ae84648d97230115c2e9c3437424968
2024-09-04 04:24:02 -07:00
Yuval Tassa 42eb669e4e Precompute mappings between M <-> D sparse representations.
PiperOrigin-RevId: 670898353
Change-Id: I4b15477b1b6eb4a64cf7d4a0bb5af8fcb95d4e45
2024-09-04 02:57:13 -07:00
Baruch Tabanpour 303e5e7718 Fix test threshold for external tests.
PiperOrigin-RevId: 670720396
Change-Id: I28bff46535ffdd99724c75f8137834d84c3ec534
2024-09-03 15:06:42 -07:00
Baruch Tabanpour 49711fa14f Add support for joint and tendon frictionloss to MJX.
PiperOrigin-RevId: 670679777
Change-Id: I2eb56d013c11d4e1851f1c2edd6d98faaf854db9
2024-09-03 13:17:41 -07:00
Yuval Tassa 2d3d5415b7 Add mj_jacDot: Time derivative of kinematic Jacobian.
PiperOrigin-RevId: 670505417
Change-Id: Icf30cff5dc955e002bd2f5d5fb3a04f8388d0780
2024-09-03 04:49:47 -07:00
Nimrod Gileadi fb38727303 Update zipp to 3.19.1 in make_sdist_requirements.txt
PiperOrigin-RevId: 670486730
Change-Id: I1dfabb8d5206024595a49d2421f148a284a4eac7
2024-09-03 03:37:49 -07:00
Copybara-Service a02934a408 Merge pull request #2036 from kevinzakka:doc-fix
PiperOrigin-RevId: 670207735
Change-Id: I810720a41e6b770f8d7d3bacea9f5dc1433827b7
2024-09-02 07:08:56 -07:00
Kevin Zakka f60ab4492d Remove vestigial mentions of mjOption.collision in the docs. 2024-08-31 16:49:25 -07:00
Yuval Tassa 7abd5d427a Restore mistakenly deleted/modified changelog items.
PiperOrigin-RevId: 669732777
Change-Id: I473480acb06f881049c1f338e1e87ff86c30f330
2024-08-31 15:04:08 -07:00
Taylor Howell 9805df616b Add framelinvel and frameangvel sensors to MJX.
PiperOrigin-RevId: 669647542
Change-Id: I612230e81b456c26f29173d1cb5a60975791875a
2024-08-31 06:12:37 -07:00
Abhishek Joshi c0dc787cee Removing mujoco renderer dependency 2024-08-30 18:23:13 -04:00
Yuval Tassa 651868ab05 Add GitHub Issue and Discussion templates.
PiperOrigin-RevId: 669365189
Change-Id: I6e14bdf68de0ddc0029937291d7258d26eb65b75
2024-08-30 10:13:38 -07:00
Taylor Howell 5391e6011a Add sensor cutoff to MJX.
PiperOrigin-RevId: 669363779
Change-Id: Ia5c3f913c1b84e1893aa6072268a334123f00aeb
2024-08-30 10:09:17 -07:00
Abhishek Joshi 5dc9c07fa6 Removing scipy dependency 2024-08-30 12:56:25 -04:00
Abhishek Joshi 1d2ee40c9b Updating pillow hashes 2024-08-30 12:32:45 -04:00
Abhishek Joshi f54380206c Adding pillow dependency 2024-08-30 12:30:15 -04:00
Abhishek Joshi 4a8b54c7ec Adding backslash char 2024-08-30 12:16:16 -04:00
Abhishek Joshi 83c8814149 Adding new usd-core hashes 2024-08-30 12:14:26 -04:00
Taylor Howell cf02171bf8 Add velocimeter and gyro sensors to MJX.
PiperOrigin-RevId: 669337697
Change-Id: I5e7f245b96eb334ffddd01757a9f631d9ad862cd
2024-08-30 08:39:40 -07:00
Taylor Howell a94694f608 Fix formatting in mjx.rst
PiperOrigin-RevId: 669262462
Change-Id: I6354b152eff36923b85918e10fedf89a44c851f6
2024-08-30 03:16:46 -07:00
Taylor Howell 8272211dd5 Update MJX documentation for ellipsoid and cylinder collision support.
fixes #1908

PiperOrigin-RevId: 669244021
Change-Id: I5f757562be333b5b9923655d155d51ed3dbd09c4
2024-08-30 01:59:27 -07:00
Erik Frey 494e166f28 Fix a bug where mjx.make_data qLDiagInv has wrong size for sparse mass matrices.
PiperOrigin-RevId: 669087189
Change-Id: I39e97264a192a621e67ae5e079334fc8be38a25d
2024-08-29 15:40:08 -07:00
Taylor Howell 9cab5a42a4 Remove unnecessary normal vector computation from mju_wrap cylinder case.
PiperOrigin-RevId: 669010760
Change-Id: Ie3869a9f112ca88b2a7ec4990c402ef3e92d36a8
2024-08-29 11:46:38 -07:00
Yuval Tassa a1036b86d3 Allow connect constraints to be specified using sites.
PiperOrigin-RevId: 668925419
Change-Id: I10cb71e6706e617c830cd90d6d0836b94a5a8cfa
2024-08-29 07:10:51 -07:00
Goncalo Gordo 5faff169b7 Update simulation params in MJX's tutorial 2024-08-29 14:39:08 +01:00
Goncalo Gordo ee731506d7 Update params in humanoid's training 2024-08-29 14:37:38 +01:00
Taylor Howell 646455406c Fix changelog by moving bug fix to proper section.
PiperOrigin-RevId: 668435872
Change-Id: I9042eb3f119cc778675944e7cfb8f6be0e9379b2
2024-08-28 07:07:11 -07:00
Yuval Tassa f3cfe7a84a Minor clean up in mj_jac.
PiperOrigin-RevId: 668395751
Change-Id: I5c3104ad59a5a709cf1639df663c864fa9d02399
2024-08-28 04:45:40 -07:00
Taylor Howell 3e701b2125 Fix tendon sphere wrapping when using external sidesite.
PiperOrigin-RevId: 668391942
Change-Id: I78b44e1f90bb26fa6f5544eeb884c8ea22e41d33
2024-08-28 04:30:07 -07:00
Yuval Tassa 72a0ab145d Refactor frustum drawing to use a local makeTriangle function.
PiperOrigin-RevId: 668168658
Change-Id: I0ee9038c36eb28e2c4a0a8c94bea7430f68c6b77
2024-08-27 15:42:31 -07:00
Kyle Bayes ddb29e9293 Fix bug in computing pos in EPA by replacing S2D with computing affine coordinates directly to recover the witness points.
PiperOrigin-RevId: 668006152
Change-Id: I1de33c5bb94de1a14523a88a5dff7d6ec984628e
2024-08-27 08:55:40 -07:00
Abhishek Joshi e03f8f5f65 Merge branch 'main' into usd-fixes 2024-08-25 19:15:17 -04:00
Kyle Bayes cad8ca6ffd Do pre-checking when creating initial polytope for EPA.
PiperOrigin-RevId: 666807572
Change-Id: I64c3715dc72c24f9b6b2206b3568951bd8c2384a
2024-08-23 08:37:34 -07:00
Yuval Tassa 9d4f8edad9 Avoid pointer access in loop conditionals in engine_core_smooth.c
PiperOrigin-RevId: 666800203
Change-Id: Iec6ce752d0cac1a98809ab085ed8f94416f79e95
2024-08-23 08:13:52 -07:00
Kyle Bayes d360ea1ce6 Minor GJK + EPA improvements:
1. Correct stopping criteria for GJK.
2. Store witness points from EPA in mjCCDObj,
3. Get dir directly from EPA instead of computing dir from witness points.

PiperOrigin-RevId: 666791852
Change-Id: I6a168f635b57c17692d31da6f6076b48c32ff2e3
2024-08-23 07:44:30 -07:00
Alessio Quaglino 505d01a1c1 Add error handling to mj_recompile.
This CL adds error handling to the mj_recompile function. If the recompile fails, the function will return -1 and set the error message in the spec. The Python wrapper for mj_recompile will catch the error and raise a ValueError exception.

PiperOrigin-RevId: 666784579
Change-Id: I225eca1769ea839c782be3c03fc4ff1ea5885a48
2024-08-23 07:18:28 -07:00