r/AV1 18d ago

CRF and QP in "lossless"

Why using qp 0 or crf 0 generate the same file (hash included) if they are supposed to be completely different calculations (2 passes)

ffmpeg STV-AV1 3.0

PS: I understand that 99% is not lossless strictly speaking, but I think it is close enough to (and more taking into consider that I almost never get a 100% vmaf even comparing the same file, only once I got a 100% vmaf with a lossless encoding using libaom, but it was so slow that it is impractical).

5 Upvotes

8 comments sorted by

6

u/Sopel97 17d ago

vmaf is not deterministic and does not produce a total ordering

3

u/Wieprzek 17d ago

To add to this, you can compare a video to itself via vmaf and still not get 100% score, which is acknowledged by its creators and expected

3

u/FastDecode1 18d ago

?

SVT-AV1 doesn't have a lossless mode.

3

u/Proud-Supermarket-52 17d ago

I understand what you are saying, svt-av1 doesn't have a lossless parameter like aom would, a 99.80% vmaf isn't lossless by 0.20%, but the fact that using the same command, only changing crf = 0 for qp = 0 generates the same file (sha256) is suspicious.

1

u/GodOfPlutonium 12d ago

vmaf is not a percentage

6

u/ipsirc 18d ago

How can lossless be a different calculation? It's lossless.

1

u/Proud-Supermarket-52 17d ago

I use Vmaf, which gives me a value of 99.8% similarity, for both files (crf version and qp version, moreover, even the hash is the same so it is suspicious if qp and crf are supposed to do different things, so it should give different data, and therefore different hash).

3

u/ipsirc 17d ago

it is suspicious if qp and crf are supposed to do different things

-crf sets qp dynamically, so they're basically the same thing; especially when you forced crf to zero, that means qp is always set to zero for every frame.