tensorflow.python.framework.errors_impl.OutOfRangeError: FIFOQueue
原创文章,请勿转载哦~!!
觉得有用的话,欢迎一起讨论相互学习~Follow Me
今天遇到了这个问题
tensorflow.python.framework.errors_impl.OutOfRangeError:
FIFOQueue '_0_input_producer' is closed and has insufficient elements (requested 1, current size 0)
[[Node: ReaderReadV2 = ReaderReadV2[_device="/job:localhost/replica:0/task:0/cpu:0"](WholeFileReaderV2, input_producer)]]
经过查找资料:local变量没有初始化.
初始化变量语句改成:
init_op = tf.group(tf.global_variables_initializer(), tf.local_variables_initializer())
sess.run(init_op)