Softmax for Probabilities
Turn raw scores into a class distribution.
From Scores to Choices
A classifier's last layer spits out raw scores, one per class. These unbounded numbers are called logits, and they are hard to read directly. 🔢
Enter Softmax
Softmax turns a vector of logits into a clean probability distribution over all your classes. Now each score becomes a chance.
import torch.nn.functional as F
probs = F.softmax(logits, dim=-1)