运行程序报错如下:
tensorflow.python.framework.errors_impl.NotFoundError: No algorithm worked! [Op:Conv2D]
问题出现的原因:批次跑的数据过多,所以要防止批次数据跑的太多爆内存,在文件开头写入一下代码。
physical_devices = tf.config.experimental.list_physical_devices('GPU')
assert len(physical_devices) > 0, "Not enough GPU hardware devices available"
tf.config.experimental.set_memory_growth(physical_devices[0], True)