|
|
|
@ -8,6 +8,7 @@ nvmlDevice_t nvidiaDevice;
|
|
|
|
|
bool nvmlSuccess = false;
|
|
|
|
|
unsigned int nvidiaTemp;
|
|
|
|
|
struct nvmlUtilization_st nvidiaUtilization;
|
|
|
|
|
struct nvmlMemory_st nvidiaMemory;
|
|
|
|
|
|
|
|
|
|
bool checkNvidia(){
|
|
|
|
|
if (nvml.IsLoaded()){
|
|
|
|
@ -28,4 +29,5 @@ void getNvidiaInfo(){
|
|
|
|
|
nvml.nvmlDeviceGetHandleByIndex(0, &nvidiaDevice);
|
|
|
|
|
nvml.nvmlDeviceGetUtilizationRates(nvidiaDevice, &nvidiaUtilization);
|
|
|
|
|
nvml.nvmlDeviceGetTemperature(nvidiaDevice, NVML_TEMPERATURE_GPU, &nvidiaTemp);
|
|
|
|
|
nvml.nvmlDeviceGetMemoryInfo(nvidiaDevice, &nvidiaMemory);
|
|
|
|
|
}
|