From 3f7e8a9a91ab07d1d29945f9c105debc6ecda011 Mon Sep 17 00:00:00 2001 From: drisspg Date: Wed, 9 Oct 2024 21:31:36 -0700 Subject: [PATCH] better file name --- benchmarks/fp8_matmul.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/benchmarks/fp8_matmul.py b/benchmarks/fp8_matmul.py index 059874d..0217fdf 100644 --- a/benchmarks/fp8_matmul.py +++ b/benchmarks/fp8_matmul.py @@ -19,6 +19,7 @@ matmul_tma_persistent, matmul_device_tma_persistent, ) +from datetime import datetime from enum import Enum import csv @@ -242,7 +243,8 @@ def plot_tflops_comparison(df, save_path: Path): plt.tight_layout() # Generate the file name and save in the same directory as the CSV file - file_name = f"fp8_kernel_comparison_{m_value}_{n_value}.png" + timestamp = datetime.now().strftime("%Y%m%d_%H%M%S") + file_name = f"fp8_kernel_comparison_{m_value}_{n_value}_{timestamp}.png" graph_path = save_path.parent / file_name plt.savefig(graph_path, dpi=300) print(f"TFLOPS comparison plot saved as {graph_path}")