Commit Graph

933 Commits

Author SHA1 Message Date
Copybara-Service 15cb1fdfb4 Merge pull request #2271 from xela-95:patch-1
PiperOrigin-RevId: 703493322
Change-Id: I5034ecdbc2e129986bb1e61930637fd2c24b96a6
2024-12-06 07:26:47 -08:00
Yuval Tassa f547d58351 Fix typo in docs
PiperOrigin-RevId: 703449955
Change-Id: I3a5764278406dea4ff013ff82872cc27f5440f5e
2024-12-06 04:16:16 -08:00
Alessandro Croci 342a72839a Fix typo in mjx.rst 2024-12-06 09:16:37 +01:00
Jake Harmon fb8e40208c 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: 703126479
Change-Id: Ie50003b4620db767663f2f95be40557cfe0b8dd3
2024-12-05 08:37:01 -08:00
Yuval Tassa 0e7d2ef6df Fix bug in box-sphere collider. Fixes #2206
PiperOrigin-RevId: 702627603
Change-Id: Ie6015b7fa6f8507459325d692581b0f5f83aa159
2024-12-04 01:19:27 -08:00
Yuval Tassa ec9986dcb7 Clean up changelog.
PiperOrigin-RevId: 702369712
Change-Id: I44293f18de54ddc65af31f64c40dfbe608278b6d
2024-12-03 09:39:14 -08:00
Taylor Howell a793a3417a Raise error in mjx.rne_postconstraint for currently unsupported connect and weld constraints and raise error in mjx.put_model for unsupported sensor and equality constraint combinations.
PiperOrigin-RevId: 702119449
Change-Id: I034363db41629f19ef98bea79ec89140052a7a3c
2024-12-02 16:28:23 -08:00
Gabe Oppenheimer c90a63a926 Update the version number to 3.2.7 following the 3.2.6 release.
PiperOrigin-RevId: 702103729
Change-Id: Id5581cc823a17360e7bb98ac0aa4342020c1aefa
2024-12-02 15:30:52 -08:00
Gabe Oppenheimer bbedc7f339 Update the chancelog for the v3.2.6 release
PiperOrigin-RevId: 702021093
Change-Id: I1c748581ad63ae934b043f56b929d7a5a362bb23
2024-12-02 10:56:29 -08:00
Alessio Quaglino 300450f8b8 Add circle to flexcomp and remove rope and loop from composite.
Add pulley example to show a circle use case.

Switch on flex edge rendering by default (no effect when flex skin is rendered).

PiperOrigin-RevId: 700738379
Change-Id: I8469bbf194de01c8dab66c9a51c49879013df141
2024-11-27 10:14:25 -08:00
Copybara-Service 85c6fc1bdb Merge pull request #2250 from aftersomemath:rollout-list
PiperOrigin-RevId: 700715697
Change-Id: Ia3af7c6af8a9fe1eb8b020efedd1755ae606f77b
2024-11-27 08:52:17 -08:00
Levi Burner e6eab04dd0 rollout fixups and correctly initialize unspecified controls 2024-11-27 07:04:23 -05:00
Levi Burner bd361447bb merge items in changelog 2024-11-26 08:22:28 -05:00
Alessio Quaglino e310c23267 Fix return value of mj_saveXML and mj_saveXMLString, fixes #2247
PiperOrigin-RevId: 700269761
Change-Id: Ifb7e9c66c70eac7d681cfcf106712d47291cf9e2
2024-11-26 02:32:50 -08:00
Levi Burner 943eb6bc7e rollout accepts a list of models of length nroll 2024-11-25 21:29:14 -05:00
Levi Burner 96a8f002bc Remove nroll argument from rollout
nroll can always be implied from the other arguments of rollout.

Add tests for nroll inference.
2024-11-25 14:10:42 -05:00
Alessio Quaglino 7e46e21ef3 Add mju_mat2Rot.
This function extracts the 3D rotation from an arbitrary 3x3 matrix by refining the input quaternion. It is based on the paper "A robust method to extract the rotational part of deformations" by Müller, Matthias, Jan Bender, Nuttapong Chentanez, and Miles Macklin.

PiperOrigin-RevId: 700006006
Change-Id: I77550993233dea9cdf68601762a3ae7ded749bdf
2024-11-25 09:19:10 -08:00
Alessio Quaglino c6ba8f27fd Add bind() method to MjModel and MjData.
This method allows users to bind a spec to a model or data object, making it less verbose to access its arrays.

PiperOrigin-RevId: 699952211
Change-Id: I6b71a88d5a6968bc0f902bd49db7c568b46a4dfb
2024-11-25 05:53:58 -08:00
Alessio Quaglino f909d63cdf Enable to attach a spec to a frame.
PiperOrigin-RevId: 699703988
Change-Id: Idbddcbce1e68286248458eb0bd24d5080451a58a
2024-11-24 07:35:14 -08:00
Alessio Quaglino 3a12db9ad2 Remove id attribute from mjSpec objects in Python bindings.
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.

