Che*_*rry 4 python tensorflow tensorboard
我只有一个graph.pbtxt文件。我想在tensorboard 中查看图表。但我不知道如何做到这一点。我必须编写任何 python 脚本还是可以从终端本身完成?请帮助我了解所涉及的步骤。
您可以从您的保存.pb文件.pbtxttf.train.write_graph
from google.protobuf import text_format
with open('graph.pbtxt') as f:
text_graph = f.read()
graph_def = text_format.Parse(text_graph, tf.GraphDef())
tf.train.write_graph(graph_def, path, 'graph.pb', as_text=False)
Run Code Online (Sandbox Code Playgroud)
然后你就可以加载它了tf.Session。看看这个要点
https://gist.github.com/jubjamie/2eec49ca1e4f58c5310d72918d991ef6
| 归档时间: |
|
| 查看次数: |
4201 次 |
| 最近记录: |