TensorFlow 1 version View source on GitHub

Class StatsOptions

Represents options for collecting dataset stats using StatsAggregator.

You can set the stats options of a dataset through the experimental_stats property of; the property is an instance of For example, to collect latency stats on all dataset edges, use the following pattern:

aggregator =

options =
options.experimental_stats.aggregator = aggregator
options.experimental_stats.latency_all_edges = True
dataset = dataset.with_options(options)


View source


Initialize self. See help(type(self)) for accurate signature.



Associates the given statistics aggregator with the dataset pipeline.


Prefix for the statistics recorded as counter.


Whether to add latency measurements on all edges. Defaults to False.


Prefix to prepend all statistics recorded for the input dataset with.



View source


Return self==value.


View source


Return self!=value.