Skip to main content

Video Representations Extractor (VRE) Video reader

Project description

FFmpeg Video

A python video reader that can read video frames using ffmpeg behind the scenes.

Install:

git clone https://gitlab.com/meehai/ffmpeg-video/
echo "$(pwd)/ffmpeg-video" >> ~/.bashrc
source ~/.bashrc
pip install -r ffmpeg-video/requirements.txt

Handle venv/conda/uv stuff on your own!

Usage:

from ffmpeg_video import FFmpegVideo
video = FFmpegVideo("video.mp4")
frame = video[ix] # returns a numpy array

TODOs:

  • A mid term plan is to get rid of ffmpeg-python package and just call ffmpeg ourselves.
  • Make the generic video class receive FrameReader and FrameWriter and make FFmpegVideo inherit FrameReader so we can have different backends for reading/writing.
  • More integration tests with actual videos

Potential future API:

from video_reader import Video
video = Video("video.mp4", backend="ffmpeg") # or read/write_backend ?
frame = video[ix]

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vre_video-0.1.2.tar.gz (8.6 kB view details)

Uploaded Source

File details

Details for the file vre_video-0.1.2.tar.gz.

File metadata

  • Download URL: vre_video-0.1.2.tar.gz
  • Upload date:
  • Size: 8.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for vre_video-0.1.2.tar.gz
Algorithm Hash digest
SHA256 07a2f02c14b23f7536a981de0522fbda16a364f9d912a0fca28e43efe8b186e0
MD5 42a74f2eec7055bac591f89bf742ab10
BLAKE2b-256 2627dccf89e14dd9f3fa54344f1f9f198e902c018bbb3160127a4850ebbfba02

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page