Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
A

ab-av1

> 编程语言
Open source

AV1 re-encoding using ffmpeg, svt-av1 & vmaf.

957 stars0 likes0 views
WebsiteGitHub

About

AV1 re-encoding using ffmpeg, svt-av1 & vmaf.

ab-av1

AV1 video encoding tool with fast VMAF sampling & automatic encoder crf calculation. Uses ffmpeg, svt-av1 & vmaf.

Also supports other ffmpeg compatible encoders like libx265 & libx264.

Command: auto-encode

Automatically determine the best crf to deliver the --min-vmaf and use it to encode a video or image.

Two phases:

  • crf-search to determine the best --crf value
  • ffmpeg to encode using the settings
ab-av1 auto-encode [OPTIONS] -i  --preset  --min-vmaf 

Command: crf-search

Interpolated binary search using sample-encode to find the best crf value delivering --min-vmaf & --max-encoded-percent.

Outputs:

  • Best crf value
  • Mean sample VMAF score
  • Predicted full encode size
  • Predicted full encode time
ab-av1 crf-search [OPTIONS] -i  --preset  --min-vmaf 

Notable options

  • --min-xpsnr may be used as an alternative to VMAF.

Command: sample-encode

Encode short video samples of an input using provided crf & preset. This is much quicker than full encode/vmaf run.

Outputs:

  • Mean sample VMAF score
  • Predicted full encode size
  • Predicted full encode time
ab-av1 sample-encode [OPTIONS] -i  --crf  --preset 

Notable options

  • --xpsnr specifies calculation of XPSNR score instead of VMAF.

Command: encode

Invoke ffmpeg to encode a video or image.

ab-av1 encode [OPTIONS] -i  --crf  --preset 

Notable options

These also apply to auto-encode.

  • --verify checks the finished encode before it is moved into place: decodes it in full failing on decode errors (--verify-decode) & fails if its duration does not match the input within 2s (--verify-duration). Either check can be enabled on its own. The encoder can otherwise exit successfully having written a damaged or cut short result, e.g. from a truncated input.
  • --fail-fast stops the encode at the first ffmpeg reported error instead of writing a damaged result.

Command: vmaf

Full VMAF score calculation, distorted file vs reference file. Works with videos and images.

  • Auto sets model version (4k or 1k) according to resolution.
  • Auto sets n_threads to system threads.
  • Auto upscales lower resolution videos to the model.
ab-av1 vmaf --reference  --distorted 

Command: xpsnr

Full XPSNR score calculation, distorted file vs reference file. Works with videos and images.

ab-av1 xpsnr --reference  --distorted 

JSON output

See --stdout-format json docs.

Install

Arch Linux

Available in the AUR.

Linux

Pre-built statically linked x86_64-unknown-linux-musl binary included in the latest release.

Windows

Pre-built ab-av1.exe included in the latest release.

Using cargo

Latest release

bash
cargo install ab-av1

Latest code direct from git

bash
cargo install --git https://github.com/alexheretic/ab-av1

Requirements

ffmpeg newer than git-2022-02-24 with libsvtav1, libvmaf, libopus enabled.

ffmpeg should be in $PATH.

Debug

Enable debug logs by setting env var RUST_LOG=ab_av1=debug. This includes all ffmpeg calls.

$ RUST_LOG=ab_av1=debug ab-av1 auto-encode -i vid.mkv

Minimum supported rust compiler

Maintained with latest stable rust.

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

Rust

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言