Commits
Commits on
68cf7a69b80f16fa32ec222cdfd758fa2faff4b7Filtered to crates/ec-av1/src/decode.rsClear filter2026-09-12
fix(av1): the raw-tile inter decode wrapper takes the frame's own reduced_tx_set instead of guessing true -- the widened inter search made the bit chroma-relevant (a screen GOP's inter luma takes V_DCT and the chroma inheritance reduces against this exact bit, so the GOP round-trip tests desynced and surfaced the empty-ref-slot refusal), Encoded carries the bit and the GOP and key-frame tile tests pass it; encoder output is byte-identical (witnesses re-run at 8143/8211 bytes), the three tests plus pins are green and the full three-lane suite reads 592 passed / 0 failedAhmet Kaan Gümüş · 9c0a4a2
fix(av1): the raw-tile inter decode wrapper takes the frame's own reduced_tx_set instead of guessing true -- the widened inter search made the bit chroma-relevant (a screen GOP's inter luma takes V_DCT and the chroma inheritance reduces against this exact bit, so the GOP round-trip tests desynced and surfaced the empty-ref-slot refusal), Encoded carries the bit and the GOP and key-frame tile tests pass it; encoder output is byte-identical (witnesses re-run at 8143/8211 bytes), the three tests plus pins are green and the full three-lane suite reads 592 passed / 0 failed
fix(av1): the inter tx-type search widens to the Set1 alphabets on reduced_tx_set=0 frames with the chroma inheritance made honest -- the frame sets its own reduced_tx_set_inter on the shared context and the writer codes every inter chroma plane with the luma type reduced to the chroma set (lane-intertx desyncs (a)+(b)), the one-D witness codes 40 V_DCT + 521 H_DCT inter units on a non-screen clip and all three planes read sample-exact through ffmpeg and decode_stream, the RED run with the chroma half neutralized desyncs the tileAhmet Kaan Gümüş · 630cb11Browse files
2026-09-08
fix(av1): one cdef_idx literal covers every 64x64 unit its block spans; the 128 residual arm ships opt-inAhmet Kaan Gümüş · f677e4c
fix(av1): one cdef_idx literal covers every 64x64 unit its block spans; the 128 residual arm ships opt-in libaom stores the cdef_idx it reads at the origin mi of the 64x64 CDEF unit, and av1_cdef_frame reads the strength back off each unit's origin mi -- so a block WIDER than one unit (the 128 root's own block, the only one there is) drives every unit it covers with its single literal. This decoder stamped the reading block's own cell alone, which no stream could reach before the 128 root carried a residual. The residual arm itself is measured INERT (0-2 blocks per frame against ~90 whole 128 roots on the native gate) and, switched on, leaves 8 luma samples of the bars 2160p row disagreeing with ffmpeg at a 128 superblock's horizontal edge -- a filter-stage interaction, not the coefficient path (the arm's own forced witness is byte-exact through ffmpeg over 420 blocks). It therefore ships behind EC_AV1_B128RES=1 until that is root-caused; the default encoder is byte-identical. The gate driver now prints the whole mismatch map (count + row/col span) before it panics, which is what made the 8-sample cluster readable.
Merge branch 'lane-b128m' (14c23a84): 128x128 superblocks on by default; delta_q coded once per 128 root, filter context copy carries the superblock size, intrabc predictor by superblock size, encode-then-decode gates use the encoder context; pins re-taken at the merge 8354 / 33222Ahmet Kaan Gümüş · a4a0871Browse files
fix(av1): write a cut palette block's colour-index map over its on-screen part onlyAhmet Kaan Gümüş · 254b908
fix(av1): write a cut palette block's colour-index map over its on-screen part only A palette block straddling the frame's right/bottom mi edge codes its map over spec 5.11.50's onscreenWidth x onscreenHeight corner and the decoder replicates it outward. The writer walked the full block grid, so every conformant decoder read the map short and desynced the rest of the tile; our own trial decode agreed with itself because the encoder-side FrameCtx carried no mi dims and the reader mirrored the writer there. Both frame encoders now publish the header's mi dims on that ctx, the palette search folds its searched map to the on-screen corner (so the priced, reconstructed and written map are one map), and the writer codes that corner only. The reader's mirror-the-writer branch is gone. Witness: encoder::tests::a_palette_block_cut_by_the_frame_edge_decodes_ exactly_through_ffmpeg -- our encoder at 384x152, 12 cut maps written, every plane of every frame equal to ffmpeg's decode.
fix(av1): the on-screen palette clamp only applies where the frame's mi dims are knownAhmet Kaan Gümüş · d84ad00
fix(av1): the on-screen palette clamp only applies where the frame's mi dims are known The encoder's own in-process reconstruct runs on a FrameCtx that never saw set_segmentation, so its mi dims are zero and every colour-index map read clamped to 1x1 -- 16 round-trip gates refused with a bogus reference-slot error. Its writer half is unclamped as well, so that path mirrors itself.
fix(av1): the superblock size travels with a FrameCtx copy; two reach gates pin 64Ahmet Kaan Gümüş · ab4ff0c
fix(av1): the superblock size travels with a FrameCtx copy; two reach gates pin 64 filter_ctx_copy dropped sb128_flag/reach_sb_px, so a tile SEARCH worker searched at 64 while the calling thread searched at 128: the coded bytes depended on EC_AV1_TILE_THREADS under EC_AV1_SB128 (tile_bytes_do_not_depend_on_the_thread_count, 1x2 tiles, 9251 vs 9239). every_tile_layout: the spec's uniform spacing derives the tile count from the superblock grid, so a 128-superblock frame with 5 SB columns codes 3 tiles for tile_cols_log2=2; the test now expects the encoder's own grid. The two reach gates transcribe libaom's 64-superblock tables, so they pin a 64 context instead of following the process knob.
Merge branch 'lane-b128' (98bde66d) into lane-b128m: 128-root PARTITION_NONE search behind EC_AV1_SB128; pins kept (default off)Ahmet Kaan Gümüş · 7bb33bdBrowse files
fix(av1): the palette colour-index map is read over the block's on-screen part onlyAhmet Kaan Gümüş · 2461f80
fix(av1): the palette colour-index map is read over the block's on-screen part only A palette block cut by the frame's bottom or right mi edge codes its colour-index map over spec 5.11.50's onscreenWidth x onscreenHeight corner and replicates it outward; this decoder read the full block grid, consuming symbols libaom never wrote and desyncing the rest of the tile (the symptom was either a wrong bottom-edge superblock row or a 'Golomb tail longer than this decoder reads' refusal further down).
Merge branch 'lane-svt1' (6ec1414a): a skipped square intra block armed its palette/intrabc override only when the transform equalled the block, so a skipped split-transform palette block predicted DC; SVT-AV1 screen stream sample-exactAhmet Kaan Gümüş · bab01c8Browse files
fix(av1): ten decode round-trip tests decoded their own encoder's stream at the wrong superblock sizeAhmet Kaan Gümüş · 330a2df
fix(av1): ten decode round-trip tests decoded their own encoder's stream at the wrong superblock size Every one of them encodes with this process's encoder and then decodes the tile directly with a plain FrameCtx, whose superblock size is the decoder default (64) rather than the size the writer used -- so with 128 superblocks on, the reader skipped the root's partition symbol and the whole tile desynced. FrameCtx::for_encoder exists for exactly this (stale-header class, the same shape as the filter_intra_on argument beside it). Swept the module: two more tests had the same defect without failing yet. EC_AV1_B128=0 attribution knob added.
fix(av1): a skipped palette block with a split transform predicted DC off its edgesAhmet Kaan Gümüş · 1edcdab
fix(av1): a skipped palette block with a split transform predicted DC off its edges A square intra block that is SKIPPED predicts its whole side x side luma in one call; the palette (and intrabc) prediction override was armed only when the transform covered the whole block, so a 16x16 palette block with tx_depth == 1 and skip == 1 fell back to edge prediction. Right symbols -- the whole mode ladder diffs clean against an instrumented aomdec -- wrong pixels: 812 luma samples in the key frame of an SVT-AV1 preset-8 screen stream, carried by the V_PRED blocks under it to 10122 over 12 frames. Sibling paths (decode_leaf8, decode_rect_split, the intra-in-inter walk) already arm on both arms; this was the one site left. Gate rides the kept stream via EC_AV1_SVT1_STREAM (SKIP when unset), asserts the fixed arm fires, and adds EC_AV1_DEBUG_SKIP_LR beside the deblock/CDEF debug rungs for the stage bisect.
perf(av1): the symbol-trace annotations allocate only when the trace is armedAhmet Kaan Gümüş · 2301cb5Browse files
Merge branch 'lane-seg2' (291453c1): the sub-8x8 intra reader never read intra_segment_id and stamped a 1x1 mi footprint; film B under libaom adaptive quantization decodes exact at every ladder pointAhmet Kaan Gümüş · 4a5d8eaBrowse files
fix(av1): a sub-8x8 intra leaf stamps its own mi footprint, not 1x1Ahmet Kaan Gümüş · 120e018
fix(av1): a sub-8x8 intra leaf stamps its own mi footprint, not 1x1 An 8x4/4x8 leaf goes through the same reader as a BLOCK_4X4 split leaf; a 1x1 segment stamp left its second mi cell at segment 0, which a later block read back as the spatial prediction and cdf_index. Adds the EC_SEG / EC_SEGHDR / sub8 EC_ISTEP traces the diff was found with.
Merge branch 'lane-golomb2' (6675a24b): the straddle gate generates its segmented streams by recipe and asserts the block-q span; the Golomb reader bound is libaom's to the bit, comments correctedAhmet Kaan Gümüş · 778c3d3Browse files
fix(av1): a BLOCK_4X4 intra leaf never read its own segment_idAhmet Kaan Gümüş · 96c590f
fix(av1): a BLOCK_4X4 intra leaf never read its own segment_id read_intra_mode_sub8 skipped spec 5.11.6's intra_segment_id entirely, so on a segmented key frame the first sub-8x8 split ate the segment_id symbol's place in the tile (msac desync from that block on) and every 4x4 leaf dequantized with the previous block's SEG_LVL_ALT_Q.
docs(av1): read_golomb's cap IS libaom's (decodetxb.c:30), so the refusal is a desync symptom, never a reader gapAhmet Kaan Gümüş · 6be36b1
docs(av1): read_golomb's cap IS libaom's (decodetxb.c:30), so the refusal is a desync symptom, never a reader gap Corrects two comments that invited widening the bound, and records the lane.
Merge branch 'lane-txw' (832daabb): the tile writer coded every transform unit as TX_CLASS_2D; V_DCT/H_DCT now take the 1-D class scan, eob row and contexts; wide intra tx set ships screen-gatedAhmet Kaan Gümüş · 08bb725Browse files
test(av1): the straddle gate's SEG_LVL_ALT_Q rows are generated by recipe, not two uncommittable film cropsAhmet Kaan Gümüş · 29e03fe
test(av1): the straddle gate's SEG_LVL_ALT_Q rows are generated by recipe, not two uncommittable film crops The two pinned .obu files were crops of a real film in the gitignored shared fixtures dir, so the half of the gate that actually saw the rect dequant defect SKIPped on every fresh clone. Replaced by a synthetic lavfi source -- half flat grey, half heavy noise -- encoded by libaom -aq-mode 1, whose activity segmentation gives segments with distinct quantizers; the new decode::block_q_span() counter asserts that property so the row cannot go blind. Sensitivity re-measured: with e4cab216's six sites reverted the recipe row fails at 384x152 crf 20, frame 0 plane U (160,64), 126 vs 123.
Merge branch 'lane-d792' (2fb5e976): six rectangular dequant sites used the frame q index instead of the block's (segment ALT_Q); all 27 dequant sites take the block index nowAhmet Kaan Gümüş · df5d11d
Merge branch 'lane-d792' (2fb5e976): six rectangular dequant sites used the frame q index instead of the block's (segment ALT_Q); all 27 dequant sites take the block index now Class: parsed then discarded. Only frame edges force rectangular partitions in the references' streams, so it read as a bottom-straddle defect; the 1920x792 reference ladder decodes 8/8 exact.
fix(av1 decoder): dequantize a rectangular intra transform unit with the block's segment quantizer, not the frame'sAhmet Kaan Gümüş · cd170cb
fix(av1 decoder): dequantize a rectangular intra transform unit with the block's segment quantizer, not the frame's The rect intra paths passed FrameCtx::current_q_idx where every square path passes block_q_idx, so a block in a segment carrying SEG_LVL_ALT_Q was dequantized with the frame's own index. Only a frame edge forces rectangular partitions in the reference encoders' streams, so this showed up as a bottom-straddle-only mismatch: the whole 1920x792 reference ladder (libaom and rav1e, 8 points) now decodes sample-exact against ffmpeg, as does a 384x152 straddle repro.
Merge branch 'lane-refs' (904af5ee): the frame interpolation filter is a real knob (mc::predict had hard-wired REGULAR), default byte-identical; the LAST2 censusAhmet Kaan Gümüş · f1b38e0
Merge branch 'lane-refs' (904af5ee): the frame interpolation filter is a real knob (mc::predict had hard-wired REGULAR), default byte-identical; the LAST2 census SMOOTH/SHARP refuted as frame defaults. A second past reference would remove 7-10% of prediction SAD on both films at both levels (LAST2/LAST3 alias LAST's DPB slot today; slot 7 is free) -- built as its own lane.
lane-d792: narrow the straddle defect to the dequant step (prediction, levels, scan, tx type and the 16x8 kernel all pinned equal) and land the instrumentsAhmet Kaan Gümüş · 4caf191Browse files
fix(av1): the tile writer coded every transform unit as TX_CLASS_2DAhmet Kaan Gümüş · ae80b33
fix(av1): the tile writer coded every transform unit as TX_CLASS_2D A V_DCT/H_DCT unit is TX_CLASS_VERT/TX_CLASS_HORIZ for the decoder: its own Mrow/Mcol scan, its own eob_pt row (eob_pt_class1) and its own nz-map/base-range context offsets. The writer had none of that, so the first 1-D type any search offered -- the wider reduced_tx_set = 0 alphabets -- desynced the tile from the encoder's own trial decode, surfacing as "a reference frame selected with no picture at this frame's own ref_frame_idx slot" (class refusal-from-own-desync). write_coeffs now resolves the class off tx_type exactly as decode::TxClass::of does, and takes the class scan, the class-1 eob row and class-aware base_ctx/br_ctx from it; the pricer goes through the same function, so a priced type is priced in its own alphabet and class. The wide-alphabet witness is un-ignored: preset 0 codes 1820 V_DCT and 2435 H_DCT intra units and both decoders read the clip sample-exact.
docs(txi): the per-plane instrument, the surcharge, and the reduced_tx_set=0 blockerAhmet Kaan Gümüş · f36c793
docs(txi): the per-plane instrument, the surcharge, and the reduced_tx_set=0 blocker Also: the encoder's own trial decode of an inter frame read the tile back under a hardcoded reduced_tx_set=true instead of the frame's own bit, and EC_AV1_REFPROBE=1 names the reference slot a desynced trial decode lands on.
instrument(av1): a LAST2 SAD census and a frame-level interpolation filter knobAhmet Kaan Gümüş · 012b9fc
instrument(av1): a LAST2 SAD census and a frame-level interpolation filter knob The census answers whether a second retained past reference is worth its slot bookkeeping and its second motion search before either is built; the filter knob makes the frame's kernel reach the search, the trials and the trial decode through FrameCtx instead of a hardwired Regular in mc::predict.
2026-09-07
fix(av1): an inter block's chroma inherits its luma transform typeAhmet Kaan Gümüş · 25e26f3
fix(av1): an inter block's chroma inherits its luma transform type The decoder derives an inter block's chroma tx_type from the luma type at the block's chroma-reference position (spec 5.11.40, libaom av1_get_tx_type / reduce_inherited_chroma_tx_type); the encoder quantised chroma under a DCT_DCT basis whatever the luma type search chose, so every non-DCT luma winner had its chroma levels inverse-transformed on a basis they were never produced for. Instrumented on the bars 1080p gate row at q=60, unconditional inter type search: luma 53.66 -> 53.70 dB (the search's own win, real), U 51.97 -> 49.15, V 52.52 -> 45.53. Pre-filter frame luma sse is lower on every frame in the arm, so neither the RDOQ distortion model, the type rate term (EC_AV1_TXRD_LAMBDA=0 reproduces the collapse) nor the typed forward gain (measured 0.98-1.03 of unity for every type and size) was the cause. Adds EC_AV1_TXRD_LAMBDA / EC_AV1_TXRD_CENSUS and the per-frame / per-plane / pre- and post-filter gate instruments the diagnosis needed.
Merge branch 'lane-txset' (cdb209a0): the luma transform-type search (intra 5-type reduced set), screen-gated; forward kernels for all 16 types; the writer had coded one type everywhereAhmet Kaan Gümüş · 5b25319
Merge branch 'lane-txset' (cdb209a0): the luma transform-type search (intra 5-type reduced set), screen-gated; forward kernels for all 16 types; the writer had coded one type everywhere Screen capture +27.8/-26.0 -> +20.8/-30.1; the film rows lose unconditionally (local RD on references), so the search is gated on screen content and the film rows stay byte-identical. Pins unchanged.
fix(av1): the decoder's FrameCtx no longer reads the encoder's SB128 globalAhmet Kaan Gümüş · d1b410e
fix(av1): the decoder's FrameCtx no longer reads the encoder's SB128 global lane-sb128 seeded FrameCtx::new()'s sb128_flag / reach_sb_px from crate::encode::sb128_on(), so any test forcing the encoder knob (the 128-superblock encoder witness) made every concurrently decoding thread start its context at 128: the three real-aomenc sb128 decode gates failed in parallel and no_per_frame_state_is_thread_local_any_more flagged "encode.rs: SB128" as per-frame state outside FrameCtx. FrameCtx::new() is a DECODER context again (false / 64, overwritten by set_sb128 from the parsed sequence header). The encoder's own contexts come from the new FrameCtx::for_encoder(), used at every FrameCtx construction in encode.rs and encoder.rs, so the mode search's Reach and the filter search's internal decodes still agree with the tile writer. The static is renamed ENC_SB128 -- an encoder knob like speed::SPEED, which is what the state test's name pin intends.
feat(av1): search an intra luma transform unit's own tx_typeAhmet Kaan Gümüş · 2fd2ac4
feat(av1): search an intra luma transform unit's own tx_type The writer coded DCT_DCT for every luma transform unit ever written -- the symbol was a constant -- while the five-type reduced-set alphabet (TX_SET_INTRA_2: IDTX, DCT_DCT, ADST_ADST, ADST_DCT, DCT_ADST) was already the CDF it wrote into. The search now offers that set per intra luma unit, priced through the same RDOQ'd trial path (the tx_type symbol included, coeff_bits_typed), and the writer names the chosen type through the decoder's own symbol map (decode::tx_type_symbol, keyed by the CDF's alphabet width, so the two cannot drift). The forward transform gains the FLIPADST family as well: a flipped axis is the plain ADST basis over the mirrored residual, which is what the decoder's ud_flip/lr_flip undoes. All sixteen types now round trip.
Merge branch 'lane-sb128' (f3298510): the tile writers can walk 128x128 superblocks (EC_AV1_SB128), off by defaultAhmet Kaan Gümüş · ad81365
Merge branch 'lane-sb128' (f3298510): the tile writers can walk 128x128 superblocks (EC_AV1_SB128), off by default Structurally +7 B of partition symbols per 60 roots, but the spec forces the loop-restoration unit to 128 under a 128 superblock and the 12-frame gate loses 0.3 dB on film A for it (+21.7/-4.4 -> +38.8/+9.1). The writer's no-neighbour partition sentinel moved from 64 to the decoder's 128 (table and reader move together). Under the flag a ref-slot refusal still fires intermittently (open).
Merge branch 'lane-deltaq' (d5dddb4c): per-superblock delta_qindex from the tpl map, wired and measured, off by default; the encoder's trial decode hard-coded DeltaParamsAhmet Kaan Gümüş · 8ce79c1
Merge branch 'lane-deltaq' (d5dddb4c): per-superblock delta_qindex from the tpl map, wired and measured, off by default; the encoder's trial decode hard-coded DeltaParams Best arm is within 0.3 of the control on the films and 0.7 worse on screen (the tpl lambda arm was already neutral, so the same factor through the quantiser is the same information). decode_inter_frame_tiles_lr now takes the frame's delta params (stale-header class, instance 10).
feat(av1): the tile writers walk 128x128 superblocks under EC_AV1_SB128Ahmet Kaan Gümüş · d2e10de
feat(av1): the tile writers walk 128x128 superblocks under EC_AV1_SB128 The sequence bit, a 128 partition root whose only arm is SPLIT into the four 64x64 superblocks the encoder already codes, loop restoration read once over the 128 span (and its unit size forced to 128, the smallest a 128 superblock can signal), and libaom's TL/TR/BL/BR visit order. The writer's no-neighbour partition sentinel moves 64 -> 128 to match the decoder's: at 64 it is byte-neutral, at the 128 root it put the symbol on CDF row 3 instead of row 0.
feat(av1): per-superblock delta_qindex from the tpl mapAhmet Kaan Gümüş · 1c072fa
feat(av1): per-superblock delta_qindex from the tpl map The tpl map only scaled LAMBDA per superblock, so it could move mode decisions but never the quantizer where the map says a superblock is worth more. This codes the spec's own per-superblock syntax instead: delta_q_present with delta_q_res in the frame header, a delta_qindex symbol group at the first coded block of every superblock, and the search quantizing (luma and chroma) at that superblock's own qindex. The mapping is derived, not fitted: RD lambda goes as the square of the quantizer step, so a superblock the map gives a lambda factor f wants the qindex whose ac_q is sqrt(f) times the frame's -- inverted through the ac_q table itself. EC_AV1_DELTAQ (res log2, 0 = off), _K, _CLAMP. Also: decode_inter_frame_tiles_lr hard-coded DeltaParams::default(), the stale-header class its own three parameters above it document, so the encoder's trial decode desynced at the first superblock.
fix(av1): the key 64x64 intra root only on a superblock-aligned frameAhmet Kaan Gümüş · ce92789
fix(av1): the key 64x64 intra root only on a superblock-aligned frame A 248x152 frame -- bottom-right superblock cut on both axes -- desyncs that corner's CHROMA three ways once the frame carries whole 64 roots elsewhere (luma stays exact). Named corner-cut with the trace as its upgrade path. The filter-intra decode fixture carries a step edge now: its smooth field was coded as four whole 64x64 roots, which are too big for filter intra, so the gate went blind to the feature it pins. The witness asserts the per-FRAME mode count instead of the process-global counter.
fix(av1): two lossless INTER defects on screen content -- a skip 8x8 leaf restored the previous block's luma band, and a rect sub-8x8 intra leaf read one TX_4X8Ahmet Kaan Gümüş · 025c254
fix(av1): two lossless INTER defects on screen content -- a skip 8x8 leaf restored the previous block's luma band, and a rect sub-8x8 intra leaf read one TX_4X8 - decode_leaf8/decode_inter_block8: `saved_luma_ctx` is only valid on the arm that actually published per-TU luma state. A SKIP block publishes none, and on a lossless frame `read_block_tx_size` hands back 4x4 leaves for a skip block too, so the restore put the previous block's levels back over the zeros `record_mi` had written (libaom `av1_reset_entropy_context`). Class [[override-slot-on-one-arm]]. - decode_intra_sub8_leaf / decode_leaf_rect8 / the 16x4 rect4 reader: their `tx_depth != 0` split guards never fire on a lossless frame (no depth symbol is coded), so a 4x8/8x4 intra leaf read ONE rect transform where libaom codes two TX_4X4 -- the same widening the five other rect sites already carry. Gate: a_lossless_libaom_inter_frame_decodes_sample_exact grows a 640x384 tune-content=screen -g 3 six-frame row (inter frames of screen content).
fix(av1): lossless chroma units read a windowed palette prediction, one entropy cell, and stop at the frame edgeAhmet Kaan Gümüş · 6f56c94
fix(av1): lossless chroma units read a windowed palette prediction, one entropy cell, and stop at the frame edge Three defects the synthetic (non-screen) fixtures could not see, all found by a tune-content=screen -crf 0 stream: - a 4x4 chroma unit was handed the WHOLE-BLOCK palette prediction buffer and read it at its own stride, so every unit reconstructed the block's top-left corner (the luma split-transform paths already window; palette_window() is now shared by decode_block, decode_rect_split and the new intra helper). A 320x192 screen key frame decoded 9600/15360 chroma samples wrong. - a unit whose block hangs off the frame edge is still coded by libaom (max_blocks_high clips in LUMA mi, then rounds UP for chroma), and our two-cell neighbour read then indexed past the band. libaom reads exactly ONE chroma entropy entry for a TX_4X4 chroma unit (get_txb_ctx's a[0]/l[0]); our bands carry that entry replicated over the unit's two luma-mi cells, so one cell is the same answer and never runs off. - units whose ORIGIN is past the frame edge are not coded at all. The 320x192 and 640x384 screen key frames are now sample-exact.
feat(av1): lossless INTER frames decode -- the chroma plane is 4x4 units, plane-majorAhmet Kaan Gümüş · 5136c0f
feat(av1): lossless INTER frames decode -- the chroma plane is 4x4 units, plane-major A lossless frame codes TX_4X4 on every plane (libaom read_tx_size returns TX_4X4 before it ever consults max_txsize_rect_lookup), and decode_token_recon_block walks a 64x64 mu chunk PLANE-MAJOR (for (plane..) for (blk_row..) for (blk_col..)). The inter readers still read chroma as one transform per block, so a lossless inter frame was refused by name; they now walk the 4x4 units, and the refusal is gone. Three defects the previous lane's gate could not see (its source had a FLAT chroma plane, so every chroma unit coded one txb_skip symbol against all-zero contexts -- class gate-blind-to-feature): - decode_block read its chroma units interleaved U,V per unit instead of plane-major. Identical order at one unit per plane per chunk (every non-lossless case), wrong for a lossless block's 4x4 raster. - decode_rect_split's lossless chroma branch stamped each unit's neighbour context and then let record_split_luma_rect_mi overwrite all of them with the LAST unit's state, so the next block read dc_sign_ctx 1 where libaom reads 0 (class override-slot-on-one-arm). - decode_inter_sub8_rect2 kept one 8x4/4x8 luma transform on a lossless frame, which fed a rect grid to the 4x4 Walsh-Hadamard. Gates: the key gate's source is now textured chroma, and a_lossless_libaom_inter_frame_decodes_sample_exact replaces the retired refusal gate with four libaom -crf 0 fixtures (256x128 8-bit, 192x96 10-bit, 320x192, 256x256 --sb-size=128), each sample-exact vs ffmpeg.
feat(av1): lossless key frames decode exact; lossless inter refused by nameAhmet Kaan Gümüş · 1e1a080
feat(av1): lossless key frames decode exact; lossless inter refused by name Key/intra-only lossless frames decode sample-exact at 8 and 10 bit (64x64, 256x128 8-bit, 192x96 10-bit libaom -crf 0 streams, 0 sample diffs vs ffmpeg). The inter path's luma leaves are synthesized as TX_4X4 but its chroma plane is still one transform per block, so a lossless INTER frame is refused by name and the refusal inventory carries it. The old refusal gate becomes a_lossless_libaom_key_frame_decodes_sample_exact.
feat(av1): a lossless key frame decodes sample-exactAhmet Kaan Gümüş · b0db8e9
feat(av1): a lossless key frame decodes sample-exact The rect strip readers take the per-transform-unit walk on a lossless frame (depth_to_tx_wh returns TX_4X4 before it looks at the block), their chroma is coded as 4x4 units plane-major with get_txb_ctx's +10 offset rows, and the Walsh-Hadamard orientation is pinned by measurement. A 64x64 libaom -crf 0 key frame now decodes sample-exact against ffmpeg (6488 entropy steps identical to aomdec's EC_TRACE_COEFF, 0 sample diffs).
wip(av1): lossless lane snapshot at the turn cap (orchestrator)Ahmet Kaan Gümüş · 9a5f8e7Browse files
feat(av1): lossless decode groundwork -- WHT, TX_4X4 forcing, CfL narrowingAhmet Kaan Gümüş · f0a5a15
feat(av1): lossless decode groundwork -- WHT, TX_4X4 forcing, CfL narrowing The 4x4 Walsh-Hadamard inverse (libaom av1_iwht4x4_16_add_c) with its own round-trip test, a per-frame CodedLossless flag replacing the refusal (a frame mixing lossless and lossy segments is still refused by name), the TX_4X4 forcing in the square and 8x8-leaf intra readers, no tx_type symbol (libaom read_tx_type: qindex 0 returns early), DCT_DCT on every plane, the is_cfl_allowed narrowing to a 4x4 chroma plane block, and the +10 chroma txb_skip rows at TX_4X4 that only a lossless frame reaches.
fix(av1): a 128x128 intra block inside an inter frame re-stamped its four chroma units with the top-left one's coefficient contextAhmet Kaan Gümüş · bdab11eBrowse files
fix(av1): the palette neighbour bands are cleared by the key-frame sub-8x8 leavesAhmet Kaan Gümüş · 2fe9a36
fix(av1): the palette neighbour bands are cleared by the key-frame sub-8x8 leaves Narrows the previous commit: the 5 INTER-side zero-stamps regressed 13 tests (our own encoder's screen streams stopped decoding) because the inter readers' band index/footprint convention is not the palette bands' -- reverted, recorded in lanes/dkey.report.md as the open half of the sweep. The two key-frame sub-8x8 stamps, which are what the measured mi(76,88) desync needed, stay.
fix(av1): temporal MV candidates ignored force_integer_mvAhmet Kaan Gümüş · 0c17efc
fix(av1): temporal MV candidates ignored force_integer_mv `lower_mv_precision` implemented only its `is_integer == false` half, on a comment claiming no reachable stream sets `force_integer_mv` because `allow_screen_content_tools` is refused at the stream level. Neither half of that claim holds: libaom turns screen-content tools on for dark, smooth FILM (`av1_set_screen_content_options` counts near-flat 16x16 blocks) and then sets `force_integer_mv` on the frames its hash test calls static, and this decoder parses such streams without refusing anything. The consequence was invisible to the parse: every temporal MV candidate came out at eighth-pel where libaom rounds it to full pel, so the mv stack held values libaom never produced. The stack still had the right shape for a while, so the frame decoded "successfully" into a whole-frame prediction mismatch, and the entropy desync that followed surfaced as the unrelated refusal "a Golomb tail longer than this decoder reads" (class `refusal-names-a-correlate`). First divergence, measured against the instrumented libaom oracle: film-B gate clip, `-cpu-used 6 -crf 35 -g 12`, decode-order frame 3 (order_hint 1, the one inter frame with `force_integer_mv == 1`), block mi(0,0), the NEWMV predictor -- identical `EC_TPL` field cells and identical range in both decoders, aomdec's stack `(16,0)w16 (16,-8)w12 (8,-40)w4` against ours `(14,-4)w16 (12,-2)w8 (12,-38)w4 (16,-4)w4`. Class: `branch-dropped-as-unreachable` -- a spec branch deleted on an unreachability note that a capability change (screen-content streams no longer refused) silently invalidated. All four libaom film-B ladder points at 48 frames now decode sample-exact against ffmpeg/libdav1d except crf 5, which desyncs on the KEY frame at mi(184,344) (base_q 9) -- a separate, still-open defect.
feat(av1): a decode-side syntax census, and the film B vs rav1e table it producedAhmet Kaan Gümüş · 373b6a2
feat(av1): a decode-side syntax census, and the film B vs rav1e table it produced The BD gate says our stream is bigger; it never says which syntax it is bigger in. This adds a per-CDF-table bit accountant to the symbol decoder (EC_AV1_BITCENSUS=1, one relaxed load per symbol when off) plus block, tx, mv, mode and frame-header funnels, and an examples/syntax_census.rs that prints one table per stream -- so our stream and rav1e's are measured by the same reader. lanes/census-filmB.md holds the answer for film B at matched PSNR: the whole gap is in the inter frames (our key frame is the smaller and the worse one), 75% of it in the leaves, and the three mechanisms are the flat pyramid q ladder, the missing 64x64 blocks and transforms, and a 52.5% vs 84.8% skip share.