Skip to content
Snippets Groups Projects
Commit 236447ec authored by Daniel CARRON's avatar Daniel CARRON :b:
Browse files

[trainer] Hardcode name of loss to monitor

parent ae55d184
No related branches found
No related tags found
1 merge request!38Replace sampler balancing by loss balancing
Pipeline #86794 passed
......@@ -93,8 +93,6 @@ def run(
main_pid=os.getpid(),
)
monitor_key = "loss/validation"
# This checkpointer will operate at the end of every validation epoch
# (which happens at each checkpoint period), it will then save the lowest
# validation loss model observed. It will also save the last trained model
......@@ -102,7 +100,7 @@ def run(
dirpath=output_folder,
filename=CHECKPOINT_ALIASES["best"],
save_last=True, # will (re)create the last trained model, at every iteration
monitor=monitor_key,
monitor="loss/validation",
mode="min",
save_on_train_epoch_end=True,
every_n_epochs=validation_period, # frequency at which it checks the "monitor"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment