Add Qwen-Image DMD2 QAT and PEFT-backed SVDQuant - #2069
Draft
jingyu-ml wants to merge 1 commit into
Draft
Conversation
Contributor
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
Add Qwen-Image support to the Diffusers quantization and FastGen DMD2/QAT flows. Move calibrated SVDQuant low-rank factors into trainable Hugging Face PEFT adapters for NVFP4, INT4, and INT8 recipes, and preserve their topology and values through ModelOpt save/restore. Keep the final DMD2 example scoped to Qwen-Image by removing the intermediate Qwen-Image-Edit additions. Signed-off-by: Jingyu Xin <jingyux@nvidia.com>
jingyu-ml
force-pushed
the
jingyux/qwen-image-dmd2-svdquant-peft
branch
from
August 5, 2026 02:13
4e8d35c to
1583d68
Compare
|
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
Contributor
|
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 does this PR do?
Type of change: new feature / backward-breaking SVDQuant representation change
This PR adds Qwen-Image support to the Diffusers quantization example and the FastGen DMD2/QAT flow. The final diff is scoped to Qwen-Image itself; the intermediate Qwen-Image-Edit/2511 implementation has been removed.
It also changes generic SVDQuant calibration for NVFP4, INT4, and INT8 recipes so the calibrated low-rank residual is owned by a structural Hugging Face PEFT adapter:
Q(W_residual)x + B(Ax), including the existing input pre-scale and output-quantizer placement;mto.save/mto.restoreand splitmodelopt_state+ completestate_dictcheckpoints rebuild the PEFT topology and preserve A/B exactly;QATTrainercompletes structural quantization before optimizer and distributed model preparation for train/evaluate/predict.The generic unified/deployment exporter flow is intentionally unchanged.
Usage
For split checkpoints, restore
mto.modelopt_state(model)first and then load the completemodel.state_dict()before constructing DDP/FSDP and the optimizer.Testing
52 passed: focused PEFT-backed SVDQuant tests, existing calibration tests, full CPU quantization regression file, and the layerwise-calibration support gate (Slurm 303961).12 passed, 1 skipped: Qwen-Image FastGen plugin and quantizer-state round-trip tests (Slurm 303935).git diff --check, and a staged-snapshot scan confirming no Qwen-Image-Edit/2511/2512 or Attention Grill content in the PR.Before your PR is "Ready for review"
CONTRIBUTING.md: N/A; PEFT is already part of the existinghfoptional dependencies.CHANGELOG.rst?: ✅