Repository navigation
test: define Wan fused BF16 parity budget - #8188
Conversation
Signed-off-by: andyluo7 <andy.luo@amd.com>
|
Self-review: I checked the current |
|
This PR appears to be related to model: Wan. Model owners: @bjf-frz @NickCao @yenuo26 Routing: @bjf-frz via semantic router, model owner; @NickCao via CODEOWNERS; @yenuo26 via CODEOWNERS @andyluo7, please review your own changes and leave a short self-review comment describing what you checked. PRs without author self-review may not be assigned a reviewer. Please take a look when you have a chance. If you would like an automated review, mention @vllm-omni-review-bot in a comment. |
Omni ReviewBot triage noteAutomated triage of commit
These are automated triage suggestions only — the final decision belongs to the maintainers. |
Signed-off-by: andyluo7 <andy.luo@amd.com>
Omni ReviewBot: supersededThe CI failure noted on |
Omni ReviewBot routing recordAssigned Strict under experiment |
vllm-omni-review-bot
left a comment
There was a problem hiding this comment.
Omni ReviewBot review
PR description
This pull request changes only the Wan decoder CPU fast-path test. The exact streaming path still has to match the untouched decoder bit-for-bit, and the fused path in FP32 still uses a tight assert_close. Under BF16 autocast, fused outputs are now judged by a pair of absolute budgets: worst-element error at four BF16 epsilons and whole-tensor RMS error at one BF16 epsilon, instead of a generic allclose. The same fused check is used for the local decoder and the two-rank gloo shard.
Change flow
flowchart TD
A["[EXISTING] WanStreamingDecoder CPU chunks"]:::existing
B["[EXISTING] install_wan_decoder_fast_path exact/fused"]:::existing
C["[CHANGED] _check_pair local and 2-rank compare"]:::changed
D["[NEW] _assert_fused_output_close BF16 max+RMS budget"]:::new
E["[EXISTING] exact torch.equal; FP32 fused assert_close"]:::existing
A --> B --> C
C -->|"fused bf16"| D
C -->|"exact / fused fp32"| E
classDef existing fill:#e5e7eb,stroke:#6b7280,color:#111827
classDef changed fill:#fef3c7,stroke:#d97706,color:#451a03,stroke-width:2px
classDef new fill:#dcfce7,stroke:#16a34a,color:#052e16,stroke-width:2px
classDef removed fill:#fee2e2,stroke:#dc2626,color:#450a0a,stroke-width:2px
CI at
d37f77f62950(2026-09-27T20:39:55.130997+00:00): required check(s) blocking:buildkite/vllm-omni(failed), and -5 more. Observed Buildkite:buildkite/vllm-omni-amd-ci(failed),buildkite/vllm-omni-npu-ci(passed),buildkite/vllm-omni(failed), and 1 more.
No actionable findings.
|
CI failed |
|
Fresh exact-head CI after syncing with current Wan BF16 validation passed on AMD build #12898:
The AMD aggregate is red only for failures outside this one-file Wan test diff:
All other required checks passed: generic Buildkite #16263, Intel #9220, NPU #7984, pre-commit/Ruff, both wheel builds, DCO, and docs. There are no failures attributable to #8188. The remaining gates are the known #8165 baseline/routing dependency and maintainer approval. |
Summary
Root cause
FusedWanRMSNormSiLUreturns BF16 activations immediately, while the eager Wan norm keeps its affine and SiLU result in FP32 until the following convolution rounds it. Requiring bit identity, or a generic elementwise relative tolerance near zero, treats that intentional precision boundary as a regression.Across repeated AMD failures the observed maximum absolute errors were 0.0195 and 0.0273. The new contract caps the worst output error at four BF16 epsilons (0.03125) and the whole-output RMS error at one BF16 epsilon (0.0078125). Decoder outputs are tanh-bounded to [-1, 1], so these absolute limits are directly interpretable.
Examples:
Validation
python3 -m py_compile tests/diffusion/distributed/test_wan_decoder_fast_path.pygit diff --check origin/main...HEADb34e9bfb5e45648b7f92d1031ab66372f2035db0, synchronized with currentmainafter test: keep Hunyuan LoRA CPU path on native linear #8166:Signed-off-by: andyluo7 andy.luo@amd.com