最近,我试着重复在吉突布进行的深度学习实验。然而,每次我运行该实验,我将收到以下错误信息。
2018-08-27 09:32:16.827025: E T:\src\github\tensorflow\tensorflow\stream_executor\cuda\cuda_dnn.cc:332] could not create cudnn handle: CUDNN_STATUS_ALLOC_FAILED在这种情况下,我将Tensorflow中的会话设置为以下内容。
sess = tf.Session(config=tf.ConfigProto(allow_soft_placement=True, log_device_placement=False))如果我试图限制GPU内存如下,我发现我没有足够的内存来运行我的模型。
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=0.333)
sess = tf.Session(config=tf.ConfigProto(gpu_options=gpu_options))有关我的GPU的信息如下。我不知道问题在哪里,我曾多次遇到这样的问题。谢谢你的贡献!
2018-08-27 09:31:45.966248: IT:\src\github\tensorflow\tensorflow\core\platform\cpu_feature_guard.cc:141] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2
2018-08-27 09:31:46.199314: I T:\src\github\tensorflow\tensorflow\core\common_runtime\gpu\gpu_device.cc:1392] Found device 0 with properties:
name: GeForce GTX 1080 Ti major: 6 minor: 1 memoryClockRate(GHz): 1.683
pciBusID: 0000:01:00.0
totalMemory: 11.00GiB freeMemory: 9.09GiB发布于 2018-08-27 02:58:06
肖恩。根据文档的说法。错误状态CUDNN_STATUS_ALLOC_FAILED是主机内存而不是设备内存的问题。也检查一下你的内存。
发布于 2020-12-22 16:24:32
在我的例子中,这是由于同时使用GPU运行2个TensorFlow进程(由您或其他用户):https://stackoverflow.com/a/53707323/10993413
来源:https://forums.developer.nvidia.com/t/could-not-create-cudnn-handle-cudnn-status-alloc-failed/108261
https://stackoverflow.com/questions/52031619
复制相似问题