A Fix for Softmax and Cross-Entropy

Standard implementations of softmax, log-softmax, and cross-entropy have two numerical bugs. One rounds the target logit's gradient to zero under some conditions. The second produces non-zero gradients even when the student and teacher logits are equal.

arXiv.org
https://arxiv.org/abs/2610.31642