1)登录 NGC | NVIDIA GPU Cloud 官网,创建 NGC 用户并登录
2)在右上角用户名的下拉界面点击 setup

3)进入 setup 页后生成 NGC 秘钥并做好记录,该秘钥在模型训练过程以及推理过程都会使用到,且只有在创建时可看到秘钥内容,无法后续进行查询

下载大赛网盘中相应的资料,资料目录结构说明如下:

x86 CPU + NVIDIA GPU + Ubuntu 18.04 以上
NVIDIA 驱动要求 460 以上版本,安装完成后需要重启,重启完后执行 nvidia-smi 检查驱动
root@Alex-McAvoy:~$ apt-get install software-properties-common
root@Alex-McAvoy:~$ add-apt-repository ppa:graphics-drivers/ppa
root@Alex-McAvoy:~$ apt-get install nvidia-driver-460
root@Alex-McAvoy:~$ reboot
关于 docker,详见:docker 手册,命令图解如下:
安装完毕后,使用 docker run hello-world 测试是否安装成功
root@Alex-McAvoy:~$ apt-get install -y ca-certificates curl gnupg lsb-release
root@Alex-McAvoy:~$ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o
/usr/share/keyrings/docker-archive-keyring.gpg
root@Alex-McAvoy:~$ echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu $(lsb_release -cs)stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
root@Alex-McAvoy:~$ apt-get update
root@Alex-McAvoy:~$ apt-get install -y docker-ce docker-ce-cli containerd.io
当出现以下信息后,说明 docker 安装成功

安装完毕后,使用 docker run --rm --gpus all nvidia/cuda:11.0.3-base-ubuntu20.04 nvidia-smi 测试是否安装成功
root@Alex-McAvoy:~$ curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | apt-key add -distribution=$(. /etc/os-release;echo $ID$VERSION_ID)
root@Alex-McAvoy:~$ curl -s -L https://nvidia.github.io/nvidia-docker/$distribution/nvidia-docker.list | tee /etc/apt/sources.list.d/nvidia-docker.list
root@Alex-McAvoy:~$ apt-get update && apt-get install -y nvidia-docker2
root@Alex-McAvoy:~$ systemctl restart docker
当出现以下信息后,说明 nvidia-docker2 安装成功

root@Alex-McAvoy:~$ docker login -u '$oauthtoken' --password-stdin nvcr.io <<< '申请的密钥'
root@Alex-McAvoy:~$ export DL_SITE=https://mirrors.tuna.tsinghua.edu.cn/anaconda/miniconda
root@Alex-McAvoy:~$ wget -c $DL_SITE/Miniconda3-py38_4.10.3-Linux-x86_64.sh
root@Alex-McAvoy:~$ bash Miniconda3-py38_4.10.3-Linux-x86_64.sh
root@Alex-McAvoy:~$ source ~/.bashrc
root@Alex-McAvoy:~$ pip install jupyter jupyterlab
root@Alex-McAvoy:~$ export PW='登录密码'
root@Alex-McAvoy:~$ python3 -c "from notebook.auth.security import set_password; set_password('$PW','$HOME/.jupyter/jupyter_notebook_config.json')"