Skip to content

Commit

Permalink
Update GCClassic benchmark statas output to spreadsheet format
Browse files Browse the repository at this point in the history
gcpy/benchmark/modules/benchmark_gcclassic_stats.py
- Add 2 blank columns after "Wall Time"
- Add 2 blank columns after "CH4"
- Remove "blank" after "Mean OH"

This now allows you to cut-n-paste the output into the Google sheet
and then pick Data -> Split cell into columns.

Signed-off-by: Bob Yantosca <[email protected]>
  • Loading branch information
yantosca committed Aug 27, 2024
1 parent ea826f3 commit a146193
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions gcpy/benchmark/modules/benchmark_gcclassic_stats.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@ def print_stats(stats):
stats (dict) : Dictionary with statistics to print
"""
# Time and memory
line = f"{stats['Wall Time']},{stats['Memory']},"
line = f"{stats['Wall Time']},,,{stats['Memory']},"

# OH metrics
line += f"{stats['Mean OH']},blank,{stats['CH3CCl3']},{stats['CH4']}"
line += f"{stats['Mean OH']},,{stats['CH3CCl3']},{stats['CH4']},,"

# Timers
timers = TIMERS
Expand Down Expand Up @@ -113,7 +113,7 @@ def scrape_stats(text):
stats["CH3CCl3"] = line.split(":")[1].strip()
if line_count == 18 and "Dev" in line:
stats["Mean OH"] = line.split(":")[1].strip()

# Skip commands
if "++ sed" in line:
line_count += 1
Expand Down

0 comments on commit a146193

Please sign in to comment.