Add support for any number of GPUs
This commit is contained in:
parent
c0bf1cdf2b
commit
c3de89f678
1 changed files with 1 additions and 2 deletions
|
@ -2,8 +2,7 @@ import GPUtil
|
|||
import time
|
||||
|
||||
gpus = GPUtil.getGPUs()
|
||||
gpu = gpus[0]
|
||||
|
||||
while True:
|
||||
print(str(gpu.temperature) + " C")
|
||||
print(str(max(gpu.temperature for gpu in gpus)) + " C")
|
||||
time.sleep(3)
|
Loading…
Reference in a new issue