Read Files from Google Drive in JupyterLab

Viewed 1085

I have installed the jupyter lab extension to connect to google drive. I can create and open files in the drive from the JupyterLab UI. But I can't find a way to read files located in the drive in the notebook. For example I would want to be able to run in my notebook the following:

df = pd.read_csv("Gdrive/MyDrive/somefileinthedrive.csv")

Any suggestions ?

1 Answers

You could open jupyterlab directly in the Google Drive directory like this answer: https://stackoverflow.com/a/69077943/13129641

I use to open jupyterlab from anaconda prompt with:

python -m jupyterlab --notebook-dir=G:/

Note: You can change G:/ to another directory, if you desire.

Related