一. 网络模型可视化
import tensorflow as tf
model = 'tflite_graph_300.pb'
graph = tf.get_default_graph()
graph_def = graph.as_graph_def()
graph_def.ParseFromString(tf.gfile.FastGFile(model, 'rb').read())
tf.import_graph_def(graph_def, name='graph')
summaryWriter = tf.summary.FileWriter('log_300/', graph)
执行完上述程序, 将在log_300目录下生成events.out.tfevents.1564989783.amax.
接着,在服务器上执行:
tensorboard --logdir=./log_300
TensorBoard 1.13.1 at http://amax:6006 (Press CTRL+C to quit)
最后,在浏览器上输入命令进行可视化; 并点击Choose File导入tflite_graph_300.pbtxt
http://172.20.36.201:6006