Tensorflow:如何在张量板上查看检查点?

Tensorflow: how to view checkpoint in tensorboard?

假设我有包含以下内容的检查点:

checkpoint
├── model.ckpt-240000.data-00000-of-00001
├── model.ckpt-240000.index
└── model.ckpt-240000.meta

是否可以在tensorboard中查看检查点的内容,或者只能转换为.pb格式?

看起来可以这样做:

import tensorflow as tf

g = tf.Graph()

with g.as_default() as g:
    tf.train.import_meta_graph('./checkpoint/model.ckpt-240000.meta')

with tf.Session(graph=g) as sess:
    file_writer = tf.summary.FileWriter(logdir='checkpoint_log_dir/faceboxes', graph=g)

然后tensorboard --logdir checkpoint_log_dir/faceboxes/