Log in

View Full Version : Crf to Two Pass


XPecto
20th May 2009, 03:32
I was encoding some of my animes with following x264 Settings:

--crf 26.5 --me hex --subme 6 --merange 16 --bframes 16 --b-adapt 1 --b-pyramid --direct temporal --trellis 2 --ref 5 --mixed-refs --psy-rd 0.6 --partitions p8x8,b8x8,i4x4,i8x8 --8x8dct --progress


i was quite satisfied with the quality ( i don't have eyes of a pro :-| ).

I was wondering how should i use them in 2pass mode i mean how to have faster encodes(like fast first pass) and is theres something i should use and don't use.

Chengbin
20th May 2009, 04:02
You shouldn't use psy-rd for anime

You should use b-adapt 2, and lower the b-frame number to 6 or something more sane.

me=umh, and subme=9.

burfadel
20th May 2009, 04:17
Of course me=umh and subme=9 will be a bit slower, but the encode will be much more efficient. Also make sure you are using the latest x264!

--direct auto may be better too, there are many that say spatial is better, others temporal is better. The way I see it, let x264 decide so you end up with a mixed spatial/temporal mode, depending on what was deemed as more suitable at the time!

A little psy-rd may not hurt anime, I guess it depends on what you deem is more suitable. Maybe --psy-rd 0.5:0.1 (so you have a little psy trellis too)

There's not much you can change in your encode settings to make it faster without losing too much efficiency. Funnily enough the suggestions chengbin and I have given you will result in a slower encode (but more efficient).

Sagekilla
20th May 2009, 04:50
Direct spatial is best for one pass (i.e. crf mode), and even if you decide to use direct auto, it only rarely (< 0.5% IIRC) uses temporal. On the other hand, if you're doing two passes, by all means use direct auto on your second pass. It's only really useful when you have 2 or more passes.

XPecto
20th May 2009, 07:33
Hmmm! Nice, Thankyou all.
One last thing i wat to ask is what is turbo in MeGUI when we select two pass mode?

Chengbin
20th May 2009, 12:33
Psy-rd is quite bad for anime at very low bitrates.

burfadel
20th May 2009, 13:49
I did notice that there is low temporal usage in CRF. That of course means spatial is more suitable, but if it uses some temporal leaving it on auto would still be the more practical suggestion (wouldn't it?).

The AutoVAQ patch works really well (it may benefit from some bitrate distribution optimisations), I guess auto Psy-rd/psy-trellis is also possible, and would make sense! I guess psy-rd/trellis doesn't work as well on anime due to the flatness, where AQ does help. In a detailed scene, psy-rd/psy-trellis is beneficial, so an auto function for these too would hopefully give you the best for both situations.

Kind of like an auto function on a camera (which most people now use), it adjusts to meet the situation. But, (on the not so basic camera's) having the manual settings for those that want to tweak it to their liking!

OvejaNegra
8th June 2009, 21:21
Chengbin: Why Psy-rd is bad for anime?
What about animes with added grain or lots of particles like rain or something like that?
If you remember the End of Evangelion, there are some scenes with intentional film grain.
Psy-rd will help with the preservation of the grain? (of course i'm using high bit rate)
Please read here if you have time: http://forum.doom9.org/showthread.php?t=147410

TheRyuu
8th June 2009, 21:32
You shouldn't use psy-rd for anime

You should use b-adapt 2, and lower the b-frame number to 6 or something more sane.

me=umh, and subme=9.

Nothing wrong with psy-rd + anime. Lowering the strength may help some though.

i.e. --psy-rd 0.8:0.2

Direct spatial is best for one pass (i.e. crf mode), and even if you decide to use direct auto, it only rarely (< 0.5% IIRC) uses temporal. On the other hand, if you're doing two passes, by all means use direct auto on your second pass. It's only really useful when you have 2 or more passes.

--direct auto should be best for all rc modes.

Chengbin
8th June 2009, 22:16
psy-rd is fine with high bitrate anime. For most people we use low bitrates for anime, and psy-rd kills quality (I've done tests where I've seen it takes double the bitrate to match the quality from the non psy-rd encode)

OvejaNegra
8th June 2009, 22:21
AHH OK!!

And (again sorry for repeat the same but i cant get fresh info about this):
Does psy-rd helps to preserve intentional grain and particles? Even if it's anime? (Flat areas with grain).
Thanks.

Forteen88
8th June 2009, 23:11
You're using the default value for aq-strength (1.0), which is too strong for anime, use --aq-strength 0.2 or similar.

LoRd_MuldeR
8th June 2009, 23:13
You're using the default value for aq-streangth (1.0), which is too strong for anime, use --aq-strength 0.2 or similar.

Also one of the AutoVAQ patched builds may be worth a try...

Forteen88
8th June 2009, 23:31
Also one of the AutoVAQ patched builds may be worth a try...After your criticism of AutoVAQ I didn't think you'd recommend it :)

LoRd_MuldeR
8th June 2009, 23:35
After your criticism of AutoVAQ I didn't think you'd recommend it :)

What? I reported back my first results. And with my test clip (which was not anime), I liked the Non-AutoVAQ version more. That doesn't mean that AutoVAQ is generally worse at all!

So go, try with your own clip and see the results! Especially if you think that the normal VAQ is too "strong" on your clip...

BTW: Remember that AutoVAQ changes the CRF meanings once again. So when switching from Non-AutoVAQ to AutoVAQ, you will probably need to rebalanced your CRF values...

Forteen88
8th June 2009, 23:48
What? I reported back my first results. And with my test clip (which was not anime), I liked the Non-AutoVAQ version more. That doesn't mean that AutoVAQ is generally worse at all!Ok, I wasn't that serious with that comment (hence the smiley), but I'd expect you'd mention your criticism (your first result) of AutoVAQ. I'd do test-clips, VAQ 0.2 vs AutoVAQ on anime, because AutoVAQ hasn't been tested enough on anime.