tf.compat.v1.train.shuffle_batch_join

Create batches by randomly shuffling tensors. (deprecated)

The tensors_list argument is a list of tuples of tensors, or a list of dictionaries of tensors. Each element in the list is treated similarly to the tensors argument of tf.compat.v1.train.shuffle_batch().

This version enqueues a different list of tensors in different threads. It adds the following to the current Graph:

  • A shuffling queue into which tensors from tensors_list are enqueued.
  • A dequeue_many operation to create batches from the queue.
  • A QueueRunner to QUEUE_RUNNER collection, to enqueue the tensors from tensors_list.

len(tensors_list) threads will be started, with thread i enqueuing the tensors from tensors_list[i]. tensors_list[i1][j] must match tensors_list[i2][j] in type and shape, except in the first dimension if enqueue_many is true.

If enqueue_many is False, each tensors_list[i] is assumed to represent a single example. An input tensor with shape [x, y, z] will be output as a tensor with shape [batch_size, x, y, z].

If enqueue_many is True, tensors_list[i]