NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

On the Benefits of Public Representations for Private Transfer Learning under Distribution Shift

Pratiksha Thaker, Amrith Setlur, Steven Wu, Virginia Smith

TL;DR

Public pretraining is a powerful tool for differentially private (DP) machine learning, even when the public data looks nothing like the private data. This paper demonstrates that using public representations can boost private training accuracy by up to 67% over training from scratch. By proving that shared low-dimensional structures exist between disparate datasets, the authors show that private learning is practical even for highly sensitive, out-of-distribution domains like medical and satellite imaging.

The Challenge: Privacy vs. Utility under Distribution Shift

Training models with Differential Privacy (DP)—a mathematical guarantee that individual data points aren't leaked—usually comes with a heavy "utility tax." To protect privacy, noise is added during training, which often leads to significantly lower accuracy compared to non-private methods.

A popular workaround is to pretrain a model on large-scale public data (like the internet) and then finetune it on private data. However, critics have pointed out a major flaw in current research: most benchmarks use public and private datasets that are very similar (e.g., pretraining on ImageNet to finetune on CIFAR-10). In the real world, private data (like medical records or legal documents) is often out-of-distribution (OOD) relative to the web.

The central question this paper addresses is: Does public pretraining still help when there is an extreme distribution shift between the public and private data?

Methodology and Datasets

The researchers tackle this question using both empirical experiments and theoretical modeling.

Empirical Approach: They use a CLIP ViT-B/32 model (pretrained on the massive LAION-2B dataset) as a "public" feature extractor. They compare three main strategies for training on private data:

  1. Training from scratch: No public data used.
  2. Full finetuning: Updating all model weights privately.
  3. Linear probing: Freezing the public backbone and only training a simple linear classification head privately.

Datasets: The authors chose three datasets where standard public models (like CLIP) perform poorly "out of the box," indicating a significant distribution shift:

  • PatchCamelyon (PCam): Medical images for lymph node tumor detection.
  • Functional Map of the World (fMoW): 62-class satellite image classification.
  • RESISC45: 45-class remote sensing (satellite) scene classification.

These differ from standard benchmarks because their "zero-shot" performance is nearly random, making them excellent proxies for sensitive, specialized private data.

Key Findings & Results

The empirical results strongly validate the use of public pretraining, even under extreme distribution shifts.

Accuracy across PCam, fMoW, and RESISC45 datasets comparing training from scratch, full finetuning, and linear probing under varying privacy budgets (epsilon).
  • Massive Accuracy Gains: On the RESISC45 dataset, using public features via linear probing improved accuracy by 67% over training from scratch.
  • Making the "Unusable" Practical: For the fMoW satellite dataset, training from scratch yielded "unusably weak" results (near random guessing). However, private linear probing using public features brought performance close to non-private levels.
  • Less is More in DP: In private learning, updating fewer parameters is often better. The authors found that linear probing consistently outperformed full finetuning. This is because DP noise scales with the number of parameters being updated; by only training the last layer, you keep the noise low.
  • Efficiency: Linear probing is not only more accurate under DP but also requires significantly fewer computational resources (memory and time) than full finetuning.

Theoretical Insights: The Power of Subspaces

To explain why public data is so useful even when it looks completely different from the private data, the authors propose a "two-phase" linear regression model.

  1. Phase 1: Use diverse public tasks to estimate a shared, low-dimensional subspace (a simplified representation of the data).
  2. Phase 2: Perform private linear regression only within that learned subspace.

Even if a pretrained model cannot correctly label a medical image zero-shot, the features it has learned about shapes, textures, and edges are still incredibly useful. By using public data to find this "neighborhood" of useful features, we reduce the "ambient dimension" of the problem. This means the DP algorithm has to deal with less noise, saving the "privacy budget" for the final, task-specific learning.

Eigenvalues of the feature covariance matrix for the PCam dataset, showing rapid decay.

The theoretical model relies on a linear subspace assumption. The authors provide empirical evidence that this holds by plotting the eigenspectrum of feature matrices, which shows a rapid decay, confirming that the data effectively lives in a much lower-dimensional space.

Limitations and Future Work

While the results are promising, the authors note a few limitations:

  • Backbone Dependency: The quality and scale of the "public" features matter. Experiments with smaller pretraining sets (like Datacomp-14M) showed lower final accuracy, suggesting that massive scale is still a critical factor for OOD generalization.
  • Beyond Linear Simplifications: Real-world neural network representations are non-linear and more complex than the theoretical linear subspace model suggests. Future work could explore more complex "shared structures" to better model how deep neural networks transfer knowledge privately.

Summary updated

BibTeX
@inproceedings{thaker2024benefits,
  author = {Pratiksha Thaker and Amrith Setlur and Steven Wu and Virginia Smith},
  title = {{On the Benefits of Public Representations for Private Transfer Learning under Distribution Shift}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2024},
  url = {https://openreview.net/forum?id=E1nBLrEaJo},
}
Figure