DOMjudge / domjudge

DOMjudge programming contest jury system
https://www.domjudge.org
GNU General Public License v2.0
739 stars 259 forks source link

Redesign to support other scoring methods #2525

Open eldering opened 6 months ago

eldering commented 6 months ago

In the past there have been various requests to support other scoring methods than pass/fail with penalty time, some have been listed in https://github.com/DOMjudge/domjudge/labels/scoring

Before we try to support any of these, we should consider what a common (internal) interface/data structures would look like to generically support these. This would include making a trade-off where the more weird scoring methods we'd support, the broader and less well-defined this interface would become. This ticket is to discuss that interface.

We should then also refactor our code so that all scoring related code is hidden behind implementations of this interface. Currently there is plenty of code scattered around the code base.

eldering commented 6 months ago

Some comments/questions for this:

  1. I think we should not allow a scoring method to take arbitrary data from the system to determine the score (like: the current CPU load on the server, to name something silly). So what should be the set of allowed input to a score for a single submission? For team team on a problem? For a team in the whole contest?
  2. Related, what is the data format for the score for a submission, problem, etc? A float, or can it be any more complex structure like, {"points": 123, "time": 6534.061, "penalty": 20, "foobar": [1, 2, 3]}?
meisterT commented 6 months ago

Some thoughts here: