Jump to content

Issues with Hardware Transcoding (Docker, Unraid, Nvidia)


Go to solution Solved by softworkz,

Recommended Posts

RaptorCentauri
Posted (edited)

Hello, 

I am having the following issue. At times when I am playing a 4K Video, the video is completely glitched out, sometimes with a green screen, sometimes with a black screen (audio remains fine). I can remedy the situation by disabling NVDEC and leaving it to use software decoding, but I don't like putting my CPU under that stress. The problem is not consistent with all 4K Video. I have attached an FFMPEG Log of a failing playback. Please let me know what other info would be helpful. This is on Emby Server 4.5.0.50

Thanks!

ffmpeg-transcode-16c556b2-920d-4b15-8203-258337e73c69_1.txt

Edited by RaptorCentauri
Happy2Play
Posted

Hard to say exactly but are all the problem item in level 153?

RaptorCentauri
Posted (edited)
7 minutes ago, Happy2Play said:

Hard to say exactly but are all the problem item in level 153?

Yes, all failing videos have been in level 153. However not all level 153 videos have failed.

Edited by RaptorCentauri
Happy2Play
Posted
Just now, RaptorCentauri said:

Can you explain what you mean by level 153?

Encoding profiles, but since the item is being transcoded it shouldn't matter.  If it were streaming it is technically beyond Apple specs.

Quote

"Profile":"Main 10","Type":"Video","AspectRatio":"16:9","Index":0,"IsExternal":false,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Protocol":"File","PixelFormat":"yuv420p10le",

"Level":153,"IsAnamorphic":false}

 

RaptorCentauri
Posted

Would it be helpful to post a log of a working video as well?

Happy2Play
Posted
9 minutes ago, RaptorCentauri said:

Would it be helpful to post a log of a working video as well?

Possibly as the devs can compare them.

Happy2Play
Posted

Main difference I see is reason for transcoding "&TranscodeReasons=ContainerNotSupported" and "&TranscodeReasons=ContainerBitrateExceedsLimit" so different methods will provide different results as one is setting a lower bitrate and the other is not.

Working is limited to 40Mb

&VideoBitrate=39616000&AudioBitrate=384000

Not working is set to 140Mb

&VideoBitrate=139616000&AudioBitrate=384000

 

RaptorCentauri
Posted

These were on different devices. Also the problem has appeared on multiple devices with multiple OS versions. It has occurred on the local network as well as remote.

 

Happy2Play
Posted

Are they wired or wireless.

Does lowering the in app quality bitrate make a difference on the device that is failing?

RaptorCentauri
Posted

It's been a mix of wired and wireless. Changing the app quality bitrate has not seemed to make a difference. I would ultimately like to find the solution server-side. Transcoding when done properly should mean my users don't need to worry about this stuff.

Happy2Play
Posted
6 minutes ago, RaptorCentauri said:

Changing the app quality bitrate has not seemed to make a difference.

What did you change it to?

Another question, are saying all devices or just Apple devices?

But most devices only have a 10/100 network for ethernet so restriction will have to be applied, as wireless can possibly provide higher bitrates but network specific.

 

 

RaptorCentauri
Posted
2 minutes ago, Happy2Play said:

What did you change it to?

Another question, are saying all devices or just Apple devices?

But most devices only have a 10/100 network for ethernet so restriction will have to be applied, as wireless can possibly provide higher bitrates but network specific.

 

 

Unfortunately I do not remember. This problem has been going on for several months, and I've tried various bitrates. 

I am aware of the problem happening on at least, iOS Devices, tvOS Devices, Emby Theater for Windows, and FireTV.

Strangely enough, for the logs I provided. The working one was on an Apple TV at my parents connected via wifi. The failing one was on an Apple TV on a local hardwired gigabit network. (That one also failed on remote plays). 

Sadly I do not have all of the old logs.

Happy2Play
Posted
1 minute ago, RaptorCentauri said:

The failing one was on an Apple TV on a local hardwired gigabit network.

But my understanding is they do not have a Gigabit nics, only fast ethernet 10/100 (but could be device specific).  Were all your tests below 80Mb?

