Editor’s introduction
The study evaluates how model pruning affects predictive performance and explanation reliability in two long-tailed medical imaging datasets. It reveals that lower-frequency clinical conditions degrade more severely under pruning, indicating a pattern of long-tail forgetting. The research shows that explanation degradation stems primarily from the collapse of class-discriminative gradients, not from loss of feature activations. These findings highlight that performance evaluation must include class-aware and explanation-aware metrics to detect hidden failure modes in compressed models. The evidence supports that moderate sparsity levels offer a practical trade-off between model size, prediction accuracy, and explanation trustworthiness in medical imaging applications.
Introduction
Model pruning has emerged as a principal strategy for reducing the memory footprint and computational cost of deep neural networks. By removing redundant weights, pruning can substantially reduce inference cost with minimal impact on aggregate performance. While such compression is attractive for deploying deep learning models in resource-constrained environments, aggregate performance metrics can mask important changes in model behavior. This issue is especially relevant in medical AI, where failures on clinically important cases may have significant consequences.
Medical imaging datasets are often long-tailed, with common conditions such as pleural effusion and infiltration represented by thousands of training examples, whereas rare but clinically significant conditions such as hernia, pneumomediastinum, and melanoma occur much less frequently. Under such a class imbalance, pruning may disproportionately degrade performance on rare classes. Holste et al. referred to this phenomenon as long-tail forgetting, showing that rare classes are particularly vulnerable to pruning. However, their analysis considered only a single pruning strategy and focused solely on predictive performance.
A second concern is explanation reliability. Explainability methods are increasingly embedded in clinical workflows to audit model decisions, identify failure modes, and support clinician trust in automated outputs. If pruning destabilizes these explanations, causing a compressed model to attend to different image regions than its dense counterpart, then a model may retain acceptable aggregate accuracy while producing clinically misleading localizations. This constitutes a silent safety hazard: a compressed model that passes standard performance benchmarks yet cannot be trusted to explain its predictions. This concern is particularly important for rare diseases, where model behavior is already difficult to assess due to limited data. The regulatory guidance for AI-based medical systems further emphasizes the importance of explainable decision-making.
To answer these questions, we conduct a systematic study across two long-tailed medical imaging datasets, NIH-CXR-LT and ISIC-2019, two architectures (ResNet-50 and DenseNet-121), four pruning strategies (L1-based magnitude pruning, SNIP, GraSP, and random pruning), and sparsity levels ranging from 0% to 95%.
Neural Network Pruning
Model pruning reduces the computational and memory requirements of deep neural networks by removing redundant parameters while maintaining predictive performance. Pruning methods differ primarily in how parameter importance is estimated. Early approaches such as Optimal Brain Damage and Optimal Brain Surgeon estimate parameter importance using second-order information, whereas magnitude-based pruning removes weights with small absolute values and remains a widely adopted baseline because of its simplicity and effectiveness. More recent methods estimate parameter importance using first-order information. SNIP identifies connections based on sensitivity to the training loss at initialization, whereas GraSP preserves gradient flow to improve trainability after pruning. This work compares four representative pruning strategies: magnitude-based pruning (L1), sensitivity-based pruning (SNIP), gradient-preserving pruning (GraSP), and Random pruning.
Explainability
Explainability methods provide post-hoc insights into the decision-making process of deep neural networks and are increasingly used to improve transparency and trust in medical AI. Among these, feature attribution methods such as saliency maps, Integrated Gradients, SmoothGrad, DeepLIFT, and Grad-CAM are widely adopted because they highlight image regions that contribute to model predictions. Quantitative evaluation of explanations commonly relies on measures of stability, which assess consistency across models or perturbations, and faithfulness, which evaluates whether highlighted regions causally influence predictions. These metrics provide complementary perspectives on explanation reliability and have become increasingly important for evaluating trustworthy medical AI systems.
Impact of Pruning
Although pruning often preserves aggregate predictive performance, it can substantially alter class-specific model behavior. Hooker et al. showed that pruning disproportionately affects a subset of classes despite preserving overall performance, demonstrating pruning-induced forgetting in natural image classification. Extending this observation to medical imaging, Holste et al. showed that rare diseases are more vulnerable to pruning than common diseases, identifying the phenomenon of long-tail forgetting. More recently, several studies have investigated the effect of pruning on explainability, reporting that moderate pruning can preserve or even improve explanation quality, whereas aggressive compression often degrades attribution fidelity.
Despite these advances, two important gaps remain. First, existing medical studies of long-tail forgetting have primarily focused on magnitude-based pruning, leaving it unclear whether the phenomenon generalizes across different pruning strategies. Second, prior work typically evaluates predictive performance or explainability independently, without jointly analyzing how compression affects both. To address these gaps, we conduct a comprehensive empirical study of four representative pruning strategies (L1, SNIP, GraSP, and Random) across two long-tailed medical imaging datasets and two widely used CNN architectures. Beyond predictive performance, we quantify explanation reliability using attribution stability and faithfulness, providing a unified analysis of how pruning influences both long-tail forgetting and explanation reliability.
Datasets
We conduct experimentation on two publicly available long-tailed medical imaging datasets spanning clinically distinct domains, thoracic radiology and dermatology, providing complementary settings for evaluating pruning behavior across different imaging modalities, task formulations, and degrees of class imbalance. Table I summarizes their key characteristics, including dataset size, class distribution, and long-tail statistics.
NIH-CXR-LT
NIH-CXR-LT is a long-tailed extension of the ChestX-ray14 dataset, comprising 20 classes (19 thoracic diseases and No Finding). We follow the official training, validation, and test splits provided with the benchmark. Following, classes are grouped into head, mid, and tail categories according to their training frequency.
ISIC-2019
ISIC-2019 contains dermoscopic images from eight skin-lesion categories with a pronounced long-tailed class distribution. We exclude the Unknown test class and adopt an 85%/15% stratified training/validation split while evaluating on the official challenge test set. To ensure a consistent experimental setup across datasets, we formulate ISIC-2019 as a one-vs-rest classification problem using sigmoid outputs and binary cross-entropy loss, matching the multi-label formulation used for NIH-CXR-LT.
Models
We evaluate two widely used CNN backbones: ResNet-50 and DenseNet-121. These architectures represent two established CNN design paradigms and differ substantially in connectivity (residual versus dense) and model capacity (approximately 25.6M versus 8.0M parameters), providing complementary settings for assessing whether pruning-induced behavior generalizes across CNN architectures. Both models are initialized with ImageNet-pretrained weights and fine-tuned end-to-end.
For each backbone, the original classification layer is replaced with a task-specific linear layer, producing 20 outputs for NIH-CXR-LT and 8 outputs for ISIC-2019. Following the one-vs-rest formulation adopted in this work, sigmoid activations are applied independently to each output, and the networks are optimized using binary cross-entropy with logits. No class reweighting or resampling is employed, preserving the natural long-tailed class distribution throughout training.
Pruning Strategies
We compare four representative one-shot unstructured pruning strategies spanning magnitude-based, gradient-based, and random pruning: L1-based magnitude pruning, SNIP, GraSP, and Random pruning. We focus on these methods to enable a controlled comparison of distinct weight-importance criteria. For all methods, sparsity levels of 0%, 5%, 10%, 15% …, 95% are evaluated, with 0% corresponding to the dense baseline. Following pruning, all models are fine-tuned using an identical training protocol to ensure a fair comparison.
Evaluation Framework
We evaluate how model pruning influences both predictive performance and the reliability of post-hoc explanations, with particular emphasis on long-tailed class behavior. Explanation reliability is assessed using Grad-CAM along two complementary dimensions: explanation stability, which measures consistency with the dense model, and explanation faithfulness, which evaluates whether highlighted regions causally contribute to the model’s predictions. Together, these metrics provide a comprehensive assessment of how pruning affects both predictive behavior and explanation reliability.
Impact of Pruning on Predictive Performance
While all pruning methods exhibit frequency-dependent degradation, their severity differs considerably. SNIP preserves class-wise performance most effectively and occasionally improves AP for several representative classes at low-to-moderate sparsity, possibly reflecting an implicit regularization effect. GraSP incurs an early performance penalty but maintains relatively stable degradation thereafter. In contrast, L1 pruning exhibits a pronounced high-sparsity collapse, with lower-frequency classes generally experiencing larger performance degradation than higher-frequency classes despite some class-specific exceptions. Random pruning performs worst, causing rapid degradation across all class-frequency groups even at low sparsity. These results demonstrate that gradient-informed pruning strategies preserve predictive performance more effectively across both aggregate and class-wise evaluations than magnitude-based and random pruning under aggressive compression.
Why Does Pruning Disproportionately Affect Rare Diseases?
A central finding of this work is that long-tail forgetting is a systematic consequence of model pruning rather than a property of a particular pruning algorithm. Across all datasets, architectures, and pruning methods, pruning robustness exhibits a strong association with class frequency. Although individual classes deviate from this trend, lower-frequency classes generally experience earlier and larger performance degradation than higher-frequency classes. We hypothesize that this behavior arises from differences in representational redundancy. Frequent diseases are observed repeatedly during training and therefore develop richer and more redundant feature representations, whereas rare diseases rely on comparatively fewer discriminative pathways. Consequently, globally applied pruning criteria are more likely to remove parameters that are critical for rare-class recognition.
Although long-tail forgetting is consistently observed, its severity varies across pruning methods. Gradient-informed approaches, particularly SNIP, preserve class-wise performance substantially better than magnitude-based and random pruning, suggesting that retaining optimization-sensitive connections is beneficial for maintaining minority-class representations under aggressive compression. These observations extend previous studies that primarily investigated magnitude-based pruning by demonstrating that long-tail forgetting generalizes across multiple pruning strategies.
Explanation Stability and Faithfulness Provide Complementary Insights
Explanation stability and explanation faithfulness exhibit distinct responses to model pruning, indicating that they capture complementary aspects of explanation reliability. Unlike predictive performance, neither metric exhibits a consistent frequency-dependent ordering across representative classes. Instead, both explanation stability and explanation faithfulness are influenced primarily by the pruning strategy, suggesting that explanation robustness and predictive robustness respond differently to compression. While explanation stability decreases progressively with increasing sparsity, explanation faithfulness remains comparatively robust for gradient-informed pruning methods over a wide range of sparsity levels. This indicates that compressed models may continue to rely on clinically meaningful image evidence even when predictive performance begins to decline.
These observations further highlight that explanation stability and explanation faithfulness quantify different properties of model behavior. Stability measures the consistency of explanations relative to the dense model, whereas faithfulness evaluates whether highlighted regions causally contribute to the model’s prediction. Consequently, a pruned model may generate explanations that differ spatially from those of the dense model while still highlighting image regions that remain important for its predictions. Evaluating both metrics therefore provides a more comprehensive assessment of explanation reliability than either metric alone.
Mechanisms Underlying Explanation Degradation
The qualitative Grad-CAM analysis, together with the activation and gradient studies, provides insight into why explanations degrade under aggressive pruning. While Random pruning substantially weakens feature activations, L1 pruning largely preserves activation magnitudes despite producing severely degraded attribution maps. In contrast, both methods exhibit a pronounced collapse of class-discriminative gradients at the Grad-CAM target layer. Since Grad-CAM directly relies on these gradients to weight feature maps, the collapse of gradient information provides a plausible explanation for the degenerate attribution maps observed under extreme sparsity.
These findings suggest that preserving feature activations alone is insufficient to maintain reliable explanations after aggressive pruning. Instead, explanation quality depends critically on preserving class-discriminative gradients. This may also help explain the favorable behavior of SNIP, which retains connections with high first-order sensitivity to the training loss, although its objective does not explicitly optimize explanation gradients. More broadly, these results demonstrate that preserving predictive performance alone is insufficient to ensure reliable explanations after compression.
Implications for Deployment of Compressed Medical AI
Our findings have several implications for the deployment of compressed medical AI systems. First, aggregate performance metrics alone are insufficient because they can obscure substantial degradation in clinically important but infrequent diseases. Per-class evaluation is therefore essential, particularly for long-tailed medical datasets where aggregate metrics may conceal clinically important failure modes. Second, explanation reliability should be evaluated alongside predictive performance, as compression affects these properties differently depending on the pruning strategy. Finally, moderate sparsity levels consistently provide the best compromise between compression, predictive performance, and explanation reliability across datasets and architectures.
These findings suggest that compressed medical AI systems should be evaluated using class-aware and explanation-aware protocols rather than aggregate performance alone. Such evaluations provide a more realistic assessment of model robustness in safety-critical clinical applications, where failures on rare diseases or unreliable explanations may have important clinical consequences.
Conclusion
This paper presents a systematic study of long-tail forgetting and explanation reliability under model pruning in medical imaging. Across four pruning strategies, two architectures, and two long-tailed datasets, we show that long-tail forgetting is consistently observed under pruning, with lower-frequency classes degrading earlier and more severely than higher-frequency classes. We further demonstrate that pruning affects explanation reliability in a method-dependent manner, with gradient-informed pruning, particularly SNIP, providing the most favorable balance between predictive performance and explanation reliability. Our qualitative and mechanistic analyses suggest that degradation of Grad-CAM explanations under aggressive pruning is primarily associated with the collapse of class-discriminative gradients rather than the disappearance of high-level feature activations. These findings highlight the importance of evaluating compressed medical AI models using class-aware and explanation-aware protocols in addition to conventional aggregate performance metrics. Moderate sparsity levels consistently provide a practical operating regime that preserves both predictive performance and explanation reliability.
While this study focuses on CNN architectures, extending the analysis to transformer-based models will be important to determine whether the observed pruning behaviors generalize across different architectural paradigms. Future work will also investigate other compression strategies, including structured pruning, quantization, and knowledge distillation, and broader medical imaging tasks such as localization, detection, and segmentation.


