Skip to content

Commit

Permalink
Scoring script: Adjust power score calculation to ensure only w/q val…
Browse files Browse the repository at this point in the history
…ues are kept
  • Loading branch information
szarnyasg committed Nov 3, 2022
1 parent 586a31c commit 9586154
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion scoring/calculate-scores.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,10 +119,13 @@
for f in glob.glob(f'./*-{tool}-sf{sf_string}.tex'):
os.remove(f)

# calculate the geometric mean of runtimes for the power score
# only include writes (w) and queries (q1, q2a, ...)
con.execute("""
CREATE OR REPLACE TABLE power_score AS
SELECT 3600 / ( exp(sum(ln(total_time::real)) * (1.0/count(total_time))) ) AS power
FROM power_test_stats;
FROM power_test_stats
WHERE q IN ('writes', '1', '2a', '2b', '3', '4', '5', '6', '7', '8a', '8b', '9', '10a', '10b', '11', '12', '13', '14a', '14b', '15a', '15b', '16a', '16b', '17', '18', '19a', '19b', '20a', '20b');
""")
con.execute("""SELECT power FROM power_score""")
p = con.fetchone()[0]
Expand Down

0 comments on commit 9586154

Please sign in to comment.