73:4%accuracy. In contrast, TimeSformer, also pretrained
on ImageNet-1K, only requires 416Tesla V100 GPU hours
to achieve a higher 75:8%accuracy (see Table 2). Furthermore, if we constrain SlowFast to be trained under a
somewhat similar computational budget as TimeSformerMethod Pretraining K400 SSv2
TimeSformer ImageNet-1K 75.8 59.5
TimeSformer ImageNet-21K 78.0 59.5
TimeSformer-HR ImageNet-1K 77.8 62.2
TimeSformer-HR ImageNet-21K 79.7 62.5
TimeSformer-L ImageNet-1K 78.1 62.4
TimeSformer-L ImageNet-21K 80.7 62.3
Table 3. Comparing the effectiveness of ImageNet-1K and
ImageNet-21K pretraining on Kinetics-400 (K400) and SomethingSomething-V2 (SSv2). On K400, ImageNet-21K pretraining leads
consistently to a better performance compared to ImageNet-1K pretraining. On SSv2, ImageNet-1K and ImageNet-21K pretrainings
lead to similar accuracy.
We present a convolution-free approach to video classification built
exclusively on self-attention over space and time. Our method, named
"TimeSformer," adapts the standard Transformer architecture to video by
enabling spatiotemporal feature learning directly from a sequence of
frame-level patches. Our experimental study compares different self-attention
schemes and suggests that "divided attention," where temporal attention and
spatial attention are separately applied within each block, leads to the best
video classification accuracy among the design choices considered. Despite the
radically new design, TimeSformer achieves state-of-the-art results on several
action recognition benchmarks, including the best reported accuracy on
Kinetics-400 and Kinetics-600. Finally, compared to 3D convolutional networks,
our model is faster to train, it can achieve dramatically higher test
efficiency (at a small drop in accuracy), and it can also be applied to much
longer video clips (over one minute long). Code and models are available at:
https://github.com/facebookresearch/TimeSformer.
Gedas Bertasius Heng Wang Lorenzo Torresani