FA-10731 / Raster memory layout / Open access
Row stride addressing · case 01
Packed-row addressing reads alignment padding as pixels in subsequent rows.
ROOT CAUSE
Packed-row addressing reads alignment padding as pixels in subsequent rows.
VERIFIED REPAIR
Use the stage contract: Extract height rows of width scalar pixels from a sufficiently large flat buffer with stride>=width; padding is not image data.
Unsuccessful approach: Using stride for row length includes padding in each returned image row.
Case contract
Extract height rows of width scalar pixels from a sufficiently large flat buffer with stride>=width; padding is not image data.
Why this case matters
A deterministic software graphics stage with explicit channel and coordinate conventions; no hardware, device profile or API behavior is inferred.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(pixels, width, height, stride):
return [pixels[y*width:y*width+width] for y in range(height)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve(*([1, 2, 99, 3, 4, 99], 2, 2, 3)), [[1, 2], [3, 4]])
check('fixture 2', solve(*([1, 2], 2, 1, 2)), [[1, 2]])
check('fixture 3', solve(*([], 0, 0, 0)), [])
check('fixture 4', solve(*([1, 99, 2, 99], 1, 2, 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, 2], [99, 3]] | [[1, 2], [3, 4]] | Failed |
| fixture 2 | [[1, 2]] | [[1, 2]] | Passed |
| fixture 3 | [] | [] | Passed |
| fixture 4 | [[1], [99]] | [[1], [2]] | Failed |
SHA-256 / fb855b8414f1ce7d885c88b757571cb2302d302c77235391d533efe380fc34a5
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(pixels, width, height, stride):
return [pixels[y*stride:y*stride+stride] for y in range(height)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve(*([1, 2, 99, 3, 4, 99], 2, 2, 3)), [[1, 2], [3, 4]])
check('fixture 2', solve(*([1, 2], 2, 1, 2)), [[1, 2]])
check('fixture 3', solve(*([], 0, 0, 0)), [])
check('fixture 4', solve(*([1, 99, 2, 99], 1, 2, 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, 2, 99], [3, 4, 99]] | [[1, 2], [3, 4]] | Failed |
| fixture 2 | [[1, 2]] | [[1, 2]] | Passed |
| fixture 3 | [] | [] | Passed |
| fixture 4 | [[1, 99], [2, 99]] | [[1], [2]] | Failed |
SHA-256 / 247775a20b36eb47d3f8b3697369c4ac373c75421a66195bdfc75f766addbd43
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(pixels, width, height, stride):
return [pixels[y*stride:y*stride+width] for y in range(height)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve(*([1, 2, 99, 3, 4, 99], 2, 2, 3)), [[1, 2], [3, 4]])
check('fixture 2', solve(*([1, 2], 2, 1, 2)), [[1, 2]])
check('fixture 3', solve(*([], 0, 0, 0)), [])
check('fixture 4', solve(*([1, 99, 2, 99], 1, 2, 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, 2], [3, 4]] | [[1, 2], [3, 4]] | Passed |
| fixture 2 | [[1, 2]] | [[1, 2]] | Passed |
| fixture 3 | [] | [] | Passed |
| fixture 4 | [[1], [2]] | [[1], [2]] | Passed |
SHA-256 / ad8cc5a16b402d3f8039e58f350a9864279429124c3b7676974f08e4cd420032
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:41.714072+00:00.
Case digest / d0f54cabebd57895d64cfb55ffc74cb1f922cc97426bc9c6717819b7a1b6c6c1