Sharpness of minima is a promising quantity that can correlate with generalization in deep networks and, when optimized during training, can improve generalization. However, standard sharpness is not invariant under reparametrizations of neural networks, and, to fix this, reparametrization-invariant sharpness definitions have been proposed, most prominently adaptive sharpness (Kwon et al., 2021). But does it really capture generalization in modern practical settings? We comprehensively explore this question in a detailed study of various definitions of adaptive sharpness in settings ranging from training from scratch on ImageNet and CIFAR-10 to fine-tuning CLIP on ImageNet and BERT on MNLI. We focus mostly on transformers for which little is known in terms of sharpness despite their widespread usage. Overall, we observe that sharpness does not correlate well with generalization but rather with some training parameters like the learning rate that can be positively or negatively correlated with generalization depending on the setup. Interestingly, in multiple cases, we observe a consistent negative correlation of sharpness with out-of-distribution error implying that sharper minima can generalize better. Finally, we illustrate on a simple model that the right sharpness measure is highly data-dependent, and that we do not understand well this aspect for realistic data distributions. The code of our experiments is available at https://github.com/tml-epfl/sharpness-vs-generalization.


翻译:摘要:最小值的锐度是一个有前景的量,它能与深度网络中的泛化性相关联,且在训练过程中进行优化时可提升泛化能力。然而,标准锐度在神经网络重参数化下不具备不变性,为此研究者提出了重参数化不变的锐度定义,其中最具代表性的是自适应锐度(Kwon等人,2021年)。但在现代实际场景中,它是否真正能反映泛化性?我们通过详细研究多种自适应锐度定义,全面探讨了这一问题,涵盖从在ImageNet和CIFAR-10上从头训练,到在ImageNet上微调CLIP和在MNLI上微调BERT等场景。我们主要聚焦于Transformer模型,尽管其应用广泛,但其锐度特性鲜有研究。总体而言,我们观察到锐度与泛化性并非高度相关,而是与某些训练参数(如学习率)存在关联,而学习率与泛化性的相关性根据设置可能为正或负。有趣的是,在多种情况下,我们发现锐度与分布外误差存在一致的负相关,这意味着更尖锐的最小值可能具有更好的泛化性。最后,我们通过一个简单模型说明,正确的锐度度量高度依赖于数据,而我们对真实数据分布下这一方面的理解仍不充分。实验代码已发布于https://github.com/tml-epfl/sharpness-vs-generalization。

0
下载
关闭预览

相关内容

专知会员服务
41+阅读 · 2020年9月6日
【哈佛大学商学院课程Fall 2019】机器学习可解释性
专知会员服务
106+阅读 · 2019年10月9日
VCIP 2022 Call for Demos
CCF多媒体专委会
1+阅读 · 2022年6月6日
全球首个GNN为主的AI创业公司,募资$18.5 million!
图与推荐
1+阅读 · 2022年4月16日
Hierarchically Structured Meta-learning
CreateAMind
27+阅读 · 2019年5月22日
Transferring Knowledge across Learning Processes
CreateAMind
29+阅读 · 2019年5月18日
Unsupervised Learning via Meta-Learning
CreateAMind
44+阅读 · 2019年1月3日
A Technical Overview of AI & ML in 2018 & Trends for 2019
待字闺中
18+阅读 · 2018年12月24日
disentangled-representation-papers
CreateAMind
26+阅读 · 2018年9月12日
【推荐】用Tensorflow理解LSTM
机器学习研究会
36+阅读 · 2017年9月11日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
Arxiv
38+阅读 · 2021年8月31日
Arxiv
15+阅读 · 2020年12月17日
Learning in the Frequency Domain
Arxiv
11+阅读 · 2020年3月12日
VIP会员
最新内容
博士论文 | 面向大模型推理的内存高效算法
专知会员服务
0+阅读 · 7月27日
美空军新型反无人机部队初探
专知会员服务
4+阅读 · 7月27日
《防空交战流程的概率建模研究》
专知会员服务
6+阅读 · 7月27日
ICML 2026 教程 | 数值优化理论还重要吗?
专知会员服务
5+阅读 · 7月26日
ICM 2026 | 陶哲轩:人工智能时代的数学
专知会员服务
9+阅读 · 7月26日
《反无人机交战场景下的战斗归零研究》
专知会员服务
7+阅读 · 7月26日
博士论文 | 用代码结构感知方法推进代码大模型
相关VIP内容
专知会员服务
41+阅读 · 2020年9月6日
【哈佛大学商学院课程Fall 2019】机器学习可解释性
专知会员服务
106+阅读 · 2019年10月9日
相关资讯
VCIP 2022 Call for Demos
CCF多媒体专委会
1+阅读 · 2022年6月6日
全球首个GNN为主的AI创业公司,募资$18.5 million!
图与推荐
1+阅读 · 2022年4月16日
Hierarchically Structured Meta-learning
CreateAMind
27+阅读 · 2019年5月22日
Transferring Knowledge across Learning Processes
CreateAMind
29+阅读 · 2019年5月18日
Unsupervised Learning via Meta-Learning
CreateAMind
44+阅读 · 2019年1月3日
A Technical Overview of AI & ML in 2018 & Trends for 2019
待字闺中
18+阅读 · 2018年12月24日
disentangled-representation-papers
CreateAMind
26+阅读 · 2018年9月12日
【推荐】用Tensorflow理解LSTM
机器学习研究会
36+阅读 · 2017年9月11日
相关基金
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
Top
微信扫码咨询专知VIP会员