forge
Explore
Log in

Don't you dare go Hollow

ec-av1: the seventh 4:2:2 corpus cell is pinned, and re-measured exact here

Browse files at this commit

d6ceb79ee48b7775c8b932e557ebd86c42fbff92Ahmet Kaan GümüşParent: abb01bd
the_pinned_422_corpus_cells_decode_pixel_exact carried six of the seven cells
lanes/av1422ffmpegbase.report.md 2.1 measured as diverging, and its doc said why
the seventh was missing: "THIS BRANCH MUST NOT LAND UNTIL THAT CELL CLOSES AND
THE CORPUS RE-MEASURES 51/51". s422_384x240 has since closed -- lane-av1422tailskip
measured it byte-exact on all 16 displayed and all 17 decode-order frames and
refuted the group-tail chroma SKIP arm the risk study's R4 blamed -- so the first
half of that condition is met and the row belongs in the gate.

Re-measured on THIS tree, not taken from the closure report, with
EC_AV1_REQUIRE_FFMPEG=1 and the crate's own comparator (ffmpeg, display order,
yuv422p): byte-exact on all 16 frames, per-plane coefficient-unit census
delta units [1992, 1254, 1256] and coded [955, 742, 854], so the compare is not
vacuous with respect to 4:2:2. The sibling gate on the same bytes
(the_pinned_422_palette_intra_in_inter_cell_window_is_byte_exact) also runs green
here: 17 decode-order frames byte-exact against aomdec, 16 chroma palette unit
windows.

The row pins 422_palette_intra_in_inter_384x240_17f.obu rather than committing a
second copy of the sweep's s422_384x240.obu: lane-av1422tailskip had already
committed those exact bytes under that name and the two files are byte for byte
identical (sha256 bf1c658e...a4b815b, 19344 B, fnv1a64 0x923ccabfcb933e90). One
stream, one pin.

