class_docstr: Hook to print out examples per second.
  
  Total time is tracked and then divided by the total number of steps
  to get the average step time and then batch_size is used to determine
  the running average of examples per second. The examples per second for the
  most recent interval is also logged.
docstr: Called before each call to run().
  
  Args:
    run_context: A SessionRunContext object.
  
  Returns:
    A SessionRunArgs object or None if never triggered.
docstr_tok: ["Called","before","each","call","to","run","(",")",".","Args",":","run_context",":","A","SessionRunContext","object",".","Returns",":","A","SessionRunArgs","object","or","None","if","never","triggered","."]
code: def before_run(self, run_context):  # pylint: disable=unused-argument
      """Called before each call to run().
  
      Args:
        run_context: A SessionRunContext object.
  
      Returns:
        A SessionRunArgs object or None if never triggered.
      """
      return tf.estimator.SessionRunArgs(self._global_step_tensor)
  
file_path: autodist/examples/benchmark/utils/logs/hooks.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import tensorflow
  from utils.logs import logger
label_desc: Use image node_id 3 for calling the ExamplesPerSecondHook obj's underlying member method code with example usage: obj.before_run(run_context) and returns: tf