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

如何在小规模数据集上训练视觉Transformer?

How to Train Vision Transformer on Small-scale Datasets?

Hanan Gani, Muzammal Naseer, Mohammad Yaqub

摘要:

视觉Transformer(ViT)是一种与卷积神经网络完全不同的架构,具有多种优势,包括设计简单、鲁棒性和许多视觉任务的最新性能。然而,与卷积神经网络相比,视觉Transformer缺乏固有的感应偏差。因此,这些模型的成功训练主要归功于在大规模数据集上进行的预训练,例如具有1.2M图像的ImageNet或具有300 M图像的JFT。这阻碍了视觉Transformer对小规模数据集的直接适配。在这项工作中,我们证明了自我监督的归纳偏差可以直接从小规模数据集中学习,并作为一种有效的权重初始化方案进行微调。这允许训练这些模型,而无需大规模的预训练、对模型架构或损失函数的改变。我们提出了全面的实验,成功地训练单片和非单片视觉Transformer上五个小的数据集,包括CIFAR 10/100,CINIC 10,SVHN,Tiny-ImageNet和两个细粒度的数据集:飞机和汽车。我们的方法不断提高性能的视觉Transformer,同时保留其属性,如注意到显着的地区和更高的鲁棒性。我们的代码和预训练模型可在https://github.com/hananshafi/vits-for-small-scale-datasets上获得。

英文摘要:

Vision Transformer (ViT), a radically different architecture than convolutional neural networks offers multiple advantages including design simplicity, robustness and state-of-the-art performance on many vision tasks. However, in contrast to convolutional neural networks, Vision Transformer lacks inherent inductive biases. Therefore, successful training of such models is mainly attributed to pre-training on large-scale datasets such as ImageNet with 1.2M or JFT with 300M images. This hinders the direct adaption of Vision Transformer for small-scale datasets. In this work, we show that self-supervised inductive biases can be learned directly from small-scale datasets and serve as an effective weight initialization scheme for fine-tuning. This allows to train these models without large-scale pre-training, changes to model architecture or loss functions. We present thorough experiments to successfully train monolithic and non-monolithic Vision Transformers on five small datasets including CIFAR10/100, CINIC10, SVHN, Tiny-ImageNet and two fine-grained datasets: Aircraft and Cars. Our approach consistently improves the performance of Vision Transformers while retaining their properties such as attention to salient regions and higher robustness. Our codes and pre-trained models are available at: https://github.com/hananshafi/vits-for-small-scale-datasets.

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

↑