Row non-vacuity: mutating that row's fnv1a64 by one turns the gate red on
"[422_palette_intra_in_inter_384x240_17f.obu]: bytes drifted", so the row is
read and compared. (Mutating the sha256 column stays green by design -- it is
the corpus's identity column for a re-capture, not an in-process assertion.)

The doc's "Why these six" paragraph is corrected rather than extended: the
seventh is NOT a round_ss cell. 384x240 is 8- AND 16-aligned; it was the
late-starting frame-1 alt-ref chroma residual, so it is described as its own
class rather than folded into the non-8-aligned-geometry sentence.

The gate's own landing condition had a second half -- "AND THE CORPUS RE-MEASURES
51/51" -- so it was run here rather than assumed: the census's ffmpeg-oracle driver
(~/.cache/census422b/ffcensus.py, display order, shown frames, geometry from ffprobe,
a count over zero frames is a hard error) against a dump_yuv built from THIS lane's
tree. 51 of 51 4:2:2 cells BYTE-EXACT, s422_384x240 among them at 0/0/0, and the
same run put all 44 4:2:0 / 4:4:4 controls at BYTE-EXACT (95/95 over the corpus).
Every remapped stream path's sha256 was checked against the census's recorded sha
before use; 0 unresolved. Limits: ffmpeg oracle, display order (the aomdec
decode-order census was not re-run), and the census's probe_split_control is
obsolete now that the lift has landed.
crates/ec-av1/src/stream.rsmodified+58 -14
@@ -3994,25 +3994,51 @@ pub(crate) mod tests {
39943994 /// earned, and the one that replaces seven gates whose only behavioural
39953995 /// assertion was `err.contains(REFUSAL)`.
39963996 ///
3997- /// **Why these six.** The measurement base
3997+ /// **Why these seven.** The measurement base
39983998 /// (`lanes/av1422ffmpegbase.report.md` section 2.1) recorded seven 4:2:2
39993999 /// cells that diverged from ffmpeg: `s422_320x246`, `s422_322x240`,
40004000 /// `s422_322x246`, `s422_352x242_10b`, `s422_384x240`,
4001- /// `s422_416x242_10b`, `s422_416x250_10b`. Six are closed and are pinned
4002- /// here, each byte-exact against ffmpeg with the per-plane
4003- /// coefficient-unit census as its non-vacuity arm. All six are
4001+ /// `s422_416x242_10b`, `s422_416x250_10b`. ALL SEVEN are closed and are
4002+ /// pinned here, each byte-exact against ffmpeg with the per-plane
4003+ /// coefficient-unit census as its non-vacuity arm. Six of them are
40044004 /// CHROMA-only divergences at non-8-aligned geometries -- odd or
40054005 /// 2-mod-4 luma dimensions, where `round_ss` and the chroma block walk
40064006 /// disagree with a hardcoded `>> 1` -- which is why they are the rows a
40074007 /// lift cannot afford to leave unasserted: they are the cells that would
40084008 /// go quietly wrong again.
40094009 ///
4010- /// **The seventh, `s422_384x240`, is NOT here, on purpose.** It is the
4011- /// reserved group-tail chroma SKIP arm (`decode.rs`; the risk study R4
4012- /// flags it as owned elsewhere), it is still red, and pinning a red cell
4013- /// inside a green gate is how a gate stops being a gate.
4014- /// **THIS BRANCH MUST NOT LAND UNTIL THAT CELL CLOSES AND THE CORPUS
4015- /// RE-MEASURES 51/51** -- see `lanes/av1422lift.report.md`.
4010+ /// **The seventh, `s422_384x240`, IS here now.** lane-av1422lift pinned six
4011+ /// of the seven and deliberately left this one out: it was still red, and
4012+ /// pinning a red cell inside a green gate is how a gate stops being a gate
4013+ /// ("THIS BRANCH MUST NOT LAND UNTIL THAT CELL CLOSES AND THE CORPUS
4014+ /// RE-MEASURES 51/51", `lanes/av1422lift.report.md` §7). The cell closed in
4015+ /// lane-av1422tailskip, and NOT through the reserved group-tail chroma SKIP
4016+ /// arm the risk study's R4 blamed: that lane measured it byte-exact against
4017+ /// ffmpeg on all 16 displayed frames and all 17 decode-order frames, 0/0/0
4018+ /// wrong samples in Y/U/V, with the fix's own counter
4019+ /// (`palette_422_unit_window_hits`) non-zero on this stream.
4020+ /// `lanes/av1422tailskip.report.md` §1 records the measurement and the
4021+ /// refutation of the arm attribution.
4022+ ///
4023+ /// That lane had already committed these exact bytes under the name
4024+ /// `422_palette_intra_in_inter_384x240_17f.obu` (sha256 `bf1c658e...a815b`,
4025+ /// the sweep artifact byte for byte), so the row below pins THAT file
4026+ /// rather than committing a second copy of one stream under a second name.
4027+ /// Unlike the other six, this cell sits at an 8- AND 16-aligned geometry
4028+ /// (384x240): it was the late-starting frame-1 alt-ref chroma residual
4029+ /// (`lanes/av1422late.report.md`), not the `round_ss` class -- which is why
4030+ /// it is pinned as its own row here rather than folded into that sentence.
4031+ ///
4032+ /// **The corpus re-measures 51/51**, which was the second half of the
4033+ /// condition the paragraph above quotes. Re-run for this row with the
4034+ /// ffmpeg-oracle census driver (`~/.cache/census422b/ffcensus.py`: display
4035+ /// order, shown frames, geometry from `ffprobe`, a count over zero frames
4036+ /// is a hard error) and a `dump_yuv` built from THIS lane's tree:
4037+ /// **51 of 51 4:2:2 cells BYTE-EXACT** -- `s422_384x240` among them at
4038+ /// 0/0/0 -- and, in the same run, all 44 4:2:0 / 4:4:4 controls BYTE-EXACT
4039+ /// (95/95 over the whole corpus). That run is a measurement of this tree,
4040+ /// not a re-reading of the closure report; the per-cell rows here are what
4041+ /// keep the seven named ones from drifting back.
40164042 ///
40174043 /// **The census arm, per row.** `assert_422_stream_pixel_exact` asserts
40184044 /// that all three planes read a non-zero number of coefficient units AND
@@ -4023,14 +4049,18 @@ pub(crate) mod tests {
40234049 /// the same decode walked 4994 units, so a green here with no census
40244050 /// assert would have proven nothing about 4:2:2.
40254051 ///
4026- /// **Provenance of the six pins.** All six are `aomenc --codec=av1
4052+ /// **Provenance of the seven pins.** All seven are `aomenc --codec=av1
40274053 /// --profile=2 --input-bit-depth=<8|10> --cpu-used=0 --cq-level=24
40284054 /// --limit=16 --auto-alt-ref=1 --enable-global-motion=1 --passes=1
40294055 /// --obu` over a hand-built `C422` y4m (header line, then `FRAME\n` plus
40304056 /// one frame of planes per frame -- libaom's y4minput requires those six
4031- /// bytes before EVERY frame), produced by the census sweep and copied in
4032- /// from `~/.cache/census422b/sweep/`. They are ordinary libaom 4:2:2
4033- /// streams with nothing bolted on.
4057+ /// bytes before EVERY frame), produced by the census sweep. The first six
4058+ /// were copied in from `~/.cache/census422b/sweep/`; the seventh is the
4059+ /// same sweep's `s422_384x240.obu`, which lane-av1422tailskip had already
4060+ /// committed under the name in its own row (the two files are byte for
4061+ /// byte identical -- sha256 `bf1c658e9bfdc13ec1ed51e59049d2b81201941b6ef45\
4062+ /// 71f8382f356ea4b815b`), so it is pinned under that name here. They are
4063+ /// ordinary libaom 4:2:2 streams with nothing bolted on.
40344064 #[test]
40354065 fn the_pinned_422_corpus_cells_decode_pixel_exact() {
40364066 const NAME: &str = "the_pinned_422_corpus_cells_decode_pixel_exact";
@@ -4100,6 +4130,20 @@ pub(crate) mod tests {
41004130 10,
41014131 16,
41024132 ),
4133+ (
4134+ // Census cell `s422_384x240` -- the seventh previously
4135+ // diverging cell, closed by lane-av1422tailskip. Same bytes as
4136+ // the sweep's `s422_384x240.obu`, already in this fixtures dir
4137+ // under the name lane-av1422tailskip's own gate pins.
4138+ "422_palette_intra_in_inter_384x240_17f.obu",
4139+ 19344usize,
4140+ 0x923ccabfcb933e90u64,
4141+ "bf1c658e9bfdc13ec1ed51e59049d2b81201941b6ef4571f8382f356ea4b815b",
4142+ 384usize,
4143+ 240usize,
4144+ 8u8,
4145+ 16usize,
4146+ ),
41034147 ] {
41044148 let row = format!("{NAME}[{file}]");
41054149 let path = crate_pin(file);