Abstract
Deep neural networks frequently assign high confidence to incorrect predictions, particularly when encountering out-of-distribution (OOD) data or adversarial attacks. This paper introduces a unified geometric framework to quantify input ambiguity by analyzing the latent feature space of the model's final hidden layer. By measuring distances to class-specific convex hulls and decision boundaries, the proposed ambiguity measure ($\zeta$) provides a robust mechanism for detecting various failure modes—including OOD samples and adversarial examples—using a single, computationally efficient metric.
Introduction: The Challenge of Model Overconfidence
Deep neural networks are notoriously "confidently wrong." They often assign high probability scores to inputs they have never seen before or to samples specifically engineered to deceive them. This phenomenon occurs because a model’s internal confidence (typically the softmax score) is a function of its distance to a decision boundary, not its proximity to actual training data.
Currently, researchers employ separate, often computationally expensive tools to handle different types of failures, such as OOD detection, adversarial defense, and calibration. This research seeks a unified framework: a single measure that identifies ambiguous inputs regardless of whether the ambiguity stems from a lack of data or inherent class confusion.
Methodology: Geometric Ambiguity Framework
The proposed approach shifts the focus from the model's output to the geometry of its last hidden layer (the feature space). The framework involves three primary components:
- SVD Compression: Singular Value Decomposition (SVD) is used to project the high-dimensional latent space into a compressed space ($\Psi$). This step reduces computational overhead and enhances the geometric separation between classes.
- Geometric Projections: For any new input, the system calculates four specific distances:
- Distance to Convex Hulls: Proximity to the "envelope" containing training samples for each class.
- Distance to Decision Boundaries: Proximity to the "flip point" where the model would change its classification.
- Class Overlap: Identification of regions where training samples from different classes naturally mingle.
- Knowledge Gaps: Detection of "holes" within the training distribution.
- The Ambiguity Measure ($\zeta$): These distances are combined into a single formula where high values indicate high ambiguity, suggesting the model should "abstain" from making a prediction.
Key Insights and Experimental Results
The paper evaluates the framework using CIFAR-10 (with ResNet and ViT), ImageNet (with Swin Transformer), and the Adult Income Dataset. Key findings include:
- Confidence Guarantees: The authors mathematically prove that a model is guaranteed to have high softmax confidence as long as an input stays a certain distance away from decision boundaries, even if the input is nonsensical. For a ViT on CIFAR-10, an input 5.07 units away from a boundary guarantees at least 90% confidence.
- Separation via SVD: The SVD-transformed space ($\Psi$) showed superior class separation. Using distance to the convex hull as a classifier achieved ~94.4% accuracy on CIFAR-10, rivaling standard softmax-based accuracy.
- Efficiency and Explainability: Geometric projections can be calculated in 50–100 milliseconds on a GPU. Furthermore, because the measure is based on physical distances, it can generate human-readable explanations for why an image is considered ambiguous.
Discussion and Future Work
While promising, this framework is a work in progress. Calculating exact convex hulls in high dimensions is NP-hard, necessitating approximation algorithms. Future research will focus on capturing non-linear ambiguities deeper in the network and refining the empirical heuristics used to set the ambiguity threshold ($\tau$) for model abstention.
Summary updated