class_docstr: A hook to capture metadata for a single step.
  Useful for performance debugging. It performs a full trace and saves
  run_metadata and Chrome timeline information to a file.
  
  Args:
    step: The step number to trace. The hook is only enable for this step.
code: def before_run(self, _run_context):
      if not self.is_chief or self._done:
          return
      if not self._active:
          return tf.train.SessionRunArgs(self._global_step)
      else:
          tf.logging.info("Performing full trace on next step.")
          run_options = tf.RunOptions(
              trace_level=tf.RunOptions.FULL_TRACE
          )  # pylint: disable=E1101
          return tf.train.SessionRunArgs(
              self._global_step, options=run_options
          )
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  from __future__ import unicode_literals
  import abc
  import os
  import numpy
  import six
  import yaml
  import tensorflow
  from tensorflow.python.training.basic_session_run_hooks import SecondOrStepTimer
  from tensorflow.python.training import session_manager
  from tensorflow.python.client import timeline
  from tensorflow import gfile
  from seq2seq.configurable import Configurable, abstractstaticmethod
  from seq2seq import graph_utils, global_vars
label_desc: Use image node_id 4 for calling the MetadataCaptureHook obj's underlying member method code with example usage: obj.before_run(_run_context) and returns: tf, tf