AI tools, scored for your job
Get paid to train AI
🤝 You're in the Free & Open Source library — community-built tools you can use without paying. A different concept from our scored AI directory.
Home › Free & Open Source › Video › autocrop
✦ Free & open sourceVideo

autocrop

Automatically detects and crops faces from batches of pictures or video frames.

Batch face cropping for media pipelines

Open-source Python tool and CLI for automated, face-centered image and video frame cropping.

Free forever · source-available · Licence not stated in the repository
✓ Light setup✓ Browser-based✓ Real-time collaboration
6.5
ZEKAI
CLI face-cropping utility
Free & open source · Video
Ease of setup2
Usefulness8
Maintenance9.5
Community6.5
★ 680
GITHUB
Sep 2026
UPDATED
Licence not stated in the repository
LICENSE
🛠 Don't want to self-host? We can set it up →
⚡ Quick answer

Autocrop is a Python library and command-line utility that detects the biggest face in an image and crops around it using OpenCV's YuNet neural network. It suits video editors and media producers handling batch portrait processing or video frame extraction pipelines.

Runs on
Cross-platform
Hosting
Desktop
Languages
Python
License
Licence not stated in the repository

What it is

The tool ingests image files or standard input, identifies faces using a bundled ONNX model, and outputs resized or native-resolution crops centered on the subject. It integrates cleanly with shell utilities like find, fd, and GNU parallel for batch workflows, or directly via a Python API.

Who it's for

It suits video editors and developers integrating automated face framing into command-line scripts or Python pipelines. It does not suit users needing a graphical user interface or interactive face-selection tools.

Key features

OpenCV YuNet Detection

Uses a bundled neural network face detector that operates completely offline.

Flexible CLI and API

Accepts single images, standard input, or NumPy arrays directly through Python.

Video Frame Processing

Extracts video frames via FFmpeg and crops faces across sequences using shell loops.

Custom Dimensions

Allows explicit width, height, and face percentage scaling parameters.

How to start

Up and running in 3 steps

1
Install the package via pip install autocrop or set up your local development environment using uv sync.
2
Run autocrop on an individual image file from the command line, specifying custom width and height if needed.
3
Combine autocrop with FFmpeg or find in a shell script to automate face detection across batch image or video folders.
Real talk

Our honest verdict

What's great

  • Bundles the YuNet ONNX model locally so it runs entirely offline without runtime model downloads
  • Works seamlessly with standard stream piping and command-line batch tools like find and GNU parallel
  • Accepts both file paths and OpenCV-style NumPy arrays via a straightforward Python API
  • Supports dozens of image formats including JPEG, PNG, WebP, and TIFF

Where it falls short

  • Processes strictly one image per standard CLI invocation, requiring custom shell scripts for batch runs
  • Only handles the first frame of animated GIFs and ignores subsequent frames
  • Requires familiarity with command-line scripting and FFmpeg to process video files effectively
  • The repository metadata does not explicitly state an open-source license for the package itself
Cost

Pricing & license

The software is available as an open-source package with no hosted service options mentioned. The only cost is your own hardware and execution time.

Paid work

Open remote AI-training roles

880 open remote AI-training roles, updated November 15, 2026; most pay $20–$175 an hour. Zekai lists them free; the application goes to the employer’s platform.

See all open roles →
Compare

Alternatives

🎁 Free & open-source alternatives

These reviewed AI tools do the same job instantly — from our scored directory.

Get more

Use it, or have us set it up

📄 Free PDF: autocrop for Video
A plain-language guide to getting your first result. Sent to your inbox.
🔔 64 people want a full video tutorial — add your vote
🛠 Don't want to set it up yourself?
We'll install, host & configure autocrop for you — and train your team.
Get it done for you ↗
Questions

FAQ

How does autocrop handle video files?

Autocrop is designed for still images, but you can extract video frames using FFmpeg and pipe them through autocrop in a shell loop.

Can I run autocrop without an internet connection?

Yes. It vendors OpenCV Zoo's YuNet face detection model directly, allowing entirely offline processing.

What inputs does the Python API accept?

The Cropper crop method accepts standard filepaths or OpenCV-style BGR and BGRA NumPy arrays.

Radar

Latest AI news

✉️ The weekly free toolkit
The best new free & open-source tools for Video — one short email a week, in your language.
Free · 1 email/week · unsubscribe anytime
Get paid to train AI →

See Zekai first in Google