udnn安装注意点:
cudnn的安装其实很简单,关键点是一定要安装cuda对应的cudnn包,本机中安装的cuda7.5所以对应的cudnn为v5.1这很重要,我就是安装错了版本,导致后面caffe的编译总是出错。
cudnn安装步骤:
1、从官网上下载cudnn的安装包。
2、将安装包解压,将此安装包放在home路径下即可,并在当前路径下进行解压,解压后的文件夹名为cuda。
3、在终端上编辑如下代码:
$ cd cuda/include
$ sudo cp *.h /usr/local/cuda/include/ (注意这里是你自己的cuda的安装地址,复制*.h文件)
4、关闭终端并重新打开(也可以返回最开始的目录)
$ cd cuda/lib64
$ sudo cp libcudnn* /usr/local/cuda/lib64/
5、终端运行:
$ sudo chmod a+r /usr/local/cuda/include/cudnn.h /usr/local/cuda/lib64/libcudnn*
运行faster rcnn代码提示:
Loaded runtime CuDNN library: 7.1.3 but source was compiled with: 7.4.1. CuDNN library major and minor version needs to match or have higher minor version in case of CuDNN 7.0 or later version. If using a binary install, upgrade your CuDNN library. If building from sources, make sure the library loaded at runtime is compatible with the version specified during compile configuration.
遂将cudnn卸载:
sudo rm -rf /usr/local/cuda/include/cudnn.h
sudo rm -rf /usr/local/cuda/lib64/libcudnn*
将cudnn卸载后,重新安装cudnn
转自:https://blog.csdn.net/u010480194/article/details/54287727