Skip to content

Commit

Permalink
Add preprocessor cpu cores benchmark and fix template usage
Browse files Browse the repository at this point in the history
  • Loading branch information
FrancoBar committed Jan 13, 2024
1 parent 2ad2d69 commit d9b295a
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
4 changes: 2 additions & 2 deletions analysis/graphics/benchmark-open3d-trimesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,11 +78,11 @@ def main():
trimesh_time.append(timeit.timeit(lambda : trimesh_benchmark(mesh), number=1))
open3d_time.append(timeit.timeit(lambda : open3d_benchmark(mesh), number=1))

templates.template_style()
fig, ax = plt.subplots()
ax.plot(element_amount, open3d_time, label="Open3d", marker="s")
ax.plot(element_amount, trimesh_time, label="Trimesh", marker="s")
templates.template_style()
templates.template_plot(ax, "Open3d vs Trimesh", "Number of Elements", "Execution Time (s)")
templates.template_plot(ax, "Number of Elements", "Execution Time (s)", "Open3d vs Trimesh")
templates.template_save_multiple_images([fig], "open3d_vs_trimesh", ["open3d_vs_trimesh"])

main()
14 changes: 14 additions & 0 deletions analysis/graphics/preprocessor_cpu_cores.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import matplotlib.pyplot as plt
import templates

CORES = [1,2,4,8,12]
TIMES = [132.091, 85.243, 68.884, 60.039, 57.369]
def main():

templates.template_style()
fig, ax = plt.subplots()
ax.plot(CORES, TIMES, label="PC1", marker="s")
templates.template_plot(ax, "Execution Time (s)", "Cores Amount", "Preprocessor Scaling CPU Cores")
templates.template_save_multiple_images([fig], "preprocessor_cpu_cores", ["preprocessor_cpu_cores"])

main()

0 comments on commit d9b295a

Please sign in to comment.