Repository navigation
NVFP4 on the fine-grained machinery - #49779
Draft
IlyasMoutawwakil wants to merge 19 commits into
Draft
IlyasMoutawwakil wants to merge 19 commits into
IlyasMoutawwakil wants to merge 19 commits into
Conversation
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 20, 2026 11:08
3afadf9 to
4050b0b
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 20, 2026 11:20
4050b0b to
1986d87
Compare
|
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update. |
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 20, 2026 13:33
1986d87 to
0967ed4
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 20, 2026 14:35
0967ed4 to
0af5e23
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 20, 2026 15:30
0af5e23 to
33ba73d
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 20, 2026 15:47
33ba73d to
d89fabc
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 20, 2026 16:04
d89fabc to
95d3b51
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 20, 2026 16:25
95d3b51 to
45ed092
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 20, 2026 16:43
45ed092 to
d130d74
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 20, 2026 17:34
d130d74 to
fb471e1
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 22, 2026 07:00
e08039f to
bba8419
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 22, 2026 07:00
e08039f to
bba8419
Compare
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 22, 2026 07:18
bba8419 to
4a79406
Compare
2 tasks done
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 23, 2026 13:03
4a79406 to
a7ac103
Compare
… NVFP4 exports - NVFP4Config / NVFP4HfQuantizer become a block-scaled format: E2M1 weights with E4M3 group-16 scales and an fp32 global (two-level), in both modelopt layouts (per expert, stacked per layer) and compressed-tensors'; the gate|up halves' globals fold through FineGrainedWeightGlobals; a weight-only checkpoint refuses quantized activations; integrations/nvfp4 is frozen. - shared_gate_up_activation_global: share the experts' gate_up activation global (max over all experts or over the rank's). - The modelopt and compressed-tensors readers learn NVFP4 (incl. modelopt MIXED_PRECISION plans across formats). - MuseSpark: its input-scaled RMS norm fuses into the kernels' chain, and its TP plan keeps experts with a post-expert norm whole. - Tests: the NVFP4 suite, the producer readers and skip-lists, the NVFP4 marshalling and conversion tests, mixed FP8/MXFP4/NVFP4 plans. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…sion plans Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Nothing imports it. It was single-device, not serializable, and no checkpoint shipped its layout. Its lazy exports and its hub kernel entry go with it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A weight-only checkpoint then needs activation_format="bf16" in a passed config, unless the load dequantizes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…zzle Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
It shipped in v5.16 to v5.19, so its names warn and go in v5.25 instead of breaking now. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
MuseSpark's norm declares fused_norm_kind, so the shared integration no longer imports a model. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…roducer readers' PR NVFP4 keeps its own key layout, the ModelOpt one that transformers saves. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
IlyasMoutawwakil
force-pushed
the
fg-split/7-nvfp4
branch
from
October 23, 2026 13:35
a7ac103 to
9ee98c8
Compare
Contributor
|
[For maintainers] Suggested jobs to run (before merge) run-slow: muse_spark, qwen4_exp, finegrained, nvfp4 |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What.
NVFP4ConfigandNVFP4HfQuantizerbecome a block-scaled format. Weights are E2M1 with an E4M3 scale per 16 and anfp32 global. This moves NVFP4 onto the shared kernels and loaders that FP8 and MXFP4 already use.
(GLM-5.2-NVFP4) and stacked per layer (vLLM).
FineGrainedWeightGlobals. A gate|up stack keeps one global, so the up ratiomoves into the down global.
input_scaleto run them with. The check isskipped when the load dequantizes, since a dequantized model runs no activation format.
NVFP4Configkeeps main's positionalmodules_to_not_convert, so existing callers keep working.integrations/nvfp4.pystays importable, with aFutureWarning. It goes in v5.25.(1 + weight)and rounds tobf16 before the norm, so it gets its own kernel name.
tiny-random-Muse-Spark-NVFP4is its first user.Behaviour change. A pre-quantized NVFP4 checkpoint on CPU dequantizes instead of raising.
Depends on. #49778.
How tested.
tests/quantization/nvfp4, the NVFP4 testsin
tests/kernelsandtests/integrations/finegrained, mixed FP8/MXFP4/NVFP4 plans, Qwen4-exp.The comments and docstrings that say why each change exists are there for readability. Feel free to ask for any of them to go if it's self-evident.
🤖 Generated with Claude Code