/[pdpsoft]/nl.nikhef.ndpf.groupviews/trunk/ndpf-gv-mkplots
ViewVC logotype

Diff of /nl.nikhef.ndpf.groupviews/trunk/ndpf-gv-mkplots

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3271 by templon, Tue Oct 8 10:42:17 2019 UTC revision 3272 by templon, Wed Oct 9 09:53:58 2019 UTC
# Line 171  def doplot(glist, dbtype, psize, timetag Line 171  def doplot(glist, dbtype, psize, timetag
171          if 'offline'  in grouplist:          if 'offline'  in grouplist:
172              skipgroup += 1              skipgroup += 1
173    
174      for idx in range(len(grouplist)):      ngr = len(grouplist)
175        ncol = len(colors)
176        for idx in range(ngr):
177          thisgrp = grouplist[idx]          thisgrp = grouplist[idx]
178            print idx, thisgrp
179          if thisgrp == 'unused':          if thisgrp == 'unused':
180              gcolors[thisgrp] = '#d8d8d8'              gcolors[thisgrp] = '#d8d8d8'
181          elif thisgrp == "offline":          elif thisgrp == "offline":
182              gcolors[thisgrp] = "#790ead"              gcolors[thisgrp] = "#790ead"
183          else:          else:
184              gcolors[thisgrp] = colors[idx+skipgroup]              print "ranktype, ngr, idx, skipgroup", ranktype, ngr, idx, skipgroup
185                gcolors[thisgrp] = colors[(ncol - ngr) + idx + skipgroup]
186    
187      if dbtype == 'queued':      if dbtype == 'queued':
188          if 'unused'  in grouplist: grouplist.remove('unused')          if 'unused'  in grouplist: grouplist.remove('unused')
# Line 247  def doplot_wait(glist, dbtype, psize, ti Line 251  def doplot_wait(glist, dbtype, psize, ti
251      for group in (grouplist + ['rollover','lastroll']):      for group in (grouplist + ['rollover','lastroll']):
252          data_defs.append('DEF:'+group+'='+DATADIR+group+'.'+dbtype+'.rrd:'+dbtype+':AVERAGE')          data_defs.append('DEF:'+group+'='+DATADIR+group+'.'+dbtype+'.rrd:'+dbtype+':AVERAGE')
253    
254        ncol = len(colors)
255        ngr  = len(grouplist)
256      for idx in range(len(grouplist)):      for idx in range(len(grouplist)):
257          group = grouplist[idx]          group = grouplist[idx]
258          if group == 'unused':          if group == 'unused':
# Line 256  def doplot_wait(glist, dbtype, psize, ti Line 262  def doplot_wait(glist, dbtype, psize, ti
262              acolor = "#790ead"              acolor = "#790ead"
263              skipgroup += 1              skipgroup += 1
264          else:          else:
265              acolor = colors[idx+skipgroup]              print ncol, ngr, idx, skipgroup
266                acolor = colors[(ncol - ngr) + idx ]
267          pdefstr = 'LINE3' ':' + group + acolor + ':' + group          pdefstr = 'LINE3' ':' + group + acolor + ':' + group
268          pdefstr = pdefstr + '\\n'          pdefstr = pdefstr + '\\n'
269          plot_defs.append(pdefstr)          plot_defs.append(pdefstr)

Legend:
Removed from v.3271  
changed lines
  Added in v.3272

grid.support@nikhef.nl
ViewVC Help
Powered by ViewVC 1.1.28