Abstract: In many applications, one works with neural network models trained by someone else. For such pretrained models, one may not have access to training data or test data. Moreover, one may not know details about the model, e.g., the specifics of the training data, the loss function, the hyperparameter values, etc. Given one or many pretrained models, it is a challenge to say anything about the expected performance or quality of the models. Here, we address this challenge by providing a detailed meta-analysis of hundreds of publicly available pretrained models. We examine norm-based capacity control metrics as well as power law based metrics from the recently-developed Theory of Heavy-Tailed Self Regularization. We find that norm based metrics correlate well with reported test accuracies for well-trained models, but that they often cannot distinguish well-trained versus poorly trained models. We also find that power law based metrics can do much better-quantitatively better at discriminating among series of well-trained models with a given architecture; and qualitatively better at discriminating well-trained versus poorly trained models. These methods can be used to identify when a pretrained neural network has problems that cannot be detected simply by examining training/test accuracies.
Introduction
In the modern AI ecosystem, researchers and engineers frequently utilize pre-trained models from "model zoos" such as HuggingFace or PyTorch Hub. These models are often "black boxes" where the original training data is unavailable due to privacy or proprietary reasons, and a perfectly matched labeled test set may not be at hand. Standard practice relies on reported training/test accuracies, but these metrics fail to reveal if a model is over-parameterized, poorly regularized, or structurally compromised by techniques like distillation. This paper introduces a "data-free" approach to predicting model quality by analyzing the statistical "fingerprints" left in a model's weight matrices.
Methods
The authors performed a massive meta-analysis of over 500 state-of-the-art (SOTA) models using a tool called WeightWatcher. Their approach is rooted in Random Matrix Theory (RMT) and statistical mechanics, specifically the Theory of Heavy-Tailed Self-Regularization.
The analytical pipeline follows four key steps:
- Spectral Analysis: For every layer in a network, the weight matrix $W$ is extracted, and the eigenvalues of the correlation matrix $X = W^T W$ are computed.
- Power Law (PL) Fitting: The distribution of these eigenvalues (the Empirical Spectral Density) is fitted to a power-law: $\rho(\lambda) \sim \lambda^{-\alpha}$.
- Metric Calculation: The authors compare traditional norm-based metrics (like Frobenius or Spectral norms) against PL-based metrics, most notably Weighted Alpha ($\hat{\alpha}$), which weights the power-law exponent of each layer by its scale.
- Meta-Analysis: These internal weight statistics were correlated with publicly reported test accuracies for diverse architectures including VGG, ResNet, DenseNet, and the GPT series.
Key Insights and Ideas
- The "Heavy-Tail" Signature: Well-trained SOTA models exhibit "heavy-tailed" distributions, a signature of Implicit Self-Regularization. As a model learns, its eigenvalues shift from a random distribution (fitting the Marchenko-Pastur law) to a power-law distribution.
- Correlation Flow: For effective generalization, information must "flow" across layers. High-quality models (e.g., ResNet-152) maintain stable and small PL exponents ($\alpha \approx 2.0$) across most layers.
- Scale Collapse: The metrics can detect "Scale Collapse," where spectral norms plummet due to specific optimization techniques. While the model might still show decent test accuracy, this indicates structural fragility that traditional metrics miss.
- Diagnostic Power: While simple norms correlate with accuracy in well-behaved families, PL-based metrics are more robust at distinguishing well-trained models from poorly trained ones.
Key Results
- High Correlation with Accuracy: For the ResNet family, the PL-based metric $\hat{\alpha}$ achieved an $R^2$ of 0.96 when predicting Top-1 accuracy.
- NLP Success: In the GPT2 series, PL metrics correctly predicted that larger models were superior and identified that the original GPT model was "under-trained" compared to GPT2, evidenced by unusually large $\alpha$ values.
- Diagnostic Thresholds: The study found that $\alpha$ values typically fall between 2 and 4 for high-quality models. Layers with $\alpha > 6$ likely indicate over-parameterization or under-training relative to the data.
Conclusion and Future Work
This work provides a practical framework for evaluating neural networks "in the wild" using only their weights. While the "baseline" for a good $\alpha$ currently varies by architecture, these metrics offer a powerful diagnostic tool. Future directions include using these PL signatures as regularizers during training or as early-stopping criteria that do not require a validation set.
Summary updated