All these Dalit threads on AV1 are shitting me off, so I wasted hours of my time to make this script for the BRAHMAs out there. It targets SSIM, only 1 input video file per folder though.
@echo off & mkdir temp
:loop
set /p crf="CRF? (30-50 reccomended): "
for %%f in (*.mkv, *.mp4, *.mov) do (
ffmpeg -i "%%f" -c:v libsvtav1 ^
-crf %crf% -preset 4 -pix_fmt yuv420p10le -svtav1-params ^
keyint=2s:lookahead=120:tune=0:enable-variance-boost=1:variance-boost-strength=3:variance-octile=4 ^
-c:a libopus -b:a 64k -y "%%f_CRF-%crf%_AV1.webm"
echo: & echo SSIM result:
ffmpeg -hide_banner -loglevel error -i "%%f" -c:v libx264 -pix_fmt yuv420p10le ^
-preset ultrafast -crf 0 -y temp/temp_source_2_10b.mkv
ffmpeg -hide_banner -i "%%f_CRF-%crf%_AV1.webm" -i temp/temp_source_2_10b.mkv ^
-lavfi ssim -f null - 2>&1 | findstr "[Parsed_ssim"
echo:
)
goto loop
1 problem: AV1 cheats in SSIM. It intelligently preserves the structure of video but destroys fine detail. However these disable SSIM cheating:
tune=0 Prioritizes perceptual/visual quality
enable-variance-boost=1
allocates more bits to low-contrast areas (such as skin, clouds, or foggy scenes) that typically suffer from blurring and artifacting in fixed-quantization encoding.
variance-boost-strength=3
Applies medium strength variance boost, enough to improve quality but not bloat bitrate.
variance-octile=4
Applies medium strength for the new 8x8 variance algorithm, which is used for adaptive quantization.
All of these not only give you better/accurate SSIM scores but allow AV1 to create subjectively medium to high quality AV1 encodes, not just compete in objective metric pissing contests.
Now that there's a place to post AV1 videos, I'll post them directly on https://umigalaxy.com/explore/general/494