arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2212.00776cs.CV
收藏

ResFormer:通过多分辨率训练缩放ViT

ResFormer: Scaling ViTs with Multi-Resolution Training

Fudan University(复旦大学);Microsoft Research Asia(微软亚洲研究院);Shanghai AI Laboratory(上海人工智能实验室)

Rui Tian, Zuxuan Wu, Qi Dai, Han Hu, Yu Qiao, Yu-Gang Jiang

AI总结:

ResFormer框架通过多分辨率训练和全局-局部位置嵌入策略,解决了ViTs在未见分辨率下性能下降的问题,并在图像分类等任务中展现出优异的缩放能力。

摘要:

视觉Transformer(ViTs)取得了压倒性的成功,但它们在分辨率缩放方面存在脆弱性,即当输入在训练期间未见过的分辨率时,性能会急剧下降。我们引入了ResFormer,这是一个建立在多分辨率训练这一开创性思想之上的框架,旨在提高在各种(主要是未见过的)测试分辨率下的性能。具体而言,ResFormer对不同分辨率的复制图像进行操作,并强制执行尺度一致性损失,以促进不同尺度间的交互信息。更重要的是,为了在不同分辨率之间有效切换,尤其是测试中的新分辨率,我们提出了一种全局-局部位置嵌入策略,该策略根据输入尺寸平滑变化。我们在ImageNet上进行了广泛的图像分类实验。结果提供了强有力的定量证据,表明ResFormer在广泛的分辨率范围内具有出色的缩放能力。例如,ResFormer-B-MR在相对较低和较高分辨率(即96和640)下评估时,分别达到了75.86%和81.72%的Top-1准确率,比DeiT-B分别高出48%和7.49%。此外,我们还证明ResFormer具有灵活性,可以轻松扩展到语义分割、目标检测和视频动作识别。代码可在https://github.com/ruitian12/resformer获取。

英文摘要:

Vision Transformers (ViTs) have achieved overwhelming success, yet they suffer from vulnerable resolution scalability, i.e., the performance drops drastically when presented with input resolutions that are unseen during training. We introduce, ResFormer, a framework that is built upon the seminal idea of multi-resolution training for improved performance on a wide spectrum of, mostly unseen, testing resolutions. In particular, ResFormer operates on replicated images of different resolutions and enforces a scale consistency loss to engage interactive information across different scales. More importantly, to alternate among varying resolutions effectively, especially novel ones in testing, we propose a global-local positional embedding strategy that changes smoothly conditioned on input sizes. We conduct extensive experiments for image classification on ImageNet. The results provide strong quantitative evidence that ResFormer has promising scaling abilities towards a wide range of resolutions. For instance, ResFormer-B-MR achieves a Top-1 accuracy of 75.86% and 81.72% when evaluated on relatively low and high resolutions respectively (i.e., 96 and 640), which are 48% and 7.49% better than DeiT-B. We also demonstrate, moreover, ResFormer is flexible and can be easily extended to semantic segmentation, object detection and video action recognition. Code is available at https://github.com/ruitian12/resformer.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