tf.test.Benchmark

View source on GitHub

Abstract class that provides helpers for TensorFlow benchmarks.

tf.test.Benchmark()

Methods

evaluate

View source

evaluate(
    tensors
)

Evaluates tensors and returns numpy values.

Args:

Returns:

tensors numpy values.

is_abstract

View source

@classmethod
is_abstract()

report_benchmark

View source

report_benchmark(
    iters=None, cpu_time=None, wall_time=None, throughput=None, extras=None,
    name=None, metrics=None
)

Report a benchmark.

Args:

run_op_benchmark

View source

run_op_benchmark(
    sess, op_or_tensor, feed_dict=None, burn_iters=2, min_iters=10,
    store_trace=False, store_memory_usage=True, name=None, extras=None, mbs=0
)

Run an op or tensor in the given session. Report the results.

Args:

Returns:

A dict containing the key-value pairs that were passed to report_benchmark. If store_trace option is used, then full_chrome_trace_format will be included in return dictionary even though it is not passed to report_benchmark with extras.