edith_codecs
Clone
https://git.tahinli.com/Tahinli/edith_codecs.git
0 watching0 forksRust370.3 MiB9b67700Tahinli3 days ago4021 commits
| 1 | use *; |
| 2 | use *; |
| 3 | use *; |
| 4 | use crate; |
| 5 | use craterun_with_stdin; |
| 6 | use ; |
| 7 | |
| 8 | /// lane-av1oracledepth: the depth-generic 4:4:4 oracle comparator, armed |
| 9 | /// on the same pinned 10-bit 4:4:4 cell |
| 10 | /// `a_444_lossy_palette_chroma_unit_window_is_byte_exact_at_352x242_10bit` |
| 11 | /// gates (fixture sha256 |
| 12 | /// `84df2f37cc7982f9a572443d85dfcc13bf366a64f3fb567391dcd5acd58a0ad2`): |
| 13 | /// every plane of every SHOWN frame must come back byte-exact against |
| 14 | /// ffmpeg's `yuv444p10le` rawvideo of the same bytes, with the depth read |
| 15 | /// from the stream's own sequence header, never assumed. |
| 16 | /// |
| 17 | /// The flip control is the crate's own comparator-liveness shape (the |
| 18 | /// same one |
| 19 | /// [`every_ffmpeg_comparator_reds_on_a_one_sample_wrong_ffmpeg`] runs for |
| 20 | /// the other helpers): with a thread-local ffmpeg shim that rotates ONE |
| 21 | /// byte of the oracle's own rawvideo stdout, the compare must move from |
| 22 | /// 0 to EXACTLY 1 differing sample in the tampered plane and stay at 0 in |
| 23 | /// the other two -- a comparator that cannot see a one-sample difference |
| 24 | /// would make every "byte-exact" claim above vacuous. |
| 25 | |
| 26 | |
| 27 | |
| 28 | |
| 29 | |
| 30 | |
| 31 | |
| 32 | |
| 33 | |
| 34 | |
| 35 | |
| 36 | |
| 37 | |
| 38 | |
| 39 | |
| 40 | |
| 41 | |
| 42 | |
| 43 | |
| 44 | |
| 45 | |
| 46 | |
| 47 | |
| 48 | |
| 49 | |
| 50 | |
| 51 | |
| 52 | |
| 53 | |
| 54 | |
| 55 | |
| 56 | |
| 57 | |
| 58 | |
| 59 | |
| 60 | |
| 61 | |
| 62 | |
| 63 | |
| 64 | |
| 65 | |
| 66 | |
| 67 | |
| 68 | |
| 69 | |
| 70 | |
| 71 | |
| 72 | |
| 73 | |
| 74 | |
| 75 | |
| 76 | |
| 77 | |
| 78 | |
| 79 | |
| 80 | |
| 81 | |
| 82 | |
| 83 | |
| 84 | |
| 85 | |
| 86 | |
| 87 | |
| 88 | |
| 89 | |
| 90 | |
| 91 | |
| 92 | |
| 93 | |
| 94 | |
| 95 | |
| 96 | |
| 97 | |
| 98 | |
| 99 | |
| 100 | |
| 101 | |
| 102 | |
| 103 | |
| 104 | |
| 105 | |
| 106 | |
| 107 | |
| 108 | |
| 109 | |
| 110 | |
| 111 | |
| 112 | |
| 113 | |
| 114 | |
| 115 | |
| 116 | |
| 117 | |
| 118 | |
| 119 | |
| 120 | |
| 121 | |
| 122 | |
| 123 | |
| 124 | |
| 125 | |
| 126 | |
| 127 | |
| 128 | |
| 129 | |
| 130 | |
| 131 | |
| 132 | |
| 133 | |
| 134 | |
| 135 | |
| 136 | |
| 137 | |
| 138 | |
| 139 | |
| 140 | |
| 141 | |
| 142 | |
| 143 | |
| 144 | |
| 145 | |
| 146 | |
| 147 | |
| 148 | |
| 149 | |
| 150 | |
| 151 | |
| 152 | |
| 153 | |
| 154 | |
| 155 | |
| 156 | |
| 157 | |
| 158 | |
| 159 | |
| 160 | |
| 161 | |
| 162 | |
| 163 | |
| 164 | |
| 165 | |
| 166 | |
| 167 | /// lane-av1oracledepth: `ffmpeg_decode_sequence_10bit` must REFUSE a |
| 168 | /// wrong-depth stream by the stream's OWN sequence header, the way the |
| 169 | /// 12-bit gates read `assert_12bit_sequence_header`. An 8-bit 4:2:0 |
| 170 | /// stream handed to the 10-bit helper is the wrong-depth shape: ffmpeg |
| 171 | /// converts it to `yuv420p10le` and sizes no plane differently, so |
| 172 | /// without the depth assert a gate could compare a converted 8-bit |
| 173 | /// reference against our 10-bit decode and read exact. |
| 174 | |
| 175 | |
| 176 | |
| 177 | |
| 178 | |
| 179 | |
| 180 | |
| 181 | |
| 182 | |
| 183 | |
| 184 | |
| 185 | |
| 186 | |
| 187 | |
| 188 | |
| 189 | |
| 190 | |
| 191 | |
| 192 | |
| 193 | |
| 194 | |
| 195 | |
| 196 | |
| 197 | |
| 198 | |
| 199 | |
| 200 | |
| 201 | |
| 202 | |
| 203 | |
| 204 | |
| 205 | |
| 206 | |
| 207 | |
| 208 | /// lane-av1rawhelper: `assert_rawvideo_matches` used to pack our samples |
| 209 | /// as `u16` for EVERY stream, while `aomdec --rawvideo` writes 8 bits |
| 210 | /// per sample for an 8-bit stream. An 8-bit caller therefore died on a |
| 211 | /// raw-SIZE assertion (2359296 vs 1179648) without comparing a single |
| 212 | /// sample, and a high-bitdepth caller was the only one that could work. |
| 213 | /// |
| 214 | /// Two arms, both on a real `aomenc` 8-bit stream: |
| 215 | /// |
| 216 | /// 1. the correct label compares real samples -- the byte counts it |
| 217 | /// walks equal the oracle's, so every `u8` in the 8-bit pack is |
| 218 | /// zipped against a real oracle byte; |
| 219 | /// 2. a WRONG label fails by name, quoting both depths and the fact that |
| 220 | /// the pack would compare nothing, rather than by size. Arm 2 is what |
| 221 | /// keeps arm 1 from being a green that a reverted check would also |
| 222 | /// give. |
| 223 | |
| 224 | |
| 225 | |
| 226 | |
| 227 | |
| 228 | |
| 229 | |
| 230 | |
| 231 | |
| 232 | |
| 233 | |
| 234 | |
| 235 | |
| 236 | |
| 237 | |
| 238 | |
| 239 | |
| 240 | |
| 241 | |
| 242 | |
| 243 | |
| 244 | |
| 245 | |
| 246 | |
| 247 | |
| 248 | |
| 249 | |
| 250 | |
| 251 | |
| 252 | |
| 253 | |
| 254 | |
| 255 | |
| 256 | |
| 257 | |
| 258 | |
| 259 | |
| 260 | |
| 261 | |
| 262 | |
| 263 | |
| 264 | |
| 265 | |
| 266 | |
| 267 | |
| 268 | |
| 269 | |
| 270 | |
| 271 | |
| 272 | |
| 273 | |
| 274 | |
| 275 | |
| 276 | |
| 277 | |
| 278 | |
| 279 | |
| 280 | |
| 281 | |
| 282 | |
| 283 | |
| 284 | |
| 285 | |
| 286 | |
| 287 | |
| 288 | |
| 289 | |
| 290 | |
| 291 | |
| 292 | |
| 293 | |
| 294 | |
| 295 | |
| 296 | |
| 297 | |
| 298 | |
| 299 | |
| 300 | |
| 301 | |
| 302 | |
| 303 | |
| 304 | |
| 305 | |
| 306 | |
| 307 | |
| 308 | |
| 309 | |
| 310 | |
| 311 | |
| 312 | |
| 313 | |
| 314 | |
| 315 | |
| 316 | /// lane-svtinter: an SVT-AV1 screen stream whose frame height is not a |
| 317 | /// multiple of the superblock size codes PALETTE blocks in the bottom |
| 318 | /// (and right) superblock row that hang off the mi grid. Spec 5.11.50 |
| 319 | /// `palette_tokens` reads the colour-index map only over the block's |
| 320 | /// `onscreenWidth x onscreenHeight` corner and replicates it outward; |
| 321 | /// this decoder read the full block grid, so it consumed colour-index |
| 322 | /// symbols libaom never wrote and desynced the rest of the tile -- either |
| 323 | /// a wrong bottom superblock row (1599 luma samples in this stream's |
| 324 | /// frame 0, ~80k per inter frame after) or, further along the same tile, |
| 325 | /// a bogus "a Golomb tail longer than this decoder reads" refusal. |
| 326 | /// |
| 327 | /// Unlike its lane-svt1 sibling above this one BUILDS its stream: the |
| 328 | /// recipe is synthetic (`smptebars,drawgrid` through `libsvtav1 -preset 8 |
| 329 | /// -svtav1-params screen-content-mode=1`), and 384x152 puts a 32x32 |
| 330 | /// palette block at mi row 32 of a 38-mi-tall frame, 24 of its 32 rows |
| 331 | /// on screen. `palette_onscreen_cut_hits` is asserted non-zero so the row |
| 332 | /// cannot pass on a stream that never cuts a palette map (class |
| 333 | /// gate-blind-to-feature). |
| 334 | |
| 335 | |
| 336 | |
| 337 | |
| 338 | |
| 339 | |
| 340 | |
| 341 | |
| 342 | |
| 343 | |
| 344 | |
| 345 | |
| 346 | |
| 347 | |
| 348 | |
| 349 | |
| 350 | |
| 351 | |
| 352 | |
| 353 | |
| 354 | |
| 355 | |
| 356 | |
| 357 | |
| 358 | |
| 359 | |
| 360 | |
| 361 | |
| 362 | |
| 363 | |
| 364 | |
| 365 | |
| 366 | |
| 367 | |
| 368 | |
| 369 | |
| 370 | |
| 371 | |
| 372 | |
| 373 | |
| 374 | |
| 375 | |
| 376 | |
| 377 | |
| 378 | |
| 379 | |
| 380 | |
| 381 | |
| 382 | |
| 383 | |
| 384 | |
| 385 | |
| 386 | |
| 387 | |
| 388 | |
| 389 | |
| 390 | |
| 391 | |
| 392 | |
| 393 | |
| 394 | /// lane-svt1: an SVT-AV1 (v3.1.2, `-preset 8`) screen key frame codes 16x16 |
| 395 | /// PALETTE blocks with `skip == 1` whose `tx_depth` split the luma |
| 396 | /// transform. [`crate::decode::decode_block`] armed the palette prediction |
| 397 | /// only when the transform covered the whole block, so that one block |
| 398 | /// predicted DC off its own edges instead: the right symbols (the whole mode |
| 399 | /// ladder diffs clean against an instrumented aomdec) and the wrong pixels |
| 400 | /// -- 812 luma samples in frame 0, carried by the V_PRED blocks under it to |
| 401 | /// 10122 samples over the 12-frame stream the defect was found on. |
| 402 | /// |
| 403 | /// lane-av1pinspec2: the gate used to RIDE an external crop named by |
| 404 | /// `EC_AV1_SVT1_STREAM` and SKIP when that was unset, so it never ran on a |
| 405 | /// stock box -- which is exactly why its oracle count could not be pinned |
| 406 | /// (an assert on a gate that never executes is an unexercised assert wearing |
| 407 | /// a pin's clothes). It now runs on the COMMITTED pin |
| 408 | /// `crates/ec-av1/fixtures/svt1-split-tx-pin.obu`. |
| 409 | /// |
| 410 | /// The pin is a REPLAY, not a fresh capture, and the recipe is recorded |
| 411 | /// because it reproduces the bytes exactly (two independent encodes on this |
| 412 | /// box, SVT-AV1 v3.1.2, both sha256 |
| 413 | /// `c9d9c0ae934fba72fc9a9374bc36853f290796a8a4d6442140e239669e0b341f`, |
| 414 | /// 1838 bytes): |
| 415 | /// |
| 416 | /// ffmpeg -v error -f lavfi \ |
| 417 | /// -i "smptehdbars=s=192x152:r=12,drawgrid=w=8:h=8:t=1:c=black" \ |
| 418 | /// -frames:v 1 -c:v libsvtav1 -preset 8 -crf 50 \ |
| 419 | /// -svtav1-params "lp=1:screen-content-mode=1" -g 12 -f obu out.obu |
| 420 | /// |
| 421 | /// `-frames:v 1` is the part lane-svt1's search lacked: its 6x5x6 sweep ran |
| 422 | /// FOUR frames per stream, and the ~200k-sample misses that killed every |
| 423 | /// candidate were on the INTER frames (`lanes/svt1.report.md`). One key |
| 424 | /// frame has no inter frames, and this one reaches the fixed arm |
| 425 | /// (`skip_split_tx_override_hits == 1`) and is pixel-exact. |
| 426 | /// |
| 427 | /// THE COUNT, and why it is derived from the wire rather than from a |
| 428 | /// literal. The oracle is handed the number of frame OBUs this stream |
| 429 | /// actually codes, counted with `Av1Parser` below -- never our decode's |
| 430 | /// length, which is the thing under test. A header count would OVER-count |
| 431 | /// a stream carrying `show_existing_frame` (spec 5.9.5: it codes no pixels, |
| 432 | /// so the header count is larger than the shown-frame count), so that case |
| 433 | /// is asserted impossible on this pin rather than assumed: the loop refuses |
| 434 | /// any frame header with `show_existing_frame` set, which is what makes |
| 435 | /// "one header == one shown frame" a checked fact here instead of an |
| 436 | /// argument. |
| 437 | /// |
| 438 | /// `EC_AV1_SVT1_STREAM` still overrides the pin, so a re-capture is one env |
| 439 | /// var away; `crate_pin` falls back to `pin_dir()` for the same reason. |
| 440 | /// |
| 441 | /// `skip_split_tx_override_hits` is asserted non-zero so the row cannot |
| 442 | /// pass on a stream that never reaches the fixed arm (class |
| 443 | /// gate-blind-to-feature). |
| 444 | |
| 445 | |
| 446 | |
| 447 | |
| 448 | |
| 449 | |
| 450 | |
| 451 | |
| 452 | |
| 453 | |
| 454 | |
| 455 | |
| 456 | |
| 457 | |
| 458 | |
| 459 | |
| 460 | |
| 461 | |
| 462 | |
| 463 | |
| 464 | |
| 465 | |
| 466 | |
| 467 | |
| 468 | |
| 469 | |
| 470 | |
| 471 | |
| 472 | |
| 473 | |
| 474 | |
| 475 | |
| 476 | |
| 477 | |
| 478 | |
| 479 | |
| 480 | |
| 481 | |
| 482 | |
| 483 | |
| 484 | |
| 485 | |
| 486 | |
| 487 | |
| 488 | |
| 489 | |
| 490 | |
| 491 | |
| 492 | |
| 493 | |
| 494 | |
| 495 | |
| 496 | |
| 497 | |
| 498 | |
| 499 | |
| 500 | |
| 501 | |
| 502 | |
| 503 | |
| 504 | |
| 505 | |
| 506 | |
| 507 | |
| 508 | |
| 509 | |
| 510 | |
| 511 | |
| 512 | |
| 513 | |
| 514 | |
| 515 | /// `decode_stream` agrees with ffmpeg/dav1d on the same wire bytes -- an |
| 516 | /// independent decoder, not just this crate checking its own tile path. |
| 517 | |
| 518 | |
| 519 | |
| 520 | |
| 521 | |
| 522 | |
| 523 | |
| 524 | |
| 525 | |
| 526 | |
| 527 | |
| 528 | |
| 529 | |
| 530 | |
| 531 | |
| 532 | |
| 533 | |
| 534 | |
| 535 | |
| 536 | |
| 537 | |
| 538 | |
| 539 | |
| 540 | |
| 541 | |
| 542 | |
| 543 | |
| 544 | |
| 545 | |
| 546 | |
| 547 | |
| 548 | |
| 549 | |
| 550 | |
| 551 | |
| 552 | |
| 553 | |
| 554 | |
| 555 | |
| 556 | |
| 557 | |
| 558 | |
| 559 | |
| 560 | |
| 561 | |
| 562 | |
| 563 | /// lane-av1rect: the encoder used to REFUSE every size where a 32x32 |
| 564 | /// block straddles BOTH true frame edges at once ("straddles the true |
| 565 | /// frame edge in a way that needs a rectangular (HORZ/VERT) transform |
| 566 | /// this encoder does not code yet"). That refusal was a misreading of |
| 567 | /// spec 5.11.4: a block whose `hasRows` and `hasCols` are BOTH false |
| 568 | /// reads no partition symbol at all and is `PARTITION_SPLIT` by |
| 569 | /// inference, down to the 8x8 leaves whose own mi origin is inside the |
| 570 | /// frame -- exactly the leaves this writer already codes for the |
| 571 | /// one-axis case, and no rectangular transform anywhere. The sweep walks |
| 572 | /// the corners around the 32-multiples (each width has a 16x16 column |
| 573 | /// whose right half is outside, each height a row whose bottom half is, |
| 574 | /// so the bottom-right 16x16 of every size here is cut on both axes) and |
| 575 | /// three-way compares: our decoder, the encoder's own reconstruction and |
| 576 | /// ffmpeg, over a 4-frame GOP so the inter writer's copy of the same |
| 577 | /// signaling is covered too. `edge_both_cut_hits` proves the decoder |
| 578 | /// really took the inferred-split path rather than the gate passing on |
| 579 | /// geometry that never fires it. |
| 580 | |
| 581 | |
| 582 | |
| 583 | |
| 584 | |
| 585 | |
| 586 | |
| 587 | |
| 588 | |
| 589 | |
| 590 | |
| 591 | |
| 592 | |
| 593 | |
| 594 | |
| 595 | |
| 596 | |
| 597 | |
| 598 | |
| 599 | |
| 600 | |
| 601 | |
| 602 | |
| 603 | |
| 604 | |
| 605 | |
| 606 | |
| 607 | |
| 608 | |
| 609 | |
| 610 | |
| 611 | |
| 612 | |
| 613 | |
| 614 | |
| 615 | |
| 616 | |
| 617 | |
| 618 | |
| 619 | |
| 620 | |
| 621 | |
| 622 | |
| 623 | |
| 624 | |
| 625 | |
| 626 | |
| 627 | |
| 628 | |
| 629 | |
| 630 | |
| 631 | |
| 632 | |
| 633 | |
| 634 | |
| 635 | |
| 636 | |
| 637 | |
| 638 | |
| 639 | |
| 640 | |
| 641 | /// lane-corner: sizes whose LAST superblock is cut by the true frame |
| 642 | /// edge on BOTH axes with more than half of each still inside -- so |
| 643 | /// `has_cols` and `has_rows` are both true and the spec lets that |
| 644 | /// superblock stay a whole 64x64 `PARTITION_NONE` block, which this |
| 645 | /// encoder's roots take (`EC_AV1_B64EDGE` on the inter side, the key |
| 646 | /// frame's own `Superblock::Whole`). The sibling luma-only test |
| 647 | /// (`encoder.rs`'s `a_non_superblock_aligned_clip_...`) is blind to |
| 648 | /// chroma (class `metric-blind-to-a-plane`), so this one compares all |
| 649 | /// three planes three ways: our decoder, the encoder's own |
| 650 | /// reconstruction, and ffmpeg. |
| 651 | |
| 652 | |
| 653 | |
| 654 | |
| 655 | |
| 656 | |
| 657 | |
| 658 | |
| 659 | |
| 660 | |
| 661 | |
| 662 | |
| 663 | |
| 664 | |
| 665 | |
| 666 | |
| 667 | |
| 668 | |
| 669 | |
| 670 | |
| 671 | |
| 672 | |
| 673 | |
| 674 | |
| 675 | |
| 676 | |
| 677 | |
| 678 | |
| 679 | |
| 680 | |
| 681 | |
| 682 | |
| 683 | |
| 684 | |
| 685 | |
| 686 | |
| 687 | |
| 688 | |
| 689 | |
| 690 | |
| 691 | |
| 692 | |
| 693 | |
| 694 | |
| 695 | |
| 696 | |
| 697 | |
| 698 | |
| 699 | |
| 700 | |
| 701 | |
| 702 | |
| 703 | |
| 704 | |
| 705 | |
| 706 | |
| 707 | |
| 708 | |
| 709 | |
| 710 | |
| 711 | |
| 712 | |
| 713 | |
| 714 | |
| 715 | |
| 716 | |
| 717 | |
| 718 | |
| 719 | |
| 720 | |
| 721 | |
| 722 | |
| 723 | |
| 724 | |
| 725 | |
| 726 | /// A hand-built 3-frame stream that actually fires `GOLDEN_FRAME` |
| 727 | /// through [`decode_stream`], proving the round-4 flip (`decode.rs`'s |
| 728 | /// `decode_inter_block` `GOLDEN_FRAME` arm) the way 120+ real aomenc |
| 729 | /// attempts never could: frame 0 is a real key frame (this crate's own |
| 730 | /// encoder, real texture), refreshing all 8 DPB slots as spec requires -- |
| 731 | /// slot 3 keeps that exact picture from here on. Frame 1 is a hand-coded |
| 732 | /// inter frame whose lone 32x32 block is *intra* (`DC_PRED`, `skip`), |
| 733 | /// refreshing only slot 0 with a flat 128 block -- distinguishable from |
| 734 | /// frame 0's real texture, so slot 0 (`LAST_FRAME`) and slot 3 |
| 735 | /// (`GOLDEN_FRAME`) hold visibly different pictures once frame 2 runs. |
| 736 | /// Frame 2 is a hand-coded inter frame naming `ref_frame_idx[3] = 3` |
| 737 | /// (GOLDEN_FRAME's slot) and `ref_frame_idx[0] = 0` (LAST_FRAME's), whose |
| 738 | /// lone block codes `single_ref` all the way out to `GOLDEN_FRAME` |
| 739 | /// (`p1=0, p3=1, p5=1`) and a `skip` zero-MV `NEARESTMV`: a direct copy |
| 740 | /// of GOLDEN's picture, so its output must equal frame 0's own |
| 741 | /// reconstruction exactly, and must differ from frame 1's -- proof the |
| 742 | /// decoder actually read the golden plane, not silently substituted |
| 743 | /// `LAST_FRAME`'s. Rounds 4-9 masked and re-masked this arm chasing a |
| 744 | /// deblock/MC residue that turned out to be film-grain synthesis |
| 745 | /// (lane-av1golden7's `apply_grain` refusal, unrelated to GOLDEN); |
| 746 | /// lane-av1golden8 fixed mvstack's single-ref extension pass, clearing |
| 747 | /// the last real defect (`pinned_golden7` non_last_ref_hits 0->2), so |
| 748 | /// this fixture flips back to its round-4 pixel-exact form. ffmpeg |
| 749 | /// decodes the identical wire bytes as the foreign oracle |
| 750 | /// (shared-oracle-blindness class): this crate's own decoder agreeing |
| 751 | /// with itself would prove nothing. |
| 752 | |
| 753 | |
| 754 | |
| 755 | |
| 756 | |
| 757 | |
| 758 | |
| 759 | |
| 760 | |
| 761 | |
| 762 | |
| 763 | |
| 764 | |
| 765 | |
| 766 | |
| 767 | |
| 768 | |
| 769 | |
| 770 | |
| 771 | |
| 772 | |
| 773 | |
| 774 | |
| 775 | |
| 776 | |
| 777 | |
| 778 | |
| 779 | |
| 780 | |
| 781 | |
| 782 | |
| 783 | |
| 784 | |
| 785 | |
| 786 | |
| 787 | |
| 788 | |
| 789 | |
| 790 | |
| 791 | |
| 792 | |
| 793 | |
| 794 | |
| 795 | |
| 796 | |
| 797 | |
| 798 | |
| 799 | |
| 800 | |
| 801 | |
| 802 | |
| 803 | |
| 804 | |
| 805 | |
| 806 | |
| 807 | |
| 808 | |
| 809 | |
| 810 | |
| 811 | |
| 812 | |
| 813 | |
| 814 | |
| 815 | |
| 816 | |
| 817 | |
| 818 | |
| 819 | |
| 820 | |
| 821 | |
| 822 | |
| 823 | |
| 824 | |
| 825 | |
| 826 | |
| 827 | |
| 828 | |
| 829 | |
| 830 | |
| 831 | |
| 832 | |
| 833 | |
| 834 | |
| 835 | |
| 836 | |
| 837 | |
| 838 | |
| 839 | |
| 840 | |
| 841 | |
| 842 | |
| 843 | |
| 844 | |
| 845 | |
| 846 | |
| 847 | |
| 848 | |
| 849 | |
| 850 | |
| 851 | |
| 852 | |
| 853 | |
| 854 | |
| 855 | |
| 856 | |
| 857 | |
| 858 | |
| 859 | |
| 860 | |
| 861 | |
| 862 | |
| 863 | |
| 864 | |
| 865 | |
| 866 | |
| 867 | |
| 868 | |
| 869 | |
| 870 | /// The determinism guard: same seed twice must byte-match ffmpeg's own |
| 871 | /// output; different seeds must not. Regresses this fix if it ever |
| 872 | /// breaks. |
| 873 | |
| 874 | |
| 875 | |
| 876 | |
| 877 | |
| 878 | |
| 879 | |
| 880 | |
| 881 | |
| 882 | |
| 883 | |
| 884 | |
| 885 | |
| 886 | |
| 887 | |
| 888 | |
| 889 | |
| 890 | |
| 891 | |
| 892 | |
| 893 | |
| 894 | |
| 895 | |
| 896 | |
| 897 | |
| 898 | |
| 899 | |
| 900 | |
| 901 | |
| 902 | |
| 903 | |
| 904 | |
| 905 | |
| 906 | |
| 907 | |
| 908 | /// The end-to-end gate: two real libaom-av1 configs, decoded with |
| 909 | /// [`decode_stream`] and checked against ffmpeg's own decode of the same |
| 910 | /// bytes. Not every config this encoder writes decodes yet (partitions |
| 911 | /// below 16x16, AB partitions, CfL and others remain round-2 gaps per the |
| 912 | /// r6 catalogue) -- both configs here pick `cpu-used 8` plus the |
| 913 | /// partition/angle-delta/CfL flags r6 found narrow the encoder onto this |
| 914 | /// decoder's supported syntax, while still landing on non-`DCT_DCT` tx |
| 915 | /// types on gradient content. |
| 916 | |
| 917 | |
| 918 | |
| 919 | |
| 920 | |
| 921 | |
| 922 | |
| 923 | |
| 924 | |
| 925 | |
| 926 | |
| 927 | |
| 928 | |
| 929 | |
| 930 | |
| 931 | |
| 932 | |
| 933 | |
| 934 | |
| 935 | |
| 936 | |
| 937 | |
| 938 | |
| 939 | |
| 940 | |
| 941 | |
| 942 | |
| 943 | |
| 944 | |
| 945 | |
| 946 | |
| 947 | |
| 948 | |
| 949 | |
| 950 | |
| 951 | |
| 952 | |
| 953 | |
| 954 | |
| 955 | |
| 956 | |
| 957 | |
| 958 | |
| 959 | |
| 960 | |
| 961 | |
| 962 | |
| 963 | |
| 964 | /// lane-dgolomb: the `force_integer_mv` gate. libaom turns screen-content |
| 965 | /// tools on for DARK, SMOOTH content -- its `av1_set_screen_content_options` |
| 966 | /// counts 16x16 blocks with 2..=4 distinct luma values -- and then sets |
| 967 | /// `force_integer_mv` on any inter frame whose source is pixel-identical to |
| 968 | /// the previously coded source (`av1_is_integer_mv`: `cs_rate >= 0.8` and |
| 969 | /// `C == T`, every collocated 8x8 block matching, is the only path that |
| 970 | /// returns 1). Both hold on his real AV1 films, and this decoder used to |
| 971 | /// drop `lower_mv_precision`'s `is_integer` half as unreachable, so every |
| 972 | /// temporal MV candidate on such a frame came out at eighth-pel: the frame |
| 973 | /// decoded without any error into a whole-frame prediction mismatch, and |
| 974 | /// the desync surfaced blocks later as "a Golomb tail longer than this |
| 975 | /// decoder reads". |
| 976 | /// |
| 977 | /// The source is SYNTHETIC (no film sample lives in `fixtures`): the |
| 978 | /// near-flat dark pattern libaom's own screen-content detector counts as |
| 979 | /// screen content, at the film-B crop size 1920x1024, SCROLLING globally |
| 980 | /// 5 px per frame and frozen on frame 8 -- an exact duplicate of frame 7 |
| 981 | /// (the `C == T` trigger) whose twin is not among its own references, so |
| 982 | /// its blocks still code real motion under `force_integer_mv`. |
| 983 | /// |
| 984 | /// lane-dpm1 made this gate SENSITIVE: with the `force_integer_mv` branch |
| 985 | /// of [`crate::motion_field::lower_mv_precision`] stubbed out (`if false |
| 986 | /// &&`) the stream decodes WRONG -- frame 8, luma sample 25695, 20 against |
| 987 | /// ffmpeg's 19 -- where the previous patch-in-a-static-background recipe |
| 988 | /// (and two others tried) still decoded byte-exact: there the used mv-stack |
| 989 | /// slots came from agreeing spatial neighbours and the rounded temporal |
| 990 | /// entries never won one. The gate asserts both halves: at least one INTER |
| 991 | /// frame really carries `force_integer_mv` (class `gate-blind-to-feature`), |
| 992 | /// and every shown frame decodes sample-exact against ffmpeg's own decode. |
| 993 | |
| 994 | |
| 995 | |
| 996 | |
| 997 | |
| 998 | |
| 999 | |
| 1000 | |
| 1001 | |
| 1002 | |
| 1003 | |
| 1004 | |
| 1005 | |
| 1006 | |
| 1007 | |
| 1008 | |
| 1009 | |
| 1010 | |
| 1011 | |
| 1012 | |
| 1013 | |
| 1014 | |
| 1015 | |
| 1016 | |
| 1017 | |
| 1018 | |
| 1019 | |
| 1020 | |
| 1021 | |
| 1022 | |
| 1023 | |
| 1024 | |
| 1025 | |
| 1026 | |
| 1027 | |
| 1028 | |
| 1029 | |
| 1030 | |
| 1031 | |
| 1032 | |
| 1033 | |
| 1034 | |
| 1035 | |
| 1036 | |
| 1037 | |
| 1038 | |
| 1039 | |
| 1040 | |
| 1041 | |
| 1042 | |
| 1043 | |
| 1044 | |
| 1045 | |
| 1046 | |
| 1047 | |
| 1048 | |
| 1049 | |
| 1050 | |
| 1051 | |
| 1052 | |
| 1053 | |
| 1054 | |
| 1055 | |
| 1056 | |
| 1057 | |
| 1058 | |
| 1059 | |
| 1060 | |
| 1061 | |
| 1062 | |
| 1063 | |
| 1064 | |
| 1065 | |
| 1066 | |
| 1067 | |
| 1068 | |
| 1069 | |
| 1070 | |
| 1071 | |
| 1072 | |
| 1073 | |
| 1074 | |
| 1075 | |
| 1076 | |
| 1077 | |
| 1078 | |
| 1079 | |
| 1080 | |
| 1081 | |
| 1082 | |
| 1083 | |
| 1084 | |
| 1085 | |
| 1086 | |
| 1087 | |
| 1088 | |
| 1089 | |
| 1090 | |
| 1091 | |
| 1092 | |
| 1093 | |
| 1094 | |
| 1095 | |
| 1096 | |
| 1097 | |
| 1098 | |
| 1099 | |
| 1100 | |
| 1101 | |
| 1102 | |
| 1103 | |
| 1104 | |
| 1105 | /// lane-dpm1: the 128x128-INTRA-inside-an-INTER-frame chroma context gate. |
| 1106 | /// A 128x128 block codes its chroma as four TX_32X32 units, one per 64x64 |
| 1107 | /// mu chunk, and libaom stamps the coefficient context PER UNIT. The two |
| 1108 | /// INTER mu-chunk sites set `mu_chroma` so the block tail re-stamps the |
| 1109 | /// four units in mu order; the INTRA-in-inter site did not, so the |
| 1110 | /// whole-block record left every unit carrying the TOP-LEFT unit's level. |
| 1111 | /// The next block then read its `txb_skip` off ctx 11 where libaom reads |
| 1112 | /// ctx 10 (class `override-slot-on-one-arm`) -- one symbol on the wrong |
| 1113 | /// CDF row, tile desynced, and because the loop-restoration coefficients |
| 1114 | /// live in the same tile data the damage showed up as a +-1 luma sample at |
| 1115 | /// the TOP of the frame (measured: frame 1, luma sample 66, ours 146 / |
| 1116 | /// ffmpeg 145, with 1.7M samples wrong behind it). |
| 1117 | /// |
| 1118 | /// Source: the repository's own 2160p colour-bar fixture at the native |
| 1119 | /// gate's crop (1920x1024 out of the middle), 12 frames, libaom |
| 1120 | /// `-cpu-used 6 -crf 45 -g 12` -- the first reference point of |
| 1121 | /// `bd_rate_screen_native`'s "bars 2160p" row, which is where the assertion |
| 1122 | /// caught it. The gate asserts the tool fired (class |
| 1123 | /// `gate-blind-to-feature`) and that every shown frame decodes sample-exact |
| 1124 | /// against ffmpeg's own decode. |
| 1125 | |
| 1126 | |
| 1127 | |
| 1128 | |
| 1129 | |
| 1130 | |
| 1131 | |
| 1132 | |
| 1133 | |
| 1134 | |
| 1135 | |
| 1136 | |
| 1137 | |
| 1138 | |
| 1139 | |
| 1140 | |
| 1141 | |
| 1142 | |
| 1143 | |
| 1144 | |
| 1145 | |
| 1146 | |
| 1147 | |
| 1148 | |
| 1149 | |
| 1150 | |
| 1151 | |
| 1152 | |
| 1153 | |
| 1154 | |
| 1155 | |
| 1156 | |
| 1157 | |
| 1158 | |
| 1159 | |
| 1160 | |
| 1161 | |
| 1162 | |
| 1163 | |
| 1164 | |
| 1165 | |
| 1166 | |
| 1167 | |
| 1168 | |
| 1169 | |
| 1170 | |
| 1171 | |
| 1172 | |
| 1173 | |
| 1174 | |
| 1175 | |
| 1176 | |
| 1177 | |
| 1178 | |
| 1179 | |
| 1180 | |
| 1181 | |
| 1182 | |
| 1183 | |
| 1184 | |
| 1185 | |
| 1186 | |
| 1187 | |
| 1188 | |
| 1189 | |
| 1190 | |
| 1191 | |
| 1192 | |
| 1193 | |
| 1194 | |
| 1195 | |
| 1196 | |
| 1197 | |
| 1198 | |
| 1199 | |
| 1200 | |
| 1201 | |
| 1202 | |
| 1203 | |
| 1204 | |
| 1205 | |
| 1206 | |
| 1207 | |
| 1208 | |
| 1209 | |
| 1210 | |
| 1211 | |
| 1212 | |
| 1213 | |
| 1214 | |
| 1215 | |
| 1216 | /// lane-lossless: the refusal became an implementation, so its gate became |
| 1217 | /// a DECODE-EXACT one (class `refusal-lifted-without-a-gate`). libaom at |
| 1218 | /// `-crf 0` codes `base_q_idx == 0` -- the same lossless frame his |
| 1219 | /// screen-capture row gets at `-crf 5` -- where every plane is TX_4X4 with |
| 1220 | /// the Walsh-Hadamard transform, no `tx_type` symbol is coded |
| 1221 | /// (`read_tx_type`, `decodetxb.c`: "No need to read transform type for |
| 1222 | /// lossless mode(qindex==0)") and `is_cfl_allowed` (`blockd.h`) narrows to |
| 1223 | /// a BLOCK_4X4 chroma plane block. The gate asserts the stream really is |
| 1224 | /// lossless (class `gate-blind-to-feature`), that every KEY frame decodes |
| 1225 | /// sample-exact against ffmpeg, and that the still-unimplemented lossless |
| 1226 | /// INTER frame is refused BY NAME rather than decoded wrong. |
| 1227 | |
| 1228 | |
| 1229 | |
| 1230 | |
| 1231 | |
| 1232 | |
| 1233 | |
| 1234 | |
| 1235 | |
| 1236 | |
| 1237 | |
| 1238 | |
| 1239 | |
| 1240 | |
| 1241 | |
| 1242 | |
| 1243 | |
| 1244 | |
| 1245 | |
| 1246 | |
| 1247 | |
| 1248 | |
| 1249 | |
| 1250 | |
| 1251 | |
| 1252 | |
| 1253 | |
| 1254 | |
| 1255 | |
| 1256 | |
| 1257 | |
| 1258 | |
| 1259 | |
| 1260 | |
| 1261 | |
| 1262 | |
| 1263 | |
| 1264 | |
| 1265 | |
| 1266 | |
| 1267 | |
| 1268 | |
| 1269 | |
| 1270 | |
| 1271 | |
| 1272 | |
| 1273 | |
| 1274 | |
| 1275 | |
| 1276 | |
| 1277 | |
| 1278 | |
| 1279 | |
| 1280 | |
| 1281 | |
| 1282 | |
| 1283 | |
| 1284 | |
| 1285 | |
| 1286 | |
| 1287 | |
| 1288 | |
| 1289 | |
| 1290 | |
| 1291 | |
| 1292 | |
| 1293 | |
| 1294 | |
| 1295 | |
| 1296 | |
| 1297 | |
| 1298 | |
| 1299 | |
| 1300 | |
| 1301 | |
| 1302 | |
| 1303 | |
| 1304 | |
| 1305 | |
| 1306 | |
| 1307 | |
| 1308 | |
| 1309 | |
| 1310 | |
| 1311 | |
| 1312 | |
| 1313 | |
| 1314 | |
| 1315 | |
| 1316 | |
| 1317 | |
| 1318 | |
| 1319 | |
| 1320 | |
| 1321 | |
| 1322 | |
| 1323 | |
| 1324 | |
| 1325 | |
| 1326 | |
| 1327 | |
| 1328 | /// lane-lossless2: the refusal `a_lossless_inter_frame_is_refused_by_name` |
| 1329 | /// pinned became an implementation, so its gate became a DECODE-EXACT one |
| 1330 | /// (class `refusal-lifted-without-a-gate`). A lossless INTER frame codes |
| 1331 | /// its chroma plane as 4x4 transform units, plane-major inside each 64x64 |
| 1332 | /// mu chunk (libaom `read_tx_size` returns TX_4X4 for every plane under |
| 1333 | /// `xd->lossless[..]`, and `decode_token_recon_block` walks |
| 1334 | /// `for (plane..) for (blk_row..) for (blk_col..)`), which is what |
| 1335 | /// `decode::read_inter_chroma_lossless` reads. The source carries TEXTURED |
| 1336 | /// CHROMA and real motion on purpose: a flat-chroma source codes one |
| 1337 | /// `txb_skip` symbol per unit and is blind to both the unit order and the |
| 1338 | /// per-unit contexts (class `gate-blind-to-feature`). |
| 1339 | |
| 1340 | |
| 1341 | |
| 1342 | |
| 1343 | |
| 1344 | |
| 1345 | |
| 1346 | |
| 1347 | |
| 1348 | |
| 1349 | |
| 1350 | |
| 1351 | |
| 1352 | |
| 1353 | |
| 1354 | |
| 1355 | |
| 1356 | |
| 1357 | |
| 1358 | |
| 1359 | |
| 1360 | |
| 1361 | |
| 1362 | |
| 1363 | |
| 1364 | |
| 1365 | |
| 1366 | |
| 1367 | |
| 1368 | |
| 1369 | |
| 1370 | |
| 1371 | |
| 1372 | |
| 1373 | |
| 1374 | |
| 1375 | |
| 1376 | |
| 1377 | |
| 1378 | |
| 1379 | |
| 1380 | |
| 1381 | |
| 1382 | |
| 1383 | |
| 1384 | |
| 1385 | |
| 1386 | |
| 1387 | |
| 1388 | |
| 1389 | |
| 1390 | |
| 1391 | |
| 1392 | |
| 1393 | |
| 1394 | |
| 1395 | |
| 1396 | |
| 1397 | |
| 1398 | |
| 1399 | |
| 1400 | |
| 1401 | |
| 1402 | |
| 1403 | |
| 1404 | |
| 1405 | |
| 1406 | |
| 1407 | |
| 1408 | |
| 1409 | |
| 1410 | |
| 1411 | |
| 1412 | |
| 1413 | |
| 1414 | |
| 1415 | |
| 1416 | |
| 1417 | |
| 1418 | |
| 1419 | |
| 1420 | |
| 1421 | |
| 1422 | |
| 1423 | |
| 1424 | |
| 1425 | |
| 1426 | |
| 1427 | |
| 1428 | |
| 1429 | |
| 1430 | |
| 1431 | |
| 1432 | |
| 1433 | |
| 1434 | |
| 1435 | |
| 1436 | |
| 1437 | |
| 1438 | |
| 1439 | |
| 1440 | |
| 1441 | |
| 1442 | |
| 1443 | |
| 1444 | |
| 1445 | |
| 1446 | |
| 1447 | |
| 1448 | |
| 1449 | |
| 1450 | |
| 1451 | |
| 1452 | |
| 1453 | |
| 1454 | |
| 1455 | |
| 1456 | |
| 1457 | |
| 1458 | |
| 1459 | |
| 1460 | |
| 1461 | |
| 1462 | |
| 1463 | |
| 1464 | |
| 1465 | |
| 1466 | |
| 1467 | |
| 1468 | |
| 1469 | |
| 1470 | |
| 1471 | |
| 1472 | |
| 1473 | |
| 1474 | |
| 1475 | |
| 1476 | |
| 1477 | |
| 1478 | |
| 1479 | |
| 1480 | |
| 1481 | |
| 1482 | |
| 1483 | |
| 1484 | |
| 1485 | |
| 1486 | |
| 1487 | |
| 1488 | |
| 1489 | |
| 1490 | |
| 1491 | |
| 1492 | |
| 1493 | |
| 1494 | |
| 1495 | |
| 1496 | |
| 1497 | |
| 1498 | |
| 1499 | |
| 1500 | |
| 1501 | |
| 1502 | |
| 1503 | |
| 1504 | |
| 1505 | |
| 1506 | |
| 1507 | |
| 1508 | |
| 1509 | |
| 1510 | |
| 1511 | /// lane-av1-llband: the pinned 4:4:4 LOSSLESS key frame |
| 1512 | /// (`fixtures/ll444-lossless-key.obu`, the `ll444` recipe's frame 0 -- |
| 1513 | /// `testsrc2 128x96` yuv444p cut to its key frame) decodes sample-exact, |
| 1514 | /// and its HORZ/VERT strips really walked their chroma as 4x4 units at |
| 1515 | /// subsampling 0/0 (one unit per mi cell). That unit walk used the 4:2:0 |
| 1516 | /// span (8 luma px per 4x4 chroma unit) unconditionally, so every unit |
| 1517 | /// past the first column/row read its `txb_skip` context two mi cells |
| 1518 | /// over and stamped a 2-cell smear -- the 178-byte key-frame miss, first |
| 1519 | /// divergence at the 16x8 leaf mi (16,24)'s U bc=2 unit (oracle |
| 1520 | /// `txb_skip` base 0 off `above[26]`, ours base 1 off the polluted |
| 1521 | /// `above[29]`). The counter assertion is the non-vacuity half (class |
| 1522 | /// `gate-blind-to-feature`): a stream that never reaches the 4:4:4 unit |
| 1523 | /// walk must not pass. |
| 1524 | |
| 1525 | |
| 1526 | |
| 1527 | |
| 1528 | |
| 1529 | |
| 1530 | |
| 1531 | |
| 1532 | |
| 1533 | |
| 1534 | |
| 1535 | |
| 1536 | |
| 1537 | |
| 1538 | |
| 1539 | |
| 1540 | |
| 1541 | |
| 1542 | |
| 1543 | |
| 1544 | |
| 1545 | |
| 1546 | |
| 1547 | |
| 1548 | |
| 1549 | |
| 1550 | |
| 1551 | |
| 1552 | |
| 1553 | |
| 1554 | |
| 1555 | |
| 1556 | |
| 1557 | |
| 1558 | |
| 1559 | |
| 1560 | |
| 1561 | |
| 1562 | |
| 1563 | |
| 1564 | |
| 1565 | |
| 1566 | |
| 1567 | |
| 1568 | |
| 1569 | |
| 1570 | |
| 1571 | |
| 1572 | |
| 1573 | |
| 1574 | |
| 1575 | |
| 1576 | |
| 1577 | |
| 1578 | |
| 1579 | |
| 1580 | |
| 1581 | |
| 1582 | |
| 1583 | |
| 1584 | |
| 1585 | |
| 1586 | |
| 1587 | |
| 1588 | |
| 1589 | |
| 1590 | |
| 1591 | |
| 1592 | |
| 1593 | |
| 1594 | |
| 1595 | |
| 1596 | |
| 1597 | |
| 1598 | |
| 1599 | |
| 1600 | |
| 1601 | |
| 1602 | |
| 1603 | |
| 1604 | |
| 1605 | |
| 1606 | |
| 1607 | |
| 1608 | |
| 1609 | |
| 1610 | |
| 1611 | |
| 1612 | |
| 1613 | |
| 1614 | |
| 1615 | |
| 1616 | |
| 1617 | |
| 1618 | |
| 1619 | |
| 1620 | |
| 1621 | |
| 1622 | /// lane-av1-llinter: the firing gate for the lossless 4:4:4 INTER chroma |
| 1623 | /// fix. The fixture is the report's dodge2 stream pinned into `fixtures/`: |
| 1624 | /// aomenc profile 1 over testsrc2 128x96 yuv444p, `--lossless=1`, |
| 1625 | /// `--sb-size=64 --min-partition-size=64 --max-partition-size=64`, 6 |
| 1626 | /// frames; 37658 bytes, sha256 |
| 1627 | /// `5a070fa351a3f2109de855234f2b3d0a872970f3e7f658db21f65c12eeb135b4`. |
| 1628 | /// The firing counter is the EXISTING `decode::chroma_split_tx_hits` (one |
| 1629 | /// bump per lossless chroma TX unit read): with min=max partition 64 the |
| 1630 | /// roots stay whole 64x64 inter blocks -- no 8x8 leaf exists in this |
| 1631 | /// stream -- so every chroma unit goes through the big-block ss-aware |
| 1632 | /// lossless route this lane fixed (fixes 2-5). A 4:2:0 lossless stream |
| 1633 | /// fires the same counter, but the fixture bytes are pinned, so the gate |
| 1634 | /// cannot run on anything else; the pre-fix 4:2:0-hardcoded math corrupts |
| 1635 | /// at 4:4:4, so the pixel-exact compares are what prove the ss-aware path |
| 1636 | /// (class `gate-blind-to-feature`). Every frame must come out pixel-exact |
| 1637 | /// through BOTH the oracle `aomdec --rawvideo` and ffmpeg. The |
| 1638 | /// default-partition ll444 stream is deliberately NOT claimed here: its |
| 1639 | /// key frame is still the intra lane's named sub8-chroma stop |
| 1640 | /// (lanes/av1llintra.report.md). |
| 1641 | |
| 1642 | |
| 1643 | |
| 1644 | |
| 1645 | |
| 1646 | |
| 1647 | |
| 1648 | |
| 1649 | |
| 1650 | |
| 1651 | |
| 1652 | |
| 1653 | |
| 1654 | |
| 1655 | |
| 1656 | |
| 1657 | |
| 1658 | |
| 1659 | |
| 1660 | |
| 1661 | |
| 1662 | |
| 1663 | |
| 1664 | |
| 1665 | |
| 1666 | |
| 1667 | |
| 1668 | |
| 1669 | |
| 1670 | |
| 1671 | |
| 1672 | |
| 1673 | |
| 1674 | |
| 1675 | |
| 1676 | |
| 1677 | |
| 1678 | |
| 1679 | |
| 1680 | |
| 1681 | |
| 1682 | |
| 1683 | |
| 1684 | |
| 1685 | |
| 1686 | |
| 1687 | |
| 1688 | |
| 1689 | |
| 1690 | |
| 1691 | |
| 1692 | |
| 1693 | |
| 1694 | |
| 1695 | |
| 1696 | |
| 1697 | |
| 1698 | |
| 1699 | |
| 1700 | |
| 1701 | |
| 1702 | |
| 1703 | |
| 1704 | |
| 1705 | |
| 1706 | |
| 1707 | |
| 1708 | |
| 1709 | |
| 1710 | |
| 1711 | |
| 1712 | |
| 1713 | |
| 1714 | |
| 1715 | |
| 1716 | |
| 1717 | |
| 1718 | |
| 1719 | |
| 1720 | |
| 1721 | |
| 1722 | |
| 1723 | |
| 1724 | |
| 1725 | |
| 1726 | |
| 1727 | |
| 1728 | |
| 1729 | |
| 1730 | |
| 1731 | |
| 1732 | |
| 1733 | |
| 1734 | |
| 1735 | |
| 1736 | |
| 1737 | |
| 1738 | |
| 1739 | |
| 1740 | |
| 1741 | |
| 1742 | |
| 1743 | |
| 1744 | |
| 1745 | |
| 1746 | |
| 1747 | |
| 1748 | |
| 1749 | |
| 1750 | |
| 1751 | |
| 1752 | |
| 1753 | |
| 1754 | |
| 1755 | |
| 1756 | /// lane-av1h5: the 128-ROOT lossless 4:4:4 pin, and the control arm |
| 1757 | /// that proves the 128 root is what it needs. |
| 1758 | /// |
| 1759 | /// Witness: testsrc2 128x96 yuv444p10le, aomenc `--profile=1 --lossless=1 |
| 1760 | /// --enable-palette=0 --enable-intrabc=0 --cpu-used=0`, 6 frames; 63429 |
| 1761 | /// bytes, sha256 `bbffb979d20d581deb271aac75b7ee779dde57c024524ed6b1389356f55ca0fa`. |
| 1762 | /// Control: the same recipe at `--max-partition-size=64` (61494 bytes, |
| 1763 | /// sha256 `4cadce41e1f8967567b32f5cf8abaa46ffdf4fd6d4afe784c8d99a7f6bf1ae4c`), |
| 1764 | /// which never reaches a 128 root. |
| 1765 | /// |
| 1766 | /// libaom's `decode_token_recon_block` (`av1/decoder/decodeframe.c:972`) |
| 1767 | /// walks 64x64 "mu" chunks with the PLANE loop inside the chunk loop, on a |
| 1768 | /// chunk grid of `mi_size_wide[BLOCK_64X64]` = 16 mi per axis. The var-tx |
| 1769 | /// leaf list is a BLOCK-wide raster (32 leaves across at 128), so a chunk's |
| 1770 | /// members are not contiguous: leaves 0..15 are chunk (0,0) row 0, but |
| 1771 | /// chunk (0,0) rows 1..15 are leaves 32..47, 64..79, ... A chunk test on |
| 1772 | /// the given order closed the chunk every SIXTEEN leaves and coded each |
| 1773 | /// chunk's chroma sixteen times. |
| 1774 | /// |
| 1775 | /// The three assertions below are all EXACT and all stay true when the |
| 1776 | /// stream becomes byte-exact. None of them is a floor on wrong output: |
| 1777 | /// a no-op [`crate::decode::mu_chunk_order`] permutation reads 0 on |
| 1778 | /// `mu_chunk_order_hits`, so the first cannot be satisfied by a gate that |
| 1779 | /// merely ran; the walk and unit totals are libaom's own per-chunk counts; |
| 1780 | /// the control arm is a straight exactness assertion. |
| 1781 | |
| 1782 | |
| 1783 | |
| 1784 | |
| 1785 | |
| 1786 | |
| 1787 | |
| 1788 | |
| 1789 | |
| 1790 | |
| 1791 | |
| 1792 | |
| 1793 | |
| 1794 | |
| 1795 | |
| 1796 | |
| 1797 | |
| 1798 | |
| 1799 | |
| 1800 | |
| 1801 | |
| 1802 | |
| 1803 | |
| 1804 | |
| 1805 | |
| 1806 | |
| 1807 | |
| 1808 | |
| 1809 | |
| 1810 | |
| 1811 | |
| 1812 | |
| 1813 | |
| 1814 | |
| 1815 | |
| 1816 | |
| 1817 | |
| 1818 | |
| 1819 | |
| 1820 | |
| 1821 | |
| 1822 | |
| 1823 | |
| 1824 | |
| 1825 | |
| 1826 | |
| 1827 | |
| 1828 | |
| 1829 | |
| 1830 | |
| 1831 | |
| 1832 | |
| 1833 | |
| 1834 | |
| 1835 | |
| 1836 | |
| 1837 | |
| 1838 | |
| 1839 | |
| 1840 | |
| 1841 | |
| 1842 | |
| 1843 | |
| 1844 | |
| 1845 | |
| 1846 | |
| 1847 | |
| 1848 | |
| 1849 | |
| 1850 | |
| 1851 | |
| 1852 | |
| 1853 | |
| 1854 | |
| 1855 | |
| 1856 | |
| 1857 | |
| 1858 | |
| 1859 | |
| 1860 | /// lane-av1lm444loss: a LOSSLESS block's transform-unit grid is clipped at |
| 1861 | /// the FRAME edge, exactly as libaom's `max_block_high`/`max_block_wide` |
| 1862 | /// clip it (`av1_common_int.h:1565`, `:1579` fold `mb_to_bottom_edge` / |
| 1863 | /// `mb_to_right_edge` into `block_size_high/wide` before `>> |
| 1864 | /// MI_SIZE_LOG2`), so a block hanging off the bottom/right codes only the |
| 1865 | /// units inside the frame. `decode_token_recon_block` then bounds every |
| 1866 | /// mu chunk with `unit_height = ROUND_POWER_OF_TWO(AOMMIN(mu_blocks_high |
| 1867 | /// + row, max_blocks_high), ss_y)`, so the overflow units are never read |
| 1868 | /// there either. |
| 1869 | /// |
| 1870 | /// Fixture is the sibling [`a_lossless_444_128_root_lossless_stream_reads_chunks_chunk_major`] |
| 1871 | /// pin -- 128x96 yuv444p 4:4:4 lossless, 6 frames, 63429 bytes -- because |
| 1872 | /// 96 is NOT a multiple of the 128 superblock: its five inter frames each |
| 1873 | /// carry one unsplit 128 root that overhangs the bottom by 32 px. That is |
| 1874 | /// the whole reason this stream is the witness. The frame is 24 mi tall, |
| 1875 | /// so `max_blocks_high >> 2` is 24 transform rows where the block's own |
| 1876 | /// `side / MI` is 32. |
| 1877 | /// |
| 1878 | /// The three assertions are all non-vacuous and all EXACT: |
| 1879 | /// |
| 1880 | /// 1. `lossless_edge_clipped()` fired -- 5, one per inter frame's 128 |
| 1881 | /// root. It is 0 on any frame whose height and width are multiples of |
| 1882 | /// the superblock, so a stream that merely decodes cannot satisfy it. |
| 1883 | /// 2. `lossless_edge_clip_units()` is 1280 = 5 x 256: the 8 transform rows |
| 1884 | /// x 32 columns the unclipped walk read past the frame bottom, per |
| 1885 | /// inter frame. The pre-fix walk read 2560 units per inter frame |
| 1886 | /// against the oracle's 2304, and this is that 256. |
| 1887 | /// 3. every sample of every frame matches the oracle `aomdec |
| 1888 | /// --rawvideo` in decode order -- all six frames, hidden alt-ref |
| 1889 | /// included, which the pre-fix tree failed from frame 1 on |
| 1890 | /// (5596 wrong samples there, growing to 33561 by frame 5). |
| 1891 | /// |
| 1892 | /// The control arm pins the other direction of the invariant: the |
| 1893 | /// `ll444_minp64_128root_control` stream has no overhanging root, so its |
| 1894 | /// clip counters must both read 0 -- the clip cannot fire on a block that |
| 1895 | /// fits, which is what keeps every other lossless pin byte-identical. |
| 1896 | |
| 1897 | |
| 1898 | |
| 1899 | |
| 1900 | |
| 1901 | |
| 1902 | |
| 1903 | |
| 1904 | |
| 1905 | |
| 1906 | |
| 1907 | |
| 1908 | |
| 1909 | |
| 1910 | |
| 1911 | |
| 1912 | |
| 1913 | |
| 1914 | |
| 1915 | |
| 1916 | |
| 1917 | |
| 1918 | |
| 1919 | |
| 1920 | |
| 1921 | |
| 1922 | |
| 1923 | |
| 1924 | |
| 1925 | |
| 1926 | |
| 1927 | |
| 1928 | |
| 1929 | |
| 1930 | |
| 1931 | |
| 1932 | |
| 1933 | |
| 1934 | |
| 1935 | |
| 1936 | |
| 1937 | |
| 1938 | |
| 1939 | |
| 1940 | |
| 1941 | |
| 1942 | |
| 1943 | |
| 1944 | |
| 1945 | |
| 1946 | |
| 1947 | |
| 1948 | |
| 1949 | |
| 1950 | |
| 1951 | |
| 1952 | |
| 1953 | |
| 1954 | |
| 1955 | |
| 1956 | |
| 1957 | |
| 1958 | |
| 1959 | |
| 1960 | |
| 1961 | |
| 1962 | |
| 1963 | |
| 1964 | |
| 1965 | |
| 1966 | |
| 1967 | |
| 1968 | |
| 1969 | |
| 1970 | |
| 1971 | |
| 1972 | |
| 1973 | |
| 1974 | |
| 1975 | |
| 1976 | |
| 1977 | /// lane-av1lm444loss-corr: the MI STEP at which `decode_intrabc_rect`'s |
| 1978 | /// lossless chroma replay walks the plane block. |
| 1979 | /// |
| 1980 | /// `lane-whtshape` (`f541d062`, merged `afa13bcf`) gave this route the |
| 1981 | /// per-TX_4X4 lossless chroma walk and the tail replay that re-stamps |
| 1982 | /// each unit's own coefficient context over the whole-block record. The |
| 1983 | /// replay stepped by `4 >> ss_y(fctx)` mi cells, which is 4:2:0-only |
| 1984 | /// arithmetic: at ss (1,1) it reads 2 and the ss-aware form |
| 1985 | /// `(4 << ss_y) / MI` also reads 2, so 4:2:0 agrees by construction; at |
| 1986 | /// ss (0,0) it reads 4 mi, i.e. 16 luma px per 4x4 chroma unit, where the |
| 1987 | /// unit covers `4 << 0` = 4 luma px = ONE mi. Every replayed unit was |
| 1988 | /// therefore stamped at 4x its own mi origin on a 4:4:4 lossless frame, |
| 1989 | /// writing over cells that belong to other blocks. |
| 1990 | /// |
| 1991 | /// This gate is the WIRNESS stream, not a vacuous one. The 4:2:0 |
| 1992 | /// 4x4-identity is stated in the step's own comment and measured by the |
| 1993 | /// `4:2:0` arm of the lane's invariant battery, not asserted here -- |
| 1994 | /// a 4:2:0 stream cannot fail this gate, by construction, and pretending |
| 1995 | /// otherwise would be a floor on wrong output. |
| 1996 | /// |
| 1997 | /// Fixture `ll444_intrabc_rect_l2.obu`, 121844 bytes, sha256 |
| 1998 | /// `f0de080edce35d34cdd628b71f63dc452f946e8328352b69d3c1da090a54ec67`: |
| 1999 | /// `testsrc2 512x128 yuv444p`, aomenc `--lossless=1 --cpu-used=2 |
| 2000 | /// --lag-in-frames=0 --kf-max-dist=100 --limit=6`, 6 frames. On main's |
| 2001 | /// step this stream is 10604 samples wrong in the KEY frame, first at |
| 2002 | /// byte 33216 (Y(64,448)) -- the corrupted chroma context desyncs the |
| 2003 | /// following luma, which is why the first divergence is luma at all. |
| 2004 | /// |
| 2005 | /// Assertions: |
| 2006 | /// |
| 2007 | /// 1. `(subsampling_x, subsampling_y, bit_depth) == (0, 0, 8)` from the |
| 2008 | /// stream's OWN parsed sequence header. At (1,1) the corrected step |
| 2009 | /// and the old one are the same number, so without this every |
| 2010 | /// assertion below would pass on a stream that cannot fail. |
| 2011 | /// 2. `intrabc_rect_lossless_chroma4_hits()` (lane-whtshape's own |
| 2012 | /// counter) is nonzero -- the replayed arm really ran, so the |
| 2013 | /// corrected expression was evaluated. |
| 2014 | /// 3. the U and V plane extents are luma-sized, which is the geometry |
| 2015 | /// the step indexes into. |
| 2016 | /// 4. `decode_all_frames_vs_oracle`: decode-order frame-count parity, |
| 2017 | /// then byte-exactness on every frame. |
| 2018 | /// |
| 2019 | /// Control: the sibling 128x96 4:4:4 lossless pin, whose blocks are |
| 2020 | /// whole and square, must not take the lossless chroma walk at all -- |
| 2021 | /// its chroma plane block IS one TX_4X4, so there is no step to replay. |
| 2022 | |
| 2023 | |
| 2024 | |
| 2025 | |
| 2026 | |
| 2027 | |
| 2028 | |
| 2029 | |
| 2030 | |
| 2031 | |
| 2032 | |
| 2033 | |
| 2034 | |
| 2035 | |
| 2036 | |
| 2037 | |
| 2038 | |
| 2039 | |
| 2040 | |
| 2041 | |
| 2042 | |
| 2043 | |
| 2044 | |
| 2045 | |
| 2046 | |
| 2047 | |
| 2048 | |
| 2049 | |
| 2050 | |
| 2051 | |
| 2052 | |
| 2053 | |
| 2054 | |
| 2055 | |
| 2056 | |
| 2057 | |
| 2058 | |
| 2059 | |
| 2060 | |
| 2061 | |
| 2062 | |
| 2063 | |
| 2064 | |
| 2065 | |
| 2066 | |
| 2067 | |
| 2068 | |
| 2069 | |
| 2070 | |
| 2071 | |
| 2072 | |
| 2073 | |
| 2074 | |
| 2075 | |
| 2076 | |
| 2077 | |
| 2078 | |
| 2079 | |
| 2080 | |
| 2081 | |
| 2082 | |
| 2083 | |
| 2084 | |
| 2085 | |
| 2086 | |
| 2087 | |
| 2088 | |
| 2089 | |
| 2090 | |
| 2091 | |
| 2092 | |
| 2093 | |
| 2094 | |
| 2095 | |
| 2096 | |
| 2097 | |
| 2098 | |
| 2099 | |
| 2100 | |
| 2101 | |
| 2102 | |
| 2103 | /// lane-av1llpredgate2: the debug-exact pin for the ss-aware |
| 2104 | /// `obmc_skip_chroma_above` decision (lane-av1-llpred2). Fixture is the |
| 2105 | /// llpred/llpred2 reports' stream pinned into `fixtures/`: testsrc2 |
| 2106 | /// 128x96 yuv444p, aomenc `--profile=1 --lossless=1 --enable-palette=0 |
| 2107 | /// --enable-intrabc=0 --min-partition-size=8 --max-partition-size=64`, |
| 2108 | /// 6 frames; 34037 bytes, sha256 |
| 2109 | /// `04fb6d38de5382e647bfb70b6a17802f1fccc5502e6698c0394167891f2b27dc`. |
| 2110 | /// |
| 2111 | /// This is a DEBUG-build path by construction: the old ratio-based ss |
| 2112 | /// derivation read `write_h >> trailing_zeros(0)` = `>> 64` on this |
| 2113 | /// stream's 4:4:4 OBMC rect strips, a panic ONLY under |
| 2114 | /// debug_assertions (release wraps and was already byte-exact), so |
| 2115 | /// `cargo test`'s default dev profile is the profile where the defect |
| 2116 | /// class reproduces and where the parent's byte-exact proof was |
| 2117 | /// measured. |
| 2118 | /// |
| 2119 | /// No skip-arm counter gate is possible on this stream, measured: |
| 2120 | /// OBMC runs 77 times with 20 rect leaves, but |
| 2121 | /// `obmc_skip_chroma_above` returns true 0 times -- at 4:4:4 the skip |
| 2122 | /// needs a 4x4/8x4/4x8 PLANE block and min-partition-8 never codes one. |
| 2123 | /// So per the lane ticket the proof splits in two: the decision TABLE |
| 2124 | /// (4:2:0 rect strips still skip, 4:4:4 shifts never leave `usize`) |
| 2125 | /// stays pinned by `decode::obmc_skip_chroma_tests:: |
| 2126 | /// rect_strips_skip_above_chroma_at_420_and_shift_never_overflows`, |
| 2127 | /// and THIS stream gate pins the end-to-end behaviour -- every sample |
| 2128 | /// of every frame must match the oracle aomdec exactly, so a returning |
| 2129 | /// chroma diff (the lane-av1-llpred ss-blind re-blend class |
| 2130 | /// `obmc-ss-blind-chroma-above`) or the debug shift panic goes red |
| 2131 | /// here by name. |
| 2132 | |
| 2133 | |
| 2134 | |
| 2135 | |
| 2136 | |
| 2137 | |
| 2138 | |
| 2139 | |
| 2140 | |
| 2141 | |
| 2142 | |
| 2143 | |
| 2144 | |
| 2145 | |
| 2146 | |
| 2147 | |
| 2148 | |
| 2149 | |
| 2150 | |
| 2151 | |
| 2152 | |
| 2153 | |
| 2154 | |
| 2155 | |
| 2156 | |
| 2157 | |
| 2158 | |
| 2159 | |
| 2160 | |
| 2161 | |
| 2162 | |
| 2163 | |
| 2164 | |
| 2165 | |
| 2166 | |
| 2167 | |
| 2168 | |
| 2169 | |
| 2170 | |
| 2171 | |
| 2172 | |
| 2173 | |
| 2174 | |
| 2175 | |
| 2176 | |
| 2177 | |
| 2178 | |
| 2179 | |
| 2180 | |
| 2181 | |
| 2182 | |
| 2183 | |
| 2184 | |
| 2185 | |
| 2186 | |
| 2187 | |
| 2188 | |
| 2189 | |
| 2190 | |
| 2191 | |
| 2192 | |
| 2193 | |
| 2194 | |
| 2195 | |
| 2196 | |
| 2197 | |
| 2198 | |
| 2199 | |
| 2200 | |
| 2201 | |
| 2202 | |
| 2203 | |
| 2204 | |
| 2205 | |
| 2206 | |
| 2207 | |
| 2208 | |
| 2209 | |
| 2210 | |
| 2211 | |
| 2212 | |
| 2213 | |
| 2214 | |
| 2215 | |
| 2216 | |
| 2217 | |
| 2218 | |
| 2219 | |
| 2220 | |
| 2221 | |
| 2222 | |
| 2223 | |
| 2224 | |
| 2225 | |
| 2226 | |
| 2227 | |
| 2228 | |
| 2229 | |
| 2230 | |
| 2231 | |
| 2232 | |
| 2233 | |
| 2234 | |
| 2235 | |
| 2236 | |
| 2237 | |
| 2238 | |
| 2239 | |
| 2240 | |
| 2241 | /// lane-av1444altref: the 4:4:4 LOSSLESS + altref chroma residual this |
| 2242 | /// lane closed -- 317 wrong bytes, Y exact, on |
| 2243 | /// `fixtures/ll444_c_altref_leaf8_warp.obu` (512220 bytes, sha256 |
| 2244 | /// `999a41d88a092840456d5e9de83590ab819a8a14686a694889e63c2258ff2bb8`; |
| 2245 | /// the cell is committed here byte for byte, never re-encoded, and its |
| 2246 | /// `aomenc` recipe is still unrecorded -- see |
| 2247 | /// `lanes/av1444altref.report.md`). |
| 2248 | /// |
| 2249 | /// The defect: `decode_inter_block8`'s COMPOUND arm warped its LUMA |
| 2250 | /// intermediates (`warp_affine_compound`) and left BOTH CHROMA arms |
| 2251 | /// translational. libaom warps per PLANE |
| 2252 | /// (`build_inter_predictors_8x8_and_bigger`, |
| 2253 | /// reconinter_template.inc:230, runs `av1_init_warp_params` + |
| 2254 | /// `av1_warp_plane` inside the plane loop with that plane's |
| 2255 | /// subsampling and origin). A GLOBALMV (affine) 8x8 leaf's MV is the |
| 2256 | /// affine's local derivative, so a translation agrees with the warp at |
| 2257 | /// the block's top-left corner and drifts apart toward its bottom-right |
| 2258 | /// -- the measured signature, a bottom-right-biased +/-1 gradient in a |
| 2259 | /// few 8x8 chroma cells of hidden altref pictures while luma stayed exact. |
| 2260 | /// |
| 2261 | /// The assertion is BYTE-EXACTNESS on all three planes of all 16 |
| 2262 | /// displayed frames against the oracle aomdec, never a route counter. The |
| 2263 | /// `flip` arm is the oracle-flip control: it rotates ONE byte of the |
| 2264 | /// oracle's own rawvideo output and requires the same comparator to |
| 2265 | /// report exactly that one sample, so the zeros above are a live |
| 2266 | /// comparison and not an empty or short zip (class |
| 2267 | /// `stale-output-faked-measurement`). `compound_warp_hits_8`'s delta is |
| 2268 | /// the supplementary reachability witness: it proves the 8x8 compound |
| 2269 | /// warp-leaf arm -- the body the fix lives in -- actually ran on this |
| 2270 | /// cell (class `gate-blind-to-feature`). |
| 2271 | |
| 2272 | |
| 2273 | |
| 2274 | |
| 2275 | |
| 2276 | |
| 2277 | |
| 2278 | |
| 2279 | |
| 2280 | |
| 2281 | |
| 2282 | |
| 2283 | |
| 2284 | |
| 2285 | |
| 2286 | |
| 2287 | |
| 2288 | |
| 2289 | |
| 2290 | |
| 2291 | |
| 2292 | |
| 2293 | |
| 2294 | |
| 2295 | |
| 2296 | |
| 2297 | |
| 2298 | |
| 2299 | |
| 2300 | |
| 2301 | |
| 2302 | |
| 2303 | |
| 2304 | |
| 2305 | |
| 2306 | |
| 2307 | |
| 2308 | |
| 2309 | |
| 2310 | |
| 2311 | |
| 2312 | |
| 2313 | |
| 2314 | |
| 2315 | |
| 2316 | |
| 2317 | |
| 2318 | |
| 2319 | |
| 2320 | |
| 2321 | |
| 2322 | |
| 2323 | |
| 2324 | |
| 2325 | |
| 2326 | |
| 2327 | |
| 2328 | |
| 2329 | |
| 2330 | |
| 2331 | |
| 2332 | |
| 2333 | |
| 2334 | |
| 2335 | |
| 2336 | |
| 2337 | |
| 2338 | |
| 2339 | |
| 2340 | |
| 2341 | |
| 2342 | |
| 2343 | |
| 2344 | |
| 2345 | |
| 2346 | |
| 2347 | |
| 2348 | |
| 2349 | |
| 2350 | |
| 2351 | |
| 2352 | |
| 2353 | |
| 2354 | |
| 2355 | |
| 2356 | |
| 2357 | /// lane-av1-444sb: the byte-exact pin for the ss-aware 128-rect chroma |
| 2358 | /// unit walk (`decode_block_128rect`). The parent walk hardcoded the |
| 2359 | /// 4:2:0 mu-chunk span -- one 32x32 chroma unit per 64x64 chunk, chunk |
| 2360 | /// offsets `*32`, clip step `*8` -- so at 4:4:4 a 128-root HORZ/VERT |
| 2361 | /// intra block coded HALF its chroma units, left the remaining units' |
| 2362 | /// coefficients unread and desynced the tile from the first such block |
| 2363 | /// on; every superblock after SB(0,0) carried damage and the chroma |
| 2364 | /// first-diffs sat on the 64/128 grid. |
| 2365 | /// |
| 2366 | /// `crates/ec-av1/fixtures/444_sb128rect_lr_witness.obu`, 794 bytes, |
| 2367 | /// sha256 |
| 2368 | /// `27825e14633a4b23e37d48a2acdc7f5d814ca4fadd0b8797d72a1ffb34061e80`: |
| 2369 | /// `ffmpeg -i bands444.y4m -frames:v 3 -vf scale=192:160 -pix_fmt |
| 2370 | /// yuv444p -f yuv4mpegpipe` piped to `aomenc --codec=av1 --profile=1 |
| 2371 | /// --passes=1 --end-usage=q --cq-level=32 --cpu-used=0 --threads=1 |
| 2372 | /// --row-mt=0 --sb-size=128 --lag-in-frames=0 --auto-alt-ref=0 |
| 2373 | /// --kf-max-dist=1000 --i444 --enable-restoration=1 --obu --limit=3`. |
| 2374 | /// Real content is required: the synthetic lavfi sources this lane swept |
| 2375 | /// (testsrc2/testsrc/smptebars/mandelbrot/gradients) all decode frame 0 |
| 2376 | /// exact because they never force a 128-root rect; bands does (kf |
| 2377 | /// PARTITION_VERT 64x128 at mi(0,32) plus an intra-in-inter 64x128). |
| 2378 | /// |
| 2379 | /// Non-vacuity via the `decode::intra_sb128_hits` delta: a stream that |
| 2380 | /// stopped coding 128-axis intra blocks reads 0 and the gate fails |
| 2381 | /// instead of passing over a decode that never reached the fixed body |
| 2382 | /// (class `gate-blind-to-feature`). The oracle arms pin every sample of |
| 2383 | /// every frame against both aomdec and ffmpeg, so a returning chroma |
| 2384 | /// span regression goes red here by name. |
| 2385 | |
| 2386 | |
| 2387 | |
| 2388 | |
| 2389 | |
| 2390 | |
| 2391 | |
| 2392 | |
| 2393 | |
| 2394 | |
| 2395 | |
| 2396 | |
| 2397 | |
| 2398 | |
| 2399 | |
| 2400 | |
| 2401 | |
| 2402 | |
| 2403 | |
| 2404 | |
| 2405 | |
| 2406 | |
| 2407 | |
| 2408 | |
| 2409 | |
| 2410 | |
| 2411 | |
| 2412 | |
| 2413 | |
| 2414 | |
| 2415 | |
| 2416 | |
| 2417 | |
| 2418 | |
| 2419 | |
| 2420 | |
| 2421 | |
| 2422 | |
| 2423 | |
| 2424 | |
| 2425 | |
| 2426 | |
| 2427 | |
| 2428 | |
| 2429 | |
| 2430 | |
| 2431 | |
| 2432 | |
| 2433 | |
| 2434 | |
| 2435 | |
| 2436 | |
| 2437 | |
| 2438 | |
| 2439 | |
| 2440 | |
| 2441 | |
| 2442 | |
| 2443 | |
| 2444 | |
| 2445 | |
| 2446 | |
| 2447 | |
| 2448 | |
| 2449 | |
| 2450 | |
| 2451 | |
| 2452 | |
| 2453 | |
| 2454 | |
| 2455 | |
| 2456 | |
| 2457 | |
| 2458 | |
| 2459 | |
| 2460 | |
| 2461 | |
| 2462 | |
| 2463 | |
| 2464 | |
| 2465 | |
| 2466 | |
| 2467 | |
| 2468 | |
| 2469 | |
| 2470 | |
| 2471 | |
| 2472 | |
| 2473 | |
| 2474 | |
| 2475 | |
| 2476 | |
| 2477 | |
| 2478 | |
| 2479 | |
| 2480 | |
| 2481 | |
| 2482 | |
| 2483 | |
| 2484 | |
| 2485 | |
| 2486 | |
| 2487 | |
| 2488 | |
| 2489 | |
| 2490 | |
| 2491 | |
| 2492 | |
| 2493 | |
| 2494 | |
| 2495 | |
| 2496 | |
| 2497 | |
| 2498 | |
| 2499 | |
| 2500 | |
| 2501 | |
| 2502 | |
| 2503 | |
| 2504 | |
| 2505 | |
| 2506 | |
| 2507 | |
| 2508 | |
| 2509 | |
| 2510 | |
| 2511 | |
| 2512 | |
| 2513 | |
| 2514 | |
| 2515 | |
| 2516 | |
| 2517 | |
| 2518 | |
| 2519 | |
| 2520 | |
| 2521 | |
| 2522 | |
| 2523 | |
| 2524 | |
| 2525 | |
| 2526 | |
| 2527 | |
| 2528 | |
| 2529 | |
| 2530 | |
| 2531 | |
| 2532 | |
| 2533 | |
| 2534 | |
| 2535 | |
| 2536 | |
| 2537 | |
| 2538 | |
| 2539 | |
| 2540 | |
| 2541 | |
| 2542 | |
| 2543 | |
| 2544 | |
| 2545 | |
| 2546 | |
| 2547 | |
| 2548 | |
| 2549 | |
| 2550 | |
| 2551 | |
| 2552 | /// lane-av1444rect (H1): the 4:4:4 LOSSY cell with a 1:4 (HORZ_4 / |
| 2553 | /// VERT_4) partition -- the largest correctness gap the chroma-format |
| 2554 | /// sweep left, and the first 4:4:4 lossy exactness gate in the crate. |
| 2555 | /// |
| 2556 | /// **The defect.** `decode_inter_block`'s `around_c` gathered a 1:4 |
| 2557 | /// strip's chroma coefficient context at the 4:2:0 PAIR extent |
| 2558 | /// (`(16, 8)` HORZ / `(8, 16)` VERT) with no `ss` gate, so at ss (0,0) |
| 2559 | /// it read one extra luma mi row of LEFT chroma context. At 4:4:4 |
| 2560 | /// `is_chroma_reference` (av1_common_int.h:1454) reduces both parity |
| 2561 | /// clauses to `!subsampling_y` / `!subsampling_x`, so every block is its |
| 2562 | /// own chroma reference and no pair exists: the strip codes its own |
| 2563 | /// 16x4 chroma over its own context. Our U unit's `get_txb_ctx` then saw |
| 2564 | /// a neighbour libaom does not have, and the arithmetic coder forked. |
| 2565 | /// |
| 2566 | /// **The recipe** (sha256 |
| 2567 | /// `77f727e76d81fe48cd03709f799131677c04869b163e18d78e96bc742ec69153`, |
| 2568 | /// 6441 bytes, 2 frames, `testsrc2 128x96 rate=25` yuv444p): |
| 2569 | /// ```text |
| 2570 | /// ffmpeg -f lavfi -i "testsrc2=size=128x96:rate=25" -frames:v 2 \ |
| 2571 | /// -pix_fmt yuv444p -f yuv4mpegpipe - | \ |
| 2572 | /// aomenc --codec=av1 --profile=1 --passes=1 --end-usage=q --cq-level=20 \ |
| 2573 | /// --cpu-used=2 --threads=1 --row-mt=0 --lag-in-frames=0 \ |
| 2574 | /// --kf-max-dist=100 --limit=2 - out.obu |
| 2575 | /// ``` |
| 2576 | /// (`rate=25` is load-bearing: `testsrc2`'s pattern is time-parameterised, |
| 2577 | /// so `rate=1` produces a different, already-exact stream.) |
| 2578 | /// |
| 2579 | /// Red before the fix: frame 1, 8884 of 36864 samples wrong, first at |
| 2580 | /// Y(91,32); the first wrong symbol was read 26263 of the frame, both |
| 2581 | /// sides at mi (8,16) -- ours a luma-shaped `txb_skip` row (our |
| 2582 | /// re-indexed chroma ctx 1), the oracle `decodetxb.c:158` on the U plane |
| 2583 | /// with `txb_skip_ctx = 7`. |
| 2584 | /// |
| 2585 | /// Non-vacuity, three ways: the pinned stream must really be ss (0,0) |
| 2586 | /// (asserted through the oracle aomdec's own sequence header, below); |
| 2587 | /// `decode::rect4_inter_own_chroma444_hits()` must be non-zero, so the |
| 2588 | /// 1:4-strip route the fix sits on really ran; and the SAME source and |
| 2589 | /// flags at 4:2:0 must leave that counter at zero, which is what makes |
| 2590 | /// it the 4:4:4-only route rather than a tally every strip bumps. |
| 2591 | |
| 2592 | |
| 2593 | |
| 2594 | |
| 2595 | |
| 2596 | |
| 2597 | |
| 2598 | |
| 2599 | |
| 2600 | |
| 2601 | |
| 2602 | |
| 2603 | |
| 2604 | |
| 2605 | |
| 2606 | |
| 2607 | |
| 2608 | |
| 2609 | |
| 2610 | |
| 2611 | |
| 2612 | |
| 2613 | |
| 2614 | |
| 2615 | |
| 2616 | |
| 2617 | |
| 2618 | |
| 2619 | |
| 2620 | |
| 2621 | |
| 2622 | |
| 2623 | |
| 2624 | |
| 2625 | |
| 2626 | |
| 2627 | |
| 2628 | |
| 2629 | |
| 2630 | |
| 2631 | |
| 2632 | |
| 2633 | |
| 2634 | |
| 2635 | |
| 2636 | |
| 2637 | |
| 2638 | |
| 2639 | |
| 2640 | |
| 2641 | |
| 2642 | |
| 2643 | |
| 2644 | |
| 2645 | |
| 2646 | |
| 2647 | |
| 2648 | |
| 2649 | |
| 2650 | |
| 2651 | |
| 2652 | |
| 2653 | |
| 2654 | |
| 2655 | |
| 2656 | |
| 2657 | |
| 2658 | |
| 2659 | |
| 2660 | |
| 2661 | |
| 2662 | |
| 2663 | |
| 2664 | |
| 2665 | |
| 2666 | |
| 2667 | |
| 2668 | |
| 2669 | |
| 2670 | |
| 2671 | |
| 2672 | |
| 2673 | |
| 2674 | |
| 2675 | |
| 2676 | |
| 2677 | |
| 2678 | |
| 2679 | |
| 2680 | |
| 2681 | |
| 2682 | |
| 2683 | |
| 2684 | |
| 2685 | |
| 2686 | |
| 2687 | |
| 2688 | |
| 2689 | |
| 2690 | |
| 2691 | |
| 2692 | |
| 2693 | |
| 2694 | |
| 2695 | |
| 2696 | |
| 2697 | |
| 2698 | |
| 2699 | |
| 2700 | |
| 2701 | |
| 2702 | |
| 2703 | |
| 2704 | |
| 2705 | |
| 2706 | |
| 2707 | |
| 2708 | |
| 2709 | |
| 2710 | |
| 2711 | |
| 2712 | |
| 2713 | |
| 2714 | |
| 2715 | |
| 2716 | |
| 2717 | |
| 2718 | |
| 2719 | |
| 2720 | |
| 2721 | |
| 2722 | |
| 2723 | |
| 2724 | |
| 2725 | |
| 2726 | |
| 2727 | |
| 2728 | |
| 2729 | |
| 2730 | /// lane-av1gates444 cell 1: **odd coded dims, 66x66** -- the partial-frame |
| 2731 | /// walk in BOTH axes (66 is not a multiple of 8, so the frame is a |
| 2732 | /// partial superblock column AND a partial row). Measured EXACT 4/4 by |
| 2733 | /// the chroma-format sweep (§6.2, 5938 bytes) and unpinned: nothing in |
| 2734 | /// the crate would go red if the odd-dimension 4:4:4 walk regressed, |
| 2735 | /// and the only red-before evidence was a lane report nobody re-runs. |
| 2736 | |
| 2737 | |
| 2738 | |
| 2739 | |
| 2740 | |
| 2741 | /// lane-av1gates444 cell 2: **odd coded dims, 130x122** -- the |
| 2742 | /// partial-frame RIGHT edge that the sweep found DIVERGENT (first wrong |
| 2743 | /// sample Y(128,16), 11521 samples on frame 3) until lane-av1444rect's |
| 2744 | /// 4:4:4 own-chroma-extent fix landed. It measures EXACT 4/4 on this |
| 2745 | /// tree and is the discriminating geometry: 66x66 was exact at the same |
| 2746 | /// settings while this was not, so the pair is what keeps "the 4:4:4 |
| 2747 | /// partial-frame walk is right" from being a one-geometry accident. |
| 2748 | |
| 2749 | |
| 2750 | |
| 2751 | |
| 2752 | |
| 2753 | |
| 2754 | |
| 2755 | |
| 2756 | |
| 2757 | /// lane-av1gates444 cell 3: **256x128**, the sweep's cell recorded as |
| 2758 | /// "4:4:4 superres 256x128 (`--superres-mode=1`)". |
| 2759 | /// |
| 2760 | /// IT IS NOT A SUPERRES CELL, and this gate is named for what it is |
| 2761 | /// instead. Measured here, live: encoding 256x128 with and without |
| 2762 | /// `--superres-mode=1` produces BYTE-IDENTICAL OBU (15239 bytes, |
| 2763 | /// sha256 06621606…, both), so the flag is a no-op on this aomenc build |
| 2764 | /// and the sweep's cell was a plain 4:4:4 lossy cq-20 stream that |
| 2765 | /// happened to carry the flag. The cell's actual value is the geometry |
| 2766 | /// plus the filter stages: 256x128 is two full 128 superblock columns, |
| 2767 | /// and the strip walk runs there with the post-deblock/CDEF/LR chain |
| 2768 | /// live on the later frames -- so this is the third witness for the |
| 2769 | /// 4:4:4 lossy strip class at a geometry the 128x96 rect4 gate does not |
| 2770 | /// cover. |
| 2771 | |
| 2772 | |
| 2773 | |
| 2774 | |
| 2775 | |
| 2776 | /// lane-av1txctxband — the 4:4:4 lossy `--sb-size=128` stream whose |
| 2777 | /// `EC_SYMR` ladder forked at read 32813, and the gate that makes the fix |
| 2778 | /// non-vacuous. |
| 2779 | /// |
| 2780 | /// **The defect.** `get_tx_size_context` (libaom |
| 2781 | /// `av1/common/pred_common.h:361-370`) gates its "an inter neighbour |
| 2782 | /// contributes its own BLOCK size" override on `xd->above_mbmi` / |
| 2783 | /// `xd->left_mbmi`, which `set_mi_offsets` |
| 2784 | /// (`av1_common_int.h:1381-1389`) takes as `xd->mi[-xd->mi_stride]` / |
| 2785 | /// `xd->mi[-1]`. `setup_mbs` (`decodeframe.c:355-361`) writes the covering |
| 2786 | /// block's own `MB_MODE_INFO` pointer into EVERY mi cell the block covers, |
| 2787 | /// so libaom's granularity is the covering block PER CELL. This decoder |
| 2788 | /// read the per-COLUMN `above_inter`/`left_inter` bands and the matching |
| 2789 | /// `above_side_mi`/`left_side_mi` bands instead — the LAST block written in |
| 2790 | /// that column, which names the abutting block only for the block directly |
| 2791 | /// below it. On this witness the 8x4 intra leaf at mi(57,52) (SB row 1, |
| 2792 | /// col 1) read a stale `above_inter=true` with `above_side=4`, took the |
| 2793 | /// override, got `above = (4 >= 8) = 0` where libaom keeps |
| 2794 | /// `above = (above_txfm_context[0] >= 8) = 1`, and read |
| 2795 | /// `tx_size_cat0[1]` where libaom reads `tx_size_cdf[...][2]`. |
| 2796 | /// |
| 2797 | /// **The fork signature that identifies it** (a CDF-row error, not a |
| 2798 | /// unit-enumeration one): the two sides held the IDENTICAL pre-state |
| 2799 | /// `pre=(7550, 45492)` and the IDENTICAL width/value `n=2 s=1`; only |
| 2800 | /// `cdf0` differed, ours 6424 (`32768-6424 = 26344`) vs the oracle's |
| 2801 | /// 19938, so the ICDF mirror convention does not reconcile it either. |
| 2802 | /// |
| 2803 | /// **Non-vacuity.** The pixel assert alone would be green on the old code |
| 2804 | /// for any stream where the bands happened to be right, so the gate also |
| 2805 | /// asserts `txctx_inter_cell_band_divergence_hits() > 0` — the number of |
| 2806 | /// `get_tx_size_context` reads where the per-CELL cover and the |
| 2807 | /// per-COLUMN band DISAGREE, i.e. exactly the reads the old code resolved |
| 2808 | /// off a different CDF row. Reverting either reader to the bands drives |
| 2809 | /// this to 0 and the gate red, with the oracle compare as the second, |
| 2810 | /// independent arm. |
| 2811 | /// |
| 2812 | /// **Fixture provenance** (`444_lossy_sb128_txctx_witness.obu`, 6186 B, |
| 2813 | /// sha256 `14acb74e825a2bb3ef195a52cc2abc67794d9c4d92080b66c739d318177fc7c6`): |
| 2814 | /// ```text |
| 2815 | /// ffmpeg -f lavfi -i "testsrc2=size=256x256:rate=25" -frames:v 2 \ |
| 2816 | /// -pix_fmt yuv444p -strict -1 -f yuv4mpegpipe -y src.y4m |
| 2817 | /// aomenc --codec=av1 --passes=1 --end-usage=q --cq-level=62 --cpu-used=2 \ |
| 2818 | /// --threads=1 --row-mt=0 --lag-in-frames=0 --kf-max-dist=100 \ |
| 2819 | /// --sb-size=128 --profile=1 --obu -o t256.obu src.y4m |
| 2820 | /// ``` |
| 2821 | /// 256x256 is the smallest geometry that gives `--sb-size=128` a SECOND |
| 2822 | /// superblock row and column, which is where the stale band bites: a cell |
| 2823 | /// whose abutting block is not the last block written in its column. The |
| 2824 | /// cq level is load-bearing — this cell is entropy-exact at cq 20..58 and |
| 2825 | /// forks at 54/56/60/62 depending on the frame count (12 of the 99 cells |
| 2826 | /// swept in `lanes/av1txctxband.report.md` §4 forked, all of them at |
| 2827 | /// cq >= 54 on 256x256/320x240/256x384). `--sb-size=128` is load-bearing |
| 2828 | /// too: at the default 64 the two superblock columns are 4 mi wide, so a |
| 2829 | /// column band and a per-cell cover coincide for every 4-column run. |
| 2830 | |
| 2831 | |
| 2832 | |
| 2833 | |
| 2834 | |
| 2835 | |
| 2836 | |
| 2837 | |
| 2838 | |
| 2839 | |
| 2840 | |
| 2841 | |
| 2842 | |
| 2843 | |
| 2844 | |
| 2845 | |
| 2846 | |
| 2847 | |
| 2848 | |
| 2849 | |
| 2850 | |
| 2851 | |
| 2852 | |
| 2853 | |
| 2854 | |
| 2855 | |
| 2856 | |
| 2857 | |
| 2858 | |
| 2859 | |
| 2860 | |
| 2861 | |
| 2862 | |
| 2863 | |
| 2864 | |
| 2865 | |
| 2866 | |
| 2867 | |
| 2868 | |
| 2869 | |
| 2870 | |
| 2871 | /// lane-arfchroma: 4:2:0 **lossless** with an alt-ref frame and 1:4 inter |
| 2872 | /// strips. Ordinary, user-reachable aomenc output, no bypass: before the |
| 2873 | /// fix this cell diverged in 15 of 16 shown frames (1 088 573 wrong |
| 2874 | /// samples, only frames 0-1 exact) or -- one knob away, e.g. |
| 2875 | /// `--sb-size=64`, `--enable-dual-filter=0`, `--max-reference-frames=3`, |
| 2876 | /// or the same stream cut to 5-12 frames -- REFUSED outright with |
| 2877 | /// `a Golomb tail longer than this decoder reads`. The refusal was this |
| 2878 | /// divergence arriving at a named guard, not an independent gap: the |
| 2879 | /// `16-frame` variant of this exact cell now decodes byte-exact. |
| 2880 | /// |
| 2881 | /// Mechanism (paired rungs, `EC_COEFF_STEP` / `EC_ECDUMP` against |
| 2882 | /// aomdec, 320x240, 5 frames): the first forked read is frame 2's 8x8 |
| 2883 | /// inter block at mi (4,0) (ref0 = 7 = ALTREF, mv (36,0), NEWMV), its |
| 2884 | /// CHROMA U `txb_skip` read. All four LUMA units match read for read, and |
| 2885 | /// the chroma read's pre-state `(rng 35592)` is IDENTICAL on both sides -- |
| 2886 | /// only the context differs: ours 2, libaom 8 |
| 2887 | /// (`7 + get_entropy_context`, `txb_common.h:360`). `EC_ECDUMP` names the |
| 2888 | /// cause: libaom's chroma left neighbour is `[0]` and ours is coded. The |
| 2889 | /// publisher is the 16x4 (1:4) strip above it: `record_mi_chroma` |
| 2890 | /// published the unit at the BLOCK's mi origin, but a 4x4 chroma unit is |
| 2891 | /// `1 << ss` luma mi per axis, so a strip whose mi row is ODD at 4:2:0 |
| 2892 | /// starts mid-cell and its state landed one mi row too low -- into the |
| 2893 | /// cell of the block that read it. libaom's per-plane |
| 2894 | /// `left/above_context_map` is indexed in the PLANE's own 4x4 units |
| 2895 | /// (`entropy.h:87`, `txb_common.h:429`), so the cell's origin is the |
| 2896 | /// step-aligned mi, which is what the fix aligns to. |
| 2897 | /// |
| 2898 | /// The gate asserts three things, in this order: the pin's identity, the |
| 2899 | /// mid-cell route counter (so it cannot pass on a stream whose chroma |
| 2900 | /// units all start on a cell boundary -- class |
| 2901 | /// gate-blind-to-feature), and then BOTH comparisons: decode order |
| 2902 | /// (which sees the hidden alt-ref frame no shown-frame gate can) and the |
| 2903 | /// per-plane shown-frame count. |
| 2904 | /// |
| 2905 | /// Recipe (both sides reproducible, 28394 bytes): |
| 2906 | /// ```text |
| 2907 | /// ffmpeg -f lavfi -i testsrc2=size=320x240:rate=25 -frames:v 5 \ |
| 2908 | /// -pix_fmt yuv420p y.yuv |
| 2909 | /// aomenc --codec=av1 --obu --lossless=1 -w 320 -h 240 \ |
| 2910 | /// --lag-in-frames=25 --auto-alt-ref=1 --limit=5 -o w.obu y.yuv |
| 2911 | /// ``` |
| 2912 | /// sha256 c5507ed97f74ca495b71449fda24f5fe2fcfa34eed38988a69141d45b126627c. |
| 2913 | /// The tree pins fixture identity by fnv1a64; a `const SHA256` compared |
| 2914 | /// against itself would be the tautology lane-av1422anom exists to kill. |
| 2915 | |
| 2916 | |
| 2917 | |
| 2918 | |
| 2919 | |
| 2920 | |
| 2921 | |
| 2922 | |
| 2923 | |
| 2924 | |
| 2925 | |
| 2926 | |
| 2927 | |
| 2928 | |
| 2929 | |
| 2930 | |
| 2931 | |
| 2932 | |
| 2933 | |
| 2934 | |
| 2935 | |
| 2936 | |
| 2937 | |
| 2938 | |
| 2939 | |
| 2940 | |
| 2941 | |
| 2942 | |
| 2943 | |
| 2944 | |
| 2945 | |
| 2946 | |
| 2947 | |
| 2948 | |
| 2949 | |
| 2950 | |
| 2951 | |
| 2952 | |
| 2953 | |
| 2954 | |
| 2955 | |
| 2956 | |
| 2957 | |
| 2958 | |
| 2959 | |
| 2960 | |
| 2961 | |
| 2962 | |
| 2963 | /// lane-av1mixllfork: per-segment MIXED LOSSLESS + an alt-ref structure. |
| 2964 | /// The first fork was entropy read **30889** of f1 (paired `EC_SYMR`: |
| 2965 | /// identical `pre[0..1]`, `n`, `s` on both sides, `post_rng` 42076 vs |
| 2966 | /// 54010), and the pre-fix `cdf0` at that read was 22401 vs the oracle's |
| 2967 | /// 15299 -- **not** the usual `32768 - x` ICDF mirror, i.e. two different |
| 2968 | /// reads, not one wrong CDF row. |
| 2969 | /// |
| 2970 | /// What each side read there: libaom `decodetxb.c:158`, the luma `txb_skip` |
| 2971 | /// of a TX_4X4 unit at `mi=(6,1)` `bc=0 br=0`; ours an untagged `n=2` |
| 2972 | /// symbol that a `set_symr_cdf` sweep over all six MV-stack copies |
| 2973 | /// (`ii16/newmv16/…/refmvB`, `inter8` phase inherited) ruled out as every |
| 2974 | /// inter mode-info read, leaving the one read that block makes *between* |
| 2975 | /// its `refmv` and its coefficients: the var-tx tree's `tx_size_cat1`. |
| 2976 | /// libaom's own reason it reads nothing: `parse_decode_block` |
| 2977 | /// (`decodeframe.c:1237`) carries `!xd->lossless[mbmi->segment_id]` as a |
| 2978 | /// **conjunct** of the tx-mode-select condition, and `read_tx_size` |
| 2979 | /// (`:1208`) answers TX_4X4 on the same flag. This tree tested |
| 2980 | /// `tx_select && !skip` and put `lossless(fctx) && !skip` in the `else if` |
| 2981 | /// arm instead, so on a lossless SEGMENT of a mixed-lossless frame it read |
| 2982 | /// a `tx_size_cat1` symbol libaom never reads, and the very next block's |
| 2983 | /// `txb_skip` forked. `SUB8_LOSSLESS_NO_VARTX` counts the leaves that |
| 2984 | /// newly take the lossless arm, so this gate cannot pass vacuously on a |
| 2985 | /// stream whose sub-8 leaves all sit in lossy segments. (Corrected |
| 2986 | /// 2026-09-30: the counter is now guarded on `tx_select_inter`, because the |
| 2987 | /// refutation pass measured 33 hits on a build with the conjunct REMOVED -- |
| 2988 | /// the arm also serves leaves whose tx-select is off. The pin's own delta |
| 2989 | /// is 10, not the 40 the lane first reported; both numbers are measured.) |
| 2990 | /// |
| 2991 | /// The trigger really is the CONJUNCTION: `--cq-level=0` with AQ makes |
| 2992 | /// *some* segments lossless and others not (`--cq-level=20`, `--cq-level=32`, |
| 2993 | /// `--lossless=1` and `--aq-mode=0` are all byte-exact on this recipe), and |
| 2994 | /// `--auto-alt-ref=0` makes it exact at 5, 6, 8 and 12 frames. After the |
| 2995 | /// fix the whole-stream `EC_SYMR` ladder is bit-identical: **96997 reads, |
| 2996 | /// 96997 paired, zero divergence** -- not just up to the fork. |
| 2997 | /// |
| 2998 | /// Recipe (ffmpeg 8.1.3 `testsrc2`, shared oracle `aomenc`, 18525 bytes): |
| 2999 | /// ```text |
| 3000 | /// ffmpeg -f lavfi -i testsrc2=size=256x128:rate=25 -frames:v 5 \ |
| 3001 | /// -pix_fmt yuv420p src5b.y4m |
| 3002 | /// aomenc --codec=av1 --obu -o c_mix5.obu --passes=1 --cpu-used=4 \ |
| 3003 | /// --limit=5 --end-usage=q --cq-level=0 --aq-mode=1 src5b.y4m |
| 3004 | /// ``` |
| 3005 | /// sha256 `3e06b5641e6a0f5a3f4ac8f114d4ee48c88638429e9eaafe6b4483e24f1dbc3a`. |
| 3006 | /// The tree pins fixture identity by fnv1a64; a `const SHA256` compared |
| 3007 | /// against itself would be the tautology lane-av1422anom exists to kill. |
| 3008 | |
| 3009 | |
| 3010 | |
| 3011 | |
| 3012 | |
| 3013 | |
| 3014 | |
| 3015 | |
| 3016 | |
| 3017 | |
| 3018 | |
| 3019 | |
| 3020 | |
| 3021 | |
| 3022 | |
| 3023 | |
| 3024 | |
| 3025 | |
| 3026 | |
| 3027 | |
| 3028 | |
| 3029 | |
| 3030 | |
| 3031 | |
| 3032 | |
| 3033 | |
| 3034 | |
| 3035 | |
| 3036 | |
| 3037 | |
| 3038 | |
| 3039 | |
| 3040 | |
| 3041 | |
| 3042 | |
| 3043 | |
| 3044 | |
| 3045 | |
| 3046 | |
| 3047 | |
| 3048 | |
| 3049 | |
| 3050 | |
| 3051 | |
| 3052 | |
| 3053 | |
| 3054 | /// lane-av1txctxband2: the 640x480 cell of the same mixed-lossless |
| 3055 | /// recipe — the THIRD defect `lanes/av1mixllconj.report.md` §4.3 / |
| 3056 | /// §11 handed over, class `context-band-not-published`. |
| 3057 | /// |
| 3058 | /// libaom's `parse_decode_block` (`decodeframe.c:1251-1261`) is an |
| 3059 | /// EITHER/OR: the var-tx branch's condition carries |
| 3060 | /// `!xd->lossless[mbmi->segment_id]` as a conjunct, and the `else` branch |
| 3061 | /// runs `read_tx_size` **and then `set_txfm_ctxs`**. `read_tx_size`'s |
| 3062 | /// FIRST line (`decodeframe.c:1214`) returns `TX_4X4` on a lossless |
| 3063 | /// segment — so a lossless block skips the symbol read, NOT the publish. |
| 3064 | /// This decoder's `read_block_tx_size` returned from its own lossless early |
| 3065 | /// return with nothing written, so on a MIXED frame every lossless square |
| 3066 | /// block left the `TXFM_CONTEXT` above band holding whatever an earlier, |
| 3067 | /// lossy block had put there. The RECT twin (`read_block_tx_size_rect`) |
| 3068 | /// has published on the same arm since lane-av1lm444loss; only the square |
| 3069 | /// arm had the hole. |
| 3070 | /// |
| 3071 | /// Measured on `420_mixll_altref_640x480_5f.obu`: the abutting 8x8 INTRA |
| 3072 | /// lossless block at mi(78,110) left `above_txfm[110]` at the 16 a skipped |
| 3073 | /// 16-px inter block at mi(36,108) had written 43 mi rows earlier, and the |
| 3074 | /// 8x4 intra leaf with `use_filter_intra` at mi(80,110) then read |
| 3075 | /// `tx_size_cat0[2]` where libaom reads row 1 — the oracle's own |
| 3076 | /// `EC_TXCTXB` prints `mi=80,110 abv=4 lft=8 above=0 left=1 ctx=1` against |
| 3077 | /// our `above_txfm=16 left_txfm=8 above=1 left=1 ctx=2`. The tile desynced |
| 3078 | /// there and the frame REFUSED (`a Golomb tail longer than this decoder |
| 3079 | /// reads`); at base the same cell decoded every frame but got 70–92 % of |
| 3080 | /// every inter frame wrong. |
| 3081 | /// |
| 3082 | /// `LOSSLESS_SQ_TXFM_BAND_OVERWRITE_HITS` counts the lossless square inter |
| 3083 | /// blocks whose publish actually OVERWROTE a size an earlier block of the |
| 3084 | /// same frame had left in the column — so the gate cannot pass vacuously |
| 3085 | /// on a stream that merely decodes a lossless fixture. After the fix the |
| 3086 | /// whole-stream paired `EC_SYMR` ladder is bit-identical: **457 907 reads, |
| 3087 | /// 457 907 paired, zero divergence** — not just up to the fork. |
| 3088 | /// |
| 3089 | /// Recipe (ffmpeg 8.1.3 `testsrc2`, shared oracle `aomenc`, 87537 bytes): |
| 3090 | /// ```text |
| 3091 | /// ffmpeg -f lavfi -i testsrc2=size=640x480:rate=25 -frames:v 5 \ |
| 3092 | /// -pix_fmt yuv420p src640.y4m |
| 3093 | /// aomenc --codec=av1 --obu -o 420_mixll_altref_640x480_5f.obu --passes=1 \ |
| 3094 | /// --cpu-used=4 --limit=5 --end-usage=q --cq-level=0 --aq-mode=1 src640.y4m |
| 3095 | /// ``` |
| 3096 | /// sha256 `3d505fd2e0bbb7ca3680a8e338d712a81defc947b955a4b7b82de6718301e73c`; |
| 3097 | /// the tree pins fixture identity by fnv1a64, not a `const SHA256` compared |
| 3098 | /// against itself. |
| 3099 | |
| 3100 | |
| 3101 | |
| 3102 | |
| 3103 | |
| 3104 | |
| 3105 | |
| 3106 | |
| 3107 | |
| 3108 | |
| 3109 | |
| 3110 | |
| 3111 | |
| 3112 | |
| 3113 | |
| 3114 | |
| 3115 | |
| 3116 | |
| 3117 | |
| 3118 | |
| 3119 | |
| 3120 | |
| 3121 | |
| 3122 | |
| 3123 | |
| 3124 | |
| 3125 | |
| 3126 | |
| 3127 | |
| 3128 | |
| 3129 | |
| 3130 | |
| 3131 | |
| 3132 | |
| 3133 | |
| 3134 | |
| 3135 | |
| 3136 | |
| 3137 | |
| 3138 | |
| 3139 | |
| 3140 | |
| 3141 | |
| 3142 | |
| 3143 | |
| 3144 | |
| 3145 | |
| 3146 | /// lane-av1txctxband2 r2: the SAME one-line publish, three MORE cells — |
| 3147 | /// the mixed-lossless RESIDUE `lanes/av1mixllconj.report.md` §7 left |
| 3148 | /// explicitly unnamed ("separate defects this change shrinks but does not |
| 3149 | /// remove"). **They are the same defect.** All three are this recipe's |
| 3150 | /// mixed-lossless+altref stream at 256x128 (6 frames) and 320x240 (5 and 6 |
| 3151 | /// frames); each has a lossy block whose `get_tx_size_context` / |
| 3152 | /// `txfm_partition_context` read a band a lossless block above should have |
| 3153 | /// published into and did not. |
| 3154 | /// |
| 3155 | /// Measured on `f2dd27b0~1` (= `0bfee517`, the tip before this lane's |
| 3156 | /// publish) against `aomdec`'s `EC_AV1_FINAL_DUMP`, decode order, per |
| 3157 | /// differing frame: |
| 3158 | /// |
| 3159 | /// ```text |
| 3160 | /// 420_mixll_256x128_6f.obu 7 dumps red f1..f6: 6051 / 4115 / 2962 / 26566 / 41876 / 14749 |
| 3161 | /// 420_mixll_320x240_5f.obu 6 dumps red f1..f5: 15031 / 16259 / 21932 / 65405 / 90077 |
| 3162 | /// 420_mixll_320x240_6f.obu 7 dumps red f6 only: 19398 |
| 3163 | /// ``` |
| 3164 | /// |
| 3165 | /// With the publish: **7/7, 6/6 and 7/7 byte-exact**, 0 differing bytes on |
| 3166 | /// every plane of every decode-order frame. `m5_320x240`'s f2/f3 here |
| 3167 | /// (16259 / 21932) differ from the 16006 / 21930 `lane-av1mixllconj` §7 |
| 3168 | /// records, because that table was taken before `lane-av1offtile`'s |
| 3169 | /// chroma-plane clip merged; f1/f4/f5 and both other cells match it exactly. |
| 3170 | /// |
| 3171 | /// Recipe (ffmpeg 8.1.3 `testsrc2`, shared oracle `aomenc`; `--limit` is the |
| 3172 | /// only variable per cell): |
| 3173 | /// ```text |
| 3174 | /// ffmpeg -f lavfi -i testsrc2=size=<W>x<H>:rate=25 -frames:v <N> -pix_fmt yuv420p src.y4m |
| 3175 | /// aomenc --codec=av1 --obu -o <cell>.obu --passes=1 --cpu-used=4 --limit=<N> \ |
| 3176 | /// --end-usage=q --cq-level=0 --aq-mode=1 src.y4m |
| 3177 | /// ``` |
| 3178 | /// sha256 `8a203e52…` (22336 B), `40d613fd…` (28716 B), `37fbe7cb…` |
| 3179 | /// (38686 B); pinned below by fnv1a64, not a `const SHA256` compared |
| 3180 | /// against itself. |
| 3181 | |
| 3182 | |
| 3183 | |
| 3184 | |
| 3185 | |
| 3186 | |
| 3187 | |
| 3188 | |
| 3189 | |
| 3190 | |
| 3191 | |
| 3192 | |
| 3193 | |
| 3194 | |
| 3195 | |
| 3196 | |
| 3197 | |
| 3198 | |
| 3199 | |
| 3200 | |
| 3201 | |
| 3202 | |
| 3203 | |
| 3204 | |
| 3205 | |
| 3206 | |
| 3207 | |
| 3208 | |
| 3209 | |
| 3210 | |
| 3211 | |
| 3212 | |
| 3213 | |
| 3214 | |
| 3215 | |
| 3216 | |
| 3217 | |
| 3218 | |
| 3219 | |
| 3220 | |
| 3221 | |
| 3222 | |
| 3223 | /// lane-av1444rect r2 — the SAME class as the gate above, second |
| 3224 | /// instance: `decode_rect4_16_intrabc` applied the 4:2:0 pair geometry at |
| 3225 | /// ss (0,0), where `is_chroma_reference` makes an intra-BC 1:4 strip its |
| 3226 | /// own chroma reference. It predicted and coded an 8x4 chroma block at |
| 3227 | /// `(lmi - 1) * MI / 2` where libaom codes 16x4 at the strip's origin. |
| 3228 | /// |
| 3229 | /// **This is a PROGRESS gate, not an exactness gate, and it says so.** The |
| 3230 | /// 4:4:4 intra-BC cell is still divergent: after the ss gate the LUMA |
| 3231 | /// plane is exact to sample 205264 (it was 164416) and the entropy fork |
| 3232 | /// moves from read 11750 to 12465, but both CHROMA planes still first |
| 3233 | /// diverge at index 20532 and 390380 of 921600 samples are wrong. So the |
| 3234 | /// assertion is a prefix floor on the plane the gate actually moved — |
| 3235 | /// which only ever grows, and which the next lane's fix cannot turn red — |
| 3236 | /// and the untouched chroma divergence is named, never asserted exact. |
| 3237 | /// |
| 3238 | /// Recipe (both fixtures, one frame, `testsrc2 640x480 r=25`): |
| 3239 | /// ```text |
| 3240 | /// aomenc --codec=av1 --bit-depth=8 --input-bit-depth=8 --passes=1 |
| 3241 | /// --end-usage=q --cpu-used=0 --lag-in-frames=0 --kf-max-dist=1 |
| 3242 | /// --limit=1 --threads=1 --enable-rect-partitions=1 |
| 3243 | /// --enable-1to4-partitions=1 --min-partition-size=4 |
| 3244 | /// --max-partition-size=64 --sb-size=64 --tune-content=screen |
| 3245 | /// --enable-intrabc=1 --enable-palette=1 --cq-level=60 |
| 3246 | /// --enable-tx-size-search=0 --obu [--profile=1] -o out.obu src.y4m |
| 3247 | /// ``` |
| 3248 | /// 4:4:4 (1016 B, sha256 7fe888ed…) carries 17 intrabc 16x4 strips at |
| 3249 | /// ss (0,0); the 4:2:0 twin (890 B, sha256 d01352af…) is byte-exact and |
| 3250 | /// is the identity arm — the ss gate cannot reach it, and the whole frame |
| 3251 | /// is compared with the length asserted first. |
| 3252 | |
| 3253 | |
| 3254 | |
| 3255 | |
| 3256 | |
| 3257 | |
| 3258 | |
| 3259 | |
| 3260 | |
| 3261 | |
| 3262 | |
| 3263 | |
| 3264 | |
| 3265 | |
| 3266 | |
| 3267 | |
| 3268 | |
| 3269 | |
| 3270 | |
| 3271 | |
| 3272 | |
| 3273 | |
| 3274 | |
| 3275 | |
| 3276 | |
| 3277 | |
| 3278 | |
| 3279 | |
| 3280 | |
| 3281 | |
| 3282 | |
| 3283 | |
| 3284 | |
| 3285 | |
| 3286 | |
| 3287 | |
| 3288 | |
| 3289 | |
| 3290 | |
| 3291 | |
| 3292 | |
| 3293 | |
| 3294 | |
| 3295 | |
| 3296 | |
| 3297 | |
| 3298 | |
| 3299 | |
| 3300 | |
| 3301 | |
| 3302 | |
| 3303 | |
| 3304 | |
| 3305 | |
| 3306 | |
| 3307 | |
| 3308 | |
| 3309 | |
| 3310 | |
| 3311 | |
| 3312 | |
| 3313 | |
| 3314 | |
| 3315 | |
| 3316 | |
| 3317 | |
| 3318 | |
| 3319 | |
| 3320 | |
| 3321 | |
| 3322 | |
| 3323 | |
| 3324 | |
| 3325 | |
| 3326 | |
| 3327 | |
| 3328 | |
| 3329 | /// lane-av1-444interband: the DEFAULT-partition lossless 4:4:4 pin for |
| 3330 | /// the inter 16x4/4x16 strip's chroma band stamping (the pair_chroma |
| 3331 | /// 4:2:0-only gate, commit d5325172). Fixture pinned into `fixtures/`: |
| 3332 | /// testsrc2 128x96 yuv444p, aomenc `--profile=1 --lossless=1 |
| 3333 | /// --enable-palette=0 --enable-intrabc=0 --passes=1 --cpu-used=4 |
| 3334 | /// --limit=6 --obu` (the av1llkf.report.md recipe), 6 frames; 32487 |
| 3335 | /// bytes, sha256 |
| 3336 | /// `1e6dd4e05038c8d51e2c8d29f8c337130c4fea0aed629415535e6e53af9a2c72`. |
| 3337 | /// |
| 3338 | /// This is the stream whose frame 1 desynced at the 16x4 inter strip |
| 3339 | /// mi(2,8) -- its U bc=0 `txb_skip` read base 0 where aom reads base 1, |
| 3340 | /// because the skipped strip (1,8)'s pair-form context stamp smeared |
| 3341 | /// zero over `left[2][1]`. Two pins, both measured at d5325172: |
| 3342 | /// end-to-end, every sample of every frame must match the oracle |
| 3343 | /// aomdec exactly (the pre-fix tree refuses mid-frame-1, so the gate |
| 3344 | /// is red by refusal, not by silent pass), and the 1:4 counter delta |
| 3345 | /// must show the strips decoded WITHOUT the pair rewrite firing |
| 3346 | /// (`horz4=20 vert4=28 chroma_pairs=0` -- chroma_pairs > 0 on this |
| 3347 | /// pairless 4:4:4 stream is the defect reappearing, the |
| 3348 | /// class `pair-rewrite-at-ss0`). |
| 3349 | |
| 3350 | |
| 3351 | |
| 3352 | |
| 3353 | |
| 3354 | |
| 3355 | |
| 3356 | |
| 3357 | |
| 3358 | |
| 3359 | |
| 3360 | |
| 3361 | |
| 3362 | |
| 3363 | |
| 3364 | |
| 3365 | |
| 3366 | |
| 3367 | |
| 3368 | |
| 3369 | |
| 3370 | |
| 3371 | |
| 3372 | |
| 3373 | |
| 3374 | |
| 3375 | |
| 3376 | |
| 3377 | |
| 3378 | |
| 3379 | |
| 3380 | |
| 3381 | |
| 3382 | |
| 3383 | |
| 3384 | |
| 3385 | |
| 3386 | |
| 3387 | |
| 3388 | |
| 3389 | |
| 3390 | |
| 3391 | |
| 3392 | |
| 3393 | |
| 3394 | |
| 3395 | |
| 3396 | |
| 3397 | |
| 3398 | |
| 3399 | |
| 3400 | |
| 3401 | |
| 3402 | |
| 3403 | |
| 3404 | |
| 3405 | |
| 3406 | |
| 3407 | |
| 3408 | |
| 3409 | |
| 3410 | |
| 3411 | |
| 3412 | |
| 3413 | |
| 3414 | |
| 3415 | |
| 3416 | |
| 3417 | |
| 3418 | |
| 3419 | |
| 3420 | |
| 3421 | |
| 3422 | |
| 3423 | |
| 3424 | |
| 3425 | |
| 3426 | |
| 3427 | |
| 3428 | |
| 3429 | |
| 3430 | |
| 3431 | |
| 3432 | |
| 3433 | |
| 3434 | |
| 3435 | |
| 3436 | |
| 3437 | /// lane-av1-leaf8oob: the OOB pin for [`decode_leaf8`]'s intrabc chroma |
| 3438 | /// frame-copy buffers. The closure hardcoding the leaf's chroma |
| 3439 | /// prediction at `4x4` (`vec![0u16; 4 * 4]`, `predict_with_filter` at |
| 3440 | /// `4, 4`) carried the 4:2:0 halving of an 8x8 luma leaf into every |
| 3441 | /// subsampling: at 4:4:4 the leaf's own chroma plane block is 8x8 |
| 3442 | /// (`csz == 8`), so the 16-sample override reached |
| 3443 | /// [`PlaneBuf::reconstruct`] as an 8x8 prediction and indexed |
| 3444 | /// `prediction[16]` of a 16-sample buffer -- |
| 3445 | /// `index out of bounds: the len is 16 but the index is 16` at the |
| 3446 | /// reconstruct call, on every conformant stream of this shape (a panic, |
| 3447 | /// never a refusal). Same signature class as lane-lossless128's |
| 3448 | /// 128-axis lossless extent (`len 16, index 16` there too). |
| 3449 | /// |
| 3450 | /// `crates/ec-av1/fixtures/444_leaf8_oob.obu`, 3577 bytes, sha256 |
| 3451 | /// `72bed2791d1ceba8be7926a052c7838c5d96d4f9d56d28fb69789a753d3593af` |
| 3452 | /// (force-added past the `fixtures` gitignore like every sibling |
| 3453 | /// fixture): the lane ticket's witness-hunt reproducer (s1a/s2e) -- a |
| 3454 | /// 320x256, 3-frame, 8-bit 4:4:4 screen-content keyframe run whose |
| 3455 | /// census pins 4 intrabc 8x8 leaves (the oracle's own MB dump opens on |
| 3456 | /// unbroken inter-classified intra = intrabc blocks). The encoding |
| 3457 | /// recipe is not independently recoverable in this lane; the bytes are |
| 3458 | /// pinned by length + FNV-1a64 here and by the oracle raw fingerprint |
| 3459 | /// below. |
| 3460 | /// |
| 3461 | /// WHAT THIS GATE DOES NOT CLAIM: sample-exactness -- and it pins no |
| 3462 | /// pixel baseline. Measured against the oracle aomdec (`--rawvideo`; |
| 3463 | /// comparison method ground-truthed by the green |
| 3464 | /// `a_lossless_sb128_rect_intra_block_decodes_sample_exact` and |
| 3465 | /// `a_lossless_444_min_partition8_inter_stream_decodes_sample_exact` |
| 3466 | /// witnesses on this same tree), this stream DIVERGES and its output is |
| 3467 | /// not even self-deterministic: frame 0's first differing LUMA sample |
| 3468 | /// is at (275,128), the (y, u, v) differing counts per frame are |
| 3469 | /// (20811, 35467, 32320)/(20308, 39177, 35994)/(20131, 39588, 36601) of |
| 3470 | /// 81920 samples per plane, and under `EC_AV1_PLANE_SENTINEL=1` the |
| 3471 | /// chroma counts move (u f0 35467 -> 35630) while luma stays put. |
| 3472 | /// Sentinel-vs-uninit output diffing localises that dependence to 458 |
| 3473 | /// WHOLE 8x8 chroma blocks (frame 0: chroma x >= 96, y >= 64) reading |
| 3474 | /// samples this decode never wrote -- ambient memory in those slots, |
| 3475 | /// hence any pixel-exact assert here drifts run to run with the batch. |
| 3476 | /// Both facts belong to ONE pre-existing defect this lane must not |
| 3477 | /// chase (the ticket's fix touches only leaf8's chroma prediction |
| 3478 | /// buffers, which cannot feed a luma sample, and the pre-fix run never |
| 3479 | /// got past the panicked leaf): a decode desync on this stream around |
| 3480 | /// frame-0 SB (3..4, 2), after which samples diverge from the oracle |
| 3481 | /// and the misread layout leaves chroma blocks unreconstructed. |
| 3482 | /// Disposition: `deferred(unblock: divergence lane -- EC trace pairing |
| 3483 | /// against the oracle on this fixture)`. So this gate pins exactly what |
| 3484 | /// its ticket owns: fixture identity, a decode that RUNS TO COMPLETION |
| 3485 | /// where the old code died with `len 16, index 16`, and the arm counter. |
| 3486 | /// |
| 3487 | /// Assertions (all before/without any skip path): |
| 3488 | /// 1. fixture bytes: exact length + FNV-1a64; |
| 3489 | /// 2. `decode_stream` succeeds -- 3 frames, 320x256 (the pre-fix run |
| 3490 | /// died here with the len-16/index-16 panic); |
| 3491 | /// 3. non-vacuity: `leaf8_intrabc_hits` moves (measured 0 -> 4), so the |
| 3492 | /// arm owning the fixed buffers really fired; |
| 3493 | /// 4. the oracle aomdec still decodes the pinned bytes (raw size + |
| 3494 | /// fingerprint), anchoring the deferred divergence comparison. |
| 3495 | |
| 3496 | |
| 3497 | |
| 3498 | |
| 3499 | |
| 3500 | |
| 3501 | |
| 3502 | |
| 3503 | |
| 3504 | |
| 3505 | |
| 3506 | |
| 3507 | |
| 3508 | |
| 3509 | |
| 3510 | |
| 3511 | |
| 3512 | |
| 3513 | |
| 3514 | |
| 3515 | |
| 3516 | |
| 3517 | |
| 3518 | |
| 3519 | |
| 3520 | |
| 3521 | |
| 3522 | |
| 3523 | |
| 3524 | |
| 3525 | |
| 3526 | |
| 3527 | |
| 3528 | |
| 3529 | |
| 3530 | |
| 3531 | |
| 3532 | |
| 3533 | |
| 3534 | |
| 3535 | |
| 3536 | |
| 3537 | |
| 3538 | |
| 3539 | |
| 3540 | |
| 3541 | |
| 3542 | |
| 3543 | |
| 3544 | |
| 3545 | |
| 3546 | |
| 3547 | |
| 3548 | |
| 3549 | |
| 3550 | |
| 3551 | |
| 3552 | |
| 3553 | |
| 3554 | |
| 3555 | |
| 3556 | |
| 3557 | |
| 3558 | |
| 3559 | /// lane-av1p1pin: the permanent pin for the 4:4:4 superblock-128 |
| 3560 | /// 128-root rect witness -- recipe P1 of `lanes/av1witness2recheck.report.md`. |
| 3561 | /// |
| 3562 | /// Provenance. Encoder: `~/.cache/aom-oracle/build/aomenc --codec=av1 |
| 3563 | /// --obu -o s1d.obu --passes=1 --threads=1 bands444.y4m --limit=3 |
| 3564 | /// --kf-max-dist=1 --cpu-used=2 --end-usage=q --cq-level=20 --sb-size=128 |
| 3565 | /// --enable-rect-partitions=1 --enable-1to4-partitions=1 |
| 3566 | /// --min-partition-size=4`, over the ffmpeg 8.1.2 lavfi source |
| 3567 | /// `nullsrc=s=320x256:rate=30:d=1,geq=lum='mod(floor((Y+T*160)/8)*67,255)': |
| 3568 | /// cb='128+20*sin(Y/17+T)':cr='128+20*sin(X/23+T*2)' -pix_fmt yuv444p` |
| 3569 | /// (`bands444.y4m`, sha256 |
| 3570 | /// `fa6218399cce8dd9eaadb6e24642d31cb2d2bde505b39a8df237938492c642ee`). |
| 3571 | /// Pinned bytes: `crates/ec-av1/fixtures/444_sb128rect_chroma_tile_witness.obu`, |
| 3572 | /// 595 bytes, sha256 |
| 3573 | /// `68773f2c6e01a2d211bf0213479accb4c2c360132c0e1bc3b326eab7861925b1` |
| 3574 | /// (FNV-1a `0xd4fa_ac7b_dccc_520b`). Rebuilt byte-for-byte from the recipe |
| 3575 | /// on `9a535ccb` -- the recipe did not drift. 3 frames, 320x256, yuv444p. |
| 3576 | /// This is NOT `fixtures/444_sb128rect_lr_witness.obu` (794 B, sha256 |
| 3577 | /// `27825e14...`), the other in-tree 4:4:4 sb128 stream. |
| 3578 | /// |
| 3579 | /// What it guards. At the report's old base `fe3e8418` this stream |
| 3580 | /// panicked -- rc=101, `decode.rs:17631: assertion failed: lossless_frame |
| 3581 | /// || (chroma_w / chroma_tx, chroma_h / chroma_tx) == (nch_x, nch_y)` -- |
| 3582 | /// because the 128-rect chroma unit walk was hardcoded to the 4:2:0 mu-chunk |
| 3583 | /// span, so a 128-root HORZ/VERT block at 4:4:4 coded half its chroma units. |
| 3584 | /// Closed by `349b3918` (the per-axis invariant now at `decode.rs:24515`); |
| 3585 | /// byte-exactness by `fa70a68c`. |
| 3586 | /// |
| 3587 | /// Two load-bearing arms, both proven to bite (lanes/av1p1pin.report.md): |
| 3588 | /// (1) the census deltas -- 6 gathered edge-VERT 128-roots, 6 |
| 3589 | /// `PARTITION_VERT` 128 roots, 6 key-frame intra 128-axis blocks, 8 coded |
| 3590 | /// `32x32` VERT strips -- so the gate fails, rather than passes, if a |
| 3591 | /// future stream stops coding the shape (class `gate-blind-to-feature`); |
| 3592 | /// (2) every sample of every frame against ffmpeg `yuv444p` rawvideo, with |
| 3593 | /// the plane-length guard that stops a short plane from zip-truncating the |
| 3594 | /// compare. Oracle arm is aomdec `--rawvideo` as well; neither is a shim. |
| 3595 | |
| 3596 | |
| 3597 | |
| 3598 | |
| 3599 | |
| 3600 | |
| 3601 | |
| 3602 | |
| 3603 | |
| 3604 | |
| 3605 | |
| 3606 | |
| 3607 | |
| 3608 | |
| 3609 | |
| 3610 | |
| 3611 | |
| 3612 | |
| 3613 | |
| 3614 | |
| 3615 | |
| 3616 | |
| 3617 | |
| 3618 | |
| 3619 | |
| 3620 | |
| 3621 | |
| 3622 | |
| 3623 | |
| 3624 | |
| 3625 | |
| 3626 | |
| 3627 | |
| 3628 | |
| 3629 | |
| 3630 | |
| 3631 | |
| 3632 | |
| 3633 | |
| 3634 | |
| 3635 | |
| 3636 | |
| 3637 | |
| 3638 | |
| 3639 | |
| 3640 | |
| 3641 | |
| 3642 | |
| 3643 | |
| 3644 | |
| 3645 | |
| 3646 | |
| 3647 | |
| 3648 | |
| 3649 | |
| 3650 | |
| 3651 | |
| 3652 | |
| 3653 | |
| 3654 | |
| 3655 | |
| 3656 | |
| 3657 | |
| 3658 | |
| 3659 | |
| 3660 | |
| 3661 | |
| 3662 | |
| 3663 | |
| 3664 | |
| 3665 | |
| 3666 | |
| 3667 | |
| 3668 | |
| 3669 | |
| 3670 | |
| 3671 | |
| 3672 | |
| 3673 | |
| 3674 | |
| 3675 | |
| 3676 | |
| 3677 | |
| 3678 | |
| 3679 | |
| 3680 | |
| 3681 | |
| 3682 | |
| 3683 | |
| 3684 | |
| 3685 | |
| 3686 | |
| 3687 | |
| 3688 | |
| 3689 | |
| 3690 | |
| 3691 | |
| 3692 | |
| 3693 | |
| 3694 | |
| 3695 | |
| 3696 | |
| 3697 | |
| 3698 | |
| 3699 | |
| 3700 | |
| 3701 | |
| 3702 | |
| 3703 | |
| 3704 | |
| 3705 | |
| 3706 | |
| 3707 | |
| 3708 | |
| 3709 | |
| 3710 | |
| 3711 | |
| 3712 | |
| 3713 | |
| 3714 | |
| 3715 | |
| 3716 | |
| 3717 | |
| 3718 | |
| 3719 | |
| 3720 | |
| 3721 | |
| 3722 | |
| 3723 | |
| 3724 | |
| 3725 | |
| 3726 | |
| 3727 | |
| 3728 | |
| 3729 | |
| 3730 | |
| 3731 | |
| 3732 | |
| 3733 | |
| 3734 | |
| 3735 | |
| 3736 | |
| 3737 | |
| 3738 | |
| 3739 | |
| 3740 | |
| 3741 | |
| 3742 | |
| 3743 | |
| 3744 | |
| 3745 | |
| 3746 | |
| 3747 | |
| 3748 | |
| 3749 | |
| 3750 | |
| 3751 | |
| 3752 | /// lane-lossless128: a LOSSLESS key frame that codes a 128-axis |
| 3753 | /// (`BLOCK_64X128`) intra block -- the shape libaom's `read_tx_size` forces |
| 3754 | /// to `TX_4X4` on its very first line (`decodeframe.c:1183`), so every plane |
| 3755 | /// of the block is a 4x4 transform unit and NO `tx_size_cat3` symbol is |
| 3756 | /// coded. |
| 3757 | /// |
| 3758 | /// On the merged base `decode_block_128rect` had no lossless carve-out: it |
| 3759 | /// read `logical_tx = 64` off `depth == 0`, handed `PlaneBuf::reconstruct` |
| 3760 | /// a 64x64 geometry with the 16-sample 4x4 residual |
| 3761 | /// [`TxParams::run`](crate::decode::TxParams) produced -- `index out of |
| 3762 | /// bounds: the len is 16 but the index is 16` at the reconstruction call, |
| 3763 | /// on EVERY conformant stream of this shape (a panic, never a refusal). |
| 3764 | /// |
| 3765 | /// `crates/ec-av1/fixtures/lossless_sb128_rect_kf.obu`, 3471 bytes, sha256 |
| 3766 | /// `013b07979c8be999c70d47f32768c2bf959be086a893f60dde1b0f5e35d4f475`: |
| 3767 | /// `aomenc --codec=av1 --passes=1 --threads=1 --obu --lossless=1 |
| 3768 | /// --cpu-used=0` over a 320x256, 4-frame source that is flat grey except a |
| 3769 | /// textured 64x128 patch in the top-right corner -- which is what makes the |
| 3770 | /// 128 root take `PARTITION_VERT` and code the `BLOCK_64X128` at mi(0,64). |
| 3771 | /// |
| 3772 | /// The counter delta keeps the gate non-vacuous: a stream that stopped |
| 3773 | /// coding the shape reads 0 and the gate fails instead of passing on a |
| 3774 | /// decode that never reached the fixed body (class |
| 3775 | /// `gate-blind-to-feature`). |
| 3776 | |
| 3777 | |
| 3778 | |
| 3779 | |
| 3780 | |
| 3781 | |
| 3782 | |
| 3783 | |
| 3784 | |
| 3785 | |
| 3786 | |
| 3787 | |
| 3788 | |
| 3789 | |
| 3790 | |
| 3791 | |
| 3792 | |
| 3793 | |
| 3794 | |
| 3795 | |
| 3796 | |
| 3797 | |
| 3798 | |
| 3799 | |
| 3800 | |
| 3801 | |
| 3802 | |
| 3803 | |
| 3804 | |
| 3805 | |
| 3806 | |
| 3807 | |
| 3808 | |
| 3809 | |
| 3810 | |
| 3811 | |
| 3812 | |
| 3813 | |
| 3814 | |
| 3815 | |
| 3816 | |
| 3817 | |
| 3818 | |
| 3819 | |
| 3820 | |
| 3821 | |
| 3822 | |
| 3823 | |
| 3824 | |
| 3825 | |
| 3826 | |
| 3827 | |
| 3828 | |
| 3829 | |
| 3830 | |
| 3831 | |
| 3832 | |
| 3833 | |
| 3834 | |
| 3835 | |
| 3836 | |
| 3837 | |
| 3838 | |
| 3839 | |
| 3840 | |
| 3841 | |
| 3842 | |
| 3843 | |
| 3844 | |
| 3845 | |
| 3846 | |
| 3847 | |
| 3848 | |
| 3849 | |
| 3850 | |
| 3851 | |
| 3852 | |
| 3853 | |
| 3854 | |
| 3855 | |
| 3856 | |
| 3857 | |
| 3858 | |
| 3859 | |
| 3860 | |
| 3861 | /// lane-av1-loss64: a lossless superblock-128 frame whose intra blocks |
| 3862 | /// overhang the bottom frame edge codes NO coefficient symbols for the |
| 3863 | /// chroma transform units whose 4x4 origin sits outside the frame's mi |
| 3864 | /// grid -- libaom `decode_reconstruct_tx` returns before any read |
| 3865 | /// (`decodeframe.c:299`, `blk_row >= max_blocks_high || blk_col >= |
| 3866 | /// max_blocks_wide`, the limits from `max_block_wide/high`, |
| 3867 | /// av1_common_int.h:1565). The square multi-transform-unit chroma loop in |
| 3868 | /// [`crate::decode`] carried no such clip (the luma loop had one) and read |
| 3869 | /// `txb_skip`+coefficients for the phantom units: on the measured stream |
| 3870 | /// the first lossless 64x64 `NONE` block, at mi(48,0), overhangs the |
| 3871 | /// 240-px frame by 4 mi, so its 32x32 chroma codes SIX rows of 4x4 units, |
| 3872 | /// not eight -- 32 phantom unit reads per plane desynced the tile and |
| 3873 | /// every later symbol (including partition reads, which is what made |
| 3874 | /// aomdec's zero-`value=8/9` census look like a partition-reader defect |
| 3875 | /// in the rect14 review) decoded as garbage. |
| 3876 | /// |
| 3877 | /// Fail-pre-fix, measured on the ed12fe52 probe: both arms differ from |
| 3878 | /// ffmpeg at byte 41120 (luma row 128 col 160, the first block decoded |
| 3879 | /// after the phantom reads). The counter delta pins non-vacuity (class |
| 3880 | /// `gate-blind-to-feature`): 96 clipped units on each arm. |
| 3881 | |
| 3882 | |
| 3883 | |
| 3884 | |
| 3885 | |
| 3886 | |
| 3887 | |
| 3888 | |
| 3889 | |
| 3890 | |
| 3891 | |
| 3892 | |
| 3893 | |
| 3894 | |
| 3895 | |
| 3896 | |
| 3897 | |
| 3898 | |
| 3899 | |
| 3900 | |
| 3901 | |
| 3902 | |
| 3903 | |
| 3904 | |
| 3905 | |
| 3906 | |
| 3907 | |
| 3908 | |
| 3909 | |
| 3910 | |
| 3911 | |
| 3912 | |
| 3913 | |
| 3914 | |
| 3915 | |
| 3916 | |
| 3917 | |
| 3918 | |
| 3919 | |
| 3920 | |
| 3921 | |
| 3922 | |
| 3923 | |
| 3924 | |
| 3925 | |
| 3926 | |
| 3927 | |
| 3928 | |
| 3929 | |
| 3930 | |
| 3931 | |
| 3932 | |
| 3933 | |
| 3934 | |
| 3935 | |
| 3936 | |
| 3937 | |
| 3938 | |
| 3939 | |
| 3940 | |
| 3941 | /// lane-av1-loss64: a SKIPPED intrabc rect strip on a lossless frame |
| 3942 | /// zeroes its whole entropy-band footprint (libaom |
| 3943 | /// `av1_reset_entropy_context`, `if (mbmi->skip_txfm)` decodeframe.c:1262 -> |
| 3944 | /// blockd.c:58) instead of leaving the previous occupant's luma bands |
| 3945 | /// standing. The skip arm of `decode_intrabc_owned_rect` never wrote the |
| 3946 | /// luma bands: the lossless `read_block_tx_size_rect` resolves the 4x4 |
| 3947 | /// leaf list before it looks at `skip`, so the tail took the |
| 3948 | /// per-transform-unit record path (chroma only) with no per-unit luma |
| 3949 | /// writes ever run. The next block then read a STALE band: on the 320x242 |
| 3950 | /// `--min-partition-size=4` sibling of this stream the skipped 8x16 |
| 3951 | /// intrabc strip at mi(48,66) left a 7 in left[48] and mi(48,68)'s first |
| 3952 | /// transform unit read `txb_skip_ctx` 3 where aomdec reads 1 (measured |
| 3953 | /// `EC_ECDUMP` against the instrumented aomdec) -- a coefficient-walk |
| 3954 | /// desync at byte 61712 with every mode symbol still matching. |
| 3955 | /// |
| 3956 | /// This gate uses the same `--min-partition-size=4` arm that reaches the |
| 3957 | /// sub-8x8 VERT -> 4x8 skipped-intrabc leaf. Post-fix it is full-frame |
| 3958 | /// exact: the skip path uses libaom's clamped 4x4 chroma intrabc |
| 3959 | /// prediction (`decodeframe.c:1011-1065`, `reconinter_template.inc:186-207`) |
| 3960 | /// instead of the ordinary skipped-intra DC predictor. The old route first |
| 3961 | /// differed at U(104,92) with the entropy ladder fully synced. |
| 3962 | /// |
| 3963 | /// Fail-pre-fix, measured on the ed12fe52 probe: differs at byte 41120 |
| 3964 | /// (the chroma-clip class, fixed in the same lane). Single-mutation on |
| 3965 | /// the lane tree with ONLY this gate's walk reverted: differs at byte |
| 3966 | /// 61712, the band-leak site. |
| 3967 | |
| 3968 | |
| 3969 | |
| 3970 | |
| 3971 | |
| 3972 | |
| 3973 | |
| 3974 | |
| 3975 | |
| 3976 | |
| 3977 | |
| 3978 | |
| 3979 | |
| 3980 | |
| 3981 | |
| 3982 | |
| 3983 | |
| 3984 | |
| 3985 | |
| 3986 | |
| 3987 | |
| 3988 | |
| 3989 | |
| 3990 | |
| 3991 | |
| 3992 | |
| 3993 | |
| 3994 | |
| 3995 | |
| 3996 | |
| 3997 | |
| 3998 | |
| 3999 | |
| 4000 | |
| 4001 | |
| 4002 | |
| 4003 | |
| 4004 | |
| 4005 | |
| 4006 | |
| 4007 | |
| 4008 | |
| 4009 | |
| 4010 | |
| 4011 | |
| 4012 | |
| 4013 | |
| 4014 | |
| 4015 | |
| 4016 | |
| 4017 | |
| 4018 | |
| 4019 | |
| 4020 | /// lane-av1-ibc444rect: an unskipped intrabc `BLOCK_8X4`/`BLOCK_4X8` leaf |
| 4021 | /// on a lossless 4:4:4 frame walks its coefficients as per-4x4 inter |
| 4022 | /// `TX_4X4` units on every plane -- `read_tx_size`'s lossless first line |
| 4023 | /// (`decodeframe.c:1203`) forces TX_4X4 before any tree, the frame's |
| 4024 | /// `TxMode` is `ONLY_4X4` so no var-tx tree is read either, and |
| 4025 | /// `av1_read_tx_type`'s qindex==0 early return (`decodemv.c:681`) drops |
| 4026 | /// the tx_type symbol the lossy 4x4 inter sets carry -- NOT the single |
| 4027 | /// `LumaRect8x4Inter`/`ChromaRect8x4` rect unit the non-lossless arm |
| 4028 | /// reads, and not the lossy per-unit arm's tx_type read. |
| 4029 | /// |
| 4030 | /// The pinned fixture `ll444_ibc_rect.obu` (99614 bytes, provenance in |
| 4031 | /// `lanes/av1ibc444rect.report.md`) is a lossless `--profile=1 --i444 |
| 4032 | /// --enable-intrabc=1` key frame. r1 pinned the (then-known) leaf8 |
| 4033 | /// `palette_window` panic as its alignment witness; with that blocker |
| 4034 | /// fixed upstream (lane-av1leaf8oob) the frame decodes to completion and |
| 4035 | /// this gate is the FULL-FRAME exact `aomdec` comparison its r1 doc |
| 4036 | /// promised, flipped by lane-av1-ibcskip2 -- which also closed the |
| 4037 | /// SKIPPED intrabc sub8 chroma cells the r1 measurement called out: a |
| 4038 | /// skipped intrabc leaf's chroma is the bare frame copy at the DV |
| 4039 | /// (libaom's `av1_build_inter_predictors_sb` runs regardless of `skip`), |
| 4040 | /// never the intra-DC push that arm used to run. Fail-before, measured on |
| 4041 | /// this tree with the DV-copy arm cut back to the intra push: 2794 U + |
| 4042 | /// 2830 V samples differ across 180 distinct 4x4 cells, 175 of them |
| 4043 | /// exactly this frame's skipped intrabc leaves, luma clean; with the arm, |
| 4044 | /// 0 differing samples on every plane. |
| 4045 | |
| 4046 | |
| 4047 | |
| 4048 | |
| 4049 | |
| 4050 | |
| 4051 | |
| 4052 | |
| 4053 | |
| 4054 | |
| 4055 | |
| 4056 | |
| 4057 | |
| 4058 | |
| 4059 | |
| 4060 | |
| 4061 | |
| 4062 | |
| 4063 | |
| 4064 | |
| 4065 | |
| 4066 | |
| 4067 | |
| 4068 | |
| 4069 | |
| 4070 | |
| 4071 | |
| 4072 | |
| 4073 | |
| 4074 | |
| 4075 | |
| 4076 | |
| 4077 | |
| 4078 | |
| 4079 | |
| 4080 | |
| 4081 | |
| 4082 | |
| 4083 | |
| 4084 | |
| 4085 | |
| 4086 | |
| 4087 | |
| 4088 | |
| 4089 | |
| 4090 | |
| 4091 | |
| 4092 | |
| 4093 | |
| 4094 | |
| 4095 | |
| 4096 | |
| 4097 | |
| 4098 | |
| 4099 | |
| 4100 | |
| 4101 | |
| 4102 | |
| 4103 | |
| 4104 | |
| 4105 | |
| 4106 | |
| 4107 | |
| 4108 | |
| 4109 | |
| 4110 | |
| 4111 | |
| 4112 | |
| 4113 | |
| 4114 | |
| 4115 | |
| 4116 | |
| 4117 | |
| 4118 | |
| 4119 | |
| 4120 | |
| 4121 | |
| 4122 | |
| 4123 | |
| 4124 | |
| 4125 | |
| 4126 | |
| 4127 | |
| 4128 | |
| 4129 | |
| 4130 | |
| 4131 | |
| 4132 | |
| 4133 | |
| 4134 | |
| 4135 | |
| 4136 | |
| 4137 | |
| 4138 | |
| 4139 | |
| 4140 | |
| 4141 | /// lane-dkey: the palette-neighbour-band gate. A palette-Y block's size and |
| 4142 | /// colours used to stay standing in the mi-granular above/left bands after a |
| 4143 | /// sub-8x8 group was decoded next to it -- the sub-8x8 readers published |
| 4144 | /// skip/lf/mode state but no palette state, while libaom's mi grid carries |
| 4145 | /// `palette_size == 0` in exactly those cells (`av1_allow_palette` needs |
| 4146 | /// BLOCK_8X8 and up). The next intra block then read `palette_y_mode` off |
| 4147 | /// CDF row 1 where libaom reads row 0 (class `cdf-row-held-constant`), |
| 4148 | /// decoded a palette libaom never coded, and skipped the `use_filter_intra` |
| 4149 | /// symbol a palette block has none of: one symbol short, tile desynced. |
| 4150 | /// |
| 4151 | /// Measured on the instrumented aomdec at KEY-frame block mi(76,88) of this |
| 4152 | /// very stream (`EC_PALSYN_AOM ... ctx=0 y=0` against our `mode_ctx=1`). |
| 4153 | /// Without the fix every one of the 12 frames differs from ffmpeg's decode |
| 4154 | /// from luma sample 491904 on. |
| 4155 | /// |
| 4156 | /// The source is SYNTHETIC (no film sample lives in `fixtures`): the dark, |
| 4157 | /// near-flat background libaom's own screen-content detector counts as |
| 4158 | /// screen content (2..=4 distinct luma values per 16x16 block), which is |
| 4159 | /// what turns palette on, plus one textured patch at a HALF-PEL position on |
| 4160 | /// half the frames so the encoder splits that region down to 4x4 groups |
| 4161 | /// beside its palette blocks. |
| 4162 | |
| 4163 | |
| 4164 | |
| 4165 | |
| 4166 | |
| 4167 | |
| 4168 | |
| 4169 | |
| 4170 | |
| 4171 | |
| 4172 | |
| 4173 | |
| 4174 | |
| 4175 | |
| 4176 | |
| 4177 | |
| 4178 | |
| 4179 | |
| 4180 | |
| 4181 | |
| 4182 | |
| 4183 | |
| 4184 | |
| 4185 | |
| 4186 | |
| 4187 | |
| 4188 | |
| 4189 | |
| 4190 | |
| 4191 | |
| 4192 | |
| 4193 | |
| 4194 | |
| 4195 | |
| 4196 | |
| 4197 | |
| 4198 | |
| 4199 | |
| 4200 | |
| 4201 | |
| 4202 | |
| 4203 | |
| 4204 | |
| 4205 | |
| 4206 | |
| 4207 | |
| 4208 | |
| 4209 | |
| 4210 | |
| 4211 | |
| 4212 | |
| 4213 | |
| 4214 | |
| 4215 | |
| 4216 | |
| 4217 | |
| 4218 | |
| 4219 | |
| 4220 | |
| 4221 | |
| 4222 | |
| 4223 | |
| 4224 | |
| 4225 | |
| 4226 | |
| 4227 | |
| 4228 | |
| 4229 | |
| 4230 | |
| 4231 | |
| 4232 | |
| 4233 | |
| 4234 | |
| 4235 | |
| 4236 | |
| 4237 | |
| 4238 | |
| 4239 | |
| 4240 | |
| 4241 | |
| 4242 | |
| 4243 | |
| 4244 | |
| 4245 | |
| 4246 | |
| 4247 | |
| 4248 | |
| 4249 | |
| 4250 | |
| 4251 | |
| 4252 | |
| 4253 | |
| 4254 | /// Hardened past the report-only test above: a real libaom-av1 gradients |
| 4255 | /// stream, pinned deterministic (`gradients`' own `seed=`, plus |
| 4256 | /// `-threads 1`/`-row-mt 0`/no tiling so libaom's `cpu-used 8` RD search |
| 4257 | /// cannot pick a different mode set run to run) and with CDEF turned off |
| 4258 | /// (this decoder's tile path never applies that in-loop filter -- see |
| 4259 | /// `cdef_is_active` in `decode_stream` -- so a stream that leaves it on |
| 4260 | /// decodes-but-wrong instead of refusing at cdef_bits==0; ffmpeg's |
| 4261 | /// `-enable-cdef 0` keeps this fixture out of that gap rather than this |
| 4262 | /// test working around it). Asserts pixel-exact against ffmpeg's own |
| 4263 | /// decode of the identical bytes, not just "decoded without error". |
| 4264 | |
| 4265 | |
| 4266 | |
| 4267 | |
| 4268 | |
| 4269 | |
| 4270 | |
| 4271 | |
| 4272 | |
| 4273 | |
| 4274 | |
| 4275 | |
| 4276 | |
| 4277 | |
| 4278 | |
| 4279 | |
| 4280 | |
| 4281 | |
| 4282 | |
| 4283 | |
| 4284 | |
| 4285 | |
| 4286 | |
| 4287 | |
| 4288 | |
| 4289 | |
| 4290 | |
| 4291 | |
| 4292 | |
| 4293 | |
| 4294 | |
| 4295 | |
| 4296 | |
| 4297 | /// As [`a_real_libaom_gradients_stream_decodes_pixel_exact`], but at |
| 4298 | /// 32x32 (below `is_cfl_allowed`'s 32x32 luma bound as a *single* |
| 4299 | /// undivided block, spec 5.11.5) rather than 64x64 -- a whole 64x64 SB |
| 4300 | /// is never CFL-eligible itself, only its <=32x32 partitions, and |
| 4301 | /// `testsrc2`/`gradients` at 64x64 with rect/ab/1to4/angle-delta search |
| 4302 | /// disabled reliably pick a whole-SB `PARTITION_NONE` (probed |
| 4303 | /// lane-av1real r2), so no fixture at that size exercises CfL at all. |
| 4304 | /// A 32x32 frame is exactly the whole-block, CFL-allowed case, and |
| 4305 | /// lane-av1real r2 found `gradients` there reliably selects |
| 4306 | /// `UV_CFL_PRED` (`uv_mode=13`) across a crf sweep -- `testsrc2` there |
| 4307 | /// stays DC. Proves the CfL port this round added, not just DC-chroma |
| 4308 | /// decode: pixel-exact against ffmpeg's own decode, not just "decoded". |
| 4309 | /// |
| 4310 | |
| 4311 | |
| 4312 | |
| 4313 | |
| 4314 | |
| 4315 | |
| 4316 | |
| 4317 | |
| 4318 | |
| 4319 | |
| 4320 | |
| 4321 | |
| 4322 | |
| 4323 | |
| 4324 | |
| 4325 | |
| 4326 | |
| 4327 | |
| 4328 | |
| 4329 | |
| 4330 | |
| 4331 | |
| 4332 | |
| 4333 | |
| 4334 | |
| 4335 | |
| 4336 | |
| 4337 | |
| 4338 | |
| 4339 | |
| 4340 | |
| 4341 |