From 0a334f2186d5033e3dd6889cb1b0cc2f0221e6c8 Mon Sep 17 00:00:00 2001 From: IlyasMoutawwakil Date: Thu, 3 Oct 2024 13:38:45 +0200 Subject: [PATCH] test --- optimum_benchmark/benchmark/report.py | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/optimum_benchmark/benchmark/report.py b/optimum_benchmark/benchmark/report.py index 6c9d7076..d712a551 100644 --- a/optimum_benchmark/benchmark/report.py +++ b/optimum_benchmark/benchmark/report.py @@ -50,13 +50,11 @@ def aggregate(measurements: List["Measurements"]) -> "Measurements": def to_plain_text(self) -> str: plain_text = "" - i = 0 for key in ["memory", "latency", "throughput", "energy", "efficiency"]: measurement = getattr(self, key) if measurement is not None: - i += 1 - plain_text += f"\t+ {i}. {key}:\n" + plain_text += f"\t+ {key}:\n" plain_text += measurement.to_plain_text() return plain_text @@ -68,13 +66,11 @@ def log(self): def to_markdown_text(self) -> str: markdown_text = "" - i = 0 for key in ["memory", "latency", "throughput", "energy", "efficiency"]: measurement = getattr(self, key) if measurement is not None: - i += 1 - markdown_text += f"{i}. {key}:\n\n" + markdown_text += f"## {key}:\n\n" markdown_text += measurement.to_markdown_text() return markdown_text