From a76e8e3ee8652e473f605975955741246d023206 Mon Sep 17 00:00:00 2001 From: Glenn Jocher Date: Mon, 1 Apr 2019 18:43:21 +0200 Subject: [PATCH] updates --- utils/utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/utils/utils.py b/utils/utils.py index 13d1a3cd..0d810685 100755 --- a/utils/utils.py +++ b/utils/utils.py @@ -267,8 +267,8 @@ def compute_loss(p, targets): # predictions, targets pi = pi0[b, a, gj, gi] # predictions closest to anchors tconf[b, a, gj, gi] = 1 # conf - lxy += (k * 16) * MSE(torch.sigmoid(pi[..., 0:2]), txy[i]) # xy loss - lwh += (k * 8) * MSE(pi[..., 2:4], twh[i]) # wh loss + lxy += (k * 8) * MSE(torch.sigmoid(pi[..., 0:2]), txy[i]) # xy loss + lwh += (k * 4) * MSE(pi[..., 2:4], twh[i]) # wh loss lcls += (k * 1) * CE(pi[..., 5:], tcls[i]) # class_conf loss # pos_weight = FT([gp[i] / min(gp) * 4.])