Skip to content

Commit

Permalink
Fix pyamdgpuinfo GPU core clock unit
Browse files Browse the repository at this point in the history
  • Loading branch information
mathoudebine committed Mar 4, 2024
1 parent 7eebd7d commit bb9d92a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion library/sensors/sensors_python.py
Original file line number Diff line number Diff line change
Expand Up @@ -339,9 +339,11 @@ def fan_percent() -> float:
@staticmethod
def frequency() -> float:
if pyamdgpuinfo:
return pyamdgpuinfo.get_gpu(0).query_sclk()
return pyamdgpuinfo.get_gpu(0).query_sclk() / 1000000
elif pyadl:
return pyadl.ADLManager.getInstance().getDevices()[0].getCurrentEngineClock()
else:
return math.nan

@staticmethod
def is_available() -> bool:
Expand Down

0 comments on commit bb9d92a

Please sign in to comment.