Measure GPU load

I’m trying to measure GPU’s performance while playing videos on Jetson Nano, but I’m not sure if it’s the right way.

I found three files:

/sys/devices/57000000.gpu/load
/sys/devices/gpu.0/load
/sys/devices/platform/host1x/57000000.gpu/load

I believe the value is 10*percentage. Usually the three files produce the same value, but sometimes they are different.

The values are very unstable. It makes me think if I got the wrong numbers. It is always 0 if there is nothing playing, which makes sense. I collect some data by reading a value every second. When I play rstp streams, the values change dramatically. It looks a little better when playing local files.

Any comments will be appreciated.
gpuloadRtsp.png
gpuloadFiles.png

Hi Harry16,

I would suggest to monitor :

/sys/devices/gpu.0/load

You are right value is 10*percentage.
Also, JetsonHacks has python based example for it:

https://github.com/jetsonhacks/gpuGraphTX/

For rtsp, can you check if the packages are being dropped ? Are these two files same in size or streaming similar number of image frames?

Hi ak-nv,

Thanks for your answer. The python example is very useful.

To answer you questions: Both images are results from /sys/devices/57000000.gpu/load. Each was read every second for about three minutes. “gpuloadRtsp.png” was when playing eight 1080p 30fps rtsp streams, while “gpuloadFiles.png” was when playing a 4K30fps local mp4 file. There are few rtsp packages dropped, but I believe not enough to cause any trouble.