You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the new time limit is announced to the user a few lines below, this is (implicitly) rounded downwards because the string expression'%d' % 2.4' apparently gives '2' (while '{:d}.format(2.4)' would have crashed).
Should just be timelim_margin = int(timelim * safety_margin) or maybe timelim_margin = round(timelim * safety_margin) or timelim_margin = int(.5 + timelim * safety_margin).
I’ll fix this (as part of a larger cleanup).
The text was updated successfully, but these errors were encountered:
Slowest AC runtime: 0.492, setting timelim to 1 secs, safety margin to 2 secs
...
WARNING in submissions: TLE submission mees-exclude-random-quadrangles.py (Python 3 w/Pypy) sensitive to time limit: limit of 1 secs -> TLE, limit of 2 secs -> AC
TLE submission mees-exclude-random-quadrangles.py (Python 3 w/Pypy) OK: TLE [test case: test case secret/wide, CPU: 2.43s @ test case secret/random-max-7]
The safety margin is reported to be 2s, but a TLE submission with runtime of 2.43s still give a warning.
By the way, no fix from my side is imminent, and the “larger cleanup” has stalled. I am still stumped by various definitions of “what a grade/judgement/verdict/score is” and can’t become constructive.
timelim_margin
may be a float (becausesafety_margin
can be set to, say,1.2
inproblem.yaml
), it is not rounded toint
in this case:problemtools/problemtools/verifyproblem.py
Line 1380 in 063b68a
When the new time limit is announced to the user a few lines below, this is (implicitly) rounded downwards because the string expression
'%d' % 2.4' apparently gives '2' (while
'{:d}.format(2.4)' would have crashed).Should just be
timelim_margin = int(timelim * safety_margin)
or maybetimelim_margin = round(timelim * safety_margin)
ortimelim_margin = int(.5 + timelim * safety_margin)
.I’ll fix this (as part of a larger cleanup).
The text was updated successfully, but these errors were encountered: