facebookresearch/pytorchvideo
A deep learning library for video understanding research.
PyTorchVideo – A Deep‑Learning Library for Video Understanding
What it is – PyTorchVideo is an open‑source Python library built on top of PyTorch that provides ready‑made components for research and development of video‑based AI models. It bundles video‑specific data loaders, transforms, and a model zoo of state‑of‑the‑art architectures (e.g., SlowFast, X3D, Multiscale Vision Transformers) together with utilities for efficient training and inference.
Why it matters – Video adds a temporal dimension to visual data, making it far more demanding than static images. PyTorchVideo abstracts away the low‑level plumbing (frame extraction, temporal augmentations, batching, GPU‑accelerated ops) so researchers can focus on model ideas rather than engineering details. The library also ships pretrained checkpoints and benchmark results, enabling reproducible experiments.
Key features
- PyTorch‑native – works seamlessly with the broader PyTorch ecosystem (optimizers, schedulers, distributed training, TorchVision, etc.).
- Model zoo – dozens of pretrained video models (SlowFast, X3D, MViT, etc.) with benchmark scores and one‑click download scripts.
- Efficient video pipelines – fast video‑specific transforms, temporal sampling, and support for accelerated inference on CPUs, GPUs, and mobile devices (e.g., an X3D model runs ~8× faster than real‑time on a Galaxy S10).
- Dataset loaders – built‑in support for popular video datasets (Kinetics, AVA, Something‑Something, etc.) with flexible configuration.
- Extensible – modular design lets you plug in custom models, transforms, or data sources without rewriting core code.
- Documentation & tutorials – a website with quick‑start guides, example notebooks, and a “tutorials” folder in the repo.
Typical use‑cases
- Academic research on action recognition, video classification, or spatio‑temporal detection.
- Prototyping video‑centric AI products (e.g., real‑time activity monitoring, video search, sports analytics).
- Benchmarking new video architectures against established baselines.
- Deploying lightweight video models on edge devices (the repo showcases a mobile‑friendly X3D demo).
Getting started
# Inside a conda environment with Python ≥3.7
pip install pytorchvideo
After installation, follow the tutorials on the official site or run the examples in the tutorials/ directory.
Community & support
- Slack: join the
#pytorchvideochannel via the badge in the README. - GitHub: issue tracker, pull‑request workflow, and contribution guidelines (
CONTRIBUTING.md). - Model zoo: documented in
docs/source/model_zoo.mdwith links to pretrained weights.
License – Apache 2.0, allowing free use, modification, and distribution.
Citation – If you use PyTorchVideo in a publication, cite the accompanying ACM MM 2021 paper (BibTeX provided in the README).
All information above is taken directly from the repository’s README and linked documentation.
Related
- Project
- Project
- Project
- Project