Out-of-Distribution Generalization in Kernel Regression
Abstract
In real word applications, data generating process for training a machine learning model often differs from what the model encounters in the test stage. Understanding how and whether machine learning models generalize under such distributional shifts have been a theoretical challenge. Here, we study generalization in kernel regression when the training and test distributions are different using methods from statistical physics. Using the replica method, we derive an analytical formula for the out-of-distribution generalization error applicable to any kernel and real datasets. We identify an overlap matrix that quantifies the mismatch between distributions for a given kernel as a key determinant of generalization performance under distribution shift. Using our analytical expressions we elucidate various generalization phenomena including possible improvement in generalization when there is a mismatch. We develop procedures for optimizing training and test distributions for a given data budget to find best and worst case generalizations under the shift. We present applications of our theory to real and synthetic datasets and for many kernels. We compare results of our theory applied to Neural Tangent Kernel with simulations of wide networks and show agreement. We analyze linear regression in further depth.
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
9 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- Learning Curves for Deep Structured Gaussian Feature Models cites Deep Double Descent: Where Bigger Models and More Data Hurt
- An Investigation of Why Overparameterization Exacerbates Spurious Correlations cites Deep Double Descent: Where Bigger Models and More Data Hurt
- Pretrain–Test Task Alignment Governs Generalization in In-Context Learning cites Optimal Ridge Regularization for Out-of-Distribution Prediction
- How Neural Networks Extrapolate: From Feedforward to Graph Neural Networks cites Neural Tangents: Fast and Easy Infinite Neural Networks in Python
Cited by top-tier papers9
- A Spectral Theory of Neural Prediction and AlignmentAbdulkadir Canatar, Jenelle Feather, Albert J. Wakhloo, SueYeon ChungNeurIPS 2023 · 29 citations
- Optimal Ridge Regularization for Out-of-Distribution PredictionPratik Patil, Jin-Hong Du, Ryan J. TibshiraniICML 2024 · 23 citations
- Learning Curves for Deep Structured Gaussian Feature ModelsJacob A. Zavatone-Veth, Cengiz PehlevanNeurIPS 2023 · 15 citations
- Towards Understanding Inductive Bias in Transformers: A View From InfinityItay Lavie, Guy Gur-Ari, Zohar RingelICML 2024 · 11 citations
- Pretrain–Test Task Alignment Governs Generalization in In-Context LearningMary Letey, Jacob A Zavatone-Veth, Yue M. Lu, Cengiz PehlevanICLR 2026 · 6 citations
Builds on9
- Out-of-Distribution Generalization via Risk Extrapolation (REx)David Krueger, Ethan Caballero, Jörn-Henrik Jacobsen, Amy Zhang et al.ICML 2021 · 1,163 citations
- Deep Double Descent: Where Bigger Models and More Data HurtPreetum Nakkiran, Gal Kaplun, Yamini Bansal, Tristan Yang et al.ICLR 2020 · 1,108 citations
- An Investigation of Why Overparameterization Exacerbates Spurious CorrelationsShiori Sagawa, Aditi Raghunathan, Pang Wei Koh, Percy LiangICML 2020 · 436 citations
- How Neural Networks Extrapolate: From Feedforward to Graph Neural NetworksKeyulu Xu, Mozhi Zhang, Jingling Li, Simon Shaolei Du et al.ICLR 2021 · 364 citations
- Neural Tangents: Fast and Easy Infinite Neural Networks in PythonRoman Novak, Lechao Xiao, Jiri Hron, Jaehoon Lee et al.ICLR 2020 · 254 citations
Related papers
- Spectrum Dependent Learning Curves in Kernel Regression and Wide Neural NetworksBlake Bordelon, Abdulkadir Canatar, Cengiz PehlevanICML 2020 · 245 citations
- What can linearized neural networks actually say about generalization?Guillermo Ortiz-Jiménez, Seyed-Mohsen Moosavi-Dezfooli, Pascal FrossardNeurIPS 2021 · 62 citations
- Towards a Unified Analysis of Kernel-based Methods Under Covariate ShiftXingdong Feng, Xin He, Caixing Wang, Chao Wang et al.NeurIPS 2023 · 17 citations
- Learning curves for continual learning in neural networks: Self-knowledge transfer and forgettingRyo Karakida, Shotaro AkahoICLR 2022 · 16 citations
- More Than a Toy: Random Matrix Models Predict How Real-World Neural Representations GeneralizeAlexander Wei, Wei Hu, Jacob SteinhardtICML 2022 · 90 citations
