-
-
Save manjulive89/01a8e5a52cb81b5aa36b419ede358727 to your computer and use it in GitHub Desktop.
Setup CUDA in Ubuntu 20.04 LTS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Nvidia Driver installation | |
sudo apt install nvidia-driver-440 | |
sudo reboot | |
# CUDA installation | |
sudo apt update | |
sudo apt install nvidia-cuda-toolkit # Focal: version 10.1 | |
nvcc --version | |
# Download cuDNN from Nvidia: https://developer.nvidia.com/rdp/cudnn-download for version 10.1 | |
cd ~/Downloads | |
tar -xzvf cudnn-10.1-linux-x64-v7.6.5.32.tgz | |
sudo cp cuda/include/cudnn.h /usr/local/cuda/include | |
sudo cp cuda/lib64/libcudnn* /usr/local/cuda/lib64 | |
sudo chmod a+r /usr/local/cuda/include/cudnn.h /usr/local/cuda/lib64/libcudnn* | |
cat /usr/local/cuda/include/cudnn.h | grep CUDNN_MAJOR -A 2 | |
# Add the following line to ~/.bashrc | |
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda/lib64 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment