-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgraphit.py
69 lines (56 loc) · 1.46 KB
/
graphit.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
path="/Users/pasithea/results_bm_vm/"
x = []
yreceived = []
ysent = []
yfivenine = []
yfournine = []
ythreenine = []
ytwonine = []
yonenine = []
ysevenfive = []
yfivezero = []
ytwofive = []
yavglatency = []
ystddevlatency = []
def graphit():
for i in range(1, 127):
x.append(i)
with open(path + "sockperf_" + str(i), "r") as f:
lines = f.readlines()
averagereceived = lines[0]
averagesent = lines[1]
averagefivenine = lines[2]
averagefournine = lines[3]
averagethreenine = lines[4]
averagetwonine = lines[5]
averageonenine = lines[6]
averagesevenfive = lines[7]
averagefivezero = lines[8]
averagetwofive = lines[9]
averageavglatency = lines[10]
averagestddevlatency = lines[11]
yreceived.append(float(averagereceived))
ysent.append(float(averagesent))
yfivenine.append(float(averagefivenine))
yfournine.append(float(averagefournine))
ythreenine.append(float(averagethreenine))
ytwonine.append(float(averagetwonine))
yonenine.append(float(averageonenine))
ysevenfive.append(float(averagesevenfive))
yfivezero.append(float(averagefivezero))
ytwofive.append(float(averagetwofive))
yavglatency.append(float(averageavglatency))
ystddevlatency.append(float(averagestddevlatency))
print(yreceived)
print(ysent)
print(yfivenine)
print(yfournine)
print(ythreenine)
print(ytwonine)
print(yonenine)
print(ysevenfive)
print(yfivezero)
print(ytwofive)
print(yavglatency)
print(ystddevlatency)
graphit()