fixed none name

This commit is contained in:
William Falcon 2019-08-07 07:25:20 -04:00
parent a895bf1b71
commit 82d63a9677
1 changed files with 1 additions and 1 deletions

View File

@ -257,7 +257,7 @@ class Trainer(TrainerIO):
for name in checkpoints:
if '.ckpt' in name:
epoch = name.split('epoch_')[1]
epoch = re.sub('[^0-9]', '' ,epoch)
epoch = int(re.sub('[^0-9]', '' ,epoch))
if epoch > last_epoch:
last_epoch = epoch