code: def get_saved_model_tag_sets(saved_model_dir):
      """Retrieves all the tag-sets available in the SavedModel.
  
      Args:
        saved_model_dir: Directory containing the SavedModel.
  
      Returns:
        List of all tag-sets in the SavedModel, where a tag-set is represented as a
        list of strings.
      """
      saved_model = read_saved_model(saved_model_dir)
      all_tags = []
      for meta_graph_def in saved_model.meta_graphs:
          all_tags.append(list(meta_graph_def.meta_info_def.tags))
      return all_tags
  
file_path: tensorflow-upstream/tensorflow/python/tools/saved_model_utils.py
imports: import os
  from google.protobuf import message
  from google.protobuf import text_format
  from tensorflow.core.protobuf import saved_model_pb2
  from tensorflow.python.lib.io import file_io
  from tensorflow.python.saved_model import constants
  from tensorflow.python.util import compat
label_desc: Use image node_id 2 for calling a global function with example usage: get_saved_model_tag_sets(saved_model_dir) and returns: all_tags