diff --git a/benchmarks/scripts/analyze.py b/benchmarks/scripts/analyze.py index 2690083df..d303907be 100755 --- a/benchmarks/scripts/analyze.py +++ b/benchmarks/scripts/analyze.py @@ -256,6 +256,7 @@ def extract_horizontal_space(df): vertical_val = row[vertical_axis_name] vertical_id = vertical_axis_ids[vertical_val] vertical_name = "{}={}".format(vertical_axis_name, vertical_val) + horizontal_id = 0 if len(horizontal_axes) > 0: horizontal_point = [] @@ -264,18 +265,24 @@ def extract_horizontal_space(df): horizontal_name = " / ".join(horizontal_point) horizontal_id = horizontal_axis_ids[horizontal_name] ax=axes[vertical_id, horizontal_id] - if vertical_id == (num_rows - 1): - ax.set_xlabel(horizontal_name) - if horizontal_id == 0: - ax.set_ylabel(vertical_name) else: ax=axes[vertical_id] ax.set_ylabel(vertical_name) sns.histplot(data, ax=ax, kde=True) + if len(horizontal_axes) > 0: + ax=axes[vertical_id, horizontal_id] + if vertical_id == (num_rows - 1): + ax.set_xlabel(horizontal_name) + if horizontal_id == 0: + ax.set_ylabel(vertical_name) + else: + ax.set_ylabel('') + for ax in axes.flat: ax.set_xticklabels([]) + ax.set_yticklabels([]) fig.suptitle(title) plt.tight_layout()