run_freeze_graph.py 文件源码

python
阅读 35 收藏 0 点赞 0 评论 0

项目:convolutional-pose-machines-tensorflow 作者: timctho 项目源码 文件源码
def load_graph(frozen_graph_filename):
    # We load the protobuf file from the disk and parse it to retrieve the
    # unserialized graph_def
    with tf.gfile.GFile(frozen_graph_filename, "rb") as f:
        graph_def = tf.GraphDef()
        graph_def.ParseFromString(f.read())
    with tf.Graph().as_default() as graph:
        tf.import_graph_def(
            graph_def,
            input_map=None,
            return_elements=None,
            name="prefix",
            op_dict=None,
            producer_op_list=None
        )
    return graph
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号