PiperOrigin-RevId: 699227286
Change-Id: Ifd83e6d85d36ff72ea43caf8b82eab9e4d552440
2024-11-22 11:05:14 -08:00
Yuval Tassa 1d64362adc Add mjv_copyModel to copy mjModel, skipping large arrays not required for abstract visualization.
This functionality is meant for fast copying of `mjModel` when synchronizing the visualization state, as in the Python passive viewer.

PiperOrigin-RevId: 699199743
Change-Id: I13a5160063eb09139ec1aee9c4969bc1c6f547f1
2024-11-22 09:38:08 -08:00
Yuval Tassa 74dcd51d83 Update changelog with Python 3.13 support (upcoming release)
PiperOrigin-RevId: 699127095
Change-Id: I098d1e91e59642f27a764d055c6ae9b77a8b1000
2024-11-22 04:34:33 -08:00
Alessio Quaglino 38ee55a957 Remove unused userfacenormal field from mjSpec.
PiperOrigin-RevId: 698739284
Change-Id: I6407356ac12ad49454d15ecf9056f2c0bef713d5
2024-11-21 05:08:39 -08:00
Taylor Howell aae5fd6906 Add nJmom, the number of non-zeros in sparse actuator_moment matrix, to mjModel.
PiperOrigin-RevId: 698343986
Change-Id: I3d4a4dea1ec095d4e7b231c2fffc0e6241cee39f
2024-11-20 04:30:47 -08:00
Yuval Tassa 5c23ae11ef Fix bug in material texrepeat attribute, fixes #2223.
Was mistakenly cast from float to int, bug introduced in 3.2.0

PiperOrigin-RevId: 697993181
Change-Id: I643a07e2b0866a4af56d7cbd3344e764a7caf56f
2024-11-19 06:30:55 -08:00
Yuval Tassa 9f51ba50db Fix field ordering in mjModel.
`nnames_map` is not required for `mjModel` construction, it is set during construction.

PiperOrigin-RevId: 696462793
Change-Id: Ie722e2a04d7fd7ed96634d3304cc94e895ed713b
2024-11-14 03:45:34 -08:00
Taylor Howell 0f381a9ebd Add muscle actuators to MJX.
PiperOrigin-RevId: 695334356
Change-Id: I6590ed6bdd4a8adc53d5c4e2641f472f7439cedc
2024-11-11 07:46:20 -08:00
Yuval Tassa d6d3d6bb25 Fix typo in changelog.
PiperOrigin-RevId: 694009875
Change-Id: I0ecafe467347a54b54c29c486b98516d1a53e5ea
2024-11-07 00:19:42 -08:00
Kevin Sayed 276f5b04cd Bump MuJoCo version to 3.2.6.
PiperOrigin-RevId: 693472991
Change-Id: Ic202f52dd42c55c43ba05ca21b5cc6a4024b0c72
2024-11-05 14:13:08 -08:00
Baruch Tabanpour f9569cdab0 Fix #2212.
PiperOrigin-RevId: 693294401
Change-Id: Ifef2b268f61b90f557580f61316786c50dc9698d
2024-11-05 04:17:48 -08:00
Google DeepMind b7bbb2b25c Update the MuJoCo changelog for the 3.2.5 release
PiperOrigin-RevId: 693032354
Change-Id: I675424a3feeda8037a9559753dc93c05b812257c
2024-11-04 11:19:46 -08:00
Yuval Tassa 298ce31e39 Update docs to highlight nativeccd
PiperOrigin-RevId: 692918061
Change-Id: I9e44bc3123fe6b8a41b769c7de01b20e3c56d758
2024-11-04 04:34:53 -08:00
Kyle Bayes c168ac3397 Add source code links in docs for remaining API functions.
PiperOrigin-RevId: 692728907
Change-Id: I145eb47453e6aa017505d53d3e17215959252e3d
2024-11-03 11:09:56 -08:00
Yuval Tassa efa5709c94 Fix broken link in XMLreference.
PiperOrigin-RevId: 692669798
Change-Id: I8f61d1032d11c63945264a1b9dc1c034b7401d98
2024-11-03 04:18:43 -08:00
Alessio Quaglino 831d9881d3 Remove box, cylinder and ellipsoid composite types.
Also, fix a bug with Flex textures that was causing an incorrect allocation of the textures in mjModel. Fixes #2013.

PiperOrigin-RevId: 692510858
Change-Id: If781716216974e085244da27bc3aa57d91c3458c
2024-11-02 11:14:13 -07:00
Alessio Quaglino ebe60b9ad5 Add const to mjsDefault when used as function argument.
Fixes #2197.

