summaryrefslogtreecommitdiff
path: root/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab/index.html
diff options
context:
space:
mode:
authorNavan Chauhan <navanchauhan@gmail.com>2020-09-08 12:43:11 +0530
committerNavan Chauhan <navanchauhan@gmail.com>2020-09-08 12:43:11 +0530
commit9c681eb127254dfd6a9b60aea35dd2e07cbdcac8 (patch)
tree1da58bb5902711444c8da2fd7ae46082bc17d66a /posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab/index.html
parent5c712abef6b9fded9c3d0b7bb930cdfeb94981d1 (diff)
Publish deploy 2020-09-08 12:43
Diffstat (limited to 'posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab/index.html')
-rw-r--r--posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab/index.html2
1 files changed, 1 insertions, 1 deletions
diff --git a/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab/index.html b/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab/index.html
index e48e0fc..f7ef789 100644
--- a/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab/index.html
+++ b/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab/index.html
@@ -1,4 +1,4 @@
-<!DOCTYPE html><html lang="en"><head><meta charset="UTF-8"/><meta name="og:site_name" content="Navan Chauhan"/><link rel="canonical" href="https://navanchauhan.github.io/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab"/><meta name="twitter:url" content="https://navanchauhan.github.io/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab"/><meta name="og:url" content="https://navanchauhan.github.io/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab"/><title>Setting up Kaggle to use with Google Colab | Navan Chauhan</title><meta name="twitter:title" content="Setting up Kaggle to use with Google Colab | Navan Chauhan"/><meta name="og:title" content="Setting up Kaggle to use with Google Colab | Navan Chauhan"/><meta name="description" content="Tutorial on setting up kaggle, to use with Google Colab"/><meta name="twitter:description" content="Tutorial on setting up kaggle, to use with Google Colab"/><meta name="og:description" content="Tutorial on setting up kaggle, to use with Google Colab"/><meta name="twitter:card" content="summary"/><link rel="stylesheet" href="/styles.css" type="text/css"/><meta name="viewport" content="width=device-width, initial-scale=1.0"/><link rel="shortcut icon" href="/images/favicon.png" type="image/png"/><link rel="alternate" href="/feed.rss" type="application/rss+xml" title="Subscribe to Navan Chauhan"/><meta name="twitter:image" content="https://navanchauhan.github.io/images/logo.png"/><meta name="og:image" content="https://navanchauhan.github.io/images/logo.png"/></head><head><script>var _paq=window._paq=window._paq||[];_paq.push(["trackPageView"]),_paq.push(["enableLinkTracking"]),function(){_paq.push(["setTrackerUrl","https://navanchauhan.matomo.cloud/matomo.php"]),_paq.push(["setSiteId","1"]);var a=document,t=a.createElement("script"),e=a.getElementsByTagName("script")[0];t.type="text/javascript",t.async=!0,t.src="//cdn.matomo.cloud/navanchauhan.matomo.cloud/matomo.js",e.parentNode.insertBefore(t,e)}();</script></head><head><script src="https://www.googletagmanager.com/gtag/js?id=UA-108635191-1v"></script><script>window.dataLayer = window.dataLayer || [];function gtag(){dataLayer.push(arguments);}gtag('js', new Date());gtag('config', 'UA-108635191-1');</script></head><body class="item-page"><header><div class="wrapper"><a class="site-name" href="/">Navan Chauhan</a><nav><ul><li><a href="/about">About Me</a></li><li><a class="selected" href="/posts">Posts</a></li><li><a href="/publications">Publications</a></li><li><a href="/assets/résumé.pdf">Résumé</a></li><li><a href="https://navanchauhan.github.io/repo">Repo</a></li></ul></nav></div></header><div class="wrapper"><article><div class="content"><span class="reading-time">1 minute read</span><span class="reading-time">Created on January 15, 2020</span><span class="reading-time">Last modified on June 1, 2020</span><h1>Setting up Kaggle to use with Google Colab</h1><p><em>In order to be able to access Kaggle Datasets, you will need to have an account on Kaggle (which is Free)</em></p><h2>Grabbing Our Tokens</h2><h3>Go to Kaggle</h3><img src="/assets/posts/kaggle-colab/ss1.png" alt=""Homepage""/><h3>Click on your User Profile and Click on My Account</h3><img src="/assets/posts/kaggle-colab/ss2.png" alt=""Account""/><h3>Scroll Down untill you see Create New API Token</h3><img src="/assets/posts/kaggle-colab/ss3.png"/><h3>This will download your token as a JSON file</h3><img src="/assets/posts/kaggle-colab/ss4.png"/><p>Copy the File to the root folder of your Google Drive</p><h2>Setting up Colab</h2><h3>Mounting Google Drive</h3><pre><code><div class="highlight"><span></span><span class="kn">import</span> <span class="nn">os</span>
+<!DOCTYPE html><html lang="en"><head><meta charset="UTF-8"/><meta name="og:site_name" content="Navan Chauhan"/><link rel="canonical" href="https://navanchauhan.github.io/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab"/><meta name="twitter:url" content="https://navanchauhan.github.io/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab"/><meta name="og:url" content="https://navanchauhan.github.io/posts/2020-01-15-Setting-up-Kaggle-to-use-with-Colab"/><title>Setting up Kaggle to use with Google Colab | Navan Chauhan</title><meta name="twitter:title" content="Setting up Kaggle to use with Google Colab | Navan Chauhan"/><meta name="og:title" content="Setting up Kaggle to use with Google Colab | Navan Chauhan"/><meta name="description" content="Tutorial on setting up kaggle, to use with Google Colab"/><meta name="twitter:description" content="Tutorial on setting up kaggle, to use with Google Colab"/><meta name="og:description" content="Tutorial on setting up kaggle, to use with Google Colab"/><meta name="twitter:card" content="summary"/><link rel="stylesheet" href="/styles.css" type="text/css"/><meta name="viewport" content="width=device-width, initial-scale=1.0"/><link rel="shortcut icon" href="/images/favicon.png" type="image/png"/><link rel="alternate" href="/feed.rss" type="application/rss+xml" title="Subscribe to Navan Chauhan"/><meta name="twitter:image" content="https://navanchauhan.github.io/images/logo.png"/><meta name="og:image" content="https://navanchauhan.github.io/images/logo.png"/></head><head><script>var _paq=window._paq=window._paq||[];_paq.push(['trackPageView']),_paq.push(['enableLinkTracking']),function(){var a='http://navanspi.duckdns.org:6969/analytics/';_paq.push(['setTrackerUrl',a+'matomo.php']),_paq.push(['setSiteId','1']);var e=document,t=e.createElement('script'),p=e.getElementsByTagName('script')[0];t.type='text/javascript',t.async=!0,t.src=a+'matomo.js',p.parentNode.insertBefore(t,p)}();</script></head><head><script src="https://www.googletagmanager.com/gtag/js?id=UA-108635191-1v"></script><script>window.dataLayer = window.dataLayer || [];function gtag(){dataLayer.push(arguments);}gtag('js', new Date());gtag('config', 'UA-108635191-1');</script></head><body class="item-page"><header><div class="wrapper"><a class="site-name" href="/">Navan Chauhan</a><nav><ul><li><a href="/about">About Me</a></li><li><a class="selected" href="/posts">Posts</a></li><li><a href="/publications">Publications</a></li><li><a href="/assets/résumé.pdf">Résumé</a></li><li><a href="https://navanchauhan.github.io/repo">Repo</a></li></ul></nav></div></header><div class="wrapper"><article><div class="content"><span class="reading-time">1 minute read</span><span class="reading-time">Created on January 15, 2020</span><span class="reading-time">Last modified on June 1, 2020</span><h1>Setting up Kaggle to use with Google Colab</h1><p><em>In order to be able to access Kaggle Datasets, you will need to have an account on Kaggle (which is Free)</em></p><h2>Grabbing Our Tokens</h2><h3>Go to Kaggle</h3><img src="/assets/posts/kaggle-colab/ss1.png" alt=""Homepage""/><h3>Click on your User Profile and Click on My Account</h3><img src="/assets/posts/kaggle-colab/ss2.png" alt=""Account""/><h3>Scroll Down untill you see Create New API Token</h3><img src="/assets/posts/kaggle-colab/ss3.png"/><h3>This will download your token as a JSON file</h3><img src="/assets/posts/kaggle-colab/ss4.png"/><p>Copy the File to the root folder of your Google Drive</p><h2>Setting up Colab</h2><h3>Mounting Google Drive</h3><pre><code><div class="highlight"><span></span><span class="kn">import</span> <span class="nn">os</span>
<span class="kn">from</span> <span class="nn">google.colab</span> <span class="kn">import</span> <span class="n">drive</span>
<span class="n">drive</span><span class="o">.</span><span class="n">mount</span><span class="p">(</span><span class="s1">&#39;/content/drive&#39;</span><span class="p">)</span>
</div></code></pre><p>After this click on the URL in the output section, login and then paste the Auth Code</p><h3>Configuring Kaggle</h3><pre><code><div class="highlight"><span></span><span class="n">os</span><span class="o">.</span><span class="n">environ</span><span class="p">[</span><span class="s1">&#39;KAGGLE_CONFIG_DIR&#39;</span><span class="p">]</span> <span class="o">=</span> <span class="s2">&quot;/content/drive/My Drive/&quot;</span>