Extending Video Masked Autoencoders to 128 frames

Video understanding has witnessed significant progress with recent video foundation models demonstrating strong performance owing to self-supervised pre-training objectives; Masked Autoencoders (MAE) being the design of choice. Nevertheless, the majority of prior works that leverage MAE pre-training have focused on relatively short video representations (16 / 32 frames in length) largely due to hardware memory and compute limitations that scale poorly with video length due to the dense memory-intensive self-attention decoding. One natural strategy to address these challenges is to subsample tokens to reconstruct during decoding (or decoder masking). In this work, we propose an effective strategy for prioritizing tokens which allows training on longer video sequences (128 frames) and gets better performance than, more typical, random and uniform masking strategies. The core of our approach is an adaptive decoder masking strategy that prioritizes the most important tokens and uses quantized tokens as reconstruction objectives. Our adaptive strategy leverages a powerful MAGVIT-based tokenizer that jointly learns the tokens and their priority. We validate our design choices through exhaustive ablations and observe improved performance of the resulting long-video (128 frames) encoders over short-video (32 frames) counterparts. With our long-video masked autoencoder (LVMAE) strategy, we surpass state-of-the-art on Diving48 by 3.9 points and EPIC-Kitchens-100 verb classification by 2.5 points while relying on a simple core architecture and video-only pre-training (unlike some of the prior works that require millions of labeled video-text pairs or specialized encoders).

Paper

References (64)

Scroll for more · 38 remaining

Similar papers

Peer review

Reviewer EcJb5/10 · confidence 4/52024-07-12

Summary

This paper studies the MAE pretraining of long videos. To address the challenges of hardware memory and compute limitations, this paper propose an effective strategy of decoder masking, subsampling tokens as reconstruction targets. This strategy leverage the MAGVIT-based tokenizer, prioritizes the most important tokens and uses quantized tokens as reconstruction objectives. The proposed decoder masking strategy outperforms previous masking strategies on EK-100 and Diving48. With 128 frames as input for pretraining and finetuning, the video encoder obtain better performance compared with the short-video (32 frames) pretraining.

Strengths

1. Study the MAE-based pretraining of long videos. The proposed adaptive decoder masking strategy solves the OOM problem of long-video training and beats some previous masking strategy on downstream tasks. 2. Compared to 32 frames MAE-based pretraining, the proposed method with 128 frames obtains better performance on EK-100 and Diving48.

Weaknesses

1. This paper only shows the results of 32 frames input and 128 frames input. To figure out the best setting of input frame number, it would be better to show experimental results when increasing the frame number from 16 to 128 gradually for pretraining and finetuning (while keeping the similar computational cost at inference). 2. This paper does not include any experiments or theory analysis to explain why to convert MAGVIT to FSQ-MAGVIT for reconstruction targets and adaptive token selection. 3. Only 2 downstream tasks are used for the main experiments.

Questions

1. Why does this work convert MAGVIT to FSQ-MAGVIT for reconstruction targets and adaptive token selection? 2. Results on other long-form video downstream tasks.

Rating

5

Confidence

4

Soundness

3

Presentation

2

Contribution

3

Limitations

Yes.

Authorsrebuttal2024-08-10

Please let us know whether we address all the issues

Dear reviewer, Thank you for the comments on our paper. We have submitted the response to your comments and a common response. Please let us know if you have additional questions so that we can address them during the discussion period. We hope that you can consider raising the score after we address all the issues. Thank you

Reviewer UhsZ6/10 · confidence 5/52024-07-13

Summary

The paper proposes a novel MAGVIT-based adaptive tokenizer & masking module to extend VideoMAE to 128 frames. The tokenizer & masking module is individually trained and applied offline, making it possible for VideoMAE to reconstruct sparser (but important) and more semantically informative targets. The experimental results show that the approach allows for significant memory savings, enabling pre-training on longer video clips and leading to improved performance on downstream long video understanding tasks.

Strengths

