I am using kaggle to train a model and once training is done I would like upload the trained model to google drive as I cant figure out a way to download the model locally. I looked into using https://pythonhosted.org/PyDrive/ after doing pip install pydrive I tried authenticating
import os
from pydrive.auth import GoogleAuth
from pydrive.drive import GoogleDrive
from oauth2client.client import GoogleCredentials
then
gauth = GoogleAuth()
gauth.credentials = GoogleCredentials.get_application_default()
drive = GoogleDrive(gauth)
I get this error ApplicationDefaultCredentialsError: The Application Default Credentials are not available. They are available if running in Google Compute Engine. Otherwise, the environment variable GOOGLE_APPLICATION_CREDENTIALS must be defined pointing to a file defining the credentials. See https://developers.google.com/accounts/docs/application-default-credentials for more information.
Is there another way to do this?
Also I have not commited my files in kaggle as I stop the training manually so the commit would go on forever and i get a more than 6 subdirectories error after I tried commiting and stopping a commit in the output area