princeton-vl / CornerNet

BSD 3-Clause "New" or "Revised" License
2.36k stars 475 forks source link

function _sigmoid() question #101

Open annzheng opened 5 years ago

annzheng commented 5 years ago

Hi, I found in function _sigmoid(), you clamp the value between (1e-4, 1-1e-4) after sigmoid, why need to do this? Here is the code: def _sigmoid(x): x = torch.clamp(x.sigmoid_(), min=1e-4, max=1-1e-4) return x

heilaw commented 5 years ago

We did it to make the training more stable.

developer0hye commented 2 years ago

Hi @heilaw!

How does it make the training more stable?