I want to get only GPU Utilization

Hi,

I’m using Quadro RTX 6000.

I want to know only GPU utilization and want to use it.

In particular, I want to code that I can get and use the value (GPU utilization) while running the program.

Is this possible? Do you have a CUDA API that does this?

You want the NVML library:

https://docs.nvidia.com/deploy/nvml-api/index.html

I have not used it, but from the documentation linked above it seems you want the nvmlDeviceGetUtilizationRates() function which returns the GPU and memory utilization rate for a given device.