Connecting Google drive to colab

#colab #google #drive

Amol Bole Dec 12 2020 · 1 min read
Share this

If you want to perform some Deep learning experiments then you need GPU, you can perform experiments on CPU also but it will take more time. Higher configuration GPU cost is high, which is not affordable to students and individuals. In this case if you want to perform some experiments then you have option called colab.

Colab is a free Jupter notebook environment that runs completely on cloud. Using Google colab you can perform deep learning experiments. For performs the deep learning experiments you need datatsets, which may be size in GB. In this case we need to use Google drive.

Here, we will see how to connect/mount google drive to colab.

1. First, go to your Google Colab then type the following command

from google.colab import drive

Click on the link here and login to google account. Once login it will generate authorization code. Copy the authorization code and paste into text box and press enter button.

After press enter it will print "Mounted at /content/gdrive"

Successfully mounted

Now you can access Google drive file in colab as like shown in below image

Access Google drive to colab
Read next