This is how Colab works If you do not do a mouse click about every fifteen minutes or so it times out and all variables are lost.
So I save the notebook whenever I make changes and rerun it.
There is a paid version of Colab, but I am not sure If this does the same thing.
I use pyautogui, if I want to go away for up to 12hrs and I want the notebook to continue running.
I also use the runall option in the RUNTIME menu so it runs all the cells until it gets to the end or finds an error.
This way I get to the end of the notebook, and can see the results even if they are no longer available.
I faced the same Error when i accessed 01_intro.ipynb notebook from https://course.fast.ai/start_colab#Using-a-GPU. This error seems occurring mainly form version mismatch in fastai,fastai2,fastcore Try to run Bellow and restart the notebook again. These version combination seems to be working.
!pip install fastai==2.0.15
!pip install fastai2==0.0.30
!pip install fastcore==1.0.16.
After working on the same notebook everyday for about two weeks and earlier today. I came back this evening ran the the first few cells, then when I ran this cell from fastai.vision.all import *
I recieved the error
ModuleNotFoundError: No module named ‘fastai.callback.all’; ‘fastai.callback’ is not a package
This time only restarting the runtime would clear it.
It looks like I now have two things to try if I get this error again.
I had this same issue the other day. What I found was that I did not have a locally saved version on my Drive, which was causing the error. I created a copy and worked off of that and the issue was gone.