Compute binary cross-entropy loss from true labels and predicted probabilities to monitor training and spot badly calibrated outputs.
p 应裁剪至 (ε,1−ε) 避免 log(0)。
| Item | Formula / Note | Source / Standard |
|---|---|---|
| Definition | cross entropy is the negative weighted log of predicted probabilities | Information theory |
| Relation to KL | cross entropy equals the true entropy plus the KL divergence | Information theory |
| Gradient property | with softmax the gradient is prediction minus label | Deep learning texts |