class_docstr: SavedModelHandler helps using SavedModel disk format.
  
  Note: This is a lower level interface than most users need. See SavedModel
  Builder/Loader API for an higher-level API centered around exporting and
  loading Sessions.
  
  A SavedModel disk format represents a collection of Graphs. To allow these
  graphs to be easy to manipulate, SavedModel extends Graphs with tags and
  signatures. Additionally it packages graphs, assets and variable checkpoints
  into an hermetic directory that can be moved around.
  
  This class hides the implementation details of SavedModels, in particular
  related with assets and signatures.
  
  SavedModelHandler deals with assets by:
    - Only supporting asset files as constant ops added to ASSET_FILEPATHS
      collection.
    - Creating a ASSETS_KEY collection only when writing meta_graphs to disk so
      they are never visible to user.
    - Baking the ASSETS_KEY collection in the graphs when loading from disk as
      to hide that the assets point to the packaged assets.
  
  SavedModelHandler deals with signatures by:
    - Providing `add_signature` API that allows to declare signatures directly
      on a graph.
    - That API is supported by a collection that is not serialized, but instead
      is converted into the right fields of MetaGraphDef when writing and
      loading a SavedModel from disk.
docstr: Exports to SavedModel directory.
  
  Args:
    path: path where to export the SavedModel to.
    variables_saver: lambda that receives a directory path where to
      export checkpoints of variables.
docstr_tok: ["Exports","to","SavedModel","directory",".","Args",":","path",":","path","where","to","export","the","SavedModel","to",".","variables_saver",":","lambda","that","receives","a","directory","path","where","to","export","checkpoints","of","variables","."]
code: def export(self, path, variables_saver=None):
      """Exports to SavedModel directory.
  
      Args:
        path: path where to export the SavedModel to.
        variables_saver: lambda that receives a directory path where to
          export checkpoints of variables.
      """
      # Operate on a copy of self._proto since it needs to be modified.
      proto = saved_model_pb2.SavedModel()
      proto.CopyFrom(self._proto)
      assets_map = _make_assets_key_collection(proto, path)
  
      self._save_all_assets(path, assets_map)
      self._save_variables(path, variables_saver)
      self._save_proto(path, proto)
  
imports: import collections
  import os
  import re
  from absl import logging
  import tensorflow
  from tensorflow_hub import module_attachment_pb2
  from tensorflow_hub import tf_utils
  from google.protobuf import message
  from tensorflow.core.protobuf import meta_graph_pb2
  from tensorflow.core.protobuf import saved_model_pb2
label_desc: Use image node_id 8 for calling the SavedModelHandler obj's underlying member method code with example usage: obj.export(path, variables_saver) without return types