From 3558ef0ef872ee49f946f1ed32f63d8d29d58a68 Mon Sep 17 00:00:00 2001 From: Jack Rosenthal Date: Tue, 13 Feb 2024 20:01:48 -0700 Subject: [PATCH] Adjust grading scales --- algobowl/controllers/competition.py | 8 +++++--- algobowl/templates/edu_landing.xhtml | 8 ++++---- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/algobowl/controllers/competition.py b/algobowl/controllers/competition.py index 6c63e80..4b433f0 100644 --- a/algobowl/controllers/competition.py +++ b/algobowl/controllers/competition.py @@ -112,6 +112,8 @@ def compute_rankings_grade(gt, fleet_num, fleet): last_adj_score = other_gt.rankings.adj_score if other_gt is gt: break + if len(fleet) == 1: + return 5 + fleet_num * 5 return (place_in_fleet / (len(fleet) - 1)) * 5 + fleet_num * 5 @@ -376,15 +378,15 @@ def new_gt(rankings_entry): gt, gt.fleet, fleets[gt.fleet] ) gt.contributions.verification = ( - (gt.verification.correct / sum(gt.verification) * 5) + (gt.verification.correct / sum(gt.verification) * 20) if any(gt.verification) else 0 ) gt.contributions.participation = ( - (compinfo.inputs - gt.rankings.reject_count) / compinfo.inputs * 70 + (compinfo.inputs - gt.rankings.reject_count) / compinfo.inputs * 50 ) gt.contributions.input_difficulty = ( - (7 + len(gt.input.scores_s) / compinfo.best_input_difference * 3) + (5 + len(gt.input.scores_s) / compinfo.best_input_difference * 10) if gt.input.scores_l else 0 ) diff --git a/algobowl/templates/edu_landing.xhtml b/algobowl/templates/edu_landing.xhtml index 6697eb5..7536e5d 100644 --- a/algobowl/templates/edu_landing.xhtml +++ b/algobowl/templates/edu_landing.xhtml @@ -123,19 +123,19 @@ Input Uploaded - 7% + 5% Input Difficulty - 3% + 10% Valid Outputs - 70% + 50% Verification Accuracy - 5% + 20% Rankings