For Ubuntu 16.04—and possibly other Debian-based Linux distros—add the NVIDIA package repository and use apt to install CUDA.
$ sudo apt-get install cuda-command-line-tools
(
$ sudo apt-cache search cuda-command-line-tool
$ sudo apt-get install cuda-command-line-tools-10-0
)
$ export LD_LIBRARY_PATH=${LD_LIBRARY_PATH:+${LD_LIBRARY_PATH}:}/usr/local/cuda/extras/CUPTI/lib64
For Ubuntu 16.04 and cuda 9
$ sudo apt-key adv --fetch-keys http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/7fa2af80.pub
$ wget http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/cuda-repo-ubuntu1604_9.1.85-1_amd64.deb
$ sudo apt install ./cuda-repo-ubuntu1604_9.1.85-1_amd64.deb
$ wget http://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1604/x86_64/nvidia-machine-learning-repo-ubuntu1604_1.0.0-1_amd64.deb
$ sudo apt install ./nvidia-machine-learning-repo-ubuntu1604_1.0.0-1_amd64.deb
$ sudo apt update
$ sudo apt install cuda9.0 cuda-cublas-9-0 cuda-cufft-9-0 cuda-curand-9-0 cuda-cusolver-9-0 cuda-cusparse-9-0 libcudnn7=7.2.1.38-1+cuda9.0 libnccl2=2.2.13-1+cuda9.0 cuda-command-line-tools-9-0
$ sudo apt update
$ sudo apt install libnvinfer4=4.1.2-1+cuda9.0
沒有留言:
張貼留言