我已经上传了 nsight-system 并将其安装在 google colab 中,并使用这些关于 nsys 的命令很好,但是当关闭并再次打开时它消失了。如何保存到再次打开时我不需要再次安装。谢谢
我不知道如何解决它
首先将 Google Drive 的空间安装到 Colab 虚拟机。
为此:
Files
-> Mount Drive
(屏幕左侧的文件夹图标),然后将该目录挂载到您的 Colab 笔记本。然后,从
https://developer.nvidia.com/downloads/assets/tools/secure/nsight-systems/2023_2/nsightsystems-linux-public-2023.2.1.122-3259852.run 获取安装
.run
脚本在您的虚拟机上。
运行安装程序,当提示安装路径时,选择 Google Drive 安装目录。
Nsight Systems 将其所有依赖项安装在一处,因此选择 Google Drive 目录即可。
如果您已将
nsys
安装在某个目录中,则可以将内容复制到您的 Google Drive 安装目录中。
或者,您可以直接在 Colab VM 上安装最新的 Nsight 系统:
!wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/nsight-systems-2023.2.3_2023.2.3.1001-1_amd64.deb
!apt update
!apt install ./nsight-systems-2023.2.3_2023.2.3.1001-1_amd64.deb
!apt --fix-broken install
确保
wget
链接上的 Ubuntu 版本和机器架构与您的 Colab 配置匹配。
检查您是否可以使用
!cat /etc/os-release | grep "VERSION_ID"
!echo "Machine's architecture: `uname -i`"