Poisson and Bernoulli losses
| data | loss f(x, m) |
∂f/∂m |
|---|---|---|
| real, constant spread | (x − m)² |
−2(x − m) |
| counts (Poisson) | m − x log m |
1 − x/m |
| binary (Bernoulli, odds link) | log(m + 1) − x log m |
1/(m + 1) − x/m |
Poisson keeps every prediction positive, and nothing enforces it. The log m term is undefined at zero and enormous just above it, so predicting nearly zero where something was observed costs an unbounded amount. The bound at EPS is only a numerical guard. At x = 0 there is no barrier: a genuinely empty cell may be predicted empty, for free.
Bernoulli models the odds. The model value m is the odds, so m / (1 + m) is a probability by construction.