But a dev will have to comment more.

  • 3 weeks later...
Posted

Hi, are you still running into this with 4.5.2?

Posted (edited)
On 9/24/2020 at 3:41 AM, RaptorCentauri said:

It's been a mix of wired and wireless. Changing the app quality bitrate has not seemed to make a difference. I would ultimately like to find the solution server-side. Transcoding when done properly should mean my users don't need to worry about this stuff.

There are two possibilities why you are experiencing this.

One would be related to NVDEC vs. CUVID and the other one would be about client capabilities.

Could you please follow the suggestions/questions from @Happy2Play ?

On 9/24/2020 at 3:57 AM, RaptorCentauri said:

I've tried various bitrates

...doesn't tell us much in this matter.

Just a single attempt requesting a really low bitrate at the client (and providing ffmpeg logs) would be incredibly helpful for us to narrow it down further.

Another thing you could try is to use the DXVA2/D3D11VA HEVC decoder instead of the NVDEC HEVC decoders.

Thanks.

Edited by softworkz
  • 3 weeks later...
RaptorCentauri
Posted
On 10/10/2020 at 8:40 PM, softworkz said:

There are two possibilities why you are experiencing this.

One would be related to NVDEC vs. CUVID and the other one would be about client capabilities.

Could you please follow the suggestions/questions from @Happy2Play ?

...doesn't tell us much in this matter.

Just a single attempt requesting a really low bitrate at the client (and providing ffmpeg logs) would be incredibly helpful for us to narrow it down further.

Another thing you could try is to use the DXVA2/D3D11VA HEVC decoder instead of the NVDEC HEVC decoders.

Thanks.

Apologies for the late reply. I'm attaching the ffmpeg log of a low bitrate playback. 

ffmpeg-transcode-13e1b330-3a3a-4837-969b-1fed95c3fc2d_1.txt

Posted
44 minutes ago, RaptorCentauri said:

Apologies for the late reply. I'm attaching the ffmpeg log of a low bitrate playback. 

Thanks for the new log.

On 10/11/2020 at 3:40 AM, softworkz said:

One would be related to NVDEC vs. CUVID and the other one would be about client capabilities.

OK, then it's most likely about a known issue with Nvidias HEVC decoder.

We will shortly provide a way to try an alternative way for decoding HEVC with Nvidia.

Meanwhile:

On 10/11/2020 at 3:40 AM, softworkz said:

Another thing you could try is to use the DXVA2/D3D11VA HEVC decoder instead of the NVDEC HEVC decoders.

 

RaptorCentauri
Posted

Thanks! I'm using running Emby in a Docker on Unraid, so I don't think the DXVA2/D3D11VA options is possible for me. 

Posted

Yes, of course you're right!

Sorry, I'm doing too many things in parallel..

  • 3 weeks later...
  • Solution
Posted

If you would be willing to try a beta version - today's beta includes a new decoder for testing that might fix this issue. 

It is called NVDEC.Ex and it is disabled by default:

image

You'd need to enable it and move it to the top.

RaptorCentauri
Posted

Just tried it. So far so good! But I do need to disable the MPV player for it to work. Is that expected?

Posted

Why do you feel that you need to do that?

Posted
1 hour ago, softworkz said:

If you would be willing to try a beta version - today's beta includes a new decoder for testing that might fix this issue. 

It is called NVDEC.Ex and it is disabled by default:

image

You'd need to enable it and move it to the top.

Can you give us more info on nvdec.ex please?

RaptorCentauri
Posted

I tried two scenarios, both with the new decoder option enabled and set to highest priority.

1) Turn OFF 'use mpv player' - movie is transcoding and video is playing well.

2) Turn ON  'use mpv player' - movie is Direct Streaming and video is NOT playing well.

I've attached logs.

 

MPV DISABLED _ ffmpeg-transcode-cf20f842-058a-4535-9bbc-975d13c361d4_1.txtMPV_ENABLED ffmpeg-remux-ed6115a5-ced3-4244-8a67-27105f03d0db_1.txt

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...