This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

hi - encoding really slow
#21
Looking at the debug output:
"C:\PROGRA~1\Hybrid\64bit\ffmpeg.exe" -y -loglevel fatal -hwaccel dxva2 -threads 1 -r 24000/1001 -analyzeduration 200M -probesize 200M -i "E:\movies\The-LEGO-Ninjago-Movie HD.7.1.Atmos\BDMV\STREAM\00002.m2ts" -map 0:0 -an -sn  -vsync 0 -strict -1 -pix_fmt yuv420p10le  -f yuv4mpegpipe - | "C:\PROGRA~1\Hybrid\64bit\NVEncC.exe" --y4m -i - --fps 23.976 --codec h265 --profile main10 --level 5.1 --sar 1:1 --lookahead 32 --output-depth 10 --vbr 6000 --max-bitrate 40000 --aq --gop-len 0 --bframes 0 --ref 3 --mv-precision Q-pel --cu-max 32 --cu-min 8 --output "C:\Users\densma\AppData\Local\Temp\lego movie_19_48_40_7110_04.265"
My guess is that the decoding might slow things down.

When calling:
"C:\PROGRA~1\Hybrid\64bit\ffmpeg.exe" -y -hwaccel dxva2 -threads 1 -r 24000/1001 -analyzeduration 200M -probesize 200M -i "E:\movies\The-LEGO-Ninjago-Movie HD.7.1.Atmos\BDMV\STREAM\00002.m2ts" -map 0:0 -an -sn  -vsync 0 -strict -1 -pix_fmt yuv420p10le  -f yuv4mpegpipe NUL
How many fps do you get?
I get slow speeds since the hardware acceleration doesn't work on my system:
[hevc @ 00000237ac810500] Failed setup for format dxva2_vld: hwaccel initialisation returned error.
which isn't a surprise since my VPU doesn't support 4k HEVC decoding. (+ Hybrid is limiting the decoding threads to 1 due to transport stream input)

In case the hardware acceleration on your system also fails, try whether using any of these:
using cuda:
"C:\PROGRA~1\Hybrid\64bit\ffmpeg.exe" -y -hwaccel cuda -threads 1 -r 24000/1001 -analyzeduration 200M -probesize 200M -i "E:\movies\The-LEGO-Ninjago-Movie HD.7.1.Atmos\BDMV\STREAM\00002.m2ts" -map 0:0 -an -sn  -vsync 0 -strict -1 -pix_fmt yuv420p10le  -f yuv4mpegpipe NUL
using qsv:
"C:\PROGRA~1\Hybrid\64bit\ffmpeg.exe" -y -hwaccel qsv -threads 1 -r 24000/1001 -analyzeduration 200M -probesize 200M -i "E:\movies\The-LEGO-Ninjago-Movie HD.7.1.Atmos\BDMV\STREAM\00002.m2ts" -map 0:0 -an -sn  -vsync 0 -strict -1 -pix_fmt yuv420p10le  -f yuv4mpegpipe NUL
using d3d11va:
"C:\PROGRA~1\Hybrid\64bit\ffmpeg.exe" -y -hwaccel d3d11va -threads 1 -r 24000/1001 -analyzeduration 200M -probesize 200M -i "E:\movies\The-LEGO-Ninjago-Movie HD.7.1.Atmos\BDMV\STREAM\00002.m2ts" -map 0:0 -an -sn  -vsync 0 -strict -1 -pix_fmt yuv420p10le  -f yuv4mpegpipe NUL
using cuvid:
"C:\PROGRA~1\Hybrid\64bit\ffmpeg.exe" -y -hwaccel cuvid -threads 1 -r 24000/1001 -analyzeduration 200M -probesize 200M -i "E:\movies\The-LEGO-Ninjago-Movie HD.7.1.Atmos\BDMV\STREAM\00002.m2ts" -map 0:0 -an -sn  -vsync 0 -strict -1 -pix_fmt yuv420p10le  -f yuv4mpegpipe NUL
works better,...

Cu Selur
Reply
#22
i get average 20fps more or less. i just tried h264 file and seem to decode well. at least faster average 112 fps.
This is same hvec decoding issue with 2 systems. one window 7 with p4000 and window 10 with gtx 1080 ti. more hybrid issue rather than my system

 is there a way to enable cuda/cuvid using gui in-app?
Reply
#23
Quote: is there a way to enable cuda/cuvid using gui in-app?
No. You can tell Hybrid to try ffmpegs gpu decoding but that is about it. (there are gpu based decoders for Avisynth and Vapoursynth, which might work)
And since nonce of the modes the gpu decoding offers seem to work for you I guess (since the decoding speed is in none of the modes faster).

Do you get 'hwaccel initialisation returned error.'-errors for each fo the different decoding calls?

Cu Selur
Reply
#24
(06.02.2018, 19:09)Selur Wrote:
Quote: is there a way to enable cuda/cuvid using gui in-app?
No. You can tell Hybrid to try ffmpegs gpu decoding but that is about it. (there are gpu based decoders for Avisynth and Vapoursynth, which might work)
And since nonce of the modes the gpu decoding offers seem to work for you I guess (since the decoding speed is in none of the modes faster).

Do you get 'hwaccel initialisation returned error.'-errors for each fo the different decoding calls?

Cu Selur

any instructions how to setup and use  Avisynth and Vapoursynth with hybrid?
 ffmpegs gpu decoding is enable but still takes longer on hvec 4k content. not sure if its working or not

i dont remember hwaccel initialization return error. where would i see this?
 job log screen?

