使用函数tf.train.slice_input_producer读取文件时,
input_queue = tf.train.slice_input_producer(
[flist], shuffle=self.shuffle,
seed=0123, num_epochs=self.num_epochs)
input_file = tf.read_file(input_queue)
出现错误:
ValueError: Shape must be rank 0 but is rank 1 for ‘train_data/ReadFile’ (op: ‘ReadFile’) with input shapes: [1].
这是因为tf.train.slice_input_producer()输出input_queue为list,而输入为:
filename: A `Tensor` of type `