1. The paper is well-written and easy to follow, with clear explanations of the proposed method and experimental results. 2. The paper addresses an important issue in video understanding, namely the scalability of video masked modeling for longer sequences. The approach in this paper is relatively orthogonal to prior work in the field. 3. The proposed module is individually trained and applied offline, which avoids the training difficulties and extra overhead in videomae pretraining that come with the complex designs. 4. The proposed module provides both decoder masking and high semantic information tokens, which saves computational overhead and improves model performance. The effectiveness of each part is verified through ablation experiments.

Weaknesses

1. The major weaknesses of this paper include the limited dataset sizes, small model sizes, and narrow range of task types, as mentioned in Section 5. I'm interested in the model's performance on action detection and temporal action detection tasks.

Questions

1. In Table 4a, the 10%+5% masking even exceeds the case without decoder masking, and perhaps the authors could provide more explanation for this phenomenon.

Rating

6

Confidence

5

Soundness

4

Presentation

4

Contribution

3

Limitations

The author discusses the limitations of the work, which I guess are largely due to resource limitations.

Authorsrebuttal2024-08-10

Please let us know whether we address all the issues

Dear reviewer, Thank you for the comments on our paper. We have submitted the response to your comments and a common response. Please let us know if you have additional questions so that we can address them during the discussion period. We hope that you can consider raising the score after we address all the issues. Thank you

Reviewer 9WAZ3/10 · confidence 4/52024-07-14

Summary

This video understanding paper extends the video mae idea to a longer 128 frames. They use the MAGVIT tokenizer to achieve this and test the approach on Diving-48 and epic kitchens. Both achieved an improved score despite using a pretty standard network and pre-training

Strengths

The use of a MAGVIT encoder masking strategy within a masking strategy of videomae The use of FSQ instead of VQ for the codebook encoding

Weaknesses

The performance for EK-100 isn't that great. The approach needs to be tested on longer sequence videos, maybe to make a more significant difference than the current two. There is limited innovation on the actual network used

Questions

Why does the approach only make sota for the verbs? What is the limit on the length of tokens

Rating

3

Confidence

4

Soundness

4

Presentation

4

Contribution

2

Limitations

The idea of focusing on more extended encodings is interesting, but the dataset performance doesn't seem to make it worth it.

Authorsrebuttal2024-08-10

Please let us know whether we address all the issues

Dear reviewer, Thank you for the comments on our paper. We have submitted the response to your comments and a common response. Please let us know if you have additional questions so that we can address them during the discussion period. We hope that you can consider raising the score after we address all the issues. Thank you

Reviewer 9WAZ2024-08-12

ok thanks for this detailled response, especially about the nouns/verb issue, I still have a concern about the length of the video sequences that are possible to be used though

Authorsrebuttal2024-08-13

Addressing the length of video sequences

