meta-pytorch/torchcodec
Media decoding and encoding for PyTorch: videos, images, and audio, on CPU and GPU. observed · 2026-09-03
Health v2 · maintenance only
87/100
- Activity 100
- Release rhythm 85
- Longevity 59
How is this computed?
round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-09-03. Adoption (stars, forks) is never an input.
- gap_med: 32
- age_days: 826
- days_rel: 20
- days_push: 0
- n_releases_24m: 20
Adoption not part of the score
1160 stars · 123 forks observed · 2026-09-03
What it is AI-extracted, prompt v1, taxonomy v1, 2026-08-30, confidence not recorded
TorchCodec is a PyTorch-native library for decoding and encoding videos, audio, and images into PyTorch tensors on CPU and CUDA GPU, built on top of FFmpeg. It provides Pythonic APIs for frame-level video access, audio decoding, and encoding, designed for ML training and inference pipelines.
Use cases
- decode video files into pytorch tensors for training
- load video frames by index or timestamp for model training
- decode audio into tensors for speech models
- encode tensors back into video or audio files
- gpu-accelerated video decoding with cuda
- convert images to tensors without ffmpeg
- build video data loading pipelines for pytorch
When to choose
- you train or run inference with PyTorch on video, audio, or image data
- you want tensors directly instead of numpy arrays or raw frames
- you need fast GPU (CUDA) media decoding
- you want a simple Pythonic API over FFmpeg's complexity
When to avoid
- you need a general-purpose media tool like ffmpeg CLI
- your project does not use PyTorch
- you need exotic codecs or container formats outside FFmpeg's coverage
- you need streaming playback rather than tensor decoding
Facets
library · maturity active
video-processing audio-processing image-processing machine-learning machine-learning deep-learning media image-processing python windows cross-platform pytorch ffmpeg tensor media-decoding media-encoding cuda video-decoder data-loading video audio linux macos gpu
2 sources
- readme: https://github.com/meta-pytorch/torchcodec · fetched 2026-09-03 · dcd7c5813daa
- homepage: http://meta-pytorch.org/torchcodec/ · fetched 2026-08-29 · fc4bcdccfb7c
Member repositories
| Repository | Role | Health v2 |
|---|---|---|
| meta-pytorch/torchcodec | main | 87 |
For agents
markdown · JSON · MCP: product_card(name="meta-pytorch/torchcodec")
Data as of 2026-08-30T08:39:29.467469+00:00 · Report a problem