Ask Your Question
0

GPU threads count from Opencv GPU module

asked 2014-06-17 03:58:47 -0600

Tariq gravatar image

How can I determine GPU resource usage from OpenCV GPU module and especially the number of threads used during my program execution?

I am using Tesla K20C for executing my experiments and using GPUTech-Z utility to monitor resource usage.. During the program execution, my GPU is 15-20% loaded and it is consuming about 4% of GPU memory

I tried using Nsight Visual Studio edition, however, it shows only calls to opencv_gpu246d.dll and not to individual CUDA function calls from the library.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2014-07-01 03:41:38 -0600

updated 2014-07-01 05:42:31 -0600

To monitor the GPU module, when you are using CUDA, have a look at the NVIDIA Visual Profiler. NVIDIA has a blog, where you could learn how to use the visual profiler (here).

[Edit] Use the flag '-lineinfo' for nvcc to help profiling with line number.

edit flag offensive delete link more

Comments

Thanks for your answers Mathieu. Visual profiler was not helpful with OpenCV GPU module, as this module is already built and included as library in my application. I have no access to CUDA code while executing my application using OpenCV GPU module functions.

Tariq gravatar imageTariq ( 2014-07-01 04:07:37 -0600 )edit

Strange, in mine, I can see all the kernel launched. Did you try to compile yourself the library?

Mathieu Barnachon gravatar imageMathieu Barnachon ( 2014-07-01 04:10:41 -0600 )edit

Yes, I compiled the library with CUDA support by myself. Is there any special setting in your visual studio project for enabling the display of kernel launches in Visual profiler?

Tariq gravatar imageTariq ( 2014-07-01 05:01:48 -0600 )edit

I can specify NVCC profiler options with CUDA files, with .cu extension, in my project. I don't have any CUDA files in my OpenCV based project. Where shall I specify the NVCC compiler flagfs in this case?

Tariq gravatar imageTariq ( 2014-07-08 06:15:17 -0600 )edit

Question Tools

Stats

Asked: 2014-06-17 03:58:47 -0600

Seen: 439 times

Last updated: Jul 01 '14