Dear reviewer, Thanks for acknowledging our response, and we are encouraged that we have addressed your concerns on nouns/verbs. To demonstrate our model’s capability on longer video sequences, below, we provide a break-down of the performance improvement of our model over previous SoTA [1] on EPIC-Kitchens-Verbs based on video durations. |Model|0s-4s|4s-8s|8s-16s|16s-32s|>32s| |-------|------|-------|--------|---------|------| |AVION - Large (previous SoTA)|75.6|66.0|64.7|66.3|51.9| |Ours - Large|77.8|67.0|66.2|72.2|57.7| |Relative Improvement (%)|+2.9|+1.5|+2.3|+8.9|+11.2| We observe sustained performance improvements on videos with longer durations signifying our model’s capability on longer sequences. When we consider the number of frames, compared to contemporary video encoders [2, 3, 4], we can process 8X their number of frames. As stated in previous comments, we leave the exciting opportunity of using our video encoder as a backbone of an e2e long-video understanding system [5, 6] or adding a memory module to increase sequence length [7] further to the future works. ### More evidence on Nouns vs Verbs and further improvements on EK-Nouns On a side note, to augment our earlier point that EK-100-Noun can indeed be improved by large-scale pre-training, we post-trained our best model on labeled Kinetics710 dataset containing approximately 1M videos, and found that we can improve EK-100 Noun accuracy from 59.5 → 61.8% and retain our SoTA on EK-100 Verbs at 75.0%. Overall, our action classification accuracy is now 52.1% which places us at Rank 3, only lagging behind AVION [1] and M&M [8]. AVION uses 4M Ego4D clip-text pairs and M&M uses 60M clip-text pairs in their pretraining. Note that our Verb accuracy didn’t improve with large-scale pre-training datasets and we achieve SoTA on Verbs despite using an order of magnitude less data than these two methods. This matches our intuition that EK-100 Nouns and EK-100 Verbs require different expertise. We will include add this to our discussion in the final submission and we thank the reviewer for pointing the difference out. [1] Zhao, Yue, and Philipp Krähenbühl. "Training a large video model on a single machine in a day." arXiv preprint arXiv:2309.16669 (2023). [2] Wang, Limin, et al. "Videomae v2: Scaling video masked autoencoders with dual masking." Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition. 2023. [3] Wang, Yi, et al. "Internvideo2: Scaling video foundation models for multimodal video understanding." arXiv preprint arXiv:2403.15377 (2024). [4] Ryali, Chaitanya, et al. "Hiera: A hierarchical vision transformer without the bells-and-whistles." International Conference on Machine Learning. PMLR, 2023. [5] Chen, Guo, et al. "Video mamba suite: State space model as a versatile alternative for video understanding." arXiv preprint arXiv:2403.09626 (2024). [6] Sun, Yuchong, et al. "Long-form video-language pre-training with multimodal temporal contrastive learning." Advances in neural information processing systems 35 (2022): 38032-38045. [7] Wu, Chao-Yuan, et al. "Memvit: Memory-augmented multiscale vision transformer for efficient long-term video recognition." Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition. 2022. [8] Xiong, Xuehan, et al. "M&m mix: A multimodal multiview transformer ensemble." arXiv preprint arXiv:2206.09852 (2022).

Reviewer LVuv6/10 · confidence 4/52024-07-16

Summary

This paper focuses on efficiently extending VideoMAE to much longer videos. It proposes an adaptive decoder masking strategy that utilizes a MAGVIT tokenizer to localize the importance of each token, which becomes targets that reduce the memory/computation of decoders. The motivation aims to scale the input video along the temporal dimension while maintaining pre-training efficiency. The key innovation is using a tokenizer to generate masks and targets, significantly reducing the training burden. The evaluation mainly focuses on long-video recognition tasks like (Epic-Kitchens-100 and Diving-48).

Strengths

The idea of using tokenization to select important tokens seems novel to me and can significantly improve the decoder's training efficiency in VideoMAE. The ablation of Table 1/2/4 clearly shows each component's effectiveness, while there is space for improvement. SoTA performance achieved without using a larger-scale dataset and under an efficient training budget setting seems promising.

Weaknesses

My main concern is the fixed budget setting (128/32 frames and 15% masking ratio on two datasets), which limits the potential to become a standard baseline for further research. This method can work well with models of various sizes and longer videos, so it is important to show that it also performs well in standard VideoMAE settings (short-video datasets). As the model grows larger, the computation of the decoder increases not only with the number of frames but also with the model size. Therefore, I am eager to see the proposed method’s results (efficiency/performance) on different datasets, number of frames, and mask ratios. In short, I am not convinced by the current results that the proposed masking strategy can be a future research baseline. The quality of the tokenizer is another important aspect that needs to be included. Table 4 shows that using MAGVIT as a target can significantly improve performance, indicating there are insights behind this choice. Moreover, the novel token selection module may influence the tokenization results or potentially benefit reconstruction. However, I cannot find tokenizer-related results. Specifically, why does utilizing such a tokenizer significantly reduce the number of tokens? Why choose MAGVIT instead of other options? The 3D tokenizer compresses the temporal dimension several times; could this lead to inferior performance?

Questions

Please see above weakness.

Rating

6

Confidence

4

Soundness

3

Presentation

2

Contribution

3

Limitations

Yes.

Authorsrebuttal2024-08-10

Please let us know whether we address all the issues

Dear reviewer, Thank you for the comments on our paper. We have submitted the response to your comments and a common response. Please let us know if you have additional questions so that we can address them during the discussion period. We hope that you can consider raising the score after we address all the issues. Thank you

