code: def main(_argv):
      """Main functions. Runs all anaylses."""
      # pylint: disable=W0212
      tfprof_logger._merge_default_with_oplog = merge_default_with_oplog
  
      FLAGS.model_dir = os.path.abspath(
          os.path.expanduser(FLAGS.model_dir)
      )
      output_dir = os.path.join(FLAGS.model_dir, "profile")
      gfile.MakeDirs(output_dir)
  
      run_meta, graph, op_log = load_metadata(FLAGS.model_dir)
  
      param_arguments = [
          param_analysis_options(output_dir),
          micro_anaylsis_options(output_dir),
          flops_analysis_options(output_dir),
          device_analysis_options(output_dir),
      ]
  
      for tfprof_cmd, params in param_arguments:
          model_analyzer.print_model_analysis(
              graph=graph,
              run_meta=run_meta,
              op_log=op_log,
              tfprof_cmd=tfprof_cmd,
              tfprof_options=params,
          )
  
          if params["dump_to_file"] != "":
              print("Wrote {}".format(params["dump_to_file"]))
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  from __future__ import unicode_literals
  import os
  import six
  from google.protobuf import text_format
  import tensorflow
  from tensorflow.contrib.tfprof import model_analyzer
  from tensorflow.contrib.tfprof.python.tools.tfprof import tfprof_logger
  from tensorflow import gfile
  from tensorflow.tools.tfprof import tfprof_log_pb2
  from tensorflow.python.framework import op_def_registry
  from tensorflow.python.framework.ops import RegisterShape
  from tensorflow.python.framework import common_shapes
  from seq2seq.decoders.attention import att_sum_bahdanau, att_sum_dot
label_desc: Use image node_id 8 for calling a global function with example usage: main(_argv) without return types