Skip to content

Commit

Permalink
Updated perftest baselines to have 1000 iterations, and cleaned up pe…
Browse files Browse the repository at this point in the history
…rftest_plot script

Signed-off-by: Vedant <[email protected]>
  • Loading branch information
vrnimje committed Aug 24, 2024
1 parent b53373e commit 7f53069
Show file tree
Hide file tree
Showing 17 changed files with 57,967 additions and 5,778 deletions.
3,294 changes: 2,997 additions & 297 deletions tools/perftests_ci/perftest/references/lsu_default/benchmark_inplace_merge.json

Large diffs are not rendered by default.

3,282 changes: 2,991 additions & 291 deletions tools/perftests_ci/perftest/references/lsu_default/benchmark_is_heap.json

Large diffs are not rendered by default.

3,292 changes: 2,996 additions & 296 deletions tools/perftests_ci/perftest/references/lsu_default/benchmark_is_heap_until.json

Large diffs are not rendered by default.

3,292 changes: 2,996 additions & 296 deletions tools/perftests_ci/perftest/references/lsu_default/benchmark_merge.json

Large diffs are not rendered by default.

2,200 changes: 2,000 additions & 200 deletions tools/perftests_ci/perftest/references/lsu_default/benchmark_nth_element.json

Large diffs are not rendered by default.

Large diffs are not rendered by default.

2,196 changes: 1,998 additions & 198 deletions tools/perftests_ci/perftest/references/lsu_default/benchmark_partial_sort.json

Large diffs are not rendered by default.

Large diffs are not rendered by default.

3,290 changes: 2,995 additions & 295 deletions tools/perftests_ci/perftest/references/lsu_default/benchmark_remove.json

Large diffs are not rendered by default.

3,290 changes: 2,995 additions & 295 deletions tools/perftests_ci/perftest/references/lsu_default/benchmark_remove_if.json

Large diffs are not rendered by default.

3,288 changes: 2,994 additions & 294 deletions tools/perftests_ci/perftest/references/lsu_default/foreach_report.json

Large diffs are not rendered by default.

1,100 changes: 1,000 additions & 100 deletions tools/perftests_ci/perftest/references/lsu_default/future_overhead_report.json

Large diffs are not rendered by default.

3,294 changes: 2,997 additions & 297 deletions tools/perftests_ci/perftest/references/lsu_default/minmax_element_performance.json

Large diffs are not rendered by default.

11,020 changes: 10,010 additions & 1,010 deletions tools/perftests_ci/perftest/references/lsu_default/small_vector_benchmark.json

Large diffs are not rendered by default.

13,182 changes: 11,991 additions & 1,191 deletions tools/perftests_ci/perftest/references/lsu_default/stream_report.json

Large diffs are not rendered by default.

2,200 changes: 2,000 additions & 200 deletions tools/perftests_ci/perftest/references/lsu_default/transform_reduce_scaling.json

Large diffs are not rendered by default.

27 changes: 8 additions & 19 deletions tools/perftests_plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@

sns.set_style("ticks",{'axes.grid' : True})

def classify(lower, higher):
def classify(lower, upper):
if upper - lower > 0.1:
return '??'
return '??'

if -0.01 <= lower <= 0 <= upper <= 0.01:
return '='
Expand Down Expand Up @@ -69,9 +69,7 @@ def median_statistic(sample1, sample2, axis=-1):
samples = []

header_flag = True
# n = ceil(len(json_obj1["outputs"]) / 2)
# fig, ax = plt.subplots(2, n, figsize=(5 * n, 6), sharey=False)
# plt.subplots_adjust(hspace=0.3)

i = 0
for test1, test2 in zip(json_obj1["outputs"], json_obj2["outputs"]):
if test1["name"] == test2["name"]:
Expand All @@ -86,27 +84,22 @@ def median_statistic(sample1, sample2, axis=-1):
data = (test2["series"] / np.median(test1["series"]), test1["series"] / np.median(test1["series"]))
res = scipy.stats.bootstrap(data, median_statistic, method='basic', random_state=rng)

mean2 = np.median(test2["series"])
mean1 = np.median(test1["series"])

# if n != 1:
# curr_plot = ax[i // n, i % n]
# else:
# curr_plot = ax[i]
median2 = np.median(test2["series"])
median1 = np.median(test1["series"])

plt.figure(figsize=(8, 4))

sns.kdeplot(test2["series"], fill=True, label='baseline')
sns.kdeplot(test1["series"], fill=True, label='current')
plt.axvline(mean2, label='baseline mean', color='k')
plt.axvline(mean1, label='current mean', color='g')
plt.axvline(median2, label='baseline median', color='k')
plt.axvline(median1, label='current median', color='g')
plt.legend()
plt.suptitle(f'{test1["name"]}, \n{test1["executor"]}')

plt.tight_layout()
plt.savefig(f"{sys.argv[3]}_{i}.png")

percentage_diff = ((mean2 - mean1) / mean2) * 100
percentage_diff = ((median2 - median1) / median2) * 100

lower, upper = res.confidence_interval

Expand All @@ -128,8 +121,4 @@ def median_statistic(sample1, sample2, axis=-1):
i += 1

html_file.close()

# plt.tight_layout()
# [fig.delaxes(a) for a in ax.flatten() if not a.has_data()]
# plt.savefig(sys.argv[3] + ".png")

0 comments on commit 7f53069

Please sign in to comment.