fix some minor stats stuff
util/stats/stats.py: fix up a few of the stats. --HG-- extra : convert_revision : 61c600cd146900c8cc0cf60a9036f2e999a5e244
This commit is contained in:
parent
9b18c0e872
commit
29f50d9345
1 changed files with 3 additions and 4 deletions
|
@ -262,6 +262,7 @@ def commands(options, command, args):
|
||||||
from output import StatOutput
|
from output import StatOutput
|
||||||
output = StatOutput(options.jobfile, source)
|
output = StatOutput(options.jobfile, source)
|
||||||
output.xlabel = 'System Configuration'
|
output.xlabel = 'System Configuration'
|
||||||
|
output.colormap = 'RdYlGn'
|
||||||
|
|
||||||
if command == 'stat' or command == 'formula':
|
if command == 'stat' or command == 'formula':
|
||||||
if len(args) != 1:
|
if len(args) != 1:
|
||||||
|
@ -286,7 +287,6 @@ def commands(options, command, args):
|
||||||
raise CommandException
|
raise CommandException
|
||||||
|
|
||||||
from info import ProxyGroup
|
from info import ProxyGroup
|
||||||
sim_seconds = source['sim_seconds']
|
|
||||||
proxy = ProxyGroup(system = source[options.system])
|
proxy = ProxyGroup(system = source[options.system])
|
||||||
system = proxy.system
|
system = proxy.system
|
||||||
|
|
||||||
|
@ -294,7 +294,6 @@ def commands(options, command, args):
|
||||||
bytes = etherdev.rxBytes + etherdev.txBytes
|
bytes = etherdev.rxBytes + etherdev.txBytes
|
||||||
kbytes = bytes / 1024
|
kbytes = bytes / 1024
|
||||||
packets = etherdev.rxPackets + etherdev.txPackets
|
packets = etherdev.rxPackets + etherdev.txPackets
|
||||||
bps = etherdev.rxBandwidth + etherdev.txBandwidth
|
|
||||||
|
|
||||||
def display():
|
def display():
|
||||||
if options.graph:
|
if options.graph:
|
||||||
|
@ -337,7 +336,7 @@ def commands(options, command, args):
|
||||||
return
|
return
|
||||||
|
|
||||||
if command == 'pps':
|
if command == 'pps':
|
||||||
output.stat = packets / sim_seconds
|
output.stat = packets / source['sim_seconds']
|
||||||
output.ylabel = 'Packets/s'
|
output.ylabel = 'Packets/s'
|
||||||
display()
|
display()
|
||||||
return
|
return
|
||||||
|
@ -355,7 +354,7 @@ def commands(options, command, args):
|
||||||
if command == 'txbps':
|
if command == 'txbps':
|
||||||
output.stat = etherdev.txBandwidth / 1e9
|
output.stat = etherdev.txBandwidth / 1e9
|
||||||
if command == 'bps':
|
if command == 'bps':
|
||||||
output.stat = bps / 1e9
|
output.stat = (etherdev.rxBandwidth + etherdev.txBandwidth) / 1e9
|
||||||
|
|
||||||
output.ylabel = 'Bandwidth (Gbps)'
|
output.ylabel = 'Bandwidth (Gbps)'
|
||||||
output.ylim = [ 0.0, 10.0 ]
|
output.ylim = [ 0.0, 10.0 ]
|
||||||
|
|
Loading…
Reference in a new issue