Creates an iterator for enumerating the elements of this dataset.
Creates an iterator for enumerating the elements of this dataset.
make_iterator_one_shot(dataset)
make_iterator_initializable(dataset, shared_name = NULL)
make_iterator_from_structure(output_types, output_shapes = NULL,
shared_name = NULL)
make_iterator_from_string_handle(string_handle, output_types,
output_shapes = NULL)
Arguments
dataset | A dataset |
shared_name | (Optional) If non-empty, the returned iterator will be shared under the given name across multiple sessions that share the same devices (e.g. when using a remote server). |
output_types | A nested structure of tf$DType objects corresponding to each component of an element of this iterator. |
output_shapes | (Optional) A nested structure of tf$TensorShape objects corresponding to each component of an element of this dataset. If omitted, each component will have an unconstrainted shape. |
string_handle | A scalar tensor of type string that evaluates
to a handle produced by the |
Value
An Iterator over the elements of this dataset.
Initialization
For make_iterator_one_shot()
, the returned
iterator will be initialized automatically. A "one-shot" iterator does not
currently support re-initialization.
For make_iterator_initializable()
,
the returned iterator will be in an uninitialized state, and you must run
the object returned from iterator_initializer()
before using it.
For make_iterator_from_structure()
, the returned iterator is not bound
to a particular dataset, and it has no initializer. To initialize the
iterator, run the operation returned by iterator_make_initializer()
.
See also
Other iterator functions: iterator_get_next
,
iterator_initializer
,
iterator_make_initializer
,
iterator_string_handle