'''
with tf.Session() as sess: # Start Tensorflow Session
display_step = 100
patience = 5
load = input("\nLoad checkpoint? y/n: ")
print("")
saver = tf.train.Saver()
#opt = tf.keras.optimizers.Adam(0.1)
#ckpt = tf.train.Checkpoint(step=tf.Variable(1), optimizer=opt, net=net)
if load.lower() == 'y':
print('Loading pre-trained weights for the model...')
saver.restore(sess, '/content/drive/My Drive/Colab Notebooks/Data/release/Model_Backup/Seq2seq_summarization.ckpt')
sess.run(tf.global_variables())
sess.run(tf.tables_initializer())
'''
所以我正在使用Tensorflow 2.0,并且在运行上面的代码时,错误抛出如下:
ValueError:传递的save_path不是有效的检查点:/ content / drive /我的驱动器/ Colab Notebooks / Data / release / Model_Backup / Seq2seq_summarization.ckpt