# Install cuda, cudnn on Linux https://koding.work/how-to-install-cuda-and-cudnn-to-ubuntu-20-04/ install cudnn via tar file ## check success or not 1. nvidia-smi works 2. check directory of cuda ``` cd /usr/local/cuda ls ``` ![](https://i.imgur.com/5MqFN7w.png) 3. check cudnn ``` cd /usr/local/cuda/include ls | grep cudnn ``` ![](https://i.imgur.com/jMg9gcd.png) ## common error ``` NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running. ``` solve-1: https://clay-atlas.com/us/blog/2022/07/29/solved-nvidia-smi-has-failed-because-it-couldnt-communicate-with-the-nvidia-driver-make-sure-that-the-latest-nvidia-driver-is-installed-and-running/ solve-2: 開啟九宮格,選取額外驅動程式: ![](https://i.imgur.com/YLyxBvD.png) 選擇其中一個nvidia driver後,套用變更並重新啟動 ![](https://i.imgur.com/7zlLQmh.png)