Reviewer LVuv2024-08-12

Response to rebuttal

Thanks for the authors' rebuttal. It addressed most of my concerns. The scaling of model size seems promising. And additional results on Something-something are helpful. I have one concern: What is the MagViTv2 inference cost regarding memory and speed? Will it become a bottleneck if we further extend the number of frames?

Authorsrebuttal2024-08-14

Thanks for your response

Dear reviewer Thank you for responding to our rebuttal and we are glad to have addressed most of your concerns. We will incorporate your several feedbacks in the final version! Below, we answer your follow-up questions: `What is the MagViTv2 inference cost regarding memory and speed?` We benchmarked MagViTv2 inference cost using a single TPUv4 device. We are able to use a maximum batch size of 32 with each batch element containing one clip of 16 frames. The peak memory usage is 6.4Gi and average throughput is 195 videos/sec. For longer video clips, as mentioned in lines 812-813 of the main paper, we simply slide a window of 16 frames over the entire video with a stride of 16 frames. So, the inference costs would scale linearly with video lengths while the memory requirement stays the same. `Will it become a bottleneck if we further extend the number of frames?` No, MagViTv2 will not become a bottleneck for longer videos because MAE training costs scale quadratically with video length while MagViTv2 costs scale linearly. In addition, MagViTv2 tokens can be computed and stored offline for the entire dataset just once as we do not update the tokenizer during MAE training. Note that we typically train MAEs for thousands of epochs, so the amortized cost of MagViTv2 computations is an order of magnitude less if we precompute the tokens.

Reviewer EcJb2024-08-12

Thanks for the authors' effort in the rebuttal. The response has addressed my first question (in the weaknesses). However, the authors have not provided experiments between different tokenizers under various ratios of adaptive masking, and the ablation studies include only a limited range of downstream tasks. I am still concerned about whether using FSQ in long-video MAE methods is necessary compared to a standard MAGVIT. Additionally, the experiments do not include various long-form video tasks, such as video action segmentation, temporal action localization, and spatiotemporal action detection. In summary, while the research topic is meaningful, I concerns that the experiments in this paper could not fully demonstrate the effectiveness and scalability of this method. Therefore, I would lower my rating slightly.

Authorsrebuttal2024-08-13

Additional clarifications on tokenizer choice

We thank the reviewer for such timely feedback. We agree with the reviewer that our exposition on the tokenizer can be improved further. However, we would like to point out that the focus of our work has been to find a way to effectively scale MAEs to 128 frames and we saw our tokenizer explorations as a means to achieve this goal. In addition, since tokenizer is the first stage of our pipeline, it is expensive to undertake ablations on tokenizer, especially, when we only see very limited gains when we switch tokenizers (as shared in common rebuttal). So, we chose the best tokenizer from literature [1] and picked one of the two best quantizers [1, 2]. Nevertheless, we are glad to see the reviewer's interest in our work and appreciate the experiment suggestions. We hope our response below addresses your concerns: `the authors have not provided experiments between different tokenizers under various ratios of adaptive masking` We thank the reviewer for this suggestion. We would first like to clarify that our tokenizer indeed sees different masking ratios during training as we fix the token budget at batch-level (on a batch size of 256) instead of at example level, and hence it can work at varying mask levels in the MAE training stage. For this reason, we treated the token budget of the tokenizer as a hyper-parameter and chose it to be 35% so that it can support a range around that value. We agree with the reviewer that both the choice of the tokenizer and the token budget can be further optimized to boost the performance of our method. We didn’t pursue this route as our focus was on enabling an effective strategy for long-video pre-training, and leave the exploration on tokenizers for understanding tasks to future works. `I am still concerned about whether using FSQ in long-video MAE methods is necessary compared to a standard MAGVIT` We chose FSQ because it's simple and performs well on reconstruction (see below for detailed results). However, we stress that the choice of quantizer is not critical for the downstream performance of our method, and we hence also do not make any claims encouraging FSQ in our work. It is likely that the crux of our paper and all the key findings may very well be unchanged had we picked LFQ. Below, we evaluate our pre-trained FSQ and LFQ tokenizers by varying the masking ratio to see how they respond. We expect the PSNR to increase (and FVD to decrease) as the token budget increases. We find that FSQ adheres to this expected behavior better than LFQ does. Especially at a lower token budget, performance of FSQ is better than LFQ. This criteria is well-suited for decoder masking where we use very high masking ratios. |Token budget|LFQ-PSNR | LFQ-FVD|FSQ-PSNR| FSQ-FVD| |-------------|-----|------|-----|-----| |15%|19.2|174.3|23.0|60.6| |20%|21.1|56.1|24.2|29.0| |25%|22.8|25.1|24.9|18.3| |30%|24.3|13.8|25.4|13.4| |35%|25.4|9.2|25.8|10.7| |40%|25.7|7.9|26.1|9.6| |45%|25.0|8.9|26.3|9.0| |50%|24.0|11.7|26.4|9.0| However, despite the reconstruction capacity, in our previous ablations we have shown that the MAE pre-training is not highly sensitive to the choice of quantizer in the Magvit. |Quantizer|EK-100| |----|---| |LFQ |46.2| |FSQ |46.4| [1] Yu, Lijun, et al. "Language Model Beats Diffusion--Tokenizer is Key to Visual Generation." arXiv preprint arXiv:2310.05737 (2023). \ [2] Mentzer, Fabian, et al. "Finite scalar quantization: Vq-vae made simple." arXiv preprint arXiv:2309.15505 (2023).

