Docker container for humanoid-gym (https://github.com/roboterax/humanoid-gym)
Tested device (host): Ubuntu 22.04, NVIDIA RTX 4060, nvidia-driver-550, CUDA 12.2
-
Download IsaacGym Preview 4 and unzip, replace the files (
Dockerfile
,build.sh
,run.sh
) in/.../isaacgym/docker/
. -
Run
bash build.sh
andbash run.sh
to build and enter the container. Remove--rm
param inrun.sh
if you want to keep the container. Use--display
if you wish to run the container with a display. After entering the container, by default you are using the python in/usr/bin/python
or python3 in/usr/bin/python3
.One thing to notice is that if you use the default user
gymuser
, you may have two python environments. It's important to know which python and pip you are using. If you do not wish to have such problems, you may always use root. -
Test if you can run IsaacGym examples
cd /opt/isaacgym/python/examples python3 1080_balls_of_solitude.py
-
Install setup.py
/usr/bin/python -m pip install --upgrade pip cd /workspace/humanoid-gym pip install -e .
Some existing packages may conflict, you may keep an eye on the output and use
pip check
to check. For my device, I did the following:sudo pip uninstall thinc confection spacy dask dask-cuda dask-cudf distributed treelite treelite-runtime sudo pip install tornado==6.2
But since these packages haven't been used in humanoid-gym yet, you may skip this.
-
Test running humanoid-gym
cd /workspace/humanoid-gym/ python humanoid/scripts/sim2sim.py --load_model logs/XBot_ppo/exported/policies/policy_example.pt