No project description provided
Project description
FFMPerative
Video Production at the Speed of Chat
FFMPerative is your copilot for video production workflows. Powered by Large Language Models (LLMs) and an intuitive chat interface, it makes complex tasks as simple as typing a sentence. Leverage the power of FFmpeg and cutting-edge machine learning tools without dealing with complex command-line arguments or scripts.
- Get Video Metadata
- Sample Image from Video
- Change Video Playback Speed
- Apply FFmpeg xfade transition filters
- Resize, Crop, Flip, Reverse Video/GIF
- Make a Video from a Directory of Images
- Overlay Image & Video for Picture-in-Picture
- Adjust Audio Levels, Background Noise Removal
- Speech-to-Text Transcription and Closed-Captions
- Split Video by N-second Gops or with Scene Detection
- Image Classifier Inference on every N-th Video Frame
Setup
Debian Package (recommended)
For debian, build and install the package:
dpkg-deb --build package_build/ ffmperative.deb
sudo dpkg -i ffmperative.deb
Configure the package to mount the directory at /home/$(hostname)/Videos/
by running:
echo -e "HUGGINGFACE_TOKEN=$HUGGINGFACE_TOKEN\nVIDEOS_PATH=/home/$(hostname)/Videos" | sudo tee /etc/ffmperative/config
Quickstart
To sample an image from a video clip, simply run FFMPerative from the command-line:
ffmperative "sample the 5th frame from /path/to/video.mp4"
Similarly, it's simple to split a long video into short clips via scene detection:
ffmperative "split the video '/path/to/my_video.mp4' by scene"
Try adding closed-captions with:
ffmperative "merge subtitles '/path/to/captions.srt' with video '/path/to/my_video.mp4' calling it '/path/to/my_video_captioned.mp4'"
FFMPerative excels in task compositition. For instance, curate video highlights by analyzing speech transcripts:
Windows & Mac Setup
Get the Docker Image
Pull an image from DockerHub:
docker pull smellslikeml/ffmperative:latest
Or clone this repo and build an image with the Dockerfile
:
git clone https://github.com/remyxai/FFMPerative.git
cd FFMPerative
docker build -t ffmperative .
Run FFMPerative in a Container
docker run -it -e HUGGINGFACE_TOKEN='YOUR_HF_TOKEN' -v /path/to/dir:/path/to/dir --entrypoint /bin/bash ffmperative:latest
Features
Python Usage
It's not required to install FFMPerative as a Debian package. If ffmpeg
is already available on your system, you can simply install FFMPerative through pip.
Base Installation
You can install the base version of ffmperative with:
# from PyPI
pip install ffmperative
# from source
git clone https://github.com/remyxai/ffmperative.git
cd ffmperative
pip install .
Usage
Simply import the library and pass your command as a string to ffmp
.
from ffmperative import ffmp
ffmp("sample the 5th frame from '/path/to/video.mp4'")
You can also use the cli with:
ffmp do --p "sample the 5th frame from '/path/to/video.mp4'"
Notebooks
Explore our notebooks for practical applications of FFMPerative:
Roadmap
- Basic Video Tools
- Release to PyPI after Agents are Added to Transformers
- Add ML-enabled Tools: demucs, PySceneDetect
- Docker Image with Latest FFmpeg
- Host .deb package for
apt-get
installation - Release LLM checkpoint fine-tuned to use FFMPerative Tools
Contributing
- Have a video processing workflow in mind? Want to contribute to our project? We'd love to hear from you! Raise an issue and we'll work together to design it.
Resources
Community
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for ffmperative-0.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 37b194ad90e72b8b326cf6b8993e493ba31549dfe53106bf690a4ec2e7307a66 |
|
MD5 | 8d6a46636d4d0e9af25a5ccfd6661d0d |
|
BLAKE2b-256 | c313b524315c8980dad28c603e839e028c21b41270fe7e74a80b26910580118e |