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.
3073 Discussions

Decoder doesn‘t use the GPU even I set the "-hw" option

mao_h_
Beginner
693 Views

When I used the MSDK decoder I found that the decoder didn't use the GPU even I set the command parameter "-hw" both on Windows and Linux operating systems.

First, I will show my test on the Windows operating system. 

The detailed information of the Windows host is:
CPU: Intel(R) Core(TM) i7-4770 CPU @3.5GHz
GPU: Intel(R) HD Graphics 4600
memory: 8G
OS: windows 7 64bit
complier: Microsoft Visual Studio 2012
GPU monitor tool: GPU-Z
MSDK version: Intel Media SDK 2014 R2 for Clients(the release time is 2014-05-12)
test application: Video Decoding Sample of  Intel Media SDK 2014 R2 for Clients

When I run the decoding program in the Microsoft Visual Studio 2012, the command parameter was "h264 -i D:\input.h264" or "h264 -hw -i D:\input.h264". The test result is as follows:
捕获.PNG
We can see that the GPU usage is 0 in both situations.

Then I will show my test on the Linux operating system.

The detailed information of the Linux host is:
CPU: Intel(R) Core(TM) i7-3615QE CPU @ 2.30GHz
GPU: Intel(R) HD Graphics 4000
memory: 8G
Linux kernel version: 3.2.0-41
Linux distribution: Ubuntu 12.04 LTS 64bit
GPU monitor tool: intel-gpu-tools 1.2
MSDK version: Intel Media SDK 2014 R2 for Linux Servers(the release time is 2014-06-06)
test application:  Video Decoding Sample of  Intel Media SDK 2014 R2 for Linux Servers

When I run the decoding program in the command line, the command parameter was "./sample_decode_drm h264 -hw -i input.h264 -o output.yuv". The document named "readme-decode.pdf" in this sample says that "-hw: Use platform-specific implementation of Intel® Media SDK. Should be always set since there is no software library for Linux platforms." So I must set the command parameter "-hw" otherwise the program would run into error. In the test, the CPU usage was about 90%, and the output of the command "intel_gpu_top" was as follows:
捕获1.PNG
As we can see, the value of "render busy" was always 0. It meant that the GPU wasn't used. When the decoding process finished, the output said the decoding frame rate was about 1060fps.

Then it confused me that why the decoder didn't use the GPU at all even I set the "-hw" option.
PS. I also tested the sample_encode and sample_transcode program. They both used the GPU when I set the "-hw" option.

0 Kudos
2 Replies
mao_h_
Beginner
693 Views

These is an error in my post.

When I tested the decoding on the Linux, the command was "./sample_decode_drm h264 -hw -i input.h264". I didn't let the program write the YUV to the file.

0 Kudos
Surbhi_M_Intel
Employee
693 Views

Hi, 

Media SDK decoder performance is quite fast, so my recommendation is to try a long enough test which will trigger the GPU. Also it would be great if you can check what graphics driver is installed on your system? Please update to the latest driver which can be found here - https://downloadcenter.intel.com

Thanks,
-Surbhi

0 Kudos
Reply