Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
IlyasMoutawwakil committed Oct 3, 2024
1 parent e1b5c68 commit 0a334f2
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions optimum_benchmark/benchmark/report.py
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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
Expand Down

0 comments on commit 0a334f2

Please sign in to comment.