Colab virtual screen in Reinforcement Learning Course

I’m running the colab tutorial for this course Let's train our first Deep Reinforcement Learning agent and upload it to the Hub 🚀 - Hugging Face Course. But I found the virtual screen is not working properly in the Colab. I think it’s expected to display something like actual screen, Instead of something like the one below:

1 Like

I was under the impression that we would see a live screen as well, but Pyvirtualdisplay does not render directly to the screen in a remote environments like Colab, it only creates a “virtual screen” stored in memory that can be accessed by other modules to generate an output… In colab, you can generate an video output by rending the pyvirtualdiplay output through the matlab library. However, this process is quite slow, and not suitable for live video.

Here’s a link that provides the explanation and links to code showing how to render an animation in Colab.