forge
Explore
Log in

Don't you dare go Hollow

Lane-hbd r3 charter -- 10-bit gate, lift the refusal, then probe his own films

Browse files at this commit

a5e1e2c1cb2a98f4b8c4459afc24142f06b28b30Ahmet Kaan GümüşParent: e673d71
  • docs
    • lane-hbd r3 charter -- 10-bit gate, lift the refusal, then probe his own films
Show full message
docs(av1): lane-hbd r3 charter -- 10-bit gate, lift the refusal, then probe his own films
lanes/hbd-r3.charter.mdadded+49 -0
@@ -0,0 +1,49 @@
1+# lane-hbd r3 — the payoff: decode a 10-bit stream
2+
3+At main (8440024). The widen is MERGED: the decoder's sample type is `u16`
4+everywhere, clamp bounds come from `bit_depth`, 8-bit output is bit-exact at
5+264/0, and the encoder keeps `u8` with a local box at its four call sites.
6+
7+Everything now stands behind one refusal: `"a stream whose bit depth is not 8
8+(this decoder reconstructs into 8-bit planes)"` in `stream.rs`. The sentence is
9+already false about the planes. Lift it — properly.
10+
11+## Order
12+1. **A 10-bit reference path.** `ffmpeg_decode_sequence` (`stream.rs`) hardcodes
13+ `-pix_fmt yuv420p`, one byte per sample. Add a second helper emitting
14+ `yuv420p10le` and parsing u16 little-endian, and make the comparison
15+ bit-depth aware. Keep the 8-bit helper exactly as it is — every existing gate
16+ depends on it.
17+2. **A gate on a real 10-bit aomenc stream.** `aomenc` needs
18+ `--bit-depth=10 --profile=0` and a 10-bit input (`ffmpeg ... -pix_fmt
19+ yuv420p10le`); confirm from the sequence header that `bit_depth` really is 10
20+ before trusting any pixel match. Hard-assert it.
21+3. **Lift the refusal** and update `refusal_inventory.rs` in the SAME commit —
22+ only once that gate is pixel-exact.
23+4. **Then the real target: his own files.** Both AV1 films on this box are
24+ `yuv420p10le`:
25+ `~/Downloads/reelb.mkv` and
26+ `~/Videos/Films/reelc.mkv`. Extract a few seconds
27+ (`ffmpeg -i <file> -t 3 -c:v copy -f obu <out.obu>`, note `-f obu`) and run
28+ `cargo run -p ec-av1 --example decode_probe -- <out.obu>`. Whatever refusal
29+ comes back next IS the next lane's charter — record it verbatim, with the
30+ film and the header state. Do not open his media in a GUI app; ffmpeg and
31+ decode_probe only, and write extracted streams into this worktree's
32+ `fixtures/`, never beside his files.
33+
34+Expect 10-bit to expose rounding that 8-bit hid: the inverse transform's
35+intermediate clamps already take `bit_depth` (`row_clamp = bit_depth + 8`,
36+`col_clamp = max(bit_depth + 6, 16)`), but every place that still assumes a
37+255 ceiling or an 8-bit rounding constant will show up as a small pixel delta,
38+not a crash. Bisect any mismatch against the oracle rather than by inspection.
39+
40+## Budget discipline
41+75 turns, no reset on resume. At about turn 55, stop starting new work: commit
42+what is green and write your report.
43+
44+Hard rules: `CARGO_TARGET_DIR=$HOME/.cache/cargo-target-hbd`; foreground
45+`nice -n 19 cargo ... -j4`; every `cargo test` a timeout >= 600000 ms; ffmpeg
46+generates bounded with `-t`; `EC_AV1_REQUIRE_AOMENC=1`; aomenc
47+`--threads=1 --row-mt=0 --sb-size=64`. Sibling worktrees have live agents —
48+never build in or edit them. Never push, never merge into main; I handle merges.
49+End with `lanes/hbd-r3.report.md`, VERDICT on line 1.