搜索 社区服务 统计排行 帮助
  • 3545阅读
  • 17回复

x264又有新参数

楼层直达
级别: 工作组
注册时间:
2007-12-16
在线时间:
0小时
发帖:
88
新的选择b帧的算法,使用方法是在命令行中加入
--b-adapt 2,默认是--b-adapt 1就是传统方法,设成0的话就是关闭b帧了。GIT中尚未加入,是个patch的形式,用新的这种的话速度会比传统的慢一些,效果还没有评测过。

奉上俺自己编译的版本,在GIT的rev 927的基础上加入psyRDO,new_bframes,hrd_pulldown和progress indication几个patch。

x264.928.modified



小更新一把,升级到rev928

级别: 工作组
注册时间:
2003-08-26
在线时间:
13小时
发帖:
6600
只看该作者 1楼 发表于: 2008-08-01
求my大的讲解

催片请点此处: http://bbs.popgo.org/bbs/read.php?tid=502402&displayMode=1#19103164
级别: 工作组
注册时间:
2007-12-16
在线时间:
0小时
发帖:
88
只看该作者 2楼 发表于: 2008-08-01
To樓上,講解啥?

级别: 工作组
注册时间:
2007-12-16
在线时间:
0小时
发帖:
88
只看该作者 3楼 发表于: 2008-08-01
先奉上Doom9上Dark Shikari的原文:

One of the GSOC projects for the summer was to improve B-frame decision. This was the most important project, IMO... but the student on the task just disappeared after the first week.

So I decided to do his job for him, and with akupenguin's assistance on the algorithm side of things, spent this week writing an optimal trellis-like function for B-frame decision. This algorithm provides perfect B-frame decision--or more precisely, as perfect as one can get with the current cost approximation function used.

The downside is that its a bit slower, and moreover, its speed scales linearly with --bframes. While with the previous algorithm, --bframes 16 was only minimally slower than --bframes 3, here it will be a lot slower. And this new algorithm is going to be default, since it is considerably better. The old algorithm will still be available for those who need a fast but inaccurate B-frame decision method.

So, this is a warning to all those who use --bframes 16, MeGUI and otherwise; the new B-frame decision is coming soon, and when it does, in the interests of speed you may want to lower the --bframes value to 3-5 or something otherwise reasonable.






使用方法是,用帶這個補丁的x264,命令行里什么都不加是用的傳統方法,加--b-adapt 2用新方法,--b-adapt 0是關閉b幀

级别: 工作组
注册时间:
2007-12-16
在线时间:
0小时
发帖:
88
只看该作者 4楼 发表于: 2008-08-01
BTW:從Doom9上看,貌似帶新的b_frames的都會在2pass的時候Crash掉,Single Pass是沒問題的,偶自己測試了Single Pass,一切正常,2pass還沒試過。

级别: 风云使者
注册时间:
2006-03-12
在线时间:
54小时
发帖:
6604
只看该作者 5楼 发表于: 2008-08-01
效果如何?

新老算法对b frame 的判定有什么不同?

级别: 新手上路
注册时间:
2006-04-16
在线时间:
0小时
发帖:
286
只看该作者 6楼 发表于: 2008-08-01
召唤翻译先
新东西值得期待
级别: 侠客
注册时间:
2006-04-10
在线时间:
0小时
发帖:
560
只看该作者 7楼 发表于: 2008-08-01
按原文--bframes 16将大幅影响速度[/han]



懒得换头签了
级别: 工作组
注册时间:
2007-12-16
在线时间:
0小时
发帖:
88
只看该作者 8楼 发表于: 2008-08-01
按个人测试。。。UMH 32+新的b frames 16,速度堪与tesa 8相媲美了

级别: 风云使者
注册时间:
2006-03-12
在线时间:
54小时
发帖:
6604
只看该作者 9楼 发表于: 2008-08-01
一般 一个10秒的长镜头 b frames 能插多少?按照25fps来算

级别: 工作组
注册时间:
2007-12-16
在线时间:
0小时
发帖:
88
只看该作者 10楼 发表于: 2008-08-01
小测试:测试源是MF第一话的1080 BDRip截取其中的500帧,设置参数如下:
--cqmfile "C:\AutoMKV\profiles\x264-profiles\matrix\M4G_High_Detail_V3.1.cfg" --no-fast-pskip --no-dct-decimate --mixed-refs --scenecut 40 -I 90 -i 25 --me umh --merange 32 --sar 1:1 --threads 3 -r 6 --nr 0 -f -2:-1 -b 16 --direct "auto" --bime --b-bias 0 --b-pyramid -w --deadzone-inter 4 --deadzone-intra 6 --aq-mode 0 --chroma-qp-offset 0 --direct-8x8 1 --8x8dct -A p8x8,p4x4,b8x8,i8x8,i4x4 -m 7 --b-rdo --psy-rd 1.0 --qpmin 10 --qpmax 51 --qpstep 4 --qcomp 0.900000 --ipratio 1.400000 --pbratio 1.300000 --vbv-init 0.9
两次压制均为Single Pass CRF=20



第二个加入--b-adapt 2


