Media (Intel® Video Processing Library, Intel Media SDK)
Access community support with transcoding, decoding, and encoding in applications using media tools like Intel® oneAPI Video Processing Library and Intel® Media SDK
Announcements
The Intel Media SDK project is no longer active. For continued support and access to new features, Intel Media SDK users are encouraged to read the transition guide on upgrading from Intel® Media SDK to Intel® Video Processing Library (VPL), and to move to VPL as soon as possible.
For more information, see the VPL website.

Encode timeout

BernardThilmant
Beginner
3,281 Views
Hello,

 

I am using oneVPL to encode simultaneously 16 low resolution video streams in H.264 (see the 

mfxVideoParam for more info).
 
All of the streams have the same characteristics.

 

 

 

mfxVideoParam encodeParams     = {};            
encodeParams.mfx.CodecId                 = MFX_CODEC_AVC;
encodeParams.mfx.CodecProfile            = MFX_PROFILE_AVC_MAIN;
encodeParams.mfx.CodecLevel              = MFX_LEVEL_AVC_4;
encodeParams.mfx.TargetUsage             = MFX_TARGETUSAGE_BALANCED;
encodeParams.mfx.RateControlMethod       = MFX_RATECONTROL_AVBR;
encodeParams.mfx.TargetKbps              = 4000;
encodeParams.mfx.MaxKbps                 = 4000;
encodeParams.mfx.InitialDelayInKB        = 384;
encodeParams.mfx.GopRefDist              = 1;
encodeParams.mfx.GopPicSize              = 8;
encodeParams.mfx.FrameInfo.FourCC        = MFX_FOURCC_NV12;
encodeParams.mfx.FrameInfo.FrameRateExtN = 60;
encodeParams.mfx.FrameInfo.FrameRateExtD = 1;
encodeParams.mfx.FrameInfo.ChromaFormat = MFX_CHROMAFORMAT_YUV420;
encodeParams.mfx.FrameInfo.CropW        = 960;
encodeParams.mfx.FrameInfo.CropH        = 544;
encodeParams.mfx.FrameInfo.Width        = ALIGN16(960);
encodeParams.mfx.FrameInfo.Height       = ALIGN16(544);

 

 

The encoding must be done in real time.

I have a test app which is based on the following example: 
https://github.com/oneapi-src/oneVPL/blob/v2023.1.1/examples/hello/hello-encode/src/hello-encode.cpp

The modification I did are:

  1. Allow multiple sessions to run in parallel 
  2. I loop the input raw files in order to have no time limits as my input raw clips have a duration of few seconds
    • At the end I always repeat the encoding of the same sequences

Every thing works well except for long duration tests (> 1 hour), where I can get some timeout errors on the MFXVideoCORE_SyncOperation call.

On the hello-encode.cpp example the timeout is set to 100ms -> I tried up to 2000ms and still have errors.

Any idea why I get these timeouts? Especially since I keep encoding the same sequences, I mean there is no surprise with a new sequence which would be more difficult to encode.


Here is some information about my setup

  • Processor: i5-12500E 
  • OS: Linux
  • oneVPL GPU Runtime: 23.1.5
  • oneVPL: v2023.1.3

Thanks in advence,

Regards,

Bernard Thilmant 

0 Kudos
17 Replies
AthiraM_Intel
Moderator
3,245 Views

Hi,


Thank you for posting in Intel Communities.


Could you please share the sample reproducer code and the exact steps you followed, so that we can reproduce the same from our end.



Thanks


0 Kudos
BernardThilmant
Beginner
3,228 Views

Hello,

Thanks for your answer. I have attached the code. I also provided an input video sample.

In the reamde.md, you will find the used command line.

Best regards,

Bernard Thilmant

0 Kudos
AthiraM_Intel
Moderator
3,149 Views

Hi,

 

We have tried to replicate your issue, but we are getting segmentation fault. We tried it on ubuntu 18.04 with oneVPL 2023.3.1.

Please see the below screenshot:

  AthiraM_Intel_0-1690304939133.png

 

Could you please check whether your issue persists with latest version of oneVPL.

If the issue still persists, please let us know the OS( specify the distribution, eg: centos/ubuntu/rhel/fedora) you used. Also share the screenshots of the error. 

 

 Thanks

 

0 Kudos
AthiraM_Intel
Moderator
3,099 Views

Hi,


We have not heard back from you. Could you please give us an update?



Thanks


0 Kudos
BernardThilmant
Beginner
3,054 Views

Hi,

Sorry for the late answer, I had an issue with my account and finally had to recreate it.

I can already see you are using the software implementation (param "-sw"), do you also have the segmentation fault with the hardware implementation (param "-hw") ?

Best regards,

Bernard Thilmant 

0 Kudos
AthiraM_Intel
Moderator
2,990 Views

Hi,

 

We are getting "Aborted (Core dumped) " issue while trying hardware implementation (-hw).

AthiraM_Intel_0-1692006113690.png

 

Could you please check whether your issue persists with latest version of oneVPL from your side.

 

If the issue still persists, please let us know the OS( specify the distribution, eg: centos/ubuntu/rhel/fedora) you used. Also share the screenshots of the error. 

 

Thanks

 

 

0 Kudos
BernardThilmant
Beginner
2,962 Views

Hello,

No core dump on my side.

I am using buildroot. 

I am going to do the update to oneVPL 2023.3.1.

Best regards,

Bernard Thilmant

0 Kudos
BernardThilmant
Beginner
2,913 Views

Hello,

I did the update. No dump on my side.

I have the following versions:

  • oneVPL  GPU 23.2.4
  • oneVPL  2023.3.1
  • Driver     23.2.4
  • Gmmlib 22.3.7
  • libva       2.19.0
  • libva-utils  2.19.0

(as it is specify here: https://github.com/oneapi-src/oneVPL-intel-gpu/releases/tag/intel-onevpl-23.2.4)

 

Maybe you could generate a dump file and get the backtrace of the program ?

0 Kudos
AthiraM_Intel
Moderator
2,870 Views

Hi,


We are checking on this issue internally. We will get back to you with an update.



Thanks


0 Kudos
BernardThilmant
Beginner
2,832 Views

Thank you

If you see something I can do to help, let me know.

Best regards

0 Kudos
AthiraM_Intel
Moderator
2,712 Views

Hi,

 

We have informed the development team regarding your issue, they asked the following details:

 

Please set a really long delay so we will have more info to know whether it is a GPU hang vs it’s just taking a really long time to return. 

The 2000ms you tried is really long, but can you try 5000 or 10,000ms – to verify whether it’s a hang.

 

If you are getting timeout error, please share the screenshots also.

 

 

Thanks

0 Kudos
BernardThilmant
Beginner
2,678 Views

Hello,

Thank you for your response.

I am going to try a longer timeout as suggested. I come back to you as soon as I can.

My wife will very soon give birth. From that moment, I will be on paternity leave for almost 2 months.

I won't be able to answer during this time. I will start working again in November.

Sorry for the inconvenience.

Regards,

Bernard Thilmant

 

0 Kudos
AthiraM_Intel
Moderator
2,658 Views

Hi,


Good day to you.


Thank you for letting us know. We will wait for your update.


Also share the VPL/UMD logs for further investigation when you come back?



Thanks



0 Kudos
BernardThilmant
Beginner
2,282 Views

Hello,

I am back to work.

I have an issue on my side when I try  to reproduce the issue.

I come back ASAP with the information that have been asked.

Regards,

Bernard Thilmant

0 Kudos
AthiraM_Intel
Moderator
2,112 Views

Hi,


Could you please give us an update? Are you able to get the logs?



Thanks


0 Kudos
AthiraM_Intel
Moderator
2,076 Views

Hi,


We have not heard back from you. Could you please give us an update?


Thanks


0 Kudos
AthiraM_Intel
Moderator
1,841 Views

Hi,


We have not heard back from you. This thread will no longer be monitored by Intel. If you need further assistance, please post a new question.


Thanks


0 Kudos
Reply