how to run env.render() in collab

Viewed 1161

NoSuchDisplayException Traceback (most recent call last) in ()

      3 env.reset()
      4 for _ in range(1000):
----> 5     env.render()
      6     env.step(env.action_space.sample()) # take a random action
      7 env.close()

9 frames /usr/local/lib/python3.6/dist-packages/pyglet/canvas/xlib.py in init(self, name, x_screen)

    121         self._display = xlib.XOpenDisplay(name)
    122         if not self._display:
--> 123             raise NoSuchDisplayException('Cannot connect to "%s"' % name)
    124 
    125         screen_count = xlib.XScreenCount(self._display)

NoSuchDisplayException: Cannot connect to "None"

0 Answers
Related