Skip to content

Commit

Permalink
Merge pull request #6 from brainlife/master
Browse files Browse the repository at this point in the history
rebase
  • Loading branch information
giulia-berto authored Feb 25, 2021
2 parents 58ccc4e + 6ffc495 commit 60af24c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions hooks/smon
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ with open(name, "w") as outfile:
#query gpu usage
gpus = []
try:
out=subprocess.check_output(["nvidia-smi", "--query-gpu=index,name,pstate,temperature.gpu,utilization.gpu,utilization.memory,fan.speed", "--format=csv"]).decode("utf-8")
out=subprocess.check_output(["nvidia-smi", "--query-gpu=index,name,pstate,temperature.gpu,utilization.gpu,utilization.memory", "--format=csv"]).decode("utf-8")
lines=out.strip().split("\n")
header=lines.pop(0)
for line in lines:
Expand All @@ -131,7 +131,7 @@ with open(name, "w") as outfile:
"temperature.gpu": int(cols[3]),
"utilization.gpu": int(cols[4][:-1]), #remove %
"utilization.memory": int(cols[5][:-1]), #remove %
"fan.speed": int(cols[6][:-1]), #remove %
#"fan.speed": int(cols[6][:-1]), #remove % ([N/A] on bridges2)
})
except Exception as err:
None
Expand Down

0 comments on commit 60af24c

Please sign in to comment.