diff options
author | Andrea Bastoni <bastoni@cs.unc.edu> | 2010-03-27 11:54:54 -0400 |
---|---|---|
committer | Andrea Bastoni <bastoni@cs.unc.edu> | 2010-03-27 11:54:54 -0400 |
commit | 0fbeff4a0887a48dea0a95a1d51e4ff9766c8d12 (patch) | |
tree | c5809ae94e6e74cbcec81d258d0f22e932622905 | |
parent | a048bb28a4f1377e81cecdefc3f9fb64f4bab7ed (diff) |
Fix "proper" iteration on arrays and typos
-rwxr-xr-x | compact_pm_ovd.py | 11 | ||||
-rwxr-xr-x | plot_pm.py | 14 |
2 files changed, 10 insertions, 15 deletions
diff --git a/compact_pm_ovd.py b/compact_pm_ovd.py index 4670de0..10151d4 100755 --- a/compact_pm_ovd.py +++ b/compact_pm_ovd.py | |||
@@ -57,14 +57,9 @@ class WSSCompactor(): | |||
57 | wstr += 'wss=' + str(wss) + ':(max, avg), ' | 57 | wstr += 'wss=' + str(wss) + ':(max, avg), ' |
58 | csvf.write(wstr[0:-2] + '\n') | 58 | csvf.write(wstr[0:-2] + '\n') |
59 | 59 | ||
60 | tkeys = self.ovhead_table.keys() | 60 | for key in sorted(self.ovhead_table.keys(), key=int): |
61 | for i in range(0,len(tkeys)): | 61 | wstr = key + ', ' |
62 | tkeys[i] = int(tkeys[i]) | 62 | for value in self.ovhead_table[key]: |
63 | tkeys.sort() | ||
64 | |||
65 | for key in tkeys: | ||
66 | wstr = str(key) + ', ' | ||
67 | for value in self.ovhead_table[str(key)]: | ||
68 | if float(value) > 0: | 63 | if float(value) > 0: |
69 | wstr += value + ', ' | 64 | wstr += value + ', ' |
70 | else: | 65 | else: |
@@ -27,10 +27,10 @@ defaults = { | |||
27 | 'alloh' : False, | 27 | 'alloh' : False, |
28 | 'type' : 'hard', | 28 | 'type' : 'hard', |
29 | 'format' : 'show', | 29 | 'format' : 'show', |
30 | 'xrange' : (99.5, 200.5), | 30 | 'xrange' : (74.5, 250.5), |
31 | 'yrange' : (0, 5300.05), | 31 | 'yrange' : (0, 5000), |
32 | 'xticks' : (0, 10), | 32 | 'xticks' : (0, 25), |
33 | 'yticks' : (0, 100), | 33 | 'yticks' : (0, 250), |
34 | 'title' : None, | 34 | 'title' : None, |
35 | 'xlabel' : 'number of tasks', | 35 | 'xlabel' : 'number of tasks', |
36 | 'ylabel' : 'overhead (us)', | 36 | 'ylabel' : 'overhead (us)', |
@@ -134,8 +134,8 @@ class PmPlotter(defapp.App): | |||
134 | self.plot(graphs, title, name, conf) | 134 | self.plot(graphs, title, name, conf) |
135 | 135 | ||
136 | def add_to_graph_list(self, tmpfile, name, conf): | 136 | def add_to_graph_list(self, tmpfile, name, conf): |
137 | self.title += overhead_heading(conf, sharedL3=self.options.sharedL3) | 137 | #self.title += overhead_heading(conf, sharedL3=self.options.sharedL3) |
138 | self.title += ' ; ' | 138 | #self.title += ' ; ' |
139 | wsslist = conf['wss'].split(',') | 139 | wsslist = conf['wss'].split(',') |
140 | wsspos = 2 | 140 | wsspos = 2 |
141 | if 'soft' in conf: | 141 | if 'soft' in conf: |
@@ -175,7 +175,7 @@ class PmPlotter(defapp.App): | |||
175 | else: | 175 | else: |
176 | self.plot_pm(tmpfile.name, name, conf) | 176 | self.plot_pm(tmpfile.name, name, conf) |
177 | else: | 177 | else: |
178 | self.err("Skipped '%s'; unkown experiment type." | 178 | self.err("Skipped '%s'; unknown experiment type." |
179 | % bname) | 179 | % bname) |
180 | 180 | ||
181 | if self.options.alloh: | 181 | if self.options.alloh: |