adding support for interrupt signals

This commit is contained in:
William Falcon 2019-06-14 09:46:41 -04:00
parent edf03063a1
commit 88ff860c90
1 changed files with 3 additions and 0 deletions

View File

@ -100,6 +100,9 @@ class TrainerIO(object):
# PRIVATE OPS # PRIVATE OPS
# ---------------------------------- # ----------------------------------
def hpc_save(self, folderpath, experiment): def hpc_save(self, folderpath, experiment):
# make sure the checkpoint folder exists
os.makedirs(folderpath, exist_ok=True)
# save exp to make sure we get all the metrics # save exp to make sure we get all the metrics
experiment.save() experiment.save()