gpt4 book ai didi

permissions - Colab : Google drive file stream access permission is a hassle. 有没有更好的方法?

转载 作者:行者123 更新时间:2023-12-03 14:43:59 25 4
gpt4 key购买 nike

我广泛使用 Google Colab。为了轻松访问我的 Google 驱动器中的文件,我将驱动器挂载到运行 Colab 的虚拟机的文件系统。像那样:

from google.colab import drive as cdrive
cdrive.mount('/content/gdrive')
% cd /content/gdrive/'My Drive'/'Colab Notebooks'/my_directory

Colab sessin. Each time

开头 每期 ,我需要授予访问我的驱动器的权限。为此,我需要按“允许”,复制一次性密码并将其粘贴到专用文本区域。这有点乏味。

有没有更好的办法?我可以根据我的机器给予永久许可吗?还有其他想法吗?

最佳答案

此时,我们可以通过 Mount Drive 访问 google drive左侧菜单栏上的按钮。
enter image description here
确认访问 Google Drive 操作。
enter image description here
然后它将安装到您的 Colab 笔记本上。
enter image description here

关于permissions - Colab : Google drive file stream access permission is a hassle. 有没有更好的方法?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59986704/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com