[論文レビュー] SpectFormer: Frequency and Attention is what you need in a Vision Transformer
SpectFormer は後半の段階で Fourier ベースのスペクトル層とマルチヘッド自己注意を組み合わせて Vision Transformer の性能を向上させ、ImageNet-1K の小型/ベース変種で最先端の結果を達成し、転移/COCO の性能も高い。
Vision transformers have been applied successfully for image recognition tasks. There have been either multi-headed self-attention based (ViT \cite{dosovitskiy2020image}, DeIT, \cite{touvron2021training}) similar to the original work in textual models or more recently based on spectral layers (Fnet\cite{lee2021fnet}, GFNet\cite{rao2021global}, AFNO\cite{guibas2021efficient}). We hypothesize that both spectral and multi-headed attention plays a major role. We investigate this hypothesis through this work and observe that indeed combining spectral and multi-headed attention layers provides a better transformer architecture. We thus propose the novel Spectformer architecture for transformers that combines spectral and multi-headed attention layers. We believe that the resulting representation allows the transformer to capture the feature representation appropriately and it yields improved performance over other transformer representations. For instance, it improves the top-1 accuracy by 2\% on ImageNet compared to both GFNet-H and LiT. SpectFormer-S reaches 84.25\% top-1 accuracy on ImageNet-1K (state of the art for small version). Further, Spectformer-L achieves 85.7\% that is the state of the art for the comparable base version of the transformers. We further ensure that we obtain reasonable results in other scenarios such as transfer learning on standard datasets such as CIFAR-10, CIFAR-100, Oxford-IIIT-flower, and Standford Car datasets. We then investigate its use in downstream tasks such of object detection and instance segmentation on the MS-COCO dataset and observe that Spectformer shows consistent performance that is comparable to the best backbones and can be further optimized and improved. Hence, we believe that combined spectral and attention layers are what are needed for vision transformers.
研究の動機と目的
- 画像表現のためにスペクトルと注意機構に基づくトークン混合を組み合わせる必要性を動機づける。
- スペクトル層を早期に、注意層を後半に用いる統合された SpectFormer アーキテクチャを設計する。
- ImageNet および下流タスクに対して、vanilla、スペクトル、階層型トランスフォーマーと比較して SpectFormer を経験的に検証する。
- SpectFormer の転移学習および物体検出/セグメンテーションの性能利点を示す。
提案手法
- SpectFormer を導入し、局所周波数の取得のためのスペクトル層(FFT ベースのゲーティング)とグローバル特徴のためのマルチヘッド自己注意からなる二部構成のトランスフォーマーブロックを用いる。
- ブロック内のスペクトル層と注意層の数を制御する調整可能な alpha を使用する。
- 標準的な ViT 風パイプラインでパッチ埋め込み層、位置エンコーディング、分類ヘッドを採用する。
- いくつかのスペクトル変種(FN、FGN、FNO、WGN)を実験し、Fourier Gating Network(FGN) が最も効果的であることを見出す。
- ImageNet-1K および転移データセットで、 vanilla SpectFormer および階層型 SpectFormer の変種を DeIT、GFNet、AFNO、LiT、Swin、PVT と比較する。
実験結果
リサーチクエスチョン
- RQ1スペクトル層とマルチヘッド注意の混在は、視覚タスクにおいて純粋なスペクトル型または純粋な注意型トランスフォーマーを上回るか。
- RQ2ImageNet の最高性能のためのスペクトル層と注意層の最適な割り当て(alpha)は何か。
- RQ3転移学習シナリオ(CIFAR、Flowers、Cars)における SpectFormer の性能は、ベースラインと比較してどうか。
- RQ4MS COCO の物体検出およびインスタンス分割などの下流タスクにおいて、SpectFormer の変種は有効か。
主な発見
- SpectFormer-S は ImageNet-1K の小型 variante で Top-1 accuracy 84.25% を達成。
- SpectFormer-L は ImageNet-1K のベースに似た大規模 variante で Top-1 accuracy 85.7% を達成。
- SpectFormer はサイズを問わず GFNet、AFNO、LiT、DeiT を上回り、階層型変種が最先端の結果をもたらす。
- スペクトルブロック変種としての Fourier Gating Network (FGN) は FN、FNO、WGN、FGN の中でアブレーション結果として最も良い。
- SpectFormer は CIFAR-10、CIFAR-100、Flowers、Cars で一貫した転移学習の利得を示し、MS COCO の物体検出/セグメンテーションでも競争力のある性能を示す。
より良い研究を、今すぐ始めましょう
論文設計から論文執筆まで、研究時間を劇的に削減しましょう。
クレジットカード登録不要
このレビューはAIが作成し、人間の編集者が確認しました。