Saving Model State and Load in Google Colab
I have 500 epochs in total to train . But it is taking 8 minutes per epoch to be completed in google colab. Can any one help me how can I save my Model state after a Particular number of epoch  completion and start the training again from where I left in google Colab ??

If you want to save the model to google drive after certain number of epochs in pytorch you can do so by using
first mount google drive
from google.colab import drive
drive.mount('/content/gdrive')

Then the run the cell in colab and authenticate. Now google drive should be mounted.
Now set the path to be
PATH = F&quot;/content/gdrive/My Drive/{Model name}/{model_save_name}&quot;
you can the save the model
    if(epoch%(number_epoch_to_save)==0):
        torch.save(model.state_dict(), PATH)

example documentation can be found here at https://pytorch.org/tutorials/beginner/saving_loading_models.html