Authorsrebuttal2024-08-13

Additional task types

We provided our results on short-clip (Something-Something-V2) and long-clip classification tasks (EPIC-Kitchens-100, Diving48) and demonstrated SoTA performance. In response to reviewer 9WAZ, we also provided a breakdown of our results according to duration of the videos, and found that [our method outperforms SoTA especially on the longer duration clips](https://openreview.net/forum?id=bFrNPlWchg&noteId=DvCiSrKkm7) i.e. >16s in length. One key issue that we faced when selecting datasets for evaluation is the lack of long-form video benchmarks. Many of the tasks that operate on long videos only require short video-contexts [1, 2, 3] and can be solved by sliding a short-clip window over the video lengths. For example, a single frame is shown to be enough to answer QA tasks in ActivityNet [2], which is also a widely used benchmark for temporal action localization. Recently, new benchmarks have come up that are shown to require a longer temporal certificate [1, 4, 5], but unfortunately they require multimodal understanding, which is beyond the scope of this paper, and we leave them to future works. [1] Mangalam, Karttikeya, Raiymbek Akshulakov, and Jitendra Malik. "Egoschema: A diagnostic benchmark for very long-form video language understanding." Advances in Neural Information Processing Systems 36 (2024). \ [2] Lei, Jie, Tamara L. Berg, and Mohit Bansal. "Revealing single frame bias for video-and-language learning." arXiv preprint arXiv:2206.03428 (2022). \ [3] Buch, Shyamal, et al. "Revisiting the" video" in video-language understanding." Proceedings of the IEEE/CVF conference on computer vision and pattern recognition. 2022. \ [4] Wang, Weihan, et al. "LVBench: An Extreme Long Video Understanding Benchmark." arXiv preprint arXiv:2406.08035 (2024). \ [5] Rawal, Ruchit, et al. "Cinepile: A long video question answering dataset and benchmark." arXiv preprint arXiv:2405.08813 (2024).

Authorsrebuttal2024-08-14

We hope that our response clarifies the rationale behind tokenizer choice and the choice of task types. We also hope that the break-down of our performance improvements along the dimension of video durations further substantiates our claims. We would like to request the reviewer to reevaluate our work in light of our response.

Authorsrebuttal2024-08-14

Please let us know whether we address all the issues by the end of discussion period

Dear reviewer, Thank you for the comments on our paper. We have submitted a response to your comments and a common response. As the other reviewers have participated in the discussions, we would like to ask you to let us know whether you have additional questions. We hope that you can consider raising the score after we address all the issues. Thank you

Program Chairsdecision2024-09-25

Decision

Accept (poster)

© 2026 NYSGPT2525 LLC