NVML multiple instance of NVDEC

Hi all,

I write a sample that instance multiple nvdec in a common cuda context and launched nvidia-smi to profile the Encoder payload, but the result is 0%. Instead using a single decoder the percentage is updated correctly.

Some one have found the same behaviour?

Thank you in advance
Paolo

PS I use Win10

Paolo

It is not clear from your message what the exact problem is.

Are you launching multiple instances of the decoder and trying to observe NVDEC utilization via NVIDIA-SMI?

Or something else?

Could you please provide sample code (or pseudo code) you used for achieving this?

Thanks

Hi Abhijit,

I have two use cases:

Using a stream H264 nvml works correctly and i can see the percentage decoder.
Using a MJPEG stream with four sub-sessions and instantiating for each one a dedicated decoder with flag cudaVideoCreate_PreferCUVID. In this case Nvml Decoder occupations drop to 0.

In the meanwhile I understood that MJpeg is decoded with CUDA and not using the hardware decoder, is it correct?

Paolo

You are right. MJPEG is decoded using CUDA and not using hardware decoder.

So, if I want to decode multiple streams concurrently, do I just need to create separate decoder for each stream? Meaning I need to call “cuvidCreateDecoder” for each stream?

Yes. Please take a look at AppDecMultiInput or AppDecMultiFiles application in the Video Codec SDK.

I don’t have any of those samples. I have CUDA v9.1 installed (

C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v9.1

)
and SDK 7.1.9 (

C:\Program Files\NVIDIA GPU Computing Toolkit\Video_Codec_SDK_7.1.9

)

I found this one https://github.com/NVIDIA/video-sdk-samples/blob/master/Samples/AppDecode/AppDecMultiFiles/AppDecMultiFiles.cpp.

  1. First of all, it seems that it decodes each file in sequence and not all files concurrently. What's the benefit of this?
  2. Secondly, it uses "NvDecoder" and not "CUvideodecoder". What version of SDK is this?

Any response please?