2
我使用tensorflow检查点使用下面的代码,每10个时代后:Tensorflow关卡模式越来越删除
checkpoint_dir = os.path.abspath(os.path.join(out_dir, "checkpoints"))
checkpoint_prefix = os.path.join(checkpoint_dir, "model")
...
if current_step % checkpoint_every == 0:
path = saver.save(sess, checkpoint_prefix, global_step=current_step)
print("Saved model checkpoint to {}\n".format(path))
的问题是,随着越来越生成新的文件,前5个的模型文件得到自动删除。
谢谢@Gregory。我错过了那部分。 – Nitin