RL and Domain Randomization Techniques for Learning Push Recovery for Humanoids across different environments
The project focuses on developing control policies that allow humanoid robots to maintain balance when subjected to external forces (pushes) in varied environments. By using domain randomization during training, the policies become more robust and can generalize to unseen conditions.
- Python 3.8+
- Git
-
Clone the repository
git clone https://github.com/yourusername/humanoid-push-recovery.git cd humanoid-push-recovery
-
Create a virtual environment
python -m venv pendulum_env
-
Activate the environment
- Windows:
pendulum_env\Scripts\activate
- Linux/macOS:
source pendulum_env/bin/activate
- Windows:
-
Install dependencies
pip install gymnasium==0.29.1 pip install mujoco==3.1.4 pip install glfw imageio pip install stable-baselines3[extra] pip install PyOpenGL PyOpenGL_accelerate # if rendering fails
-
Verify installation
python test_mujoco_install.py
This should open a MuJoCo window, confirming successful installation.
To train a policy with default parameters:
python train_ip.py
The parameters can be changed inside the code.
Visualize the trained policy:
python visualize_ip_video.py