The starting height of the robot seems to be too low here. In both cases it spawns well into the height field.
If I set the freejoint z coordinate to e.g. 2.0 (mj_data.qpos[2] = 2) then the robot bounces back in the non-jax case, so setting the initial height higher seems like a good solution here.
Issue 2)
If I simulate using jax then the resulting video rendered with mujoco.Renderer is colored incorrectly, as you can see in the latter video.
Is there any additional context you can provide (e.g., a spec sheet or a URDF to show a value mismatch)?
Which model is the issue affecting?
google_barkour_vb/scene_hfield_mjx.xml
What is the issue?
Issue 1)
The robot sinks into and falls below the floor when I simulate the scene using the (non-jax) basic simulation loop from https://github.com/google-deepmind/mujoco/blob/d029e4ff991851c12fdb2a49555bd65d1dbdf705/mjx/tutorial.ipynb
https://github.com/google-deepmind/mujoco_menagerie/assets/174741646/c505364f-5090-4aff-b3f1-4a1b5a187e9a
The robot bounces back and stabilizes on top of the height field if I run the simulation using jax:
https://github.com/google-deepmind/mujoco_menagerie/assets/174741646/f00ef2cb-48e7-44ad-8842-cec7751f64ca
The starting height of the robot seems to be too low here. In both cases it spawns well into the height field.
If I set the freejoint z coordinate to e.g. 2.0 (mj_data.qpos[2] = 2) then the robot bounces back in the non-jax case, so setting the initial height higher seems like a good solution here.
Issue 2)
If I simulate using jax then the resulting video rendered with mujoco.Renderer is colored incorrectly, as you can see in the latter video.
Is there any additional context you can provide (e.g., a spec sheet or a URDF to show a value mismatch)?
The code I used for testing:
P.s. had to do a h264 conversion to make the videos work on github:
ffmpeg -i input.mp4 -vcodec libx264 output.mp4