Lane-tiles r3 report -- confirmed r2 green, two-tile gate landed, step 3 deferred
Browse files at this commitff1bf260e94648e6ec79a3534942d399a5c83b05Parent: a5441e8- docs
- lane-tiles r3 report -- confirmed r2 green, two-tile gate landed, step 3 deferred
1 changed file +67 -0
- lanes/tiles-r3.report.md +67 -0
lanes/tiles-r3.report.mdadded+67 -0
| @@ -0,0 +1,67 @@ | |||
| 1 | +VERDICT: PARTIAL -- step 1 (confirm) and step 2 (prove) done and committed; step 3 | ||
| 2 | +(lift the refusal) not attempted, out of turn budget. | ||
| 3 | + | ||
| 4 | +## Step 1: confirmation run | ||
| 5 | +`cargo check -p ec-av1 --tests` clean. `EC_AV1_REQUIRE_AOMENC=1 cargo test -p ec-av1 | ||
| 6 | +--lib -j4`: 232 passed, 0 failed, 17 ignored, 207.55s -- matches the corrected charter | ||
| 7 | +note exactly. Nothing to commit (tree was already clean at d1c2071). | ||
| 8 | + | ||
| 9 | +## Step 2: prove the per-tile loop on a real two-tile-column stream | ||
| 10 | +Added `a_real_aomenc_stream_with_two_tile_columns_decodes_pixel_exact` to | ||
| 11 | +`crates/ec-av1/src/stream.rs` (committed 1648317). It: | ||
| 12 | +- builds a 128x64 aomenc key frame with `--tile-columns=1 --tile-rows=0 | ||
| 13 | + --sb-size=64 --loopfilter-control=0`, 20-seed sweep (structural tile split | ||
| 14 | + isn't content-dependent, but this decoder's pre-existing chroma | ||
| 15 | + smooth/paeth refusal is -- accepted as a named refusal like every sibling | ||
| 16 | + gate does for unrelated capabilities); | ||
| 17 | +- parses the stream itself (not `decode_stream`, whose `cols > 1 || rows > 1` | ||
| 18 | + refusal is exactly what this gate runs ahead of) to get the real `Vec<Tile>` | ||
| 19 | + `Av1Parser::parse_obu` already produces; | ||
| 20 | +- calls `decode_key_frame_tile_with_cdfs(&[tile0, tile1], &header.tile_info, | ||
| 21 | + ...)` directly; | ||
| 22 | +- hard-asserts `tile_hits()` delta `> 1` and pixel-exactness against ffmpeg. | ||
| 23 | + | ||
| 24 | +Result: 20/20 pixel-exact matches, 0 refusals, tile_hits > 1 every time. | ||
| 25 | +`cargo check -p ec-av1 --tests` clean after. | ||
| 26 | + | ||
| 27 | +Two things needed beyond the charter's one-liner: | ||
| 28 | +- `--sb-size=64`: this decoder hardcodes 64px superblocks everywhere | ||
| 29 | + (SB_MI=16); aomenc's own default is 128px SBs, which makes 128x64 exactly | ||
| 30 | + one superblock -- nothing for `--tile-columns=1` to split, `cols` came back | ||
| 31 | + 1 without this. | ||
| 32 | +- `--loopfilter-control=0`: deblocking crosses tile boundaries by spec | ||
| 33 | + default, and `PlaneBuf`'s `tile_x0`/`tile_y0` only ever clip a tile's own | ||
| 34 | + left/top reach (the exact known gap r2 flagged) -- a non-last column's | ||
| 35 | + right-edge deblock read into the next tile wrong without this. Sidestepped | ||
| 36 | + on purpose; not fixed, deblocking is not what this gate proves. | ||
| 37 | + | ||
| 38 | +Also caught and fixed a real bug in my own first draft while wiring the test: | ||
| 39 | +`Tile::offset` is relative to the buffer `parse_obu` was handed, not absolute | ||
| 40 | +in `stream` -- forgetting to add `obu_offset` back (the way `decode_stream` | ||
| 41 | +already does at its own tile-extraction site) fed the decoder garbage-offset | ||
| 42 | +bytes, which silently decoded as an all-skip flat DC block per tile (128/127 | ||
| 43 | +uniform) instead of erroring -- a quiet false negative, not a crash. Fixed | ||
| 44 | +before committing; the committed test carries a comment on this. | ||
| 45 | + | ||
| 46 | +## Step 3: not attempted | ||
| 47 | +Lifting the `cols > 1 || rows > 1` refusal in `decode_stream` needs more than | ||
| 48 | +deleting the `if`: the call site currently hardcodes `&[tile_bytes]` (single | ||
| 49 | +tile, `tiles.first()`), so it needs building the full `tile_bufs: Vec<&[u8]>` | ||
| 50 | +the same way this gate's test code now does (including the `obu_offset` fix), | ||
| 51 | +threaded through for BOTH `decode_key_frame_tile_with_cdfs` and | ||
| 52 | +`decode_inter_frame_tile_with_cdfs`. More importantly, real streams | ||
| 53 | +`decode_stream` sees do NOT get `--loopfilter-control=0` for free -- lifting | ||
| 54 | +the refusal for general (non-test-controlled) multi-tile streams would need | ||
| 55 | +either the right-edge reach gap actually fixed in `PlaneBuf`, or deblocking | ||
| 56 | +proven to not cross tile boundaries in the streams under test | ||
| 57 | +(`loop_filter_across_tiles_enabled` -- unread, not checked this round). | ||
| 58 | +Doing this without checking would very likely reintroduce the exact luma | ||
| 59 | +mismatch this round diagnosed (uncaught first-draft bug notwithstanding) for | ||
| 60 | +any real multi-tile stream with loop filtering on. Left for the next round; | ||
| 61 | +the intra-only case specifically (per charter step 3) still needs the deblock | ||
| 62 | +question answered first. | ||
| 63 | + | ||
| 64 | +## Refusal strings | ||
| 65 | +None added, renamed or removed this round -- the multi-tile refusal in | ||
| 66 | +`stream.rs` is untouched. (Step 3, when attempted, will need to report this | ||
| 67 | +line verbatim before deleting it, per the charter's merge note.) | ||