Skip to content
Snippets Groups Projects
Commit c89fa760 authored by tomrink's avatar tomrink
Browse files

snapshot...

parent 3ece8eb4
Branches
No related tags found
No related merge requests found
......@@ -841,11 +841,14 @@ class IcingIntensityFCN:
if ckpt_dir is None:
if not os.path.exists(modeldir):
os.mkdir(modeldir)
ckpt = tf.train.Checkpoint(step=tf.Variable(1), model=self.model, model_weights=model_weights, averaged_weights=ema_model_weights)
# ckpt = tf.train.Checkpoint(step=tf.Variable(1), model=self.model, model_weights=model_weights, averaged_weights=ema_model_weights)
# ckpt_manager = tf.train.CheckpointManager(ckpt, modeldir, max_to_keep=3)
ckpt = tf.train.Checkpoint(step=tf.Variable(1), model=self.model)
ckpt_manager = tf.train.CheckpointManager(ckpt, modeldir, max_to_keep=3)
else:
ckpt = tf.train.Checkpoint(step=tf.Variable(1), model=self.model)
ckpt_manager = tf.train.CheckpointManager(ckpt, ckpt_dir, max_to_keep=3)
ckpt.restore(ckpt_manager.latest_checkpoint)
self.writer_train = tf.summary.create_file_writer(os.path.join(logdir, 'plot_train'))
self.writer_valid = tf.summary.create_file_writer(os.path.join(logdir, 'plot_valid'))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment