W3cubDocs

/TensorFlow 2.9

tf.data.experimental.DistributeOptions

Represents options for distributed data processing.

You can set the distribution options of a dataset through the experimental_distribute property of tf.data.Options; the property is an instance of tf.data.experimental.DistributeOptions.

options = tf.data.Options()
options.experimental_distribute.auto_shard_policy = AutoShardPolicy.OFF
dataset = dataset.with_options(options)
Attributes
auto_shard_policy The type of sharding to use. See tf.data.experimental.AutoShardPolicy for additional information.
num_devices The number of devices attached to this input pipeline. This will be automatically set by MultiDeviceIterator.

Methods

__eq__

View source

Return self==value.

__ne__

View source

Return self!=value.

© 2022 The TensorFlow Authors. All rights reserved.
Licensed under the Creative Commons Attribution License 4.0.
Code samples licensed under the Apache 2.0 License.
https://www.tensorflow.org/versions/r2.9/api_docs/python/tf/data/experimental/DistributeOptions