The Softmax That Forgets Its Past: Invariance to Label Permutation vs. Feature Permutation
Suppose you train a softmax classifier on a -class problem. The model outputs
Now consider two operations:
(A) Label permutation: You relabel the training data by swapping class 1 and class 2 (and retrain from scratch).
(B) Feature sign flip: You replace every feature with (and retrain from scratch).
Question: For each operation, describe precisely what happens to the learned coefficient vectors . In particular:
- Under (A), is the model equivalent to simply swapping and ?
- Under (B), is the model equivalent to simply negating all ?
Now the punchline: the softmax loss function is
True or False (and explain): The softmax model has an identifiability problem — there exists a non-trivial transformation of that leaves all predicted probabilities unchanged for every input .
Identify this transformation explicitly and explain why it is never resolved by more data.
Answer: The Softmax That Forgets Its Past: Invariance to Label Permutation vs. Feature Permutation
Key Idea / Intuition
The softmax model is not identifiable: you can shift every coefficient vector by the same arbitrary vector — i.e., replace for all — and the predicted probabilities are completely unchanged for every input. This is because the softmax depends only on differences between the linear scores. No amount of data can break this symmetry, because the likelihood itself is flat along this entire affine subspace of parameters.
Formal Proof / Solution
Part (A): Label Permutation
If you swap class labels 1 and 2 and retrain, the new optimal classifier is obtained by swapping (and leaving all other unchanged). This is immediate from symmetry of the loss: the relabeled loss is the original loss with the roles of and exchanged. So yes — label permutation corresponds exactly to permuting the coefficient vectors.
Part (B): Feature Sign Flip
If you replace and retrain, the new optimal solution satisfies for all , since
and the model structure is preserved with . So yes — negating features corresponds to negating all coefficient vectors.
The Identifiability Problem
True. The softmax has a fundamental non-identifiability.
The transformation: For any vector , define
Then for every input :
The factor cancels in numerator and denominator. So every predicted probability is identical under this shift.
Why more data cannot resolve it:
Since the likelihood
is identical for and for every data point, the log-likelihood surface is flat along the entire -dimensional family . No data distinguishes these parameter values — the Fisher information matrix is singular.
Standard fix: Pin one class, say . This is why logistic regression for classes only needs one coefficient vector (the log-odds of class 1 vs. class 2). For general , you effectively model free coefficient vectors, giving a well-identified model.
Summary table:
| Operation | Effect on | |---|---| | Swap labels | Swap | | Flip features | Negate all: | | Shift all by | Leaves all probabilities unchanged — not identifiable |
Source: The Elements of Statistical Learning, Hastie, Tibshirani, Friedman (2nd ed.), Section 4.4