static */
| 86 | |
| 87 | /* static */ |
| 88 | Status FIFOQueue::GetElementComponentFromBatch(const FIFOQueue::Tuple& tuple, |
| 89 | int64 index, int component, |
| 90 | OpKernelContext* ctx, |
| 91 | PersistentTensor* out_tensor) { |
| 92 | TensorShape element_shape(tuple[component].shape()); |
| 93 | element_shape.RemoveDim(0); |
| 94 | Tensor* element_access = nullptr; |
| 95 | TF_RETURN_IF_ERROR(ctx->allocate_persistent( |
| 96 | tuple[component].dtype(), element_shape, out_tensor, &element_access)); |
| 97 | TF_RETURN_IF_ERROR( |
| 98 | batch_util::CopySliceToElement(tuple[component], element_access, index)); |
| 99 | return Status::OK(); |
| 100 | } |
| 101 | |
| 102 | void FIFOQueue::TryEnqueueMany(const Tuple& tuple, OpKernelContext* ctx, |
| 103 | DoneCallback callback) { |
nothing calls this directly
no test coverage detected