This directory contains examples for running MPC algorithms on gym-like environments.
-
Clone and checkout the below repos by following setup instructions in individual repos:
-
Run a toy experiment (point mass) using:
python job_script.py --output point_mass_job --config configs/point_mass_config.txt
This optimization should take only a second on so. After the optimization is complete, there will be a prompt to visualize the optimized trajectory. This can be turned off by changing the debug field in the config file.
-
Make a 7DOF sawyer arm reach various goals with the end effector (either fixed goal in episodic setting, or changing goals in continual setting)
python job_script.py --output reacher_7dof_job --config configs/reacher_7dof_config.txt python job_script.py --output continual_reacher_7dof_job --config configs/continual_reacher_7dof_config.txt
-
In-hand manipulation of a pen with a Shadow Hand (Adroit). This requires installation of the mj_envs repository. This package uses git submodules, additional care must be taken to exactly follow setup instructions. NOTE: Uncomment the
import mj_envs
line in thejob_script.py
file.python job_script.py --output pen_job --config configs/pen_config.txt
-
To visualize previous runs (stored as pickle files)
python visualize_trajectories.py --file <path/to/file.pickle> --repeat <#times to repeat>