Created
March 21, 2018 22:19
-
-
Save sharkdp/e1712590690aa95df65f5a73751d33a9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
import argparse | |
import json | |
import matplotlib.pyplot as plt | |
parser = argparse.ArgumentParser() | |
parser.add_argument("results", help="JSON file with benchmark results") | |
args = parser.parse_args() | |
with open(args.results) as f: | |
results = json.load(f)["results"] | |
commands = [b["command"] for b in results] | |
times = [b["times"] for b in results] | |
plt.boxplot(times, labels=commands) | |
plt.ylabel("Time [s]") | |
plt.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment