diff options
| author | Florian Fischer <florian.fl.fischer@fau.de> | 2018-09-14 20:21:56 +0200 |
|---|---|---|
| committer | Florian Fischer <florian.fl.fischer@fau.de> | 2018-09-14 20:21:56 +0200 |
| commit | b82099483c78acf8245a1c6be94b546b64d483d8 (patch) | |
| tree | f8300ed31fee2ae4bd0c702e4aa802d02ac59a2d /larson.py | |
| parent | ede9aaa8d602aae204df5eacba3aae73b3a352b1 (diff) | |
| download | allocbench-b82099483c78acf8245a1c6be94b546b64d483d8.tar.gz allocbench-b82099483c78acf8245a1c6be94b546b64d483d8.zip | |
fix perf parsing and add new plot functions and use them
Diffstat (limited to 'larson.py')
| -rw-r--r-- | larson.py | 38 |
1 files changed, 6 insertions, 32 deletions
@@ -1,7 +1,4 @@ -import matplotlib.pyplot as plt import multiprocessing -import numpy as np -import os import re from benchmark import Benchmark @@ -32,35 +29,12 @@ class Benchmark_Larson( Benchmark ): if res: result["throughput"] = int(res.group("throughput")) return - print(stdout) - print("no match") - - def summary(self, sd=None): - # Speedup thrash - args = self.results["args"] - nthreads = args["threads"] - targets = self.results["targets"] - - sd = sd or "" - - for arg in args: - loose_arg = [a for a in args if a != arg][0] - for arg_value in args[arg]: - for target in targets: - y_vals = [] - for perm in self.iterate_args_fixed({arg : arg_value}, args=args): - d = [m["throughput"] for m in self.results[target][perm]] - y_vals.append(np.mean(d)) - x_vals = list(range(1, len(y_vals) + 1)) - plt.plot(x_vals, y_vals, marker='.', linestyle='-', - label=target, color=targets[target]["color"]) - plt.legend() - plt.xticks(x_vals, args[loose_arg]) - plt.xlabel(loose_arg) - plt.ylabel("OPS/s") - plt.title("Larson: " + arg + " " + str(arg_value)) - plt.savefig(os.path.join(sd, ".".join([self.name, arg, str(arg_value), "png"]))) - plt.clf() + def summary(self, sumdir): + # Plot threads->throughput and maxsize->throughput + self.plot_fixed_args("{throughput}", + ylabel="'OPS/s'", + title = "'Larson: ' + arg + ' ' + str(arg_value)", + sumdir=sumdir) larson = Benchmark_Larson() |
