polish for mixup

pull/86/head
WuHaobo 2020-04-27 21:33:25 +08:00
parent 38728f638b
commit 165068cea8
1 changed files with 2 additions and 3 deletions

View File

@ -398,7 +398,6 @@ def run(dataloader, exe, program, fetchs, epoch=0, mode='train'):
else:
logger.info("END epoch:{:<3d} {:s} {:s}s".format(epoch, mode, end_str))
# save the best model
# return top1_acc in order to save the best model
if mode == 'valid':
top1_acc = fetchs["top1"][1].avg
return top1_acc
return fetchs["top1"][1].avg