Medical-SAM2 icon indicating copy to clipboard operation
Medical-SAM2 copied to clipboard

About the pos weight in BCE Loss.

Open Yaostars opened this issue 1 year ago • 0 comments

As a new learner, I wonder about the pos weight you use in your bce loss. Does "*2" have a special influence? Thank you very much.

pos_weight = torch.ones([1]).cuda(device=device)*2 criterions = nn.ModuleList([nn.BCEWithLogitsLoss(pos_weight=pos_weight), nn.L1Loss(), SCRLoss(), HCRLoss()]).to(device)

Yaostars avatar Dec 27 '24 09:12 Yaostars