Giter VIP home page Giter VIP logo

memvit's Introduction

MeMViT: Memory-Augmented Multiscale Vision Transformer for Efficient Long-Term Video Recognition

This is a PyTorch implementation of the MeMViT paper (CVPR 2022 oral):

@inproceedings{memvit2022,
  title={{MeMViT: Memory-Augmented Multiscale Vision Transformer for Efficient Long-Term Video Recognition}},
  author={Wu, Chao-Yuan and Li, Yanghao and Mangalam, Karttikeya and Fan, Haoqi and Xiong, Bo and Malik, Jitendra and Feichtenhofer, Christoph},
  booktitle={CVPR},
  year={2022}
}

MeMViT builds on the MViT models:

@inproceedings{li2021improved,
  title={{MViTv2}: Improved multiscale vision transformers for classification and detection},
  author={Li, Yanghao and Wu, Chao-Yuan and Fan, Haoqi and Mangalam, Karttikeya and Xiong, Bo and Malik, Jitendra and Feichtenhofer, Christoph},
  booktitle={CVPR},
  year={2022}
}
@inproceedings{fan2021multiscale,
  title={Multiscale vision transformers},
  author={Fan, Haoqi and Xiong, Bo and Mangalam, Karttikeya and Li, Yanghao and Yan, Zhicheng and Malik, Jitendra and Feichtenhofer, Christoph},
  booktitle={ICCV},
  year={2021}
}

Model checkpoints

On the AVA dataset:

name mAP #params (M) GFLOPs pre-train model model
MeMViT-16, 16x4 29.3 35.4 58.7 K400-pretrained model model
MeMViT-24, 32x3 32.3 52.6 211.7 K600-pretrained model model
MeMViT-24, 32x3 34.4 52.6 211.7 K700-pretrained model model

Installation

This repo is a modification on the PySlowFast repo. Installation and preparation follow that repo.

Training

Please modify the data paths and pre-training checkpoint path in config file accordingly and run, e.g.,

python tools/run_net.py \
  --cfg configs/AVA/MeMViT_16_K400.yaml \

Evaluation

To evaluate a pretrained MeMViT model:

python tools/run_net.py \
  --cfg configs/AVA/MeMViT_16_K400.yaml \
  TRAIN.ENABLE False \
  TEST.CHECKPOINT_FILE_PATH path_to_your_checkpoint \

Acknowledgement

This repository is built based on the PySlowFast.

License

MeMViT is released under the CC-BY-NC 4.0.

memvit's People

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.