|TensorFlow 2 version||View source on GitHub|
Loads the model from a SavedModel as specified by tags. (deprecated)
tf.saved_model.load( sess, tags, export_dir, import_scope=None, **saver_kwargs )
sess: The TensorFlow session to restore the variables.
tags: Set of string tags to identify the required MetaGraphDef. These should correspond to the tags used when saving the variables using the SavedModel
export_dir: Directory in which the SavedModel protocol buffer and variables to be loaded are located.
string-- if specified, prepend this string followed by '/' to all loaded tensor names. This scope is applied to tensor instances loaded into the passed session, but it is not written through to the static
MetaGraphDefprotocol buffer that is returned.
**saver_kwargs: Optional keyword arguments passed through to Saver.
MetaGraphDef protocol buffer loaded in the provided session. This
can be used to further extract signature-defs, collection-defs, etc.
RuntimeError: MetaGraphDef associated with the tags cannot be found.