
‘!’ is used to say that the modules that are being downloaded can only be accessed only in that file.from lab import filesįiles.upload() Step 3: Create the necessary folder path: Step 2: Upload the JSON file:Ĭolab provides a module named files for the purpose of uploading a file. I have used Kaggle because this is one of the most popular websites for datasetsĪfter completing the above process a file with the name “kaggle.json” will be automatically downloaded. Visit Kaggle, login to your account, go to My Account, and then Create New API Token. Step 1: Get the API key from your account: Downloading dataset into drive:ĭownloading a dataset involves 5 steps, they are:

Now that mounting is completed the user can download the required dataset into drive. root_path = 'gdrive/My Drive/your_project_folder/'


the folder where you have stored your project). Now its time to change the root path of your Drive to enter the specific folder that you want to access (i.e. Go to the link that you will encounter after running the code to retrieve the authorization code. This can be done using a module named drive that is provided by Google Colab. To download datasets into the drive we have to establish a connection between the drive and the colab file. The python notebooks that were created or accessed by the user will be stored in his or her Google Drive.īefore downloading a dataset into Drive using Google Colab one must mount his or her Google Drive to Google Colab because colab stores its files in Google Drive. To access Google Colab one should attach it with his or her Gmail.

This environment provides users with jupyter notebooks with extra RAM and disk space. This Google Colab is an online environment provided by Google, especially for AI and Machine learning enthusiasts. Google Colaboratory is commonly known as Google Colab. Before learning how to download datasets into Google Drive using Google Colab lets see what Google Colaboratory is.
