Skip to content

Commit

Permalink
Merge pull request #36 from Disty0/main
Browse files Browse the repository at this point in the history
OpenVINO add VRAM size
  • Loading branch information
vladmandic authored Sep 28, 2023
2 parents 75b6c5a + 66a6d6b commit 34ada0d
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions scripts/system-info.py
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,16 @@ def gb(val: float):
mem.update({ 'utilization': torch.cuda.utilization() }) # do this one separately as it may fail
except Exception:
pass
else:
try:
from openvino.runtime import Core as OpenVINO_Core
from modules.intel.openvino import get_device as get_raw_openvino_device
openvino_core = OpenVINO_Core()
mem.update({
'gpu': { 'total': gb(openvino_core.get_property(get_raw_openvino_device(), 'GPU_DEVICE_TOTAL_MEM_SIZE')) },
})
except Exception:
pass
return mem


Expand Down

0 comments on commit 34ada0d

Please sign in to comment.