Search code examples
python-3.xgoogle-cloud-platformgoogle-colaboratoryinstall.packages

Do I have to install packages needed each time when I start Google Colab?


I am using Google colab for one of my projects. I have a list of packages which I need to run the notebook perfectly. So, should I have to install all packages each time I start colab or only installing once I can use them forever?


Solution

  • You'll need to install it each time. From the FAQ:

    Where is my code executed? What happens to my execution state if I close the browser window? Code is executed in a virtual machine dedicated to your account. Virtual machines are recycled when idle for a while, and have a maximum lifetime enforced by the system.