Skip to content
Snippets Groups Projects
Commit bfea67e7 authored by Franck Dary's avatar Franck Dary
Browse files

Fixed bug in script detecting number of used gpu on oar

parent 327fb729
No related branches found
No related tags found
No related merge requests found
......@@ -182,7 +182,13 @@ def getOarNbUsedGpuPerNode() :
cores = 1
gpunum = 1
if "core=" in ressources :
cores = int(ressources.split("core=")[-1].split('/')[0])
coresStr=""
coresStrBase = ressources.split("core=")[-1]
for symbol in coresStrBase :
if symbol < '0' or symbol > '9' :
break
coresStr = coresStr + symbol
cores = int(coresStr)
if "gpunum=" in ressources :
gpunum = int(ressources.split("gpunum=")[-1].split(',')[0])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment