tf.train.export_meta_graph(filename=None, meta_info_def=None, graph_def=None, saver_def=None, collection_list=None, as_text=False, graph=None, export_scope=None, clear_devices=False, **kwargs)
See the guide: Variables > Exporting and Importing Meta Graphs
MetaGraphDef proto. Optionally writes it to filename.
This function exports the graph, saver, and collection objects into
MetaGraphDef protocol buffer with the intention of it being imported
at a later time or location to restart training, run inference, or be
filename: Optional filename including the path for writing the generated
collection_list: List of string keys to collect.
True, writes the
MetaGraphDefas an ASCII proto.
Graphto import into. If
None, use the default graph.
string. Name scope under which to extract the subgraph. The scope name will be striped from the node definitions for easy import later into new name scopes. If
None, the whole graph is exported. graph_def and export_scope cannot both be specified.
clear_devices: Whether or not to clear the device field for an
Tensorduring export. **kwargs: Optional keyed arguments.
ValueError: When the
GraphDefis larger than 2GB.