This quick note is one solution (may not optimal) to prevent Colab from disconnecting during training your deep learning model.
So to prevent this, we add a JS code to the console. Its purpose is to keep on clicking the page and prevent it from idling. So, I follow these steps:
- Open the chrome console,
Ctrl+ Shift + ito open inspector view
- Goto console.
- Paste and run the following code in the console:
And remember to press
Enter to start the script, it then can prevent your Colab notebook from disconnecting.