Datasets:

ArXiv:
License:
Priosin commited on
Commit
641b906
·
verified ·
1 Parent(s): 6eb6abb

Upload mjx_h1_body.xml

Browse files

This version separates visual meshes from collision handling by marking all mesh geoms as non-colliding. It replaces contact geoms with simple primitives (boxes and capsules) on key body parts relevant for crawling. Joint, inertia, and actuator parameters remain unchanged. This reduces the number of contact geoms for improved performance in MJX.

Files changed (1) hide show
  1. robots/h1/mjcf/mjx_h1_body.xml +304 -0
robots/h1/mjcf/mjx_h1_body.xml ADDED
@@ -0,0 +1,304 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <mujoco model="h1">
2
+ <compiler angle="radian" meshdir="assets" autolimits="true"/>
3
+
4
+ <default>
5
+ <default class="h1">
6
+ <geom type="mesh"/>
7
+ <joint damping="1" armature="0.1"/>
8
+ <default class="visual">
9
+ <geom contype="0" conaffinity="0" group="2" material="black"/>
10
+ </default>
11
+ <default class="collision">
12
+ <geom group="3" mass="0" density="0"/>
13
+ </default>
14
+ <site size="0.001" rgba="0.5 0.5 0.5 0.3" group="4"/>
15
+ <default class="hip">
16
+ <position forcerange="-200 200" kp="200" kv="5"/>
17
+ </default>
18
+ <default class="knee">
19
+ <position forcerange="-300 300" kp="300" kv="6"/>
20
+ </default>
21
+ <default class="ankle">
22
+ <position forcerange="-40 40" kp="40" kv="2"/>
23
+ </default>
24
+ <default class="torso">
25
+ <position forcerange="-200 200" kp="300" kv="6"/>
26
+ </default>
27
+ <default class="shoulder1">
28
+ <position forcerange="-40 40" kp="100" kv="2"/>
29
+ </default>
30
+ <default class="shoulder2">
31
+ <position forcerange="-18 18" kp="100" kv="2"/>
32
+ </default>
33
+ <default class="elbow">
34
+ <position forcerange="-18 18" kp="100" kv="2"/>
35
+ </default>
36
+ </default>
37
+ </default>
38
+
39
+ <asset>
40
+ <material name="black" rgba="0.1 0.1 0.1 1"/>
41
+ <material name="white" rgba="1 1 1 1"/>
42
+
43
+ <mesh file="pelvis.stl"/>
44
+ <mesh file="left_hip_yaw_link.stl"/>
45
+ <mesh file="left_hip_roll_link.stl"/>
46
+ <mesh file="left_hip_pitch_link.stl"/>
47
+ <mesh file="left_knee_link.stl"/>
48
+ <mesh file="left_ankle_link.stl"/>
49
+ <mesh file="right_hip_yaw_link.stl"/>
50
+ <mesh file="right_hip_roll_link.stl"/>
51
+ <mesh file="right_hip_pitch_link.stl"/>
52
+ <mesh file="right_knee_link.stl"/>
53
+ <mesh file="right_ankle_link.stl"/>
54
+ <mesh file="torso_link.stl"/>
55
+ <mesh file="left_shoulder_pitch_link.stl"/>
56
+ <mesh file="left_shoulder_roll_link.stl"/>
57
+ <mesh file="left_shoulder_yaw_link.stl"/>
58
+ <mesh file="left_elbow_link.stl"/>
59
+ <mesh file="right_shoulder_pitch_link.stl"/>
60
+ <mesh file="right_shoulder_roll_link.stl"/>
61
+ <mesh file="right_shoulder_yaw_link.stl"/>
62
+ <mesh file="right_elbow_link.stl"/>
63
+ <mesh file="logo_link.stl"/>
64
+ </asset>
65
+
66
+ <worldbody>
67
+ <!-- global light -->
68
+ <light pos="0 0 10" castshadow="false" directional="true"
69
+ ambient="0.3 0.3 0.3" diffuse="0.7 0.7 0.7" specular="0.1 0.1 0.1"/>
70
+
71
+ <!-- ================= pelvis / root ================= -->
72
+ <body name="pelvis" pos="0 0 0" childclass="h1">
73
+ <camera name="cam_default" pos="2 3 0" mode="trackcom" xyaxes="-1 0.5 0 0 0 1"/>
74
+ <inertial pos="-0.0002 4e-05 -0.04522" quat="0.498303 0.499454 -0.500496 0.501741"
75
+ mass="5.39" diaginertia="0.0490211 0.0445821 0.00824619"/>
76
+
77
+ <!-- visual pelvis mesh -->
78
+ <geom class="visual" mesh="pelvis" contype="0" conaffinity="0"/>
79
+
80
+ <!-- belly box for ground contact while crawling -->
81
+ <geom class="collision" type="box"
82
+ pos="0 0 -0.12" size="0.18 0.11 0.05"/>
83
+
84
+ <!-- =============== left leg chain =============== -->
85
+ <body name="left_hip_yaw_link" pos="0 0.0875 -0.1742">
86
+ <inertial pos="-0.04923 0.0001 0.0072"
87
+ quat="0.69699 0.219193 0.233287 0.641667"
88
+ mass="2.244"
89
+ diaginertia="0.00304494 0.00296885 0.00189201"/>
90
+ <joint name="left_hip_yaw" axis="0 0 1" range="-0.43 0.43"/>
91
+ <geom class="visual" mesh="left_hip_yaw_link" contype="0" conaffinity="0"/>
92
+
93
+ <body name="left_hip_roll_link" pos="0.039468 0 0">
94
+ <inertial pos="-0.0058 -0.00319 -9e-05"
95
+ quat="0.0438242 0.70721 -0.0729075 0.701867"
96
+ mass="2.232"
97
+ diaginertia="0.00243264 0.00225325 0.00205492"/>
98
+ <joint name="left_hip_roll" axis="1 0 0" range="-0.43 0.43"/>
99
+ <geom class="visual" mesh="left_hip_roll_link" contype="0" conaffinity="0"/>
100
+
101
+ <body name="left_hip_pitch_link" pos="0 0.11536 0">
102
+ <inertial pos="0.00746 -0.02346 -0.08193"
103
+ quat="0.979828 0.0513522 -0.0169854 -0.192382"
104
+ mass="4.152"
105
+ diaginertia="0.0829503 0.0821457 0.00510909"/>
106
+ <joint name="left_hip_pitch" axis="0 1 0" range="-3.14 2.53"/>
107
+ <geom class="visual" mesh="left_hip_pitch_link" contype="0" conaffinity="0"/>
108
+
109
+ <body name="left_knee_link" pos="0 0 -0.4">
110
+ <inertial pos="-0.00136 -0.00512 -0.1384"
111
+ quat="0.626132 -0.034227 -0.0416277 0.777852"
112
+ mass="1.721"
113
+ diaginertia="0.0125237 0.0123104 0.0019428"/>
114
+ <joint name="left_knee" axis="0 1 0" range="-0.26 2.05"/>
115
+ <geom class="visual" mesh="left_knee_link" contype="0" conaffinity="0"/>
116
+ <!-- capsule covering shin for ground contact -->
117
+ <geom class="collision" type="capsule"
118
+ fromto="0 0 -0.20 0 0 0" size="0.04"/>
119
+
120
+ <body name="left_ankle_link" pos="0 0 -0.4">
121
+ <inertial pos="0.048568 0 -0.045609"
122
+ quat="0.489385 0.510394 0.510394 0.489385"
123
+ mass="0.552448"
124
+ diaginertia="0.00362 0.00355701 0.000149987"/>
125
+ <joint name="left_ankle" axis="0 1 0" range="-0.87 0.52"/>
126
+ <geom class="visual" mesh="left_ankle_link" contype="0" conaffinity="0"/>
127
+ <!-- foot box collision -->
128
+ <geom class="collision" type="box"
129
+ pos="0.05 0 -0.055" size="0.15 0.015 0.015"/>
130
+ <site name="left_foot" pos="0 0 -0.05" rgba="0 1 0 1" size="0.2"/>
131
+ </body>
132
+ </body>
133
+ </body>
134
+ </body>
135
+ </body>
136
+
137
+ <!-- =============== right leg chain =============== -->
138
+ <body name="right_hip_yaw_link" pos="0 -0.0875 -0.1742">
139
+ <inertial pos="-0.04923 -0.0001 0.0072"
140
+ quat="0.641667 0.233287 0.219193 0.69699"
141
+ mass="2.244"
142
+ diaginertia="0.00304494 0.00296885 0.00189201"/>
143
+ <joint name="right_hip_yaw" axis="0 0 1" range="-0.43 0.43"/>
144
+ <geom class="visual" mesh="right_hip_yaw_link" contype="0" conaffinity="0"/>
145
+
146
+ <body name="right_hip_roll_link" pos="0.039468 0 0">
147
+ <inertial pos="-0.0058 0.00319 -9e-05"
148
+ quat="-0.0438242 0.70721 0.0729075 0.701867"
149
+ mass="2.232"
150
+ diaginertia="0.00243264 0.00225325 0.00205492"/>
151
+ <joint name="right_hip_roll" axis="1 0 0" range="-0.43 0.43"/>
152
+ <geom class="visual" mesh="right_hip_roll_link" contype="0" conaffinity="0"/>
153
+
154
+ <body name="right_hip_pitch_link" pos="0 -0.11536 0">
155
+ <inertial pos="0.00746 0.02346 -0.08193"
156
+ quat="0.979828 -0.0513522 -0.0169854 0.192382"
157
+ mass="4.152"
158
+ diaginertia="0.0829503 0.0821457 0.00510909"/>
159
+ <joint name="right_hip_pitch" axis="0 1 0" range="-3.14 2.53"/>
160
+ <geom class="visual" mesh="right_hip_pitch_link" contype="0" conaffinity="0"/>
161
+
162
+ <body name="right_knee_link" pos="0 0 -0.4">
163
+ <inertial pos="-0.00136 0.00512 -0.1384"
164
+ quat="0.777852 -0.0416277 -0.034227 0.626132"
165
+ mass="1.721"
166
+ diaginertia="0.0125237 0.0123104 0.0019428"/>
167
+ <joint name="right_knee" axis="0 1 0" range="-0.26 2.05"/>
168
+ <geom class="visual" mesh="right_knee_link" contype="0" conaffinity="0"/>
169
+ <geom class="collision" type="capsule"
170
+ fromto="0 0 -0.20 0 0 0" size="0.04"/>
171
+
172
+ <body name="right_ankle_link" pos="0 0 -0.4">
173
+ <inertial pos="0.048568 0 -0.045609"
174
+ quat="0.489385 0.510394 0.510394 0.489385"
175
+ mass="0.552448"
176
+ diaginertia="0.00362 0.00355701 0.000149987"/>
177
+ <joint name="right_ankle" axis="0 1 0" range="-0.87 0.52"/>
178
+ <geom class="visual" mesh="right_ankle_link" contype="0" conaffinity="0"/>
179
+ <geom class="collision" type="box"
180
+ pos="0.05 0 -0.055" size="0.15 0.015 0.015"/>
181
+ <site name="right_foot" pos="0 0 -0.05" rgba="0 1 0 1" size="0.2"/>
182
+ </body>
183
+ </body>
184
+ </body>
185
+ </body>
186
+ </body>
187
+
188
+ <!-- =============== torso & arms =============== -->
189
+ <body name="torso_link">
190
+ <inertial pos="0.000489 0.002797 0.20484"
191
+ quat="0.999989 -0.00130808 -0.00282289 -0.00349105"
192
+ mass="17.789"
193
+ diaginertia="0.487315 0.409628 0.127837"/>
194
+ <joint name="torso" axis="0 0 1" range="-2.35 2.35"/>
195
+ <geom class="visual" mesh="torso_link" contype="0" conaffinity="0"/>
196
+ <site name="head" class="visual" size="0.01" pos="0 0 0.7" rgba="1 1 1 1"/>
197
+ <geom class="visual" material="white" mesh="logo_link" contype="0" conaffinity="0"/>
198
+ <site name="imu" size="0.01" pos="-0.04452 0 0.27756"/>
199
+
200
+ <body name="left_shoulder_pitch_link" pos="0.0055 0.15535 0.42999"
201
+ quat="0.976296 0.216438 0 0">
202
+ <inertial pos="0.005045 0.053657 -0.015715"
203
+ quat="0.814858 0.579236 -0.0201072 -0.00936488"
204
+ mass="1.033" diaginertia="0.00129936 0.000987113 0.000858198"/>
205
+ <joint name="left_shoulder_pitch" axis="0 1 0" range="-2.87 2.87"/>
206
+ <geom class="visual" mesh="left_shoulder_pitch_link" contype="0" conaffinity="0"/>
207
+
208
+ <body name="left_shoulder_roll_link" pos="-0.0055 0.0565 -0.0165"
209
+ quat="0.976296 -0.216438 0 0">
210
+ <inertial pos="0.000679 0.00115 -0.094076"
211
+ quat="0.732491 0.00917179 0.0766656 0.676384"
212
+ mass="0.793" diaginertia="0.00170388 0.00158256 0.00100336"/>
213
+ <joint name="left_shoulder_roll" axis="1 0 0" range="-0.34 3.11"/>
214
+ <geom class="visual" mesh="left_shoulder_roll_link" contype="0" conaffinity="0"/>
215
+
216
+ <body name="left_shoulder_yaw_link" pos="0 0 -0.1343">
217
+ <inertial pos="0.01365 0.002767 -0.16266"
218
+ quat="0.703042 -0.0331229 -0.0473362 0.708798"
219
+ mass="0.839" diaginertia="0.00408038 0.00370367 0.000622687"/>
220
+ <joint name="left_shoulder_yaw" axis="0 0 1" range="-1.3 4.45"/>
221
+ <geom class="visual" mesh="left_shoulder_yaw_link" contype="0" conaffinity="0"/>
222
+
223
+ <body name="left_elbow_link" pos="0.0185 0 -0.198">
224
+ <inertial pos="0.15908 -0.000144 -0.015776"
225
+ quat="0.0765232 0.720327 0.0853116 0.684102"
226
+ mass="0.669" diaginertia="0.00601829 0.00600579 0.000408305"/>
227
+ <joint name="left_elbow" axis="0 1 0" range="-1.25 2.61"/>
228
+ <geom class="visual" mesh="left_elbow_link" contype="0" conaffinity="0"/>
229
+ <!-- forearm capsule for crawling contact -->
230
+ <geom class="collision" type="capsule"
231
+ fromto="0 0 -0.10 0 0 -0.30" size="0.025"/>
232
+ <site name="left_hand" pos="0.31 0 -0.01" rgba="0 1 0 1" size="0.01"/>
233
+ </body>
234
+ </body>
235
+ </body>
236
+ </body>
237
+
238
+ <body name="right_shoulder_pitch_link" pos="0.0055 -0.15535 0.42999"
239
+ quat="0.976296 -0.216438 0 0">
240
+ <inertial pos="0.005045 -0.053657 -0.015715"
241
+ quat="0.579236 0.814858 0.00936488 0.0201072"
242
+ mass="1.033" diaginertia="0.00129936 0.000987113 0.000858198"/>
243
+ <joint name="right_shoulder_pitch" axis="0 1 0" range="-2.87 2.87"/>
244
+ <geom class="visual" mesh="right_shoulder_pitch_link" contype="0" conaffinity="0"/>
245
+
246
+ <body name="right_shoulder_roll_link" pos="-0.0055 -0.0565 -0.0165"
247
+ quat="0.976296 0.216438 0 0">
248
+ <inertial pos="0.000679 -0.00115 -0.094076"
249
+ quat="0.676384 0.0766656 0.00917179 0.732491"
250
+ mass="0.793" diaginertia="0.00170388 0.00158256 0.00100336"/>
251
+ <joint name="right_shoulder_roll" axis="1 0 0" range="-3.11 0.34"/>
252
+ <geom class="visual" mesh="right_shoulder_roll_link" contype="0" conaffinity="0"/>
253
+
254
+ <body name="right_shoulder_yaw_link" pos="0 0 -0.1343">
255
+ <inertial pos="0.01365 -0.002767 -0.16266"
256
+ quat="0.708798 -0.0473362 -0.0331229 0.703042"
257
+ mass="0.839" diaginertia="0.00408038 0.00370367 0.000622687"/>
258
+ <joint name="right_shoulder_yaw" axis="0 0 1" range="-4.45 1.3"/>
259
+ <geom class="visual" mesh="right_shoulder_yaw_link" contype="0" conaffinity="0"/>
260
+
261
+ <body name="right_elbow_link" pos="0.0185 0 -0.198">
262
+ <inertial pos="0.15908 0.000144 -0.015776"
263
+ quat="-0.0765232 0.720327 -0.0853116 0.684102"
264
+ mass="0.669" diaginertia="0.00601829 0.00600579 0.000408305"/>
265
+ <joint name="right_elbow" axis="0 1 0" range="-1.25 2.61"/>
266
+ <geom class="visual" mesh="right_elbow_link" contype="0" conaffinity="0"/>
267
+ <geom class="collision" type="capsule"
268
+ fromto="0 0 -0.10 0 0 -0.30" size="0.025"/>
269
+ <site name="right_hand" pos="0.31 0 -0.01" size="0.01"/>
270
+ </body>
271
+ </body>
272
+ </body>
273
+ </body>
274
+ </body>
275
+ </body>
276
+ </worldbody>
277
+
278
+ <actuator>
279
+ <position name="left_hip_yaw" joint="left_hip_yaw" ctrlrange="-0.43 0.43" class="hip" />
280
+ <position name="left_hip_roll" joint="left_hip_roll" ctrlrange="-0.43 0.43" class="hip" />
281
+ <position name="left_hip_pitch" joint="left_hip_pitch" ctrlrange="-3.14 2.53" class="hip" />
282
+ <position name="left_knee" joint="left_knee" ctrlrange="-0.26 2.05" class="knee" />
283
+ <position name="left_ankle" joint="left_ankle" ctrlrange="-0.87 0.52" class="ankle" />
284
+ <position name="right_hip_yaw" joint="right_hip_yaw" ctrlrange="-0.43 0.43" class="hip" />
285
+ <position name="right_hip_roll" joint="right_hip_roll" ctrlrange="-0.43 0.43" class="hip" />
286
+ <position name="right_hip_pitch" joint="right_hip_pitch" ctrlrange="-3.14 2.53" class="hip" />
287
+ <position name="right_knee" joint="right_knee" ctrlrange="-0.26 2.05" class="knee" />
288
+ <position name="right_ankle" joint="right_ankle" ctrlrange="-0.87 0.52" class="ankle" />
289
+ <position name="torso" joint="torso" ctrlrange="-2.35 2.35" class="torso" />
290
+ <position name="left_shoulder_pitch" joint="left_shoulder_pitch" ctrlrange="-2.87 2.87" class="shoulder1" />
291
+ <position name="left_shoulder_roll" joint="left_shoulder_roll" ctrlrange="-0.34 3.11" class="shoulder1" />
292
+ <position name="left_shoulder_yaw" joint="left_shoulder_yaw" ctrlrange="-1.3 4.45" class="shoulder2" />
293
+ <position name="left_elbow" joint="left_elbow" ctrlrange="-1.25 2.61" class="elbow" />
294
+ <position name="right_shoulder_pitch" joint="right_shoulder_pitch" ctrlrange="-2.87 2.87" class="shoulder1" />
295
+ <position name="right_shoulder_roll" joint="right_shoulder_roll" ctrlrange="-3.11 0.34" class="shoulder1" />
296
+ <position name="right_shoulder_yaw" joint="right_shoulder_yaw" ctrlrange="-4.45 1.3" class="shoulder2" />
297
+ <position name="right_elbow" joint="right_elbow" ctrlrange="-1.25 2.61" class="elbow" />
298
+ </actuator>
299
+
300
+ <sensor>
301
+ <touch name="left_foot_sensor" site="left_foot"/>
302
+ <touch name="right_foot_sensor" site="right_foot"/>
303
+ </sensor>
304
+ </mujoco>