From 165068cea8cf2247183d07833dd1c39461fcff67 Mon Sep 17 00:00:00 2001 From: WuHaobo Date: Mon, 27 Apr 2020 21:33:25 +0800 Subject: [PATCH] polish for mixup --- tools/program.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/program.py b/tools/program.py index d7ccce7f..9afe718a 100644 --- a/tools/program.py +++ b/tools/program.py @@ -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 -- GitLab