Skip to content

Commit

Permalink
Got all inference times and plotted
Browse files Browse the repository at this point in the history
  • Loading branch information
antoninoLorenzo committed Jul 5, 2024
1 parent 111daad commit 74f7114
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Binary file added static/images/inference_times_plot_RTX.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 7 additions & 3 deletions static/inference_times_plots.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@
if __name__ == "__main__":
CASES = ['conversion', 'inference'] # inference == planning
GPUS = ['GTX-1660-Ti', 'RTX-3080']
# GPUS = ['RTX-3080']

fig, axes = plt.subplots(nrows=2, ncols=2, figsize=(16, 16))
fig, axes = plt.subplots(nrows=len(CASES), ncols=len(GPUS), figsize=(16, 16))
fig.suptitle('Inference Times')
sns.set(style="whitegrid")

Expand Down Expand Up @@ -38,7 +39,10 @@
for i, case in enumerate(CASES):
for j, gpu in enumerate(GPUS):
df = times[f'{case}_{gpu}']
ax = axes[i, j]
if len(GPUS) > 1:
ax = axes[i, j]
else:
ax = axes[i]
sns.barplot(x='model', y='time', data=df, ax=ax)

ax.set_title(f'{case[:1].upper()}{case[1:]} Times ({gpu})')
Expand All @@ -48,7 +52,7 @@
ax.tick_params(axis='x', rotation=45)

plt.savefig(
'./images/inference_times_plot.png',
'./images/inference_times_plot_RTX.png',
dpi=300,
bbox_inches='tight'
)
Expand Down

0 comments on commit 74f7114

Please sign in to comment.