📜  使用来自检查点 tensorflow 的模型 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:42.652000             🧑  作者: Mango

代码示例3
with tf.Session() as sess:    
    saver = tf.train.import_meta_graph('my-model-1000.meta')
    saver.restore(sess,tf.train.latest_checkpoint('./'))
    print(sess.run('w1:0'))
##Model has been restored. Above statement will print the saved value of w1.