AIcrowd / real_robots

Gym environments for Robots that learn to interact with the environment autonomously
https://www.aicrowd.com/challenges/neurips-2019-robot-open-ended-autonomous-learning
MIT License
34 stars 18 forks source link

render('human') and visualization=True render shadows and background both in the GUI and in the robot camera #19

Closed emilio-cartoni closed 4 years ago

emilio-cartoni commented 5 years ago

If you use env.render('human') or put visualization=True in the evaluate function it will open a GUI showing the environment. The GUI renders the environment using shadows and also shows a bluish background. As a side effect, using the GUI will also make the environment render the shadows and the background on the robot camera.
This means that robots trained on images with the GUI on might have a different performance than when the GUI is off, since images will be different.
It is possible to disable shadows from the GUI using the shortcut s or also by setting shadows off using pybullet.configureDebugVisualizer(pybullet.COV_ENABLE_SHADOWS,0), however the background will still be bluish on the robot camera (without the GUI it will be white).

sokovninn commented 4 years ago

Do I understand right that we can disable shadows in my_controller.py? And in which mode (GUI on/off) will be final evaluation?

emilio-cartoni commented 4 years ago

Dear @sokovnik , the evaluation will be run without GUI, so it will be without shadows. The command pybullet.configureDebugVisualizer(pybullet.COV_ENABLE_SHADOWS,0) can be put anywhere after the GUI has started and it is useful for when you want to test your algorithm on your computer with the GUI on and shadows off. Notice that you will still have a different background compared to GUI off, so testing with the GUI on might still be not representative of what you will get during evaluations.

emilio-cartoni commented 4 years ago

Fixed by 966c3e1404b3c01f55cb4eb85492815af4479c74, 414f955fc8f84a1301caf611691de118747d1209, c8466a1d92efa579dd9f94ca01b1a13f3d870fad.