其他分享
首页 > 其他分享> > failed to create cublas handle: CUBLAS_STATUS_ALLOC_FAILED 错误解决方法

failed to create cublas handle: CUBLAS_STATUS_ALLOC_FAILED 错误解决方法

作者:互联网

解决:

 

config = tf.ConfigProto()
config.gpu_options.allow_growth = True
session = tf.Session(config=config, ...)

 

还有这样的(固定分配):

gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=0.333)
sess = tf.Session(config=tf.ConfigProto(gpu_options=gpu_options))

记得关闭其他用显存的程序哦!。。。

 

标签:STATUS,ALLOC,handle,Session,ConfigProto,tf,gpu,config,options
来源: https://www.cnblogs.com/gaofighting/p/11059752.html