vwxyzjn/cleanrl

Gymnasium Version Requirement May Need To Be Updated

Opened this issue · 1 comments

Problem Description

Hello, I started experiments on a new server and built the environment from scratch. And I found that if and only if I ran the code in Mujoco environments, there would be problems with the video rendering. To be specific, the first video it saved was all right, and the rest of them were black(successfully saved, but black in the whole video). I tried to figure out why it occurred, including but not only changing the version of CUDA, NVIDIA DRIVER, etc.
However, finally, I checked the settings in my old server to find out why this code could run well in that one, I found the version of gymnasium was 0.29.1. Then I checked the gymnasium version on my new server, it was 0.28.1. After upgrading it to 0.29.1, the problem was solved. I felt weird because I totally followed the instructions. I can still see the gymnasium requirement is 0.28.1.

Checklist

Current Behavior

The first video it saved was all right, and the rest of them were black(successfully saved, but black in the whole video). It only happened in every Mujoco environment, but not in Atari and classic control environments.

Expected Behavior

All videos shall be correctly saved

Possible Solution

Maybe we need to upgrade the requirements in this repository. Although I don't know if this issue occurs when other people run the codes, I am sure that I am not the only one who faces this problem. As the best tutorial to write the best RL codes, the official dependencies requirements shall be 100% correct in order not to lead to annoying and slight bug results in failure experience. All the best.

Steps to Reproduce

  1. install all the requirements dependencies as requirements.txt
  2. choose Mujoco environments
  3. set the render mode as rgb_array
  4. --capture-video, and run the code

Thanks for reporting. Would you mind bumping the gymnasium version and make a PR? Should be able to update with

poetry add gymnasium==0.29.1