code: def export_compact(model_path):
      """Export trained model to use it as a frozen and pruned inference graph in
      mobile applications."""
      pred_config = PredictConfig(
          session_init=SmartInit(model_path),
          model=Model(),
          input_names=["input_img"],
          output_names=["prediction_img"],
      )
      ModelExporter(pred_config).export_compact("/tmp/compact_graph.pb")
  
imports: import argparse
  import cv2
  from tensorpack import tfv1
  from tensorpack import *
  from tensorpack.tfutils.export import ModelExporter
label_desc: Use image node_id 3 for calling a global function with example usage: export_compact(model_path) without return types