From ef51cdbe7d63485ff63befbafef0e38cb85214c9 Mon Sep 17 00:00:00 2001 From: Desuwa Date: Fri, 26 Nov 2021 18:55:57 -0800 Subject: [PATCH] Fix ETA calculation --- codes/train.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codes/train.py b/codes/train.py index acdd9815..bddf10e8 100644 --- a/codes/train.py +++ b/codes/train.py @@ -240,7 +240,7 @@ def fit(model, opt, dataloaders, steps_states, data_params, loggers): # log def eta(t_iter): # calculate training ETA in hours - return (t_iter * (opt['train']['niter'] - current_step)) / 3600 if t_iter > 0 else 0 + return (t_iter * (opt['train']['niter'] - current_step)) / 3600 / opt['logger']['print_freq'] if t_iter > 0 else 0 if current_step % opt['logger']['print_freq'] == 0 and take_step: # iteration end time