天天看點

在colab裡怎樣讀取google drive資料

參考: ​​python - Google Colab: how to read data from my google drive? - Stack Overflow​​

其他答案我都試過, 效果不行, 但是以下work for me:

What I have done is first:

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

Then

%cd /content/drive/My Drive/Colab Notebooks/      
df = pd.read_csv("data_example.csv")