From 4fe9c90514c22e815281ab2275c920dbe365f6cd Mon Sep 17 00:00:00 2001 From: Glenn Jocher Date: Fri, 3 Jan 2020 11:53:02 -0800 Subject: [PATCH] updates --- train.py | 2 +- utils/utils.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/train.py b/train.py index eda88c23..c6ad9048 100644 --- a/train.py +++ b/train.py @@ -446,7 +446,7 @@ if __name__ == '__main__': mixed_precision = False # scale hyp['obj'] by img_size (evolved at 320) - # hyp['obj'] *= opt.img_size / 320. + hyp['obj'] *= opt.img_size / 320. tb_writer = None if not opt.evolve: # Train normally diff --git a/utils/utils.py b/utils/utils.py index 0ece2b3c..52638c0f 100755 --- a/utils/utils.py +++ b/utils/utils.py @@ -367,7 +367,7 @@ def compute_loss(p, targets, model): # predictions, targets, model tcls, tbox, indices, anchor_vec = build_targets(model, targets) h = model.hyp # hyperparameters arc = model.arc # # (default, uCE, uBCE) detection architectures - red = 'sum' # Loss reduction (sum or mean) + red = 'mean' # Loss reduction (sum or mean) # Define criteria BCEcls = nn.BCEWithLogitsLoss(pos_weight=ft([h['cls_pw']]), reduction=red)