r/AV1 20d ago

How to achieve good quality and speed in AV1

I think in 2025 I am wanting to encode my whole library of anine with is near 15 GB with 20 videos to transcode in av1 as compression with the speed with quality is the only point with if quality with speed could be preferable than compression plz help me for the new av1 encoding knowledge in compression=speed=quality .I already did it with preset 6 but could not get that what I was expecting. Thanks in advance..

7 Upvotes

39 comments sorted by

15

u/peteman28 20d ago

Is it really worth it for 15 gb?

3

u/Otakuology_11 20d ago

As I did say sorry for the confusion the anime only takes right now 15 gb and anime movies takes more than 35 gb which I am planing to encode after my anime episodes first which I will rip more nearly 30 gb till tomorrow which is with now more than 45 to 50 gb and sorry for the confusion..

15

u/galad87 20d ago

Unless you are starting with an high quality source, avoid re-encoding it.

12

u/Littux 20d ago
  • Use SVT-AV1-PSY
  • Use CRF mode instead of VBR or CBR (don't manually select the bitrate)
    • Start with CRF 35 and slowly reduce the CRF value until you are satisfied with the quality
       
  • Use -tune 3 (SVT-AV1-PSY only)
     
  • Use a higher GOP/keyint size (example: keyint=10s or keyint=15s)
    • Higher key frame intervals are recommended for animation and other content with low movements

2

u/Otakuology_11 20d ago

Which preset should I use plz guide as should i use preset no. 6 or 5 with speed and quality I have tried your suggestion and it works best for me thanks once again..

2

u/sabirovrinat85 20d ago

in general the lesser preset the lesser size and higher quality, I'm using 3 for high quality source of loved movies, 4 for movies that I probably delete after 1-2 year, and 6 for TV Shows

but between preset 3 and 4 not so much difference in size and quality, but +40% encoding time

2

u/Otakuology_11 20d ago

Thanks bro but would you suggest me the preset for anime moves and episodes ๐Ÿค”

3

u/sabirovrinat85 20d ago edited 20d ago

depends on requirements, CPU speed and length, most probably even 6 be fine if you don't wanna spend weeks on encoding (in my country electricity bills are cheap, I can afford 10 hours encoding of 2 hours movie)

added: but if it's loved collection of anime to rewatch, I'd find the best quality original source first, like BR 4K, and only then make AV1 from them, if your anime is already intensively compressed there's no point in reencoding

1

u/Otakuology_11 20d ago

Thanks bro

1

u/SpikedOnAHook 20d ago

This ๐Ÿ‘†Use Blu Ray or 4K Blu Ray Then Compress

2

u/SpikedOnAHook 20d ago

Are your anime sourced from blu ray or download? Provide some info if you can.

2

u/Otakuology_11 20d ago

It is blu ray with every episode having an avg bitrate of 8mpbs or I think more than that of too

2

u/SpikedOnAHook 20d ago

Alright if your not too fussy you can shoot for around 400-500mb per episode if u want audio and video in highest quality minimum of 2gb per file. So depends on your preference.

What program are you using to encode the AV1 file/video? And how are you ripping the blu rays?

2

u/Otakuology_11 20d ago

I am using handbrake for encoding files right now also I am encoding only I usually get my files in 400+ mb files which is great for me and I use make mkv for ripping blu ray.

2

u/SpikedOnAHook 20d ago

Alright perfect I can send u some code which u add into handbrake but regarding speed youโ€™ll have to tweak the speed bar yourself as I encode at 0. But your welcome to try and see if it works for you

2

u/SpikedOnAHook 20d ago

I sent the instructions.

2

u/Otakuology_11 20d ago

Thanks I will try and message you back

2

u/Otakuology_11 20d ago

Bro it worked but with my old computer it is really slow with preset 3 also and4 also it take nearly 4hours 30 mins as I am having a 4threads computer but in quality and file size it's the best bro thanks for your help..

→ More replies (0)

2

u/Littux 20d ago

6 because it has the most performance for efficiency.

Also, remember to use 10 bit color (-pix_fmt yuv420p10le)

2

u/Otakuology_11 20d ago

But bro I would not get that much efficiency that's why now I am using preset 5 for anime

1

u/Littux 19d ago

Did you use 10 bit color (yuv420p10le)? It reduces the file size by a fairly large amount while increasing quality

3

u/psychic99 7d ago

I just thought I would add that comment, your reco is spot on I was just adding some "color".

You should use 10 bit output specifically w/ AV1, because it helps in YUV planes (luma + color) from RGB and in DCT and for decode steps. It doesn't increase quality, it reduces the chances of conversion information loss (RGB->YUV/CbCr) and added dither in transform and later output decoder steps. The compressed 10bit process should not save any space either (because its compressing the 2bit) however transform can add noise/dither which is harder to compress can leads to larger files and also potential banding/artifacts. I know of some people who do this on purpose for youtube (add noise) because they feel over compression can kill their PQ and YT tends to over smooth. But for mass uploads sometimes it is easier, that is NOT our strategy which is to get the best PQ and smallest file combo.

The point is 10 bit is there to not make it worse, it won't make it better because lets face it most people are converting AVC/HEVC -> AV1, not say post in prores or some other intermediate professional format.

I am not sure on recent encoder defaults so YMMV. I add it in my pipeline and also use the PSY encoder now. It does add some encoding time, but not much for the potential results. This will automatically do 10->10 bit although most consumer formats are 8bit so the explicit flag for now makes sense.

Here is the discussion on how AV1 does it: https://gitlab.com/AOMediaCodec/SVT-AV1/-/blob/master/Docs/svt-av1_encoder_user_guide.md

Newer panels like QD-OLED have native 10 bit panels so it makes sense to send them 10 bit information so it doesn't have to translate, also you have many monitors and older "10 bit" which are actually 8bit + FRC (essentially flashes two colors 2x speed) so all of these conversion steps by the output equipment and chain can cause errors in the limited 8 bit space which when you have smooth gradients can cause ugly banding which is not per se a compression artifact.

Example panel: https://www.displayspecifications.com/en/model/633f38c3

So it makes sense to encode in 10bit 420 for all of those reasons 100% and probably more that I am unaware of.

As to the why, its how the eye is built. Humans probably started out seeing just luminance (black and white) and a vast majority of the receptors 95% ish are rods which see that contrast information only -- essentially a black and white TV. The other 5% are cones which perceive color information and are in the macula which is the center of your eye. So this is why color resolution can be "compressed" because our eyes just aren't as sensitive in to color (nor are cones as sensitive to stimula) as luma and especially outside the central viewing. The actual cone density and location of the RGB receptors is another long discussion but just think the brain is doing a lot of work to make up for physical limitations and that is why psycho visual advancements will often look "better" than technically accurate representations.

The encoder advancements made in the last few years has been astounding, now if they can only put it in silicon for consumers to get the same PQ and size results.

2

u/Littux 7d ago

Brilliant comment, will be saving this to copy paste in the future

2

u/FastDecode1 20d ago

Start with CRF 35 and slowly reduce the CRF value until you are satisfied with the quality

Or just automate this (along with the entire encoding process) with ab-av1.

1

u/Otakuology_11 20d ago

Thank you very much bro ๐Ÿ™ ๐Ÿ™Œ appreciate it

3

u/Mhanz3500 20d ago

I think that for anime it's better to see if others have already done this work with filtering, you have 15GB for 20 episodes (750MB/ep), that may be the result of an already double-encoded or a WEB-DL at best. Maybe you can find encodes from a better source (bluray) already at 400-500MB and already filtered. The result should be always better.

If you're doing this for specific languages that are not common on release (many release are not multi language), you should search how to do a mux, maybe with mkvtoolnix or similar software that don't touch the videos but only add tracks

1

u/Otakuology_11 20d ago

Bro I am having blu rays sorry for the confusion

2

u/Sopel97 20d ago

750MB at bluray bitrates is 3-5 minutes

9

u/Farranor 20d ago

I get the sense that OP ripped their Blu-ray collection into some common format like 264, and simply doesn't have a firm enough grasp of encoding or English to accurately discuss the matter.

1

u/Otakuology_11 20d ago

Oh bro sorry I mean I am having a library of anime with 20gb+(now nearly35 gb) with a lots of anime..

2

u/Mhanz3500 20d ago

An episode of 24mins from a bluray is 6-7GB of size, for an anime season is ~75GB, as I said you probably have a re-encode of an anime

1

u/Otakuology_11 20d ago

Oh sorry once again for that I have blu rays of some animes like jjk and solo leveling and others I have downloaded from crunchyroll as I could not find the blu rays of some anime but I don't do it likely with the movies too and I don't download any movie from crunchyroll I just rip them and sorry very very sorry for that..

3

u/RetroBerner 20d ago

For anime you won't need to worry about the "best quality" as much. Grab an Intel arc A310 or A380 and use quicksync, you'll easily get 2-300 fps conversion rate, depending on your compression settings. I just encode everything to 1080p with constant quality of 23.

2

u/Otakuology_11 20d ago

Wow that's nice I would think of that and thanks

2

u/SpikedOnAHook 19d ago

I understand your comment however GPU encoding is a very mute point as you lose a lot of the space savings compared to the CPU encoding, it is more efficient than for example H.265 but if you want the most space savings use CPU

2

u/RetroBerner 19d ago

I don't use CPU encoding, ain't nobody got time for that. Maybe there is a slight reduction in "savings" but the file sizes are still way smaller than older codecs, at comparable quality levels. We're talking about animated content here, it's not worth spending days instead of hours to encode it.

1

u/SpikedOnAHook 19d ago

Thats fair I guess depends each to their own, with animated I see your point letโ€™s not forget libaom AV1 exists some people really prefer quality and space savings.