Tensorflow: What are the "output_node_names" for freeze_graph.py in the model_with_buckets model?

WS91 picture WS91 · Aug 15, 2016 · Viewed 11k times · Source

I trained a tf.nn.seq2seq.model_with_buckets with seq2seq = tf.nn.seq2seq.embedding_attention_seq2seq very similar to the example in the Tensorflow Tutorial.

Now I would like to freeze the graph using freeze_graph.py. How can I find the "output_node_names" in my model?

Answer

Peter Hawkins picture Peter Hawkins · Aug 15, 2016

You can choose names for the nodes in your model by passing the optional name="myname" argument to pretty much any Tensorflow operator that builds a node. Tensorflow will pick names for graph nodes automatically if you don't specify them, but if you want to identify those nodes to a tool like freeze_graph.py, then it's best to choose the names yourself. Those names are what you pass to output_node_names.