MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / IteratorHandleOp

Method IteratorHandleOp

tensorflow/core/kernels/data/iterator_ops.cc:267–272  ·  view source on GitHub ↗

Note that IteratorHandleOp holds a reference to the resource it creates. If cleaning up resources with DestroyResourceOp is important, consider creating resource containers with AnonymousIteratorHandleOp instead.

Source from the content-addressed store, hash-verified

265// cleaning up resources with DestroyResourceOp is important, consider creating
266// resource containers with AnonymousIteratorHandleOp instead.
267IteratorHandleOp::IteratorHandleOp(OpKernelConstruction* ctx)
268 : OpKernel(ctx), graph_def_version_(ctx->graph_def_version()) {
269 OP_REQUIRES_OK(ctx, ctx->GetAttr(kOutputTypes, &output_dtypes_));
270 OP_REQUIRES_OK(ctx, ctx->GetAttr(kOutputShapes, &output_shapes_));
271 OP_REQUIRES_OK(ctx, ctx->GetAttr("shared_name", &name_));
272}
273
274// The resource is deleted from the resource manager only when it is private
275// to kernel. Ideally the resource should be deleted when it is no longer held

Callers

nothing calls this directly

Calls 2

graph_def_versionMethod · 0.45
GetAttrMethod · 0.45

Tested by

no test coverage detected