Thanks
Reply
#25
Quote:i dont remember hwaccel initialization return error. where would i see this?
You would see them when calling the different ffmpeg calls I asked you to try.
In case they don't throw this error vpu decoding should be used.

Quote:any instructions how to setup and use Avisynth and Vapoursynth with hybrid?
Vapoursynth will be used, when "Filtering->Support" is set to "Vapoursynth" and a Vapoursynth filter is used. Sadly there is no free VPU decoder for Vapoursynth. Hybrid does support using DGDecNV (associated files and the license.txt would need to be copied into the vsfilters/DGDecNV folder), but that isn't free.
Usage of Avisynth can be enforced using "Config->Internals->Avisynth->Always use Avisynth", when "Filtering->Support" is set to "Avisynth" and one could use FRIM as a free vpu decoder supported source filter by enabling "Filtering->Avisysnth->Misc->Support FRIM".
-> ARGH, just checked, FRIM doesn't support HEVC hardware decoding.

=> So the only way to get hardware hevc decoding is either through FFmpeg or DGDecNV.
Your best change is probably ffmpeg with "-hwaccel cuvid" (see: https://trac.ffmpeg.org/wiki/HWAccelIntro, which isn't supported atm. in Hybrid, but I could add support for it fairly easy), but that only makes sense if that works and helps. (posted an appropriate call above, btw. if you test those calls you can also check whether is helps if you remove the '-threads 1' part, which limits the software decoding threads)

Cu Selur
Reply
#26
(06.02.2018, 21:56)Selur Wrote:
Quote:i dont remember hwaccel initialization return error. where would i see this?
You would see them when calling the different ffmpeg calls I asked you to try.
In case they don't throw this error vpu decoding should be used.

Quote:any instructions how to setup and use  Avisynth and Vapoursynth with hybrid?
Vapoursynth will be used, when "Filtering->Support" is set to "Vapoursynth" and a Vapoursynth filter is used. Sadly there is no free VPU decoder for Vapoursynth. Hybrid does support using DGDecNV (associated files and the license.txt would need to be copied into the vsfilters/DGDecNV folder), but that isn't free.
Usage of Avisynth can be enforced using "Config->Internals->Avisynth->Always use Avisynth", when "Filtering->Support" is set to "Avisynth" and one could use FRIM as a free vpu decoder supported source filter by enabling "Filtering->Avisysnth->Misc->Support FRIM".
-> ARGH, just checked, FRIM doesn't support HEVC hardware decoding.

=> So the only way to get hardware hevc decoding is either through FFmpeg or DGDecNV.
Your best change is probably ffmpeg with "-hwaccel cuvid" (see: https://trac.ffmpeg.org/wiki/HWAccelIntro, which isn't supported atm. in Hybrid, but I could add support for it fairly easy), but that only makes sense if that works and helps. (posted an appropriate call above, btw. if you test those calls you can also check whether is helps if you remove the '-threads 1' part, which limits the software decoding threads)

Cu Selur
i just started encoding using "-hwaccel cuvid". i will report back if it helps.

Thanks

i noticed its not working right away. getting avg 13fps

  Stream #0:0 -> #0:0 (hevc (native) -> wrapped_avframe (native))
Press [q] to stop, [?] for help
[AVHWFramesContext @ 0000026f7eef0440] Pixel format 'yuv420p10le' is not supported
[hevc @ 0000026f7ec4adc0] Error initializing a CUDA frame pool
cuvid hwaccel requested for input stream #0:0, but cannot be initialized.
[hevc @ 0000026f7ec4adc0] Error parsing NAL unit #10.
Error while decoding stream #0:0: Operation not permitted
[hevc @ 0000026f7ec4adc0] Could not find ref with POC 0
[yuv4mpegpipe @ 0000026f10174880] Warning: generating non standard YUV stream. Mjpegtools will not work.


same on another system with p4000 but getting better fps. I will test others. hwaccel cuvid seem very low speed
Reply
#27
Simply checking whether any of the calls I posted for testing doesn't report an error, would help.
[AVHWFramesContext @ 0000026f7eef0440] Pixel format 'yuv420p10le' is not supported
[hevc @ 0000026f7ec4adc0] Error initializing a CUDA frame pool
cuvid hwaccel requested for input stream #0:0, but cannot be initialized.
sounds like the decoding doesn't work using CUVID and outputting '-pix_fmt yuv420p10le'.
Does it change when using '-pix_fmt yuv420p'?

Cu Selur
Reply
#28
(07.02.2018, 06:14)Selur Wrote: Simply checking whether any of the calls I posted for testing doesn't report an error, would help.
[AVHWFramesContext @ 0000026f7eef0440] Pixel format 'yuv420p10le' is not supported
[hevc @ 0000026f7ec4adc0] Error initializing a CUDA frame pool
cuvid hwaccel requested for input stream #0:0, but cannot be initialized.
sounds like the decoding doesn't work using CUVID and outputting '-pix_fmt yuv420p10le'.
Does it change when using '-pix_fmt yuv420p'?

Cu Selur


using qsv and d3d11va return no error. seem like d3d11va offers little better speed in short test.  i will run full encoding but avg i saw was 20-30 fps. yuv420p still same error with cuvid.

Do you think DGDecNV will work better/faster? i can try out and see.
Reply
#29
I use DgDecNV for H.264 content without a problem. Can't say whether it works as stable for H.265 content since I got no graphic card which supports H.265 decoding.
Reply
#30
can you guide me through how to use DGDecNV?

NVenc Ffmpeg  performance might be better for me though its not showing fps but percentage looks great.
is it possible to add HDR patching using nvhsp for Nvenc Ffmpeg?

dxva2 and d3d11va gives better speed for me.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)