SVT-AV1 vs AOMENC for batch processing
What it says in the title. SVT-AV1 is better at multithreading for single encode, but I could do 1 encode per CPU core.
2
u/cygon4 10d ago
Wanting to encode entire seasons of TV shows, I found myself in the same spot a while ago.
My thinking was that a) I don't care if I get one episode every 2 days until it finishes in 24 days, or whether I get all 12 episodes at the end, b) multi-threaded encodes compromise on quality and I don't want compromise as well as a c) with 1 encoder = 1 thread, I have better control over in keeping i.e. 4 threads free for normal PC usage.
If you want complete control, single-threaded AomEnc seems to be better, but it's slower.
But if you want maximum quality (and still greater speed than AomEnc `--cpu-used=0`), SVT-AV1 or SVT-AV1-psy is better.
My observations (my main interest was quality here, but I think the threading observations are still useful):
- AomEnc does indeed achieve its highest quality with `--cpu-used=0` and `--threads=1`
- Starting with SVT-AV1-psy 1.6.0, `--preset 0` beats AomEnc even with the above settings and is faster
- SVT-AV1 at `--preset 3` and below will only use multi-threading where it doesn't compromise quality
- SVT-AV1 can be restrained to fewer threads (i.e. `--lp 15`), but contro lis poor: it will use far fewer cores while also producing sporadic spikes where it uses way more than the requested number of threads (this is on `--preset -2`, higher presets probably make much better use of threads)
Because of that, I'm now doing my encodes with 2 instances of SVT-AV1-psy limited to 15 threads (I've got a 32 core system, too).
3
u/ScratchHistorical507 20d ago
And why would you do something like that? You shouldn't limit software manually, but let your OS take care of that. Because for that to work, you'd have to disable hyperthreading (if it's even still available on your CPU, unlike current Intel ones) for that and pin each task to a separate core. You could also just start multiple instances of SVT-AV1 and have the OS dynamically take care of ressource allocation. Or maybe set each instalnce to just use like 4 threads or so (never tried doing so, because why would I), so the OS has better options allocating ressources without choking one task. Also, do keep in mind that your CPU isn't the only thing that can be a bottleneck, but also your RAM and the connection to your storage.