Skip to main content
QUICK REVIEW

[Paper Review] MaskViT: Masked Visual Pre-Training for Video Prediction

Agrim Gupta, Stephen Tian|arXiv (Cornell University)|Jun 23, 2022
Human Pose and Action RecognitionComputer Science45 citations
TL;DR

MaskViT pre-trains transformers via masked visual modeling with windowed attention and iterative decoding, enabling efficient, high-resolution video prediction and real-time robotic planning.

ABSTRACT

The ability to predict future visual observations conditioned on past observations and motor commands can enable embodied agents to plan solutions to a variety of tasks in complex environments. This work shows that we can create good video prediction models by pre-training transformers via masked visual modeling. Our approach, named MaskViT, is based on two simple design decisions. First, for memory and training efficiency, we use two types of window attention: spatial and spatiotemporal. Second, during training, we mask a variable percentage of tokens instead of a fixed mask ratio. For inference, MaskViT generates all tokens via iterative refinement where we incrementally decrease the masking ratio following a mask scheduling function. On several datasets we demonstrate that MaskViT outperforms prior works in video prediction, is parameter efficient, and can generate high-resolution videos (256x256). Further, we demonstrate the benefits of inference speedup (up to 512x) due to iterative decoding by using MaskViT for planning on a real robot. Our work suggests that we can endow embodied agents with powerful predictive models by leveraging the general framework of masked visual modeling with minimal domain knowledge.

Motivation & Objective

  • Motivate embodied agents to predict future visual observations conditioned on past frames and motor commands.
  • Propose a scalable masked visual pretraining framework for video prediction that reduces memory and computation.
  • Show that variable token masking and iterative decoding improve prediction quality and inference speed.
  • Demonstrate high-resolution video prediction (256x256) and real-time planning on a robot.

Proposed method

  • Use per-frame VQ-VAE (VQ-GAN) to tokenize frames into a grid of discrete tokens.
  • Pre-train a bidirectional transformer with window-restricted attention (spatial and spatiotemporal windows) using masked visual modeling with a variable masking ratio.
  • During training, mask a variable fraction (r in [0.5,1)) of future-frame tokens and train the model to reconstruct them from context tokens.
  • During inference, perform iterative decoding with a mask scheduling function to progressively reveal tokens, starting from a fully masked future and ending with full prediction.
  • Adopt an iterative non-autoregressive decoding scheme to speed up inference by reducing the number of forward passes compared to autoregressive generation.
  • Demonstrate planning on a real robot by integrating MaskViT with visual model-predictive control (CEM) and show speedups up to 512x over autoregressive methods.

Experimental results

Research questions

  • RQ1Can masked visual pretraining with windowed attention yield competitive video prediction performance?
  • RQ2Does a variable masking ratio during training better bridge the training-pretraining gap for video prediction?
  • RQ3How does iterative decoding with a mask scheduling function affect inference speed and prediction quality?
  • RQ4Is MaskViT capable of high-resolution video prediction and real-time planning in robotic tasks?

Key findings

  • MaskViT achieves competitive or state-of-the-art results on multiple video prediction datasets (BAIR, KITTI, RoboNet) with fewer parameters than some baselines.
  • Using spatiotemporal and spatial window attention reduces memory and enables 256×256 video prediction where prior methods struggle.
  • A variable masking ratio during training improves performance over fixed masking, reducing training-test mismatch.
  • Iterative decoding with a mask scheduling function yields substantial inference speedups (up to 512×) over autoregressive generation.
  • MaskViT enables visual model-predictive control on a real robot with practical planning speeds (approx. 6.5 seconds per CEM iteration).
  • For BAIR with action conditioning, MaskViT shows significant FVD improvements when actions are included.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.