Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
23rd January 2019, 14:50 | #121 | Link |
Registered User
Join Date: Oct 2017
Posts: 56
|
Thanks kanaka for testing and reporting!
Please note that the quantization scale is different in AV1 and xvc, so a lower qp in xvc might still produce lower rate (and worse quality) than AV1. Without a completed encoding and matching file sizes I'm afraid screenshot comparisons doesn't provide much information. If you are interested in still image comparisons you could perhaps start with encoding a single frame and make sure the file sizes are roughly the same. Indication of command line settings and encoding times is of course also helpful to better understand what is being compared. Regarding support for repacking .xvc files to .mp4 and vice versa, we have not yet added support for this in our ffmpeg version but it is on our todo list. I hope the xvc-in-mp4 support in ffplay is sufficient for the time being, as suggested by LigH. |
23rd January 2019, 15:53 | #122 | Link | ||
Registered User
Join Date: Jan 2019
Posts: 13
|
Quote:
https://drive.google.com/drive/folde...vX42bYkM5cp855 Quote:
What qp should I set to get similar quality? |
||
23rd January 2019, 22:41 | #123 | Link |
Registered User
Join Date: Oct 2017
Posts: 56
|
Thanks for sharing the command lines.
A couple of recommendations: - Do not use "-internal-bitdepth 8". It will make the quality worse for no real benefit. - Make sure to use corresponding key-frame interval (I believe it would be "--kf-max-dist=120" in aomenc if you want to have at most 120 picture interval between access points). Regarding what -qp to use to end up with similar quality, it is a bit difficult to guess since it can be quite sequence dependent. Is the sequence you are using available anywhere in uncompressed form? One approach is to start with a faster -speed-mode to get an indication of the bitrate a certain -qp value gives for a certain sequence, and then encode with a slower speed mode. Perhaps around -qp 25 would be a good starting point for finding correspond quality and/or bitrate for this test case. |
24th January 2019, 08:23 | #124 | Link |
Registered User
Join Date: May 2014
Posts: 292
|
Code:
C:\>ffmpeg_xvc_enc.exe -i z:/x.mov -c:v libxvc -speed-mode 3 -qp 30 -threads 1 z:/x.mp4 ffmpeg version N-85113-g298f56e Copyright (c) 2000-2017 the FFmpeg developers built with gcc 5.3.1 (GCC) 20160211 configuration: --enable-gpl --enable-nonfree --enable-ffplay --enable-libxvc --extra-ldexeflags=-static --pkg-config-flags=--static --arch=x86_64 --target-os=mingw32 --cross-prefix=x86_64-w64-mingw32- libavutil 55. 59.100 / 55. 59.100 libavcodec 57. 90.100 / 57. 90.100 libavformat 57. 72.100 / 57. 72.100 libavdevice 57. 7.100 / 57. 7.100 libavfilter 6. 83.100 / 6. 83.100 libswscale 4. 7.100 / 4. 7.100 libswresample 2. 8.100 / 2. 8.100 libpostproc 54. 6.100 / 54. 6.100 Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'z:/x.mov': Metadata: major_brand : qt minor_version : 0 compatible_brands: qt creation_time : 2019-01-24T07:05:07.000000Z encoder : FFmbc 0.7 Duration: 00:00:04.71, start: 0.000000, bitrate: 144682 kb/s Stream #0:0(eng): Video: prores (apch / 0x68637061), yuv422p10le(smpte170m/unknown/unknown, progressive), 1920x948, 144708 kb/s, 23.98 fps, 23.98 tbr, 24k tbn, 24k tbc (default) Metadata: creation_time : 2019-01-24T07:05:07.000000Z handler_name : DataHandler Stream mapping: Stream #0:0 -> #0:0 (prores (native) -> xvc (libxvc)) Press [q] to stop, [?] for help [libxvc @ 0000021db5dca360] Using 0 encoder threads Output #0, mp4, to 'z:/x.mp4': Metadata: major_brand : qt minor_version : 0 compatible_brands: qt encoder : Lavf57.72.100 Stream #0:0(eng): Video: xvc (libxvc) ([37][0][0][0] / 0x0025), yuv422p10le, 1920x948, q=2-31, 200 kb/s, 23.98 fps, 24k tbn, 23.98 tbc (default) Metadata: creation_time : 2019-01-24T07:05:07.000000Z handler_name : DataHandler encoder : Lavc57.90.100 libxvc Assertion failed! Program: C:\ffmpeg_xvc_enc.exe File: /home/jonatan/xvc/src/xvc_common_lib/resample.cc, Line 90 Expression: 0 This application has requested the Runtime to terminate it in an unusual way. Please contact the application's support team for more information.
__________________
Win10x64, Xeon E5450, GTX 750 2GB, DDR3 8GB. |
24th January 2019, 11:08 | #125 | Link | |
Registered User
Join Date: Jan 2019
Posts: 13
|
Quote:
I've made test again. Different sample of this movie. (I know that this movie is not HQ, specially) I've uploaded xvc, av1 and y4m to : https://drive.google.com/drive/folde...vX42bYkM5cp855 It seems that qp25 is ok http://screenshotcomparison.com/comparison/128563 xvc encoded with params Code:
./xvcenc -input-file 0007QDNTE7P37UMM-sample.y4m -output-file 0007QDNTE7P37UMM-sample_q25.xvc -max-keypic-distance 120 -qp 25 -threads 8 -verbose 1 Code:
aomenc.exe --frame-parallel=0 --tile-columns=3 --auto-alt-ref=1 --cpu-used=4 --tune=psnr --passes=2 --threads=4 --end-usage=q --cq-level=36 --kf-max-dist=120 --bias-pct=75 --test-decode=fatal -o 0007QXNOHNT8PWFC-sample_q36_c4_kf120.webm 0007QXNOHNT8PWFC-sample.y4m 0007QDNTE7P37UMM-sample_q25.xvc - 562.9 kB 0007QDNTE7P37UMM-sample_q36_c4_kf120.webm - 744,9 kB Last edited by kanaka; 24th January 2019 at 12:58. |
|
24th January 2019, 16:13 | #126 | Link |
Registered User
Join Date: Oct 2017
Posts: 56
|
Thanks Gravitator for pointing this out. The problem should be fixed in this version: https://drive.google.com/file/d/1uEy...ew?usp=sharing
/ Jonatan |
24th January 2019, 17:45 | #127 | Link | |
Registered User
Join Date: May 2014
Posts: 292
|
Quote:
This lack of regulation of decimals... Why not 2-pass for AOM?
__________________
Win10x64, Xeon E5450, GTX 750 2GB, DDR3 8GB. |
|
24th January 2019, 18:32 | #128 | Link | |
Moderator
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,770
|
Quote:
For someone doing private testing where that's not feasible, I recommend using 2-pass encoding and compare encodes at the same bitrate. Also, remember we are comparing encoders, not the actual bitstream formats. The bitstream's capabilities provide an upper bound on what an encoder can do. But the psychovisual and rate control features of a given encoder can make a bigger difference than those between bitstreams. Hence x264 beating libaom in lots of real-world scenarios even though AV1 is inarguably the more capable bitstream. But x264 is just a much more mature and tuned encoder than libaom. |
|
24th January 2019, 20:17 | #129 | Link | ||
Registered User
Join Date: Jan 2019
Posts: 13
|
Quote:
First we encoded x264 with 2pass, but 2pass with the same bitrate is not good solution for encoding different movies. I have 2 movies: one is single continuos shot (interview) and the second is movie from car's camera. Encoding with constant quality: first movie save 70% of size... and second is bigger (with crf) becouse movie is very dynamic. Encoding with constant quality we save about 20% of network bandwith (becouse we have a lot of interviews) and give us sure of quality. Quote:
|
||
25th January 2019, 10:14 | #130 | Link | ||
Registered User
Join Date: Oct 2017
Posts: 56
|
Quote:
Quote:
|
||
25th January 2019, 14:50 | #132 | Link | |
Registered User
Join Date: Jan 2019
Posts: 13
|
Quote:
I made another test - very dynamic movie. https://drive.google.com/drive/folde...vX42bYkM5cp855 0007QXNOHNT8PWFC-sample_q36_c4_kf250.webm - 655.9 kB 0007QXNOHNT8PWFC-sample_q25_kf250.xvc - 824.5 kB 0007QXNOHNT8PWFC-sample_q30_kf250.xvc - 402.2 kB q 30 is too bad, but q 25 is bigger than av1 qp 36. Strange |
|
25th January 2019, 14:55 | #133 | Link |
Registered User
Join Date: Jan 2019
Posts: 13
|
It's from https://forum.doom9.org/showthread.p...75#post1860475
According hvmaf-720 (https://ibb.co/6ZQ6sTn) av1 gp 36 shuld give similar quality to h264 crf 23. |
26th January 2019, 12:22 | #134 | Link |
Registered User
Join Date: May 2014
Posts: 292
|
Shows different bitrates
Code:
ffmpeg_xvc_enc.exe -i z:/1.y4m -pix_fmt yuv422p -c:v libxvc -speed-mode 3 -qp 30 z:/test.mp4 ffmpeg version N-85113-g298f56e Copyright (c) 2000-2017 the FFmpeg developers built with gcc 5.3.1 (GCC) 20160211 configuration: --enable-gpl --enable-nonfree --enable-ffplay --enable-libxvc --extra-ldexeflags=-static --pkg-config-flags=--static --arch=x86_64 --target-os=mingw32 --cross-prefix=x86_64-w64-mingw32- libavutil 55. 59.100 / 55. 59.100 libavcodec 57. 90.100 / 57. 90.100 libavformat 57. 72.100 / 57. 72.100 libavdevice 57. 7.100 / 57. 7.100 libavfilter 6. 83.100 / 6. 83.100 libswscale 4. 7.100 / 4. 7.100 libswresample 2. 8.100 / 2. 8.100 libpostproc 54. 6.100 / 54. 6.100 Input #0, yuv4mpegpipe, from 'z:/1.y4m': Duration: 00:00:05.20, start: 0.000000, bitrate: 276481 kb/s Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p(progressive), 1280x720, SAR 1:1 DAR 16:9, 25 fps, 25 tbr, 25 tbn, 25 tbc Stream mapping: Stream #0:0 -> #0:0 (rawvideo (native) -> xvc (libxvc)) Press [q] to stop, [?] for help [libxvc @ 00000138a6d74480] Using -1 encoder threads Output #0, mp4, to 'z:/test.mp4': Metadata: encoder : Lavf57.72.100 Stream #0:0: Video: xvc (libxvc) ([37][0][0][0] / 0x0025), yuv422p, 1280x720 [SAR 1:1 DAR 16:9], q=2-31, 200 kb/s, 25 fps, 12800 tbn, 25 tbc Metadata: encoder : Lavc57.90.100 libxvc frame= 130 fps=1.0 q=-0.0 Lsize= 496kB time=00:00:04.52 bitrate= 898.2kbits/s speed=0.0349x video:493kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.470185% C:\>ffmpeg_xvc_enc.exe -i z:/test.mp4 ffmpeg version N-85113-g298f56e Copyright (c) 2000-2017 the FFmpeg developers built with gcc 5.3.1 (GCC) 20160211 configuration: --enable-gpl --enable-nonfree --enable-ffplay --enable-libxvc --extra-ldexeflags=-static --pkg-config-flags=--static --arch=x86_64 --target-os=mingw32 --cross-prefix=x86_64-w64-mingw32- libavutil 55. 59.100 / 55. 59.100 libavcodec 57. 90.100 / 57. 90.100 libavformat 57. 72.100 / 57. 72.100 libavdevice 57. 7.100 / 57. 7.100 libavfilter 6. 83.100 / 6. 83.100 libswscale 4. 7.100 / 4. 7.100 libswresample 2. 8.100 / 2. 8.100 libpostproc 54. 6.100 / 54. 6.100 [libxvc @ 000002412dad4280] Using 0 decoder threads Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'z:/test.mp4': Metadata: major_brand : isom minor_version : 512 compatible_brands: isomiso2mp41 encoder : Lavf57.72.100 Duration: 00:00:05.20, start: 0.000000, bitrate: 780 kb/s Stream #0:0(und): Video: xvc (xvc1 / 0x31637678), yuv422p10le(progressive), 1280x720, 777 kb/s, SAR 1:1 DAR 16:9, 25 fps, 25 tbr, 12800 tbn, 12800 tbc (default) Metadata: handler_name : VideoHandler At least one output file must be specified
__________________
Win10x64, Xeon E5450, GTX 750 2GB, DDR3 8GB. |
8th February 2019, 17:22 | #135 | Link |
Registered User
Join Date: May 2014
Posts: 292
|
It is necessary to update the ffmpeg
Code:
C:\>ffmpeg_xvc_enc.exe -i z:\4K1.mkv -vf zscale=tin=smpte2084:min=bt2020nc:pin=bt2020:rin=tv:t=smpte2084:m=bt2020nc:p=bt2020:r=tv,zscale=t=linear:npl=100,format=gbrpf32le,zscale=p=bt709,tonemap=tonemap=hable:desat=0.000:peak=0.000,zscale=t=bt709:m=bt709:r=tv -pix_fmt yuv420p10le -strict -1 -c:v libxvc -speed-mode 3 -qp 30 -threads 1 z:\test.mp4 ffmpeg version N-85113-g298f56e Copyright (c) 2000-2017 the FFmpeg developers built with gcc 5.3.1 (GCC) 20160211 configuration: --enable-gpl --enable-nonfree --enable-ffplay --enable-libxvc --extra-ldexeflags=-static --pkg-config-flags=--static --arch=x86_64 --target-os=mingw32 --cross-prefix=x86_64-w64-mingw32- libavutil 55. 59.100 / 55. 59.100 libavcodec 57. 90.100 / 57. 90.100 libavformat 57. 72.100 / 57. 72.100 libavdevice 57. 7.100 / 57. 7.100 libavfilter 6. 83.100 / 6. 83.100 libswscale 4. 7.100 / 4. 7.100 libswresample 2. 8.100 / 2. 8.100 libpostproc 54. 6.100 / 54. 6.100 Input #0, matroska,webm, from 'z:\4K1.mkv': Metadata: creation_time : 2018-07-22T13:06:52.000000Z ENCODER : Lavf58.2.103 Duration: 00:00:02.31, start: 0.000000, bitrate: 21316 kb/s Stream #0:0: Video: hevc (Main 10), yuv420p10le(tv, bt2020nc/bt2020/smpte2084), 3840x1600 [SAR 1:1 DAR 12:5], 23.98 fps, 23.98 tbr, 1k tbn, 23.98 tbc (default) Metadata: DURATION : 00:00:02.293000000 Stream #0:1(rus): Audio: aac, 48000 Hz, stereo, fltp (default) Metadata: title : ╨Ф╤Г╨▒╨╗╨╕╤А╨╛╨▓╨░╨╜╨╜╤Л╨╣ ENCODER : Lavc58.9.100 libfdk_aac DURATION : 00:00:02.307000000 Stream mapping: Stream #0:0 -> #0:0 (hevc (native) -> xvc (libxvc)) Stream #0:1 -> #0:1 (aac (native) -> aac (native)) Press [q] to stop, [?] for help [AVFilterGraph @ 000002064b194140] No such filter: 'zscale' Error reinitializing filters! Failed to inject frame into filter network: Invalid argument Error while processing the decoded data for stream #0:0 Conversion failed!
__________________
Win10x64, Xeon E5450, GTX 750 2GB, DDR3 8GB. |
8th February 2019, 21:36 | #136 | Link | |
Moderator
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,770
|
Quote:
|
|
15th February 2019, 09:56 | #137 | Link | |
Registered User
Join Date: Jan 2019
Posts: 13
|
Quote:
Encoding Xvc or av1 takes too much time so i have i shot to quess what qp should I use. |
|
5th March 2019, 08:52 | #139 | Link | |
Registered User
Join Date: Oct 2017
Posts: 56
|
Quote:
The source code for the xvc decoder is available as open source under LGPL license: https://github.com/divideon/xvc We have also developed integrations with different frameworks and players such as FFmpeg and ExoPlayer, available on request. |
|
Tags |
codec, compression, video codec, video encoding, xvc |
Thread Tools | Search this Thread |
Display Modes | |
|
|