Using Kaggle Datasets in Google Colab
Kaggle Notebooks are free to use, but not without limits (more on that in Chapter 4), and the first one you are likely to hit is the time limit. A popular alternative is to move to Google Colab, a free Jupyter Notebook environment that runs entirely in the cloud: https://colab.research.google.com.
Even once we’ve moved the computations there, we might still want to have access to the Kaggle datasets, so importing them into Colab is a rather handy feature. The remainder of this section discusses the steps necessary to use Kaggle Datasets through Colab.
The first thing we do, assuming we are already registered on Kaggle, is head to the account page to generate the API token (an access token containing security credentials for a login session, user identification, privileges, and so on):
- Go to your account, which can be found at
https://www.kaggle.com/USERNAME/account
, and click on Create New API Token:
Figure...