第一次的结果:
x264 [info]: slice I:9 Avg QP:17.78 size: 98476 PSNR Mean Y:53.46 U:52.12 V:51.32 Avg:52.61 Global:52.28
x264 [info]: slice P:144 Avg QP:19.66 size: 44595 PSNR Mean Y:51.32 U:52.34 V:51.64 Avg:51.47 Global:51.20
x264 [info]: slice B:348 Avg QP:21.53 size: 12453 PSNR Mean Y:50.47 U:52.05 V:51.49 Avg:50.82 Global:50.57
x264 [info]: consecutive B-frames: 6.1% 14.2% 6.7% 16.3% 16.3% 35.4% 2.8% 0.0% 0.0% 0.0% 2.2% 0.0% 0.0% 0.0% 0.0% 0.0% 0.0%
x264 [info]: mb I I16..4: 21.4% 73.8% 4.8%
x264 [info]: mb P I16..4: 7.2% 13.4% 0.5% P16..4: 50.4% 7.8% 5.1% 0.1% 0.0%skip:15.4%
x264 [info]: mb B I16..4: 0.5% 0.8% 0.0% B16..8: 31.0% 0.8% 0.8% direct: 1.4% skip:64.8% L0:46.3% L1:43.7% BI:10.0%
x264 [info]: 8x8 transform intra:65.2% inter:32.2%
x264 [info]: direct mvs spatial:96.6% temporal:3.4%
x264 [info]: ref P L0 73.7% 16.7% 5.4% 2.1% 1.2% 1.0%
x264 [info]: ref B L0 85.3% 10.3% 2.8% 1.2% 0.5%
x264 [info]: ref B L1 96.2% 3.8%
x264 [info]: SSIM Mean Y:0.9946263
x264 [info]: PSNR Mean Y:50.764 U:52.135 V:51.532 Avg:51.042 Global:50.771 kb/s:4457.01


encoded 501 frames, 0.86 fps, 4457.77 kb/s





加入--b-adapt 2之后的成绩(实在太TNND慢啦!!!)

x264 [info]: slice I:9 Avg QP:17.33 size:101944 PSNR Mean Y:53.71 U:52.34 V:51.52 Avg:52.84 Global:52.49
x264 [info]: slice P:221 Avg QP:19.40 size: 36761 PSNR Mean Y:51.69 U:52.93 V:52.23 Avg:51.92 Global:51.60
x264 [info]: slice B:271 Avg QP:21.22 size: 11365 PSNR Mean Y:51.07 U:52.67 V:52.12 Avg:51.43 Global:51.10
x264 [info]: consecutive B-frames: 7.5% 49.6% 26.2% 12.2% 2.0% 2.4% 0.0% 0.0% 0.0% 0.0% 0.0% 0.0% 0.0% 0.0% 0.0% 0.0% 0.0%
x264 [info]: mb I I16..4: 19.9% 74.8% 5.2%
x264 [info]: mb P I16..4: 5.4% 9.1% 0.4% P16..4: 52.8% 6.8% 4.8% 0.1% 0.0%skip:20.5%
x264 [info]: mb B I16..4: 0.3% 0.6% 0.0% B16..8: 30.1% 0.7% 0.7% direct: 1.4% skip:66.0% L0:43.9% L1:45.5% BI:10.6%
x264 [info]: 8x8 transform intra:63.8% inter:30.1%
x264 [info]: direct mvs spatial:99.3% temporal:0.7%
x264 [info]: ref P L0 71.9% 15.6% 8.0% 2.2% 1.3% 0.9%
x264 [info]: ref B L0 87.2% 9.0% 2.3% 1.0% 0.5%
x264 [info]: ref B L1 96.5% 3.5%
x264 [info]: SSIM Mean Y:0.9951781
x264 [info]: PSNR Mean Y:51.390 U:52.781 V:52.156 Avg:51.668 Global:51.340 kb/s:4640.69


encoded 501 frames, 0.17 fps, 4641.44 kb/s




首次测试结果出炉。小点评:用新的这个,消耗的码率有所提升,连带的各个数字也更好看了,只是速度实在是。。。

级别: 侠客
注册时间:
2006-04-10
在线时间:
0小时
发帖:
560
只看该作者 11楼 发表于: 2008-08-01
优化的结果就是B帧少了好多吗?

还是用码率换质量啊,外加速度大幅下降...



懒得换头签了
级别: 工作组
注册时间:
2005-04-23
在线时间:
0小时
发帖:
4259
只看该作者 12楼 发表于: 2008-08-01
照文章说法老算法应该过不了多久就会安息了
这是虐机党的福音
专搞小容量的同志们也有的折腾了

Lux Aeterna

过去一直去,未来一直来...
级别: 工作组
注册时间:
2005-05-03
在线时间:
0小时
发帖:
2914
只看该作者 13楼 发表于: 2008-08-01
我讨厌虐机

还好我留了一手
免得它升级到虐机過ぎる的时候……

级别: 工作组
注册时间:
2007-12-16
在线时间:
0小时
发帖:
88
只看该作者 14楼 发表于: 2008-08-01
回楼上两位,,,如果b frames那项搞成3,速度和原来的比是没啥差别的。。

快速回复

限150 字节
上一个 下一个