nvidia-docker安装
(1)确保NVIDIA Drivers和Docker已经安装好
$nvcc --version
$docker
(2)安装nvidia-docker
(2.1)设置stable存储库和密钥
# 注意此步骤可能无法下载,需要手动去网页下载,然后使用apt-key add 载入
$ curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | sudo apt-key add -
(2.2)安装nvidia-docker安装包
$ sudo apt-get install -y nvidia-docker2
(2.3)重启docker
$ sudo systemctl restart docker
(2.4)验证
$ sudo docker run --rm --gpus all nvidia/cuda:11.0-base nvidia-smi
本文来自博客园,作者:海_纳百川,转载请注明原文链接:https://www.cnblogs.com/chentiao/p/16999479.html,如有侵权联系删除