diff --git a/hpvm/projects/hpvm-profiler/hpvm_profiler/__init__.py b/hpvm/projects/hpvm-profiler/hpvm_profiler/__init__.py index b421071aaf2ab95ea5a2680e5bb9dfd8cb5759c7..790540aa671555a0ad89ba5876743c20e9324324 100644 --- a/hpvm/projects/hpvm-profiler/hpvm_profiler/__init__.py +++ b/hpvm/projects/hpvm-profiler/hpvm_profiler/__init__.py @@ -125,8 +125,8 @@ def plot_hpvm_configs( qoses, speedups = qos_speedup.T fig, ax = plt.subplots(**fig_kwargs) ax.scatter(qoses, speedups) - ax.xlabel("QoS Loss") - ax.ylabel("Speedup (X)") + ax.set_xlabel("QoS Loss") + ax.set_ylabel("Speedup (X)") if save_to: fig.savefig(save_to, dpi=300) return fig diff --git a/hpvm/test/dnn_benchmarks/pytorch/test_profiling/test_profiling.py b/hpvm/test/dnn_benchmarks/pytorch/test_profiling/test_profiling.py index 66aa33d7cbb142cd473fbbaa51c4ab2a8b6eeff1..72ad213b1c1a5f69e17e7295489975c9b1f64375 100755 --- a/hpvm/test/dnn_benchmarks/pytorch/test_profiling/test_profiling.py +++ b/hpvm/test/dnn_benchmarks/pytorch/test_profiling/test_profiling.py @@ -4,7 +4,7 @@ import site from pathlib import Path from sys import argv -from hpvm_profiler import profile_configs, read_hpvm_configs, write_hpvm_configs +from hpvm_profiler import profile_configs, read_hpvm_configs, write_hpvm_configs, plot_hpvm_configs self_folder = Path(__file__).parent.absolute() site.addsitedir(self_folder.parent) @@ -20,3 +20,4 @@ out_config_file = f"./{netname}.txt" header, configs = read_hpvm_configs(config_file) profile_configs(binary_file, configs[1:6], configs[0], progress_bar=False) write_hpvm_configs(header, configs[:6], out_config_file) +plot_hpvm_configs(out_config_file, f"{netname}.png")