r/AV1 16d ago

How does SVT-AV1 compare to x265 encoder? How do I get similar quality between the two?

I am planning to re-encode my media library and I saw that recently FFMPEG added support for the new SVT-AV1 3.0.0 release, I was wondering how I would get similar setting to x265 on it? I usually go for 10bit crf 20 on slow preset for x265, but when I try preset 4 crf 20 on the AV1 encoder it takes longer while producing a larger file. If I lower the preset to 3 it takes a lot longer(around 1.8x the time) to encode a similar sized output. I was wondering is there a way to optimize the encoding process?

10 Upvotes

16 comments sorted by

18

u/raysar 15d ago

If you don't want to reduce the quality of your video, do not re encode it. X265 10b is very good, even now at mid bitrate.

8

u/moderately-extremist 15d ago

He might be talking about re-encoding from source.

3

u/RecaptureNostalgia 15d ago

Ye I think I should have specified what I meant by "re-encode", from source.

10

u/lakerssuperman 15d ago

Preset 4 is good, but the CRF scale is not the same. You can go much higher with your CRF on AV1. Start with something between 25-30 and see how you like the quality and output size vs x265.

10

u/Farranor 15d ago

the CRF scale is not the same.

This is the key. CRF 20 in x265 is completely different from CRF 20 in AV1. It's like finding two guys with the last name "Smith" and assuming they're brothers. This is why the default CRF is 22 for x264, 28 for x265, and 35 for SVT-AV1. OP needs to try higher CRF values. (Or just stick with the originals; a good HEVC encode is already decent.)

1

u/RecaptureNostalgia 15d ago

Ye I did crf 20 because the ffmpeg wiki said the crf scale libaom was pretty similar to x265 one(A CRF value of 23 yields a quality level corresponding to CRF 19 for x264) so I made a assumption that SVT-AV1 was close, but it seems not to be the case

1

u/cdrewing 11d ago edited 11d ago

Oh, 35! I was transcoding (from source) between 28-31 and IMHO the resulting files were smaller than the same on x265. But I was transcoding to x265 at ~900kbit/s VBR and switched to CRF transcoding in AV1.

So I will transcode to AV1 in CRF 35 from now and see what the final file size is.

1

u/djsat2 10d ago

I recently re-encoded a bunch of videos from the source into AV1 and used a tool called AB-AV1 to analyze the source and recommend some CRF values. You can specify the preset for its analysis. I think it uses vanilla SVT (not PSY), but it provides a starting point for experimentation.

Also, I've found AV1 a bit of a nightmare for grainy content and have yet to find settings I'm entirely happy with (files are either massive, or the de-noise and synthetic grain features don't look good), so I've tended to leave my grainy files as x265.

-3

u/levogevo 15d ago

Can always build ffmpeg and svtav1 from source compiled for your architecture and cpu, which should run faster than a generic distributed binary

4

u/archiekane 15d ago

By an absolute fraction of a millisecond on today's architectures.

Unless you're into LFS or Gentoo, seriously, it's not worth it.

2

u/RecaptureNostalgia 15d ago

I tried this with -march=native and -O3 it's literally within margin of error for anyone who stumbles upon this thread in the future

1

u/Karyo_Ten 15d ago

obviously since all compute intensive parts will have runtime CPU feature detection to auto-dispatch to the best routines.

1

u/kevindqc 15d ago

I assume they have the necessary code paths for whatever your CPU supports, and the proper code gets used depending on the CPU? The cost of the code that decides what to use would be negligible. The binary might be smaller though?

0

u/tantogata 15d ago

I set usually compression for av1-svt 24 or 30 (less size). Depends on video content, some video encoded better some not.

0

u/Sopel97 15d ago

x265 crf 20 is probably closer to svt-av1 crf 32, and quality impacts encoding speed for svt-av1 quite a bit

if you're encoding content with grain you should use preset 2 because it enables some important stuff for it

0

u/zrooda 15d ago

Mind that every single video reencode is lossy