updates
This commit is contained in:
parent
d378e32803
commit
8944db80b9
|
@ -159,8 +159,8 @@ class YOLOLayer(nn.Module):
|
|||
lh = 5 * MSELoss(h[mask], th[mask])
|
||||
lconf = 1.5 * BCEWithLogitsLoss(pred_conf[mask], mask[mask].float())
|
||||
|
||||
# lcls = CrossEntropyLoss(pred_cls[mask], torch.argmax(tcls, 1))
|
||||
lcls = 10 * BCEWithLogitsLoss(pred_cls[mask], tcls.float())
|
||||
lcls = 0.5 * CrossEntropyLoss(pred_cls[mask], torch.argmax(tcls, 1))
|
||||
# lcls = BCEWithLogitsLoss(pred_cls[mask], tcls.float())
|
||||
else:
|
||||
lx, ly, lw, lh, lcls, lconf = FT([0]), FT([0]), FT([0]), FT([0]), FT([0]), FT([0])
|
||||
|
||||
|
|
Loading…
Reference in New Issue