第11章注意機構とTransformer
11.8.6. Summary and Discussion11.8.6 まとめと考察
You may have noticed that for small datasets like Fashion-MNIST, our implemented vision Transformer does not outperform the ResNet in Section 8.6. Similar observations can be made even on the ImageNet dataset (1.2 million images). This is because Transformers lack those useful principles in convolution, such as translation invariance and locality (Section 7.1). However, the picture changes when training larger models on larger datasets (e.g., 300 million images), where vision Transformers outperform ResNets by a large margin in image classification, demonstrating intrinsic superiority of Transformers in scalability (Dosovitskiy et al., 2021). The introduction of vision Transformers has changed the landscape of network design for modeling image data. They were soon shown to be effective on the ImageNet dataset with data-efficient training strategies of DeiT (Touvron et al., 2021). However, the quadratic complexity of self-attention (Section 11.6) makes the Transformer architecture less suitable for higher-resolution images. Towards a general-purpose backbone network in computer vision, Swin Transformers addressed the quadratic computational complexity with respect to image size (Section 11.6.2) and reinstated convolution-like priors, extending the applicability of Transformers to a range of computer vision tasks beyond image classification with state-of-the-art results (Liu et al., 2021).
英語のヒント
Fashion-MNISTのような小さなデータセットでは、実装した視覚のTransformerが8.6節のResNetを上回らないことに気づいたかもしれない。ImageNetのデータセット(120万枚の画像)でさえ、似たことが観察される。これは、Transformerには、平行移動の不変性や局所性(7.1節)のような、畳み込みの役に立つ原理が欠けているからである。しかし、もっと大きなデータセット(たとえば3億枚の画像)でもっと大きなモデルを訓練すると、事情は変わる。視覚のTransformerは画像分類でResNetを大差で上回り、スケーラビリティでのTransformerの本質的な優位を示す(Dosovitskiy et al., 2021)。視覚のTransformerの登場は、画像データをモデル化するためのネットワーク設計の状況を変えた。それらはすぐに、DeiTのデータ効率のよい訓練の戦略によって、ImageNetのデータセットでも効果的であることが示された(Touvron et al., 2021)。しかし、自己注意の2乗の計算量(11.6節)のため、Transformerの構造は解像度の高い画像にはあまり向かない。コンピュータビジョンの汎用的な骨格のネットワークを目指して、Swin Transformerは、画像の大きさについての2乗の計算量(11.6.2節)に対処し、畳み込みのような事前の仮定を取り戻した。そして、Transformerの適用範囲を画像分類を超えたさまざまなコンピュータビジョンの課題にまで広げ、最先端の結果を出した(Liu et al., 2021)。