Skip to main content
QUICK REVIEW

[論文レビュー] Space-time Mixing Attention for Video Transformer

Adrian Bulat, Juan-Manuel Pérez-Rúa|arXiv (Cornell University)|Jun 10, 2021
Advanced Vision and Imaging参考文献 45被引用数 57
ひとこと要約

局所ウィンドウに時間的注意を制限し、空間-時間情報を効率的に混合することで、フレーム数に対して線形スケーリングを実現した空間-時間混合注意機構を持つVideo Transformerを提案し、軽量な時間的集約機構を追加します。

ABSTRACT

This paper is on video recognition using Transformers. Very recent attempts in this area have demonstrated promising results in terms of recognition accuracy, yet they have been also shown to induce, in many cases, significant computational overheads due to the additional modelling of the temporal information. In this work, we propose a Video Transformer model the complexity of which scales linearly with the number of frames in the video sequence and hence induces no overhead compared to an image-based Transformer model. To achieve this, our model makes two approximations to the full space-time attention used in Video Transformers: (a) It restricts time attention to a local temporal window and capitalizes on the Transformer's depth to obtain full temporal coverage of the video sequence. (b) It uses efficient space-time mixing to attend jointly spatial and temporal locations without inducing any additional cost on top of a spatial-only attention model. We also show how to integrate 2 very lightweight mechanisms for global temporal-only attention which provide additional accuracy improvements at minimal computational cost. We demonstrate that our model produces very high recognition accuracy on the most popular video recognition datasets while at the same time being significantly more efficient than other Video Transformer models. Code will be made available.

研究の動機と目的

  • 動画トランスフォーマーにおける全空間-時間注意の計算ボトルネックに対処する。
  • 局所的な時間窓と空間-時間混合機構を提案し、計算量を O(TS^2) に達成する。
  • 同時期のVideo Transformerアプローチと比較して FLOPs を削減しつつ、精度を維持または向上させる。
  • 軽量なグローバル時間注意とサマリートークンを通じて効率的な時間的集約を実現する。

提案手法

  • 空間的および時間的位置エンコーディングを用いて各フレームのパッチベースのトークン埋め込みを計算する。
  • 局所的な時間窓に対する注意を導入する: y^l_{s,t} = sum_{t' in window} sum_s' Softmax(q^l_{s,t}·k^l_{s',t'}) v^l_{s',t'}.
  • 複数の隣接フレームから単一の attended key ベクトルを構築して空間-時間混合を実現するシフトトリックを適用する(式9–10)。
  • 各層の計算量を O(TS^2) に達成し、空間のみの注意コストに匹敵する。
  • 精度向上のために、クラス・トークンに対して軽量なグローバル時間注意(Temporal Attention)を任意で組み込む。
  • フレーム情報を要約する Summary トークン機構を検討し、key/value の計算時にそれに注意を向ける。

実験結果

リサーチクエスチョン

  • RQ1局所的な時間窓と空間-時間混合を組み合わせることで、動画トランスフォーマーにおける全空間-時間注意を効率的に近似できるか。
  • RQ2提案された注意機構は、既存のVideo Transformerと比較して FLOPs を抑えつつ競争力のある精度を維持できるか。
  • RQ3局所窓のサイズ、 ta 層配置、時間的集約が性能に与える影響はどのようか。
  • RQ4軽量な時間的集約とサマリートークンは、最小のコストで有意義な利得を提供するか。

主な発見

  • O(TS^2) の計算量を達成し、空間のみの注意に匹敵する一方で、他の効率志向の Video Transformer を上回る。
  • テスト設定の中で最良の局所窓サイズは t_w = 1 で、t_w = 0(空間のみ)より有意な利得を示し、境界効果のため t_w = 2 ではいくらか劣化。
  • キーと値ベクトルへの空間-時間混合は、混合バリアントの中で最も高い精度向上をもたらす。
  • Temporal Attention レイヤーを1つ用いた時間的集約は、単純な時間平均より Top-1 を約2ポイント改善する。より多くの TA レイヤーはさらに効果を示さない。
  • SSv2、Kinetics-400、Kinetics-600、Epic Kitchens で、X-ViT は最先端に匹敵またはそれを上回りつつ TimeSformer および ViViT 系よりはるかに効率的。
  • 入力フレームを8から16に増やすと SSv2 で約1.8% の Top-1 効得、32 フレームは追加の小さな利得。

より良い研究を、今すぐ始めましょう

論文設計から論文執筆まで、研究時間を劇的に削減しましょう。

クレジットカード登録不要

このレビューはAIが作成し、人間の編集者が確認しました。