ChatPaper.aiChatPaper

ViViTトレーニングの最適化:行動認識における時間とメモリの削減

Optimizing ViViT Training: Time and Memory Reduction for Action Recognition

June 7, 2023
著者: Shreyank N Gowda, Anurag Arnab, Jonathan Huang
cs.AI

要旨

本論文では、ビデオトランスフォーマー、特にViViT(Video Vision Transformer)モデルのFactorised Encoderバージョンをアクション認識タスクのベースラインとして、その訓練時間とメモリ消費量の課題に取り組む。Factorised Encoderバリアントは、多くの最先端手法で採用されている後期融合アプローチに従っている。ViViTの異なるバリアントの中で速度と精度のトレードオフが優れているにもかかわらず、その訓練時間とメモリ要件は依然として大きな障壁となっている。我々の手法は、この障壁を低減するために設計されており、訓練中に空間トランスフォーマーを凍結するというアイデアに基づいている。これを単純に行うと低精度のモデルが得られるが、(1) 時間情報を処理するモジュールである時間トランスフォーマーを適切に初期化し、(2) 凍結された空間表現(入力画像の特定の領域に選択的に焦点を当てるモジュール)を時間トランスフォーマーに接続するコンパクトなアダプターモデルを導入することで、精度を犠牲にすることなく空間トランスフォーマーを凍結する利点を享受できることを示す。6つのベンチマークにわたる広範な実験を通じて、提案する訓練戦略が訓練コスト(約50%削減)とメモリ消費量を大幅に削減しつつ、ベースラインモデルと比較して性能を維持または最大1.79%向上させることを実証する。さらに、我々のアプローチにより、より大きな画像トランスフォーマーモデルを空間トランスフォーマーとして利用し、同じメモリ消費量でより多くのフレームにアクセスする能力が解放される。
English
In this paper, we address the challenges posed by the substantial training time and memory consumption associated with video transformers, focusing on the ViViT (Video Vision Transformer) model, in particular the Factorised Encoder version, as our baseline for action recognition tasks. The factorised encoder variant follows the late-fusion approach that is adopted by many state of the art approaches. Despite standing out for its favorable speed/accuracy tradeoffs among the different variants of ViViT, its considerable training time and memory requirements still pose a significant barrier to entry. Our method is designed to lower this barrier and is based on the idea of freezing the spatial transformer during training. This leads to a low accuracy model if naively done. But we show that by (1) appropriately initializing the temporal transformer (a module responsible for processing temporal information) (2) introducing a compact adapter model connecting frozen spatial representations ((a module that selectively focuses on regions of the input image) to the temporal transformer, we can enjoy the benefits of freezing the spatial transformer without sacrificing accuracy. Through extensive experimentation over 6 benchmarks, we demonstrate that our proposed training strategy significantly reduces training costs (by sim 50%) and memory consumption while maintaining or slightly improving performance by up to 1.79\% compared to the baseline model. Our approach additionally unlocks the capability to utilize larger image transformer models as our spatial transformer and access more frames with the same memory consumption.
PDF20December 15, 2024