{"abstract":"Cosine decay starts partway through its phase after warmup.","category":"Learning rate schedules","checks":6,"contract":"Linearly warm up through warmup; then cosine-decay to zero at total.","contract_signature":"step, base, warmup, total","evaluation_group":"lr-schedule-warmup-then-cosine","failed_approach":"Using the full horizon as the denominator leaves a positive rate at the requested end step.","family":"w3-learning-rate-schedules-warmup-then-cosine","id":"FA-99081","implementations":{"attempt":{"sha256":"8c538316c78dc241978d4c65588b1593e2f5ad6397b816ed3d70ad64bde810fe","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(step, base, warmup, total):\n    import math\n    return base*step/warmup if step<warmup else base*(1+math.cos(math.pi*(step-warmup)/total))/2 if step<=total else 0\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('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)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"broken":{"sha256":"0467a26b6cd05139ad8dde1b43e71889830618df8309c632ede5a6fa648044ac","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(step, base, warmup, total):\n    import math\n    return base*step/warmup if step<warmup else base*(1+math.cos(math.pi*step/total))/2\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('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)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"}},"limitations":"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.","method":"Deterministic executable model with adversarial boundary fixtures.","provenance":{"created_by":"Failure Map","dependencies":"Python standard library","family":"w3-learning-rate-schedules-warmup-then-cosine","generated_at":"2026-09-30T16:48:20.352005+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"A deterministic scalar schedule makes step-to-rate mapping explicit for a small training loop.","root_cause":"The cosine phase uses the global step instead of elapsed post-warmup steps.","sha256":"d3a5dfbc8c81e6570cce14b694a44a24d693e52b1e1c59ce322dc0ad53909fad","title":"Cosine decay starts partway through its phase after warmup · case 01","variant":1,"variant_policy":"The same explicitly authored fixtures repeat across all five numbered records; runtime N is unused. These records share one mechanism and must remain together in evaluation splits.","verified":true,"visibility":"public","verification":{"attempt":{"elapsed_ms":27.826,"exit_code":1,"observations":[{"actual":6.0,"check":"warmup middle","expected":6,"passed":true},{"actual":12.0,"check":"warmup end","expected":12,"passed":true},{"actual":10.242640687119284,"check":"decay midpoint","expected":6,"passed":false},{"actual":6.0,"check":"end","expected":0,"passed":false},{"actual":0,"check":"after","expected":0,"passed":true},{"actual":0.0,"check":"start","expected":0,"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"warmup middle\", \"actual\": 6.0, \"expected\": 6, \"passed\": true}, {\"check\": \"warmup end\", \"actual\": 12.0, \"expected\": 12, \"passed\": true}, {\"check\": \"decay midpoint\", \"actual\": 10.242640687119284, \"expected\": 6, \"passed\": false}, {\"check\": \"end\", \"actual\": 6.0, \"expected\": 0, \"passed\": false}, {\"check\": \"after\", \"actual\": 0, \"expected\": 0, \"passed\": true}, {\"check\": \"start\", \"actual\": 0.0, \"expected\": 0, \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":28.161,"exit_code":1,"observations":[{"actual":6.0,"check":"warmup middle","expected":6,"passed":true},{"actual":6.0,"check":"warmup end","expected":12,"passed":false},{"actual":1.7573593128807152,"check":"decay midpoint","expected":6,"passed":false},{"actual":0.0,"check":"end","expected":0,"passed":true},{"actual":0.4567228049322789,"check":"after","expected":0,"passed":false},{"actual":0.0,"check":"start","expected":0,"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"warmup middle\", \"actual\": 6.0, \"expected\": 6, \"passed\": true}, {\"check\": \"warmup end\", \"actual\": 6.0, \"expected\": 12, \"passed\": false}, {\"check\": \"decay midpoint\", \"actual\": 1.7573593128807152, \"expected\": 6, \"passed\": false}, {\"check\": \"end\", \"actual\": 0.0, \"expected\": 0, \"passed\": true}, {\"check\": \"after\", \"actual\": 0.4567228049322789, \"expected\": 0, \"passed\": false}, {\"check\": \"start\", \"actual\": 0.0, \"expected\": 0, \"passed\": true}], \"passed\": false}\n"}},"member_only":{"stages":["fixed"],"fields":["implementations.fixed","verification.fixed","harness","repair"],"note":"The verified repair, its recorded checks, the repair description, and the scoring harness are available to members."}}