FA-99081 / Learning rate schedules / Open access
Cosine decay starts partway through its phase after warmup · case 01
Cosine decay starts partway through its phase after warmup.
ROOT CAUSE
The cosine phase uses the global step instead of elapsed post-warmup steps.
THE FAILURE
The cosine phase uses the global step instead of elapsed post-warmup steps.
Unsuccessful approach: Using the full horizon as the denominator leaves a positive rate at the requested end step.
Case contract
Linearly warm up through warmup; then cosine-decay to zero at total.
Why this case matters
A deterministic scalar schedule makes step-to-rate mapping explicit for a small training loop.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(step, base, warmup, total):
import math
return base*step/warmup if step<warmup else base*(1+math.cos(math.pi*step/total))/2
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('warmup middle',solve(2,12,4,8),6); check('warmup end',solve(4,12,4,8),12); check('decay midpoint',solve(6,12,4,8),6); check('end',solve(8,12,4,8),0); check('after',solve(9,12,4,8),0); check('start',solve(0,8,4,8),0)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| warmup middle | 6.0 | 6 | Passed |
| warmup end | 6.0 | 12 | Failed |
| decay midpoint | 1.7573593128807152 | 6 | Failed |
| end | 0.0 | 0 | Passed |
| after | 0.4567228049322789 | 0 | Failed |
| start | 0.0 | 0 | Passed |
SHA-256 / 0467a26b6cd05139ad8dde1b43e71889830618df8309c632ede5a6fa648044ac
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(step, base, warmup, total):
import math
return base*step/warmup if step<warmup else base*(1+math.cos(math.pi*(step-warmup)/total))/2 if step<=total else 0
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('warmup middle',solve(2,12,4,8),6); check('warmup end',solve(4,12,4,8),12); check('decay midpoint',solve(6,12,4,8),6); check('end',solve(8,12,4,8),0); check('after',solve(9,12,4,8),0); check('start',solve(0,8,4,8),0)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| warmup middle | 6.0 | 6 | Passed |
| warmup end | 12.0 | 12 | Passed |
| decay midpoint | 10.242640687119284 | 6 | Failed |
| end | 6.0 | 0 | Failed |
| after | 0 | 0 | Passed |
| start | 0.0 | 0 | Passed |
SHA-256 / 8c538316c78dc241978d4c65588b1593e2f5ad6397b816ed3d70ad64bde810fe
HELD IN THE MEMBER ARCHIVE
The verified repair and its recorded checks are member-only.
This mechanism has 6 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.
Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.
Member access is invitation-based. Sign in with your invited account to inspect the repair.
Sign in to the archive ↗Verification & scope
These are toy scalar contracts with integer steps and finite parameters; they do not model framework defaults or optimizer state. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.
Observations recorded using Python 3.12.14 at 2026-09-30T16:48:20.352005+00:00.
Case digest / d3a5dfbc8c81e6570cce14b694a44a24d693e52b1e1c59ce322dc0ad53909fad