一、问题

先说问题,我需要配置百度的EasyDL本地gpu通用SDK需要调用paddlepaddle-gpu。在我配置好cuda-9.2以及cudnn7的环境后,安装默认的paddlepaddle-gpu(版本2.0.0),引入paddlepaddle-gpu后,报错。

Cuda error(35), CUDA driver version is insufficient for CUDA runtime version

二、解决

如果你是出现跟我类似的问题,可以按照下面的顺序去排查。

1、确认cuda以及cudnn是安装成功

我需要的是cuda9以及cudnn7的环境。
先检查cuda,控制台输入

nvcc -V

如果一下输出,说明安装成功
在这里插入图片描述
然后检查cudnn是否安装,在控制台输入

cat /usr/local/cuda-9.2/include/cudnn.h | grep CUDNN_MAJOR -A 2

在这里插入图片描述
输出版本说明,安装正确。

2、检查cuda与NVIDIA 驱动器版本是否符合

控制台输入

nvidia-smi

在这里插入图片描述
对照下表,查看你的驱动器是否需要更新
在这里插入图片描述

3、安装正确的paddlepaddle-gpu版本

如果上述排查均没有问题,那么就是paddlepaddle-gpu版本出了问题。

(from versions: 1.2.0.post85, 1.2.0.post87, 1.2.0.post97, 1.2.1.post85, 1.2.1.post87, 
1.2.1.post97, 1.3.0.post85, 1.3.0.post87, 1.3.0.post97, 1.3.1.post85, 1.3.1.post87, 
1.3.1.post97, 1.3.2.post85, 1.3.2.post87, 1.3.2.post97, 1.4.0.post85, 1.4.0.post87, 
1.4.0.post97, 1.4.1.post85, 1.4.1.post87, 1.4.1.post97, 1.5.0.post87, 1.5.0.post97, 
1.5.0.post107, 1.5.1.post87, 1.5.1.post97, 1.5.1.post107, 1.5.2.post87, 1.5.2.post97, 
1.5.2.post107, 1.6.0rc0.post107, 1.6.0.post97, 1.6.0.post107, 1.6.1.post97, 
1.6.1.post107, 1.6.2.post97, 1.6.2.post107, 1.6.3.post97, 1.6.3.post107, 1.7.0.post97, 
1.7.0.post107, 1.7.1.post97, 1.7.1.post107, 1.7.2.post97, 1.7.2.post107, 1.8.0.post97, 
1.8.0.post107, 1.8.1.post97, 1.8.1.post107, 1.8.2.post97, 1.8.2.post107, 1.8.3.post97, 
1.8.3.post107, 1.8.4.post97, 1.8.4.post107, 1.8.5.post97, 1.8.5.post107, 2.0.0a0, 2.0.0b0, 2.0.0rc0, 2.0.0rc1, 2.0.0)

版本号后面跟着的post**数字按顺序代表了你的cuda以及cudnn的版本。
比如我的环境是cuda9cudnn7那么我应该选择以post97结尾的版本。
我按照文档安装了1.2.0post97版本,运行后还是有错误,就选择了最新的1.8.5post97
至此,问题解决。

Logo

有“AI”的1024 = 2048,欢迎大家加入2048 AI社区

更多推荐