PiperOrigin-RevId: 692346264
Change-Id: Iddb9be1377a7d59c86911802d8c5563f6bf6b043
2024-11-01 18:18:42 -07:00
Yuval Tassa b6037d1759 Improve mjSpec documentation. Fixes #2074.
PiperOrigin-RevId: 692251710
Change-Id: Ia46bbbe5b7eaa890433b38fed66824f716cc9ea0
2024-11-01 12:06:14 -07:00
Kyle Bayes 1d58576d28 Fetch source code line links for API functions on docs client side.
PiperOrigin-RevId: 692115441
Change-Id: Ifbedf6a4998000f99e2275cb43293b3050daf0ee
2024-11-01 03:28:53 -07:00
Yuval Tassa c9f78ad8a8 Rename nnzJ to nJ in mjData.
This naming is more consistent.

PiperOrigin-RevId: 691858223
Change-Id: Ife3db822afa0b51b30d0792548b35b3742da388a
2024-10-31 10:43:10 -07:00
Alessio Quaglino 94bbf297fc Replace flex_xvert0 with flex_vert0
`flex_xvert0` stored the Cartesian position of the vertices in `qpos0`. This array was unused, so it is now replaced with `flex_vert0`, which still contains the positions of the vertices, but normalized on the bounding box of the flex so that the coordinates are in `[0,1]^m->flex_dim`. This will be useful in the future for using different interpolation methods for computing flex deformations.

PiperOrigin-RevId: 691779361
Change-Id: I5c4223103cd4558f4e268fe3e8d8177541e4754f
2024-10-31 06:30:36 -07:00
Kevin Zakka a9737c60e8 Copybara import of the project:
--
5b525ccaef3d7184d3167815be63ed630781a064 by Kevin Zakka <kevinarmandzakka@gmail.com>:

Add command line scripts to MJX docs.

COPYBARA_INTEGRATE_REVIEW=https://github.com/google-deepmind/mujoco/pull/2196 from kevinzakka:typo-fixes 5b525ccaef3d7184d3167815be63ed630781a064
PiperOrigin-RevId: 691497203
Change-Id: I7c5d6a8fcbd2a42939673cee5eadb30bebdad833
2024-10-30 11:41:11 -07:00
Yuval Tassa 32df8a515a Fix typos. fixes #2139
PiperOrigin-RevId: 691429879
Change-Id: I929b7a387ec41f68b8d85fe20de83083216da36a
2024-10-30 08:34:39 -07:00
Taylor Howell f47840e57c Add mju_dense2sparse to public API.
PiperOrigin-RevId: 691125900
Change-Id: Id9b7c739ee14bff2317168da258b1a3acbdafdbe
2024-10-29 12:47:48 -07:00
Yuval Tassa 6703a40fcf Improve plugin documentation.
PiperOrigin-RevId: 690974299
Change-Id: Iadaabafb7434ada9579d6e2f64aae435cdfedbd8
2024-10-29 05:07:31 -07:00
Yuval Tassa 864b805a6e Fix multiple bugs related to connect and weld constraints with site semantics. Fixes #2179
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`. 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.

PiperOrigin-RevId: 690670420
Change-Id: I55ee8a013cbee8457f8d6c7f33c2981aedafbab6
2024-10-28 10:44:04 -07:00
Yuval Tassa 3d920e6a70 Update build documentation to include instructions on how to build the docs locally.
PiperOrigin-RevId: 690616910
Change-Id: I717988e3adc67cb6d65488d39bc804c3d4f0e3b5
2024-10-28 08:17:16 -07:00
Yuval Tassa d8494fef3b Remove deprecated mjv_makeConnector function.
PiperOrigin-RevId: 690563333
Change-Id: Ice9c6b6cf41de8a55fa361477f9aee9181d50184
2024-10-28 04:51:47 -07:00
Taylor Howell 3c21abc0e5 Add ray intersection with ellipsoid to MJX.
PiperOrigin-RevId: 690557087
Change-Id: Icd2f0be1243574720baeac82b8bdd92e57c6a61c
2024-10-28 04:25:11 -07:00
Yuval Tassa 7dc8aef807 Remove the convexhull compiler option.
PiperOrigin-RevId: 690307675
Change-Id: I62d8213579ad07296ca96de004d39ae012174aa4
2024-10-27 04:31:10 -07:00
Yuval Tassa 61cb552f8a Refactor PBR texture layers from separate sub-elements to a single layer sub-element.
Add new element to PyMJCF schema.

PiperOrigin-RevId: 690115286
Change-Id: I7bb3f184cb321ca96037b2ca0ee160efef37469d
2024-10-26 07:41:38 -07:00