Exemplo n.º 1
0
def simple_test():
    from time import time

    print "running barchart test routine"
    dum = [
        ("fddo4", 1318),
        ("cn1", 1472),
        ("cn2", 1411),
        ("fddo3", 1280),
        ("asc8", 1371),
        ("orb3", 1390),
        ("fddo1", 1418),
        ("asc4", 1292),
        ("dn2", 1381),
        ("fddo2", 1341),
        ("asc1", 1352),
        ("dn1", 1441),
    ]
    t0 = time()
    doc = SimpleDocument(title="Bar Chart", bgcolor=GREY1)
    dummydata = DataList()
    dummydata.load_tuples(dum)
    dummydata.sort()
    b = BarChart(dummydata)
    b.thresholds = (1300, 1400)
    b.title = "System Throughput (jobs/week)"
    doc.append(b)
    doc.append(Pre(str(dummydata)))
    doc.write("./html/bar.html")
    print "took", time() - t0, "sec."
Exemplo n.º 2
0
def stacked_test():
    from time import time
    print "running stacked barchart test routine"
    dum = [('fddo4', 1318, 456, 235, 290), ('fddo3', 1280, 560, 129, 295),
           ('fddo1', 1418, 1201, 490, 125), ('fddo2', 1341, 810, 466, 203)]
    t0 = time()
    doc = SimpleDocument(title='Stacked Bar Chart', bgcolor=GREY1)
    dummydata = DataList()
    dummydata.segment_names = ('User', 'System', 'I/O', 'Wait')
    dummydata.load_tuples(dum)
    dummydata.sort()
    b = StackedBarChart(dummydata)
    b.title = "System Load"
    doc.append(b)
    doc.append(Pre(str(dummydata)))
    doc.write('./html/stackedbar.html')
    print "took", time() - t0, 'sec.'
Exemplo n.º 3
0
def simple_test():
    from time import time
    print "running barchart test routine"
    dum = [('fddo4', 1318), ('cn1', 1472), ('cn2', 1411), ('fddo3', 1280),
           ('asc8', 1371), ('orb3', 1390), ('fddo1', 1418), ('asc4', 1292),
           ('dn2', 1381), ('fddo2', 1341), ('asc1', 1352), ('dn1', 1441)]
    t0 = time()
    doc = SimpleDocument(title='Bar Chart', bgcolor=GREY1)
    dummydata = DataList()
    dummydata.load_tuples(dum)
    dummydata.sort()
    b = BarChart(dummydata)
    b.thresholds = (1300, 1400)
    b.title = "System Throughput (jobs/week)"
    doc.append(b)
    doc.append(Pre(str(dummydata)))
    doc.write('./html/bar.html')
    print "took", time() - t0, 'sec.'
Exemplo n.º 4
0
def stacked_test():
    from time import time
    print "running stacked barchart test routine" 
    dum = [ ('fddo4', 1318, 456, 235, 290),
            ('fddo3', 1280, 560, 129, 295), 
            ('fddo1', 1418, 1201, 490, 125),
            ('fddo2', 1341, 810, 466, 203)
            ]
    t0 = time()
    doc = SimpleDocument(title='Stacked Bar Chart', bgcolor=GREY1)
    dummydata = DataList()
    dummydata.segment_names = ('User','System','I/O','Wait')
    dummydata.load_tuples(dum)
    dummydata.sort()
    b = StackedBarChart(dummydata)
    b.title = "System Load"
    doc.append(b)
    doc.append(Pre(str(dummydata)))
    doc.write('./html/stackedbar.html')
    print "took", time() - t0, 'sec.'
Exemplo n.º 5
0
def simple_test():
    from time import time
    print "running barchart test routine" 
    dum = [ ('fddo4', 1318), ('cn1', 1472), ('cn2', 1411),
            ('fddo3', 1280), ('asc8', 1371), ('orb3', 1390),
            ('fddo1', 1418), ('asc4', 1292), ('dn2', 1381),
            ('fddo2', 1341), ('asc1', 1352), ('dn1', 1441)
            ]
    t0 = time()
    doc = SimpleDocument(title='Bar Chart', bgcolor=GREY1)
    dummydata = DataList()
    dummydata.load_tuples(dum)
    dummydata.sort()
    b = BarChart(dummydata)
    b.thresholds = (1300, 1400)
    b.title = "System Throughput (jobs/week)"
    doc.append(b)
    doc.append(Pre(str(dummydata)))
    doc.write('./html/bar.html')
    print "took", time() - t0, 'sec.'
Exemplo n.º 6
0
def stacked_test():
    from time import time

    print "running stacked barchart test routine"
    dum = [
        ("fddo4", 1318, 456, 235, 290),
        ("fddo3", 1280, 560, 129, 295),
        ("fddo1", 1418, 1201, 490, 125),
        ("fddo2", 1341, 810, 466, 203),
    ]
    t0 = time()
    doc = SimpleDocument(title="Stacked Bar Chart", bgcolor=GREY1)
    dummydata = DataList()
    dummydata.segment_names = ("User", "System", "I/O", "Wait")
    dummydata.load_tuples(dum)
    dummydata.sort()
    b = StackedBarChart(dummydata)
    b.title = "System Load"
    doc.append(b)
    doc.append(Pre(str(dummydata)))
    doc.write("./html/stackedbar.html")
    print "took", time() - t0, "sec."