It is required to introduce a pair [image, label] , which, yes, it is one pair. tf.train.batch , however, creates an internal queue. Threads num_threads will accumulate pairs in the queue until capacity reached.
images, label_batch are actually dequeue operations.
Remember that you define a computational graph, so the [image, label] pair is two nodes of the graph, and a different real pair of image, label your training set will go through these nodes. Thus, tf.train.batch can capture a stream of images and tags and fill the queue.
nessuno
source share