Skip to content

[Model] Muse Glimmer: reuse in-tree RMSNorm / GemmaRMSNorm - #64920

Merged
jeejeelee merged 3 commits into
vllm-project:mainfrom
bohnstingl:muse_glimmerrmsnorm
Nov 2, 2026
Merged

jeejeelee merged 3 commits into
vllm-project:mainfrom
bohnstingl:muse_glimmerrmsnorm

Conversation

@bohnstingl

@bohnstingl bohnstingl commented Oct 31, 2026 •

Copy link
Copy Markdown
Contributor

Overview

Replace the model-local MuseGlimmerRMSNorm (added in #51655) with the existing RMSNorm and GemmaRMSNorm CustomOps. The output is bit-identical in bf16.

Claims

  • Removes the model-local MuseGlimmerRMSNorm class. All norms in the model now use the shared CustomOps, so they get are enabled for the OOT-platform swapping.
  • No numerical change: each replacement matches the old class bit-for-bit in bf16.
  • No checkpoint or weight-loading change: parameter names and shapes are unchanged.

Validation

Old class vs replacement, bf16, A100, x = 257×5120, both forward_native and forward_cuda:

Norm (old config) Replacement Result
with_scale=False (qk_norm, embed_norm, perception_emb_norm) RMSNorm(dim, has_weight=False) bit-exact
weight_offset=1 (4 sandwich norms) GemmaRMSNorm(dim) bit-exact
final norm RMSNorm(dim, dtype=torch.float32) bit-exact
.venv/bin/python -m pytest tests/models/test_initialization.py \
    -k "MuseGlimmerForCausalLM or MuseGlimmerForConditionalGeneration" -v
# 2 passed

gsm8k on meta-models/Muse-Glimmer-30B (BF16, TP=2 on 2×A100-80GB, --model-impl vllm, 5-shot, 1319 questions, greedy, max 256 tokens):

Accuracy Correct Invalid Throughput (tok/s)
main (e318ac0979) 0.9181 1211 / 1319 1 1911
this PR 0.9189 1212 / 1319 0 1930

The 1-question delta is batching noise; the norms themselves are bit-exact.

vllm serve meta-models/Muse-Glimmer-30B --model-impl vllm --dtype bfloat16 \
    --tensor-parallel-size 2 --max-model-len 4096 \
    --limit-mm-per-prompt '{"image": 0, "video": 0}'
python tests/evals/gsm8k/gsm8k_eval.py --num-shots 5 --num-questions 1319

Details

The old class covered three cases, each of which already exists in-tree:

  • No weight: norm(x.float()).type_as(x) is RMSNorm(has_weight=False).
  • (1 + w) sandwich norms: these are HF's MuseGlimmerTextCenteredRMSNorm, a copy of Gemma's norm, so GemmaRMSNorm matches.
  • Final norm: HF computes (norm(x.float()) * w.float()).type_as(x). The in-tree op multiplies in the weight's dtype, so the weight is kept in fp32 to match HF's single cast. The fp32 weight survives the bf16 default dtype at init and default_weight_loader. The trade-off is that the fused vllm_c kernel requires matching weight/input dtypes, so this one norm (once per forward) takes the native PyTorch path instead.

Not in scope: Gemma2-style fused residual-add in the decoder layer, which would change forward.

No open PR touches this: searched open PRs for MuseGlimmerRMSNorm, MuseGlimmer RMSNorm and muse_glimmer norm.

cc @xianbaoqian @jeejeelee @zixi-qi @TheEpicDolphin (authors of #51655)


Pull Request Checklist
  • I used vLLM's /pr-checklist skill. (Mandatory for agents, optional for humans).

  • AI assistance was used during the creation of this PR.

  • Design Fit: Minimizes impact on core components, reuses existing functionality, and justifies added complexity.

  • Testing and Validation: Validates the change and ensures any added tests are meaningful and reliable, with CI coverage or documented CI resource constraints and validation performed outside CI.

  • Code Quality and Style: Keeps code and comments clear and concise, and updates relevant documentation and examples.

  • Pull Request Contents: Includes a brief summary and relevant links, supports claims with evidence, explains root causes and implementation trade-offs, and follows the contributing guide.

Signed-off-by: Thomas Ortner <boh@zurich.ibm.com>

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

@jeejeelee

Copy link
Copy Markdown
Member

/ci run

@jeejeelee
jeejeelee enabled auto-merge (squash) November 2, 2026 09:30
@github-actions github-actions Bot added the ready ONLY add when PR is ready to merge/full CI is needed label Nov 2, 2026
@github-actions

github-actions Bot commented Nov 2, 2026

Copy link
Copy Markdown

✅ Triggered Buildkite CI #99135 for commit f4fe8c8ff395.

ℹ️ This PR is 48 commits behind upstream main. Merged upstream main into this branch as f4fe8c8ff395 before starting CI. Pull the branch before pushing more changes.

@bohnstingl

Copy link
Copy Markdown
Contributor Author

I think the failing CI tests are not from this PR and a resolution is provided through #65140

@bohnstingl

Copy link
Copy Markdown
Contributor Author

/ci run

@github-actions

github-actions Bot commented Nov 2, 2026

Copy link
Copy Markdown

✅ Triggered Buildkite CI #99205 for commit 59c76771e846.

@jeejeelee

Copy link
Copy Markdown
Member

@bohnstingl if so, we can force merge this PR, please don't trigger CI again

@jeejeelee
jeejeelee merged commit f4aeb1c into vllm-project:main Nov 2, 2026
119 checks passed
bohnstingl pushed a commit to bohnstingl/spyre-inference that referenced this pull request Nov 3, 2026
Strict-xfail probe that flips once the pinned vLLM carries
vllm-project/vllm#64920, signalling that the Muse Glimmer norm swap can be
deleted.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Signed-off-by: Yannick Schnider <Yannick.Schnider1@ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready ONLY add when PR is ready to merge/full CI is needed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants