Added TorchAO FP8 weight-only and static quantization + user guides - #4577
Closed
micwill755 wants to merge 1 commit into
Closed
Added TorchAO FP8 weight-only and static quantization + user guides#4577micwill755 wants to merge 1 commit into
micwill755 wants to merge 1 commit into
Conversation
3 tasks
Collaborator
Author
|
Closing this fork-headed PR so we can reopen the same commits from pytorch/TensorRT branches. GitHub native Stacks (1/2, 2/2) cannot include PRs from forks. |
7 tasks
Collaborator
Author
|
Replacement (same-repo stack 1/2): #4589 |
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.
Description
Adds TorchAO FP8 support to the Dynamo path: weight-only (
dequantize_affine→ TensorRTIDequantizeLayer) and static FP8 (non-decomposedquantize_affine_float8/dequantize_affine_float8). Constant folding is updated so those DQ ops stay in the graph and are not folded into dense BF16/FP16 weights.This matches the existing ModelOpt INT8/FP8/FP4 QDQ flow, but for TorchAO tensor-subclass checkpoints. Examples cover a toy
nn.Linear(WOQ and static) and FLUX.1-dev WOQ. User-guide, troubleshooting, and gallery docs are updated. HTML underdocs/is left to the post-merge docgen bot.Dependencies:
torchao(examples list it inexamples/dynamo/requirements.txt). FP8 compile/runtime needs Hopper or newer (compute capability ≥ 9).Fixes # (issue)
Type of change
Please delete options that are not relevant and/or add your own.
Checklist: