Skip to content

[diffusion] Warm up CI cases at the request's quality level - #42958

Merged
mickqian merged 1 commit into
sgl-project:mainfrom
niehen6174:diffusion-ci-warmup-quality
Oct 7, 2026
Merged

mickqian merged 1 commit into
sgl-project:mainfrom
niehen6174:diffusion-ci-warmup-quality

Conversation

@niehen6174

@niehen6174 niehen6174 commented Oct 7, 2026 •

Copy link
Copy Markdown
Collaborator

Motivation

Since #42370, consistency-checked CI requests pin quality=exact, but server warmup still runs the default lossless level. Warmup therefore mounts the lossless-tier fusions, and the timed exact request unmounts them and runs a path warmup never touched.

The LTX refinement stages, already close to their limits, now exceed them on every retry: 2-GPU partition 2 passed 1 of 17 diffusion PR runs after 10-07 03:00 UTC (ltx_2_two_stage_t2v, ltx_2.3_two_stage_t2v_2gpus, ltx_2_3_two_stage_ti2v_2gpus). The server log shows the mismatch directly: warmup logs Mounted LTX-2 fused RMSNorm+modulate for quality=lossless (and two more fusions), then the request runs at exact.

The same mismatch shows up for other models. The LTX cases fail first because they have the least headroom:

Model CI cases Fusions warmup mounts at lossless Request Evidence Slowdown
LTX-2 / LTX-2.3 ltx_2_two_stage_t2v, ltx_2.3_two_stage_t2v_2gpus, ltx_2_3_two_stage_ti2v_2gpus linear+GELU, QKNorm+split-RoPE, RMSNorm+modulate exact H200 server log and A-B-A (first two cases); H100 CI failures (all three) refinement +10% / +14% (A-B-A); over the limit on every H100 retry
Wan 2.1 wan2_1_i2v_14b_480P_2gpu, wan2_1_t2v_1.3b_teacache_enabled, wan2_1_t2v_1.3b_upscaling_4x, wan2_1_t2v_1_3b_lora_1gpu linear+GELU exact H100 CI log not measured, still passes
FLUX.1 flux_image_t2i_2_gpus, flux1_modelopt_fp8_t2i LN+modulate, linear+GELU exact H100 CI log not measured, still passes
Qwen-Image qwen_image_edit_2511_ti2i, qwen_image_layered_i2i added-QKV, linear+GELU exact H100 CI log not measured, still passes
HunyuanVideo, GLM-Image, LongCat-Image, LingBot Video, Helios - lossless-tier fusion sites in the model code - code only not measured

Modifications

  • When a CI case's request names a quality level, the same level is merged into the server's --warmup-sampling-params. Existing warmup params are kept, a level the case sets itself is kept, and aliases are normalized (extra-high -> lossless).
  • Request parameters are unchanged; only warmup changes. Test code only, no runtime change.
  • Unit tests: every CI case with a request quality warms up at that quality (fails without this change), and the merge keeps existing params.

Validation

Same H200 with H100 free memory emulated (80,900 MiB per GPU, original two-stage mode), eager as in CI, 3 interleaved rounds. LTX2RefinementStage, per-run and median:

Case before #42370 (49bafb58cd) main (c52dcc5a01) main + this change
ltx_2_two_stage_t2v 800 / 775 / 772 (775 ms) 836 / 860 / 850 (850 ms) 749 / 760 / 743 (749 ms)
ltx_2.3_two_stage_t2v_2gpus 869 / 880 / 852 (869 ms) 964 / 1001 / 991 (991 ms) 860 / 885 / 859 (860 ms)

CI States

Latest PR Test (Base): ❌ Run #37613001428
Latest PR Test (Extra): 🚫 Run #37613296122
Latest PR Test (AMD ROCm 10): ❌ Run #37613001149

Motivation: since sgl-project#42370 consistency-checked CI requests pin
quality=exact while warmup runs the default lossless level, which mounts
lossless-tier fusions. The timed request unmounts them and runs a path
warmup never touched; the LTX refinement stages, already near their
limits, now fail on every retry.

Modifications: when a case's request names a quality level, merge the
same level into --warmup-sampling-params, keeping existing warmup params
and any level the case set itself.

Validation: H200 with H100 free memory emulated, eager, round 1: warming
up at exact brings LTX2RefinementStage back from 836 to 749 ms
(ltx_2_two_stage_t2v, baseline commit 800 ms) and from 964 to 860 ms
(ltx_2.3_two_stage_t2v_2gpus, 869 ms). New unit tests; the CI-case one
fails without this change.
@github-actions github-actions Bot added the diffusion SGLang Diffusion label Oct 7, 2026
@niehen6174
niehen6174 marked this pull request as ready for review October 7, 2026 11:18
@niehen6174 niehen6174 added run-ci CI: run the baseline test suite on this PR highest-priority CI: all three control labels, plus never batch-cancelled or stale-closed labels Oct 7, 2026
@niehen6174

Copy link
Copy Markdown
Collaborator Author

/tag-and-rerun-ci

@niehen6174

Copy link
Copy Markdown
Collaborator Author

/rerun-failed-ci

1 similar comment
@niehen6174

Copy link
Copy Markdown
Collaborator Author

/rerun-failed-ci

@mickqian
mickqian merged commit 0b63526 into sgl-project:main Oct 7, 2026
415 of 462 checks passed
mickqian pushed a commit that referenced this pull request Oct 7, 2026
Picks up #42958, which warms CI cases up at the request's quality level.
Without it the LTX-2 two-stage cases on the 2-GPU partition run their timed
request on a path warmup never touched and exceed their refinement limits;
main itself fails the same way.

The two streamed-encode tests move to python/sglang/multimodal_gen/test/unit/
with the rest of the diffusion unit tests (#42706), dropping their
register_cuda_ci call as the moved files did: that directory is collected
whole, so new files need no registration.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
mickqian pushed a commit that referenced this pull request Oct 7, 2026
… the streamed encode

Encoding the MP4 while the VAE decodes moves the encode inside
DecodingStage, and with it inside e2e (which is the sum of the stages).
On main the encode ran after the last stage, so neither number covered it:
the 1.07-1.10 s DecodingStage baselines and the e2e baselines measured less
work than the request does. The stage timers also do not synchronize, so
the old DecodingStage figure was mostly the CPU-side launch (0.30 s against
1.48 s of GPU decode on a synchronized H200 run); the encoder's close() now
waits for the decode inside the stage, which is the first time this stage
reports what it costs.

Whole requests are not slower: same-process A/B with the streamed encode
off and on gives 1.817 s against 1.729 s for decode plus encode, and the
fastwan request total (MP4 written) is 3.29 s against 3.55 s on main.

New values are the medians of the 7 retries of each case on H100, in the
first run with #42958 merged (37645482900):

  fastwan2_2_ti2v_5b  DecodingStage 1073.10 -> 2173.40, e2e 2444.17 -> 3073.51
  wan2_2_ti2v_5b      DecodingStage 1098.67 -> 2172.17, e2e 14853.56 -> 15599.56

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
mickqian pushed a commit to adenzhou1350/sglang that referenced this pull request Oct 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

diffusion SGLang Diffusion highest-priority CI: all three control labels, plus never batch-cancelled or stale-closed run-ci CI: run the baseline test suite on this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants