FA-10911 / Audio channel mixing / Open access
Crossfade complementary gains · case 01
Applying the same fade gain to both sources changes total gain and source weighting.
ROOT CAUSE
Applying the same fade gain to both sources changes total gain and source weighting.
VERIFIED REPAIR
Apply the explicit PCM/playback contract: Crossfade equal-length sources at fixed normalized amount with complementary linear gains, without saturation.
Unsuccessful approach: Fading in only the second source leaves the first source audible at the endpoint.
Case contract
Crossfade equal-length sources at fixed normalized amount with complementary linear gains, without saturation.
Why this case matters
A pure Python local audio pipeline stage with explicit sample formats and frame conventions; no real-time device or signal-spectrum claims.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(a, b, amount):
return [x*amount+y*amount for x,y in zip(a,b)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1',solve(*([1, 0], [0, 1], 0.25)),[0.75, 0.25])
check('fixture 2',solve(*([1], [1], 0.5)),[1])
check('fixture 3',solve(*([1], [2], 0)),[1])
check('fixture 4',solve(*([1], [2], 1)),[2])
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 |
|---|---|---|---|
| fixture 1 | [0.25, 0.25] | [0.75, 0.25] | Failed |
| fixture 2 | [1.0] | [1] | Passed |
| fixture 3 | [0] | [1] | Failed |
| fixture 4 | [3] | [2] | Failed |
SHA-256 / bb9f1b6c43eb5bb1a99717e20bbb812cf5868d8005997cca9161adb424d9d379
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(a, b, amount):
return [x+y*amount for x,y in zip(a,b)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1',solve(*([1, 0], [0, 1], 0.25)),[0.75, 0.25])
check('fixture 2',solve(*([1], [1], 0.5)),[1])
check('fixture 3',solve(*([1], [2], 0)),[1])
check('fixture 4',solve(*([1], [2], 1)),[2])
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 |
|---|---|---|---|
| fixture 1 | [1.0, 0.25] | [0.75, 0.25] | Failed |
| fixture 2 | [1.5] | [1] | Failed |
| fixture 3 | [1] | [1] | Passed |
| fixture 4 | [3] | [2] | Failed |
SHA-256 / 9539a0f368552a184a849bb7e8430723184db7b62233ed447f66a8eb0b1ca27a
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(a, b, amount):
return [x*(1-amount)+y*amount for x,y in zip(a,b)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1',solve(*([1, 0], [0, 1], 0.25)),[0.75, 0.25])
check('fixture 2',solve(*([1], [1], 0.5)),[1])
check('fixture 3',solve(*([1], [2], 0)),[1])
check('fixture 4',solve(*([1], [2], 1)),[2])
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 |
|---|---|---|---|
| fixture 1 | [0.75, 0.25] | [0.75, 0.25] | Passed |
| fixture 2 | [1.0] | [1] | Passed |
| fixture 3 | [1] | [1] | Passed |
| fixture 4 | [2] | [2] | Passed |
SHA-256 / 68f1fc29f920a7a13da721895405cf792db108901e2a307b733b5caf152b727b
Verification & scope
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-29T14:38:43.228641+00:00.
Case digest / 9100fff20e8225ab4654b126dfc030b82dab7665147cbe0a6b061ff27ff6ca55