Skip to content

Fix configuration reading and error handling for kernels#45610

Merged
vasqu merged 6 commits intomainfrom
fix-qwen3.6-fp8
Apr 23, 2026
Merged

Fix configuration reading and error handling for kernels#45610
vasqu merged 6 commits intomainfrom
fix-qwen3.6-fp8

Conversation

@hmellor
Copy link
Copy Markdown
Member

@hmellor hmellor commented Apr 23, 2026

Fixes the following issues when trying to run Qwen3.6 FP8 checkpoints such as Qwen/Qwen3.5-35B-A3B-FP8. This PR fixes the following issues:

  • The FP8 checkpoint stores the experts in a nn.ModuleList but the necessary WeightConverters were missing
  • When kernels was not installed it failed with a confusing attribute error
  • The backup config names are eagerly read in FP8Experts.__init__ so models which use the primary name fail with attribute errors

Closes #44230

hmellor and others added 3 commits April 23, 2026 17:14
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
Co-authored-by: Copilot <copilot@github.com>
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

@vasqu vasqu left a comment

Choose a reason for hiding this comment

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

LGTM overall, I don't really think we need the changes in fp8 - would be nice if you could clarify that

Comment thread src/transformers/conversion_mapping.py Outdated
Comment thread src/transformers/integrations/finegrained_fp8.py Outdated
Comment thread src/transformers/integrations/finegrained_fp8.py
@HuggingFaceDocBuilderDev
Copy link
Copy Markdown

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.

@vasqu
Copy link
Copy Markdown
Contributor

vasqu commented Apr 23, 2026

Feel free to merge after the conversion mapping + getattr detail 🤗

Co-authored-by: Copilot <copilot@github.com>
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
@hmellor hmellor enabled auto-merge April 23, 2026 18:00
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
@vasqu vasqu disabled auto-merge April 23, 2026 18:16
@vasqu vasqu merged commit 91904ac into main Apr 23, 2026
27 of 29 checks passed
@vasqu vasqu deleted the fix-qwen3.6-fp8 branch April 23, 2026 18:17
@github-actions
Copy link
Copy Markdown
Contributor

View the CircleCI Test Summary for this PR:

https://huggingface.co/spaces/transformers-community/circle-ci-viz?pr=45610&sha=a18eb3

vasqu pushed a commit that referenced this pull request Apr 23, 2026
* Fix missing conversion of experts

Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>

* Fix eager config attribute reading

Co-authored-by: Copilot <copilot@github.com>
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>

* Add proper error when kernels isn't installed

Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>

* remove unnecessary mapping

Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>

* review comments

Co-authored-by: Copilot <copilot@github.com>
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>

* remove double newline

Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>

---------

Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
Co-authored-by: Copilot <copilot@github.com>
@vasqu vasqu added the for patch Tag issues / labels that should be included in the next patch label Apr 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

for patch Tag issues / labels that should be included in the next patch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[fp8] qwen3-vl-fp8/qwen3.5 moe fp8 support (infer)

3 participants