0

In google_colab i have imported files from kaggle using kaggle token

# File Uplod
from google.colab import files;
files.upload()

!mkdir -p ~/.kaggle
!cp kaggle.json ~/.kaggle/
!chmod 600 ~/.kaggle/kaggle.json
!kaggle competitions download -c quora-question-pairs

Is there a possibility to move imported files (from kaggle) to google drive permenantly.

2 Answers2

0

Mount your Google Drive as a filesystem using this code snippet:

from google.colab import drive
drive.mount('/content/drive')

Details: https://colab.research.google.com/notebooks/io.ipynb#scrollTo=u22w3BFiOveA

Then, you can copy whatever files you wish from your backend into your Drive at /content/drive.

Bob Smith
  • 36,107
  • 11
  • 98
  • 91
0

I have answered a similar question here, upload files from kaggle to google drive.

Using code below to generate download link in Kaggle and using wget in Colab I was able get the file in colab. From there it can copied to drive using python or shell command.

from IPython.display import FileLink
FileLink(r'processed_file.zip')
B200011011
  • 3,798
  • 22
  • 33