Sim2sim Validation
Last updated
Last updated
After finish training the policy, we can first put it into a different physics simulator to validate the policy. This procedure is typically called sim2sim validation.
Here, we use as the sim2sim physics engine.
We should have the dependencies installed during the previous section, when setting up the training environment. Run the install script again to make sure we have everything ready.
The sim2sim will read user commands from a gamepad controller, just like what the real robot would do. Plug the joystick controller in the host computer before running the sim2sim script.
Getting USB gamepad controller working in Linux might be tricky. Here are some resources that might be helpful if you run into troubles reading from the joystick:
After everything is set up, we can now test our newly trained policy in MuJoCo!
Run this script to launch the sim2sim environment. The Python script creates threads to handle joystick and policy inference. These threads communicate with the main physics simulation thread via UDP, mimicing the real-world deployment scenario.
Replace the file argument after --config
to test different policies.
By default, the policy is trained to follow user command of linear velocity on X (forward-backward) and Y (sideways) axes, and angular velocity on Z (turning).