cuDNN 安装
使用tar包安装
# 下载cudnn tar包
tar -xvf cudnn-linux-x86_64-8.9.7.29_cuda11-archive.tar.xz
cd cudnn-linux-x86_64-8.9.7.29_cuda11-archive
sudo cp lib/* /usr/local/cuda/lib64/
sudo cp include/* /usr/local/cuda/include/
sudo chmod a+r /usr/local/cuda/lib64/*
sudo chmod a+r /usr/local/cuda/include/*
设定bashrc
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/local/cuda/lib64:/usr/local/cuda/extras/CUPTI/lib64"
export CUDA_HOME=/usr/local/cuda
source ~/.bashrc
启动设定
查看是否安装成功
cat /usr/local/cuda/include/cudnn_version.h | grep CUDNN_MAJOR -A 2
参考资料
https://developer.nvidia.com/rdp/cudnn-archive
https://blog.csdn.net/tangjiahao10/article/details/125227005