1 op { 2 graph_op_name: "QueueDequeueUpToV2" 3 endpoint { 4 name: "QueueDequeueUpTo" 5 } 6 in_arg { 7 name: "handle" 8 description: <<END 9 The handle to a queue. 10 END 11 } 12 in_arg { 13 name: "n" 14 description: <<END 15 The number of tuples to dequeue. 16 END 17 } 18 out_arg { 19 name: "components" 20 description: <<END 21 One or more tensors that were dequeued as a tuple. 22 END 23 } 24 attr { 25 name: "component_types" 26 description: <<END 27 The type of each component in a tuple. 28 END 29 } 30 attr { 31 name: "timeout_ms" 32 description: <<END 33 If the queue has fewer than n elements, this operation 34 will block for up to timeout_ms milliseconds. 35 Note: This option is not supported yet. 36 END 37 } 38 summary: "Dequeues `n` tuples of one or more tensors from the given queue." 39 description: <<END 40 This operation is not supported by all queues. If a queue does not support 41 DequeueUpTo, then an Unimplemented error is returned. 42 43 If the queue is closed and there are more than 0 but less than `n` 44 elements remaining, then instead of returning an OutOfRange error like 45 QueueDequeueMany, less than `n` elements are returned immediately. If 46 the queue is closed and there are 0 elements left in the queue, then 47 an OutOfRange error is returned just like in QueueDequeueMany. 48 Otherwise the behavior is identical to QueueDequeueMany: 49 50 This operation concatenates queue-element component tensors along the 51 0th dimension to make a single component tensor. All of the components 52 in the dequeued tuple will have size n in the 0th dimension. 53 54 This operation has `k` outputs, where `k` is the number of components in 55 the tuples stored in the given queue, and output `i` is the ith 56 component of the dequeued tuple. 57 END 58 } 59