This repository has been archived on 2026-11-24. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
radiance-sycl/docs
gearwave00001andClaude 241629fe8c test(ref2va): measure video/image VAE encoder parity = DIVERGED (#14)
The audio half of the #14 strict numeric value-parity was already measured and
found to diverge. This measures the OTHER half — the conv3d_ndhwc video/image
encoder, a separate kernel family — the same device-INPUT-anchored way, and it
diverges too, with the SAME signature.

New harness tests/data/ref2va/ref_venc_parity.py:
- Does NOT import comfy.ldm.minimax.vae (that drags comfy attention -> an aiter
  JIT build that fails on this box), so like vae_geom/gen_golden.py it
  AST-extracts just the encoder classes + the _normalize_pixels /
  _encode_moments methods, execs them on torch alone, and loads the REAL fp16
  minimax_h3_video_vae_fp16.safetensors into encoder+quant_conv (decoder
  excluded; the encode path has no attention). --selftest validates the
  reshape / normalisation / sorted metric with no device involvement.
- Device stores b_evc PATCH-FOLDED (op_ve_fold: 24ch x 2x2 = 96-wide rows) and
  per-channel-normalised. The fold is a pure bijection and the norm is
  per-channel, so the value MULTISET of the device slot region matches the
  reference's normalised latent regardless of fold order; the harness compares
  the two SORTED value vectors. This is immune to re-deriving the fold's
  (t,h,w)+channel packing — the mistake that once cost a bogus audio reading.
- A single reference IMAGE is the cleanest case (encode()'s T==1 branch, one
  clip, exactly one latent frame), so keep-first/last is moot; the harness
  refuses T_pad!=1.

Two inert, R4D_ENC_DEBUG-gated dumps added to core/gen/video_driver.cpp (the
staged pixel buffer + enc_geom, next to the existing audio ones) so the
reference can be fed the device's OWN staged input and only encoder math can
differ. Zero-touch when R4D_ENC_DEBUG is unset.

Result on a 256x256 gradient picture: sorted relative Frobenius 0.65, device
latent std 0.44 vs reference 1.15 (~2.6x under-spread), max-abs 4.26. DIVERGED
like the audio path.

The finding is the SHARED signature: audio collapsed std 0.59->0.23 (~2.6x) and
video 1.15->0.44 (~2.6x) across two entirely different kernel families, AND for
BOTH families the latent-normalisation constants are byte-identical to the
reference (kVaeLatentsMean/Std vs LATENTS_MEAN/STD max rel-diff 0.0). So the
collapse is NOT the norm constants and NOT audio-specific — this refines the
earlier "suspect the strided conv1d temporal reduction" note. Localising it
needs stage-by-stage activation dumps on kernels the live image/plain paths also
run through, so the kernels are deliberately NOT blind-fixed. The device
encoders remain content-live and deterministic (cont.3/5/19): self-consistent,
so conditioning is genuinely live; only reference-matching OUTPUT fidelity is
open (= #10 / P6).

docs/NOTE-REF2VA.md point 4 records the video-half result and the sharpened
ruling-out of the normalisation constants.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-10-19 16:26:21 -05:00
..
2026-10-18 15:41:44 +02:00
2026-10-18 11:38:37 +02:00
2026-10-18 15:41:44 +02:00
2026-10-16 18:25:18 +02:00
2026-10-16 18:25:18 +02:00
2026-10-16 18:25:18 +02:00
2026-10-16 18:25:18 +02:00
2026-10-16 18:25:18 +02:00
2026-10-18 11:38:37 +02:00
2026-10-16 18:25:18 +02:00
2026-10-16 18:25:18 +02:00
2026-10-16 18:25:18 +02:00