tensorflow报错
共计 712 words,预计阅读时间 4 min

tensorflow报错UnknownError: Failed to get convolution algorithm. This is probably because cuDNN failed to initialize, so try looking to see if a warning log message was printed above.


问题 在运行tensorflow时出现报错信息UnknownError: Failed to get convolution algorithm. This is probably because cuDNN failed to initialize, so try looking to see if a warning log message was printed above.

解决方法 方法一: 在项目中添加

import os
os.environ['CUDA_VISIBLE_DEVICES'] = '/gpu:0'

可以正常运行,但此时没有使用GPU,而是使用的CPU进行运算

方法二: 重新安装cuDNN,在官网上下载对应的cuDNN版本,解压,将文件夹内的所有文件复制到CUDA安装目录C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0下 再次运行可正常使用GPU进行运算

最长公共子序列
anaconda导入模块报错
copyright  2024   @ Cardy
Powered by Astro | Theme Cloud