MCPcopy Create free account
hub / github.com/CVCUDA/CV-CUDA / plot_gpu_metrics

Function plot_gpu_metrics

bench/python/benchmark.py:1223–1235  ·  view source on GitHub ↗

Plots GPU metrics as a matplotlib plot.

(gpu_metrics_info, output_dir)

Source from the content-addressed store, hash-verified

1221
1222
1223def plot_gpu_metrics(gpu_metrics_info, output_dir):
1224 """
1225 Plots GPU metrics as a matplotlib plot.
1226 """
1227 for metric_name in gpu_metrics_info:
1228 # Create pandas data frame.
1229 df = pd.DataFrame(gpu_metrics_info[metric_name])
1230 ax = df.plot(title=metric_name)
1231 ax.set_xlabel("Execution time")
1232 ax.set_ylabel(metric_name)
1233 fig = ax.get_figure()
1234 fig.savefig(os.path.join(output_dir, "plot.%s.jpg" % metric_name))
1235 plt.close(fig)
1236
1237
1238def main():

Callers 1

mainFunction · 0.85

Calls 1

joinMethod · 0.45

Tested by

no test coverage detected