Selur's Little Message Board
Trying to deinterlace with Bob NVEnc; job crashes - Printable Version

+- Selur's Little Message Board (https://forum.selur.net)
+-- Forum: Hybrid - Support (https://forum.selur.net/forum-1.html)
+--- Forum: Problems & Questions (https://forum.selur.net/forum-3.html)
+--- Thread: Trying to deinterlace with Bob NVEnc; job crashes (/thread-1958.html)

Pages: 1 2 3 4 5 6 7 8 9


RE: Trying to deinterlace with Bob NVEnc; job crashes - antoniu200 - 25.08.2021

(25.08.2021, 13:24)Selur Wrote: compiled and send you a link to a dev version which should properly use deint 2 in both cases.

Works fine now.

One problem still persists: same config is slower in Hybrid than in FFmpeg, but Hybrid uses more CPU than FFmpeg.
Any idea why this might be?


RE: Trying to deinterlace with Bob NVEnc; job crashes - Selur - 25.08.2021

Quote:One problem still persists: same config is slower in Hybrid than in FFmpeg, but Hybrid uses more CPU than FFmpeg.
Any idea why this might be?
You are not using the same config,....

Looking at the x264 encoding setting there are quire a few differences,... you especiall use a way higher sub-pixel precision in Hybrid.
"D:\Program Files\Hybrid\64bit\ffmpeg.exe" -y -loglevel fatal -noautorotate -nostdin -threads 8 -c:v h264_cuvid -deint 2 -i "G:\F1\DIGI Sport 4 HD - F3 Cursa 2021.07.31 21.47.mkv" -map 0:0 -an -sn -vf  scale=in_range=tv:out_range=tv -pix_fmt yuv420p -vsync 0 -f rawvideo - |  "D:\Program Files\Hybrid\64bit\x264.exe" --preset veryfast --profile high --level 4.2 --ref 3 --direct auto --b-adapt 0 --sync-lookahead 18 --qcomp 0.50 --rc-lookahead 40 --qpmax 51 --partitions i4x4,p8x8,b8x8 --no-fast-pskip --subme 5 --aq-mode 0 --vbv-maxrate 62500 --vbv-bufsize 78125 --sar 1:1 --non-deterministic --range tv --colormatrix bt709 --demuxer raw --input-res 1920x1080 --input-csp i420 --input-range tv --input-depth 8 --fps 50/1 --output-depth 8 --output "C:\Users\Alexa\AppData\Local\Temp\2021-08-25@21_45_31_9010_02.264" -
vs.
ffmpeg -r 50 -c:v h264_cuvid -deint 2 -i <input> -c:v libx264 -profile:v high -preset veryfast -crf 18 -x264opts "keyint=500" -c:a copy <output.mkv>

looking at what 'preset veryfast' does:
- veryfast:
                                    --no-mixed-refs --rc-lookahead 10
                                    --ref 1 --subme 2 --trellis 0 --weightp 1
you use a '--subme 5' instead of '--subme 2', which is a lot slower.


-> You use different way slower encoding settings in Hybrid. Big Grin

Cu Selur


RE: Trying to deinterlace with Bob NVEnc; job crashes - antoniu200 - 25.08.2021

(25.08.2021, 21:14)Selur Wrote:
Quote:One problem still persists: same config is slower in Hybrid than in FFmpeg, but Hybrid uses more CPU than FFmpeg.
Any idea why this might be?
You are not using the same config,....

Looking at the x264 encoding setting there are quire a few differences,... you especiall use a way higher sub-pixel precision in Hybrid.
"D:\Program Files\Hybrid\64bit\ffmpeg.exe" -y -loglevel fatal -noautorotate -nostdin -threads 8 -c:v h264_cuvid -deint 2 -i "G:\F1\DIGI Sport 4 HD - F3 Cursa 2021.07.31 21.47.mkv" -map 0:0 -an -sn -vf  scale=in_range=tv:out_range=tv -pix_fmt yuv420p -vsync 0 -f rawvideo - |  "D:\Program Files\Hybrid\64bit\x264.exe" --preset veryfast --profile high --level 4.2 --ref 3 --direct auto --b-adapt 0 --sync-lookahead 18 --qcomp 0.50 --rc-lookahead 40 --qpmax 51 --partitions i4x4,p8x8,b8x8 --no-fast-pskip --subme 5 --aq-mode 0 --vbv-maxrate 62500 --vbv-bufsize 78125 --sar 1:1 --non-deterministic --range tv --colormatrix bt709 --demuxer raw --input-res 1920x1080 --input-csp i420 --input-range tv --input-depth 8 --fps 50/1 --output-depth 8 --output "C:\Users\Alexa\AppData\Local\Temp\2021-08-25@21_45_31_9010_02.264" -
vs.
ffmpeg -r 50 -c:v h264_cuvid -deint 2 -i <input> -c:v libx264 -profile:v high -preset veryfast -crf 18 -x264opts "keyint=500" -c:a copy <output.mkv>

looking at what 'preset veryfast' does:
- veryfast:
                                    --no-mixed-refs --rc-lookahead 10
                                    --ref 1 --subme 2 --trellis 0 --weightp 1
you use a '--subme 5' instead of '--subme 2', which is a lot slower.


-> You use different way slower encoding settings in Hybrid. Big Grin

You're right. I tried reducing the command to a minimum and it seems fine now.
Thanks!

I believe it's stable enough at this point, but you decide whether or not to launch it now.
I'll also check those other CUVID options and let you know once I do. But for now, to me, it's stable and works fine.


RE: Trying to deinterlace with Bob NVEnc; job crashes - Selur - 26.08.2021

Quote:I'll also check those other CUVID options ...
do that, adding support for them isn't too hard and the main question is about the order of them,...


RE: Trying to deinterlace with Bob NVEnc; job crashes - Selur - 28.08.2021

I created a dev version which adds cuvid crop&resize support (under Crop/Resize->Misc->Misc), send you a link to it via pm.
Note that I didn't do much testing and Hybrid doesn't do any sanity checks, since the I haven't done the tests mentioned in https://forum.selur.net/thread-1958-post-13086.html#pid13086.

Cu Selur


RE: Trying to deinterlace with Bob NVEnc; job crashes - antoniu200 - 28.08.2021

Can't quite test it just yet.

I have some issues converting some files and I should convert them quick, otherwise I run out of HDDs to store the videos on.

I'll get back to you once that's solved, I haven't forgotten about the testing.

Actually, sorry for being off-topic, but if I have a .ts file with some video and audio corruption from time to time, Hybrid seems to fix it: it drops the corrupt audio and video frames through FFmpeg.

However, that renders the video and audio to be out of sync slightly. How would I go by keeping them in sync in Hybrid?

EDIT: tsMuxeR reports the following error repeatedly:
bad frame detected at position00:31:41,807. Resync stream.
These are the exact points where the stream goes out of sync.


RE: Trying to deinterlace with Bob NVEnc; job crashes - Selur - 29.08.2021

Quote:Actually, sorry for being off-topic, but if I have a .ts file with some video and audio corruption from time to time, Hybrid seems to fix it: it drops the corrupt audio and video frames through FFmpeg.

However, that renders the video and audio to be out of sync slightly. How would I go by keeping them in sync in Hybrid?
Sorry, but Hybrid is no tool to fix broken/corrupted streams.

I would try to:
a. use some tool which is meant to fix streams
b. try using whether remuxing the file with mkvtoolnix to mkv before processing it helps.

Cu Selut


RE: Trying to deinterlace with Bob NVEnc; job crashes - antoniu200 - 29.08.2021

I'm very sorry, but I think the testing for the other CUVID options is going to have to wait for now, since I have a full schedule and I also need some rest.

I think the delay will be a few months. But then again, I have to remind you: I need those options for some video files I have, so I'm not going to forget about the testing any time soon.


RE: Trying to deinterlace with Bob NVEnc; job crashes - antoniu200 - 23.09.2021

Today I finally got around to try the crop option of CUVID. It doesn't work on your build of FFmpeg and it probably won't very soon.

Here is context: https://trac.ffmpeg.org/ticket/8852

This basically means that resize and crop won't work, as both change the video scaling parameters.

The command prompt for my crop attempt attached below.


RE: Trying to deinterlace with Bob NVEnc; job crashes - Selur - 23.09.2021

Okay, thanks for testing, weill remove the options from the gui. Smile

Cu Selur