ray-project / ray

Ray is a unified framework for scaling AI and Python applications. Ray consists of a core distributed runtime and a set of AI Libraries for accelerating ML workloads.
https://ray.io
Apache License 2.0
32.01k stars 5.45k forks source link

Environment rendering not supported with gymnasium #33032

Open michalgregor opened 1 year ago

michalgregor commented 1 year ago

Hi, it seems that the current version of RLlib does not support environment rendering – since the gym/gymnasium package changed and there is no longer a rendering module under classic_control from which to import SimpleImageViewer.

Do you know whether there are any plans to fix this? Is there a workaround?

szkLaszlo commented 1 year ago

I also found this a problem. As a workaround, I would suggest creating your own renderer, but I debugged the code and found that although rllib supports a custom rendering option, at the initialization it is not checked and since the import fails it turns off rendering. They need to fix how the env_runner_v2.py calls the env.render() or does not turn off rendering after the failed import. I am also interested in a fix.

Rohan138 commented 1 year ago

Taking a look.

FangyangJz commented 1 year ago

Meet the same problem.

emmaai commented 1 year ago

same problem mark 👀

adam-crowther commented 11 months ago

+1

Tim11011 commented 10 months ago

+1

Chasingdreams6 commented 8 months ago

Is this problem solved now? I met the same problem when I using "Rllib evaluate --render" 😢

LaurenYTaylor commented 6 months ago

+1

dermuesli commented 5 months ago

Any update on this open issue? Seems like an fundemental feature (allowing to render and visually check RL policy performance by setting render_env=True) gone missing more than a year ago (or is there any workaround I missed?) ... @sven1977

alvaro-serra commented 1 month ago

+1