Skip to main content

uavs3e

uavs3e is an open-source encoder for the AVS3 codec, developed by Chinese research institutions including Peking University Shenzhen Graduate School, Peng Cheng Laboratory, and Guangdong Bohua UHD Innovation Corporation.

The encoder receives infrequent updates, which may result in bugs and compilation issues. It supports AMD64 with AVX2, ARM with NEON, and LoongArch CPUs.

Installation​

The developers do not provide pre-built binaries, so you'll need to compile it yourself. Compilation requires GNU Make and CMake. As of August 2024, uavs3e does not compile with GCC 14, using Clang 18 instead resolves this issue.

git clone https://github.com/uavs3/uavs3e.git
cd uavs3e
mkdir build/linux && cd build/linux
cmake ../.. -DCOMPILE_10BIT=0 -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++
make -j 8

If you encounter undefined calls to close or lseek64 functions, add the following two lines at the top of the test/utest.c file:

#define _LARGEFILE64_SOURCE
#include <unistd.h>

Binaries will be available in the build/linux folder. On Linux, you can run make install to install the encoder (may require elevated permissions).

10-bit Support​

To enable 10-bit support, set -DCOMPILE_10BIT=1 in the CMake command. However, the encoder compiled with this flag has been reported to cause segmentation faults on some systems.

Usage​

The encoder cannot parse .y4m files, they need to be converted to raw video (.yuv) format.

Simple 8-bit FHD 23.976 fps input with QP 20 and raw avs3 bitstream output
uavs3enc -i input.yuv -w 1920 -h 1080 -d 8 --fps_num 24000 --fps_den 1001 -q 20 -o output.avs3
Speed 2, CRF 20, intra period 120, multithreaded
uavs3enc -i input.yuv -w 1920 -h 1080 -d 8 --fps_num 24000 --fps_den 1001 -p 120 --wpp_threads 8 --frm_threads 8 --speed_level 2 --rc_type 1 -q 20 -o output.avs3

Currently, uavs3e does not support piping.

Notes​

  1. Usable speed presets range from 0 to 4, where 0 is the slowest and 4 is the fastest.
  2. The encoder can be quite competitive, even compared with the newest AV1 and VVC encoders in terms of visual fidelity.
  3. uavs3d can be used to decode the output bitstream. For real-time playback, you need to have FFmpeg compiled with --enable-libuavs3d.