Commit a48033b3 by Tobias Langer

Print the average misses number.

parent f05456ea
...@@ -63,8 +63,11 @@ def main(): ...@@ -63,8 +63,11 @@ def main():
s2s = 0 s2s = 0
e2e = 0 e2e = 0
misses = 0 misses = 0
misses_avrg = 0
exec_cnt = 0
response = 0 response = 0
for task_id, task in instances.items(): for task_id, task in instances.items():
exec_cnt += tasks[task_id]['executions']
s2s += math.sqrt(task['s2s'] / tasks[task_id]['executions']) s2s += math.sqrt(task['s2s'] / tasks[task_id]['executions'])
e2e += math.sqrt(task['e2e'] / tasks[task_id]['executions']) e2e += math.sqrt(task['e2e'] / tasks[task_id]['executions'])
misses += task['misses'] misses += task['misses']
...@@ -73,6 +76,7 @@ def main(): ...@@ -73,6 +76,7 @@ def main():
s2s /= len(tasks) s2s /= len(tasks)
e2e /= len(tasks) e2e /= len(tasks)
response /= len(tasks) response /= len(tasks)
misses_avrg /= exec_cnt
outkey = round(util, 2) outkey = round(util, 2)
...@@ -96,6 +100,11 @@ def main(): ...@@ -96,6 +100,11 @@ def main():
for elem in value: for elem in value:
print('{}; {}'.format(key, elem[2]), file=missesfile) print('{}; {}'.format(key, elem[2]), file=missesfile)
with open('analysis/misses_avrg.dat', 'w') as missesavrgfile:
for key, value in out.items():
for elem in value:
print('{}; {}'.format(key, elem[3]), file=missesavrgfile)
with open('analysis/response.dat', 'w') as responsefile: with open('analysis/response.dat', 'w') as responsefile:
for key, value in out.items(): for key, value in out.items():
for elem in value: for elem in value:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment