add softmax version to focal_loss#6544
Conversation
DCO Remediation Commit for Qingpeng Li <[email protected]> I, Qingpeng Li <[email protected]>, hereby add my Signed-off-by to this commit: cb5ed04 I, Qingpeng Li <[email protected]>, hereby add my Signed-off-by to this commit: 78eebaf Signed-off-by: Qingpeng Li <[email protected]>
|
thanks @qingpeng9802, it looks good to me, one minor thing is that if we assume |
DCO Remediation Commit for Qingpeng Li <[email protected]> I, Qingpeng Li <[email protected]>, hereby add my Signed-off-by to this commit: 5db9e58 Signed-off-by: Qingpeng Li <[email protected]>
|
/black |
Signed-off-by: monai-bot <[email protected]>
loss: torch.Tensor = torch.where(target>0.5, - (1 - input_ls.exp()).pow(gamma) * input_ls, 0)and input_ls[target>0.5]=0.
loss: torch.Tensor = - (1 - input_ls.exp()).pow(gamma) * input_lsare benchmarked. Both are significantly slower than the original one. It looks like |
|
sure, thanks for looking into these @qingpeng9802! |
Signed-off-by: Qingpeng Li <[email protected]>
|
/black |
Signed-off-by: monai-bot <[email protected]>
|
/build |
Fixes #6510 .
Description
Add softmax version to Focal loss
Types of changes
./runtests.sh -f -u --net --coverage../runtests.sh --quick --unittests --disttests.make htmlcommand in thedocs/folder.