[Quantized DeConv Support] Enable Quantized Transposed Convs with groups==1#11774
Merged
Conversation
…ups==1 Pull Request resolved: #11730 Supporting Quantized Transposed Convs with Groups being 1. Previously, There was some added support for Quantized Transposed Convolutions but only when the channel axis is 1 and when the groups is 1. The current Quantizer didn't support this because it only allows quantizaing along the zero dim, which is generally the output channels. However for TransposedConvs, the dimension of the weights are: ``` [in_channels, out_channels/groups, h, w] ``` Since we want to keep quantization along the output channels, we now need to quantize along axis = 1. The reason we require groups to be one is because XNNPACK takes in filters of the dimension: ``` [out_channels, H, W, in_channels/groups] ``` Since we are quantizing along the output channels, in pytorch we expect to have out_channels/groups scales, but in xnnpack we have out_channels scales! Realistically we would need to support this with some affine quantization, where we provide a scale for every group, every out_channel. However for now, we just ensure the constraint where groups == 1. ghstack-source-id: 291033630 @exported-using-ghexport Differential Revision: [D76631781](https://our.internmc.facebook.com/intern/diff/D76631781/)
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/11774
Note: Links to docs will display an error until the docs builds have been completed. ⏳ No Failures, 31 PendingAs of commit 59118e0 with merge base d83636d ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
…groups ==1 (#11775) This PR was created by the merge bot to help merge the original PR into the main branch. ghstack PR number: #11731 by @mcr229 ^ Please use this as the source of truth for the PR details, comments, and reviews ghstack PR base: https://github.com/pytorch/executorch/tree/gh/mcr229/32/base ghstack PR head: https://github.com/pytorch/executorch/tree/gh/mcr229/32/head Merge bot PR base: https://github.com/pytorch/executorch/tree/gh/mcr229/31/orig Merge bot PR head: https://github.com/pytorch/executorch/tree/gh/mcr229/32/orig @diff-train-skip-merge Co-authored-by: Max Ren <maxren@meta.com>
hinriksnaer
pushed a commit
to hinriksnaer/executorch
that referenced
this pull request
Jun 26, 2025
…ups==1 (pytorch#11774) This PR was created by the merge bot to help merge the original PR into the main branch. ghstack PR number: pytorch#11730 by @mcr229 ^ Please use this as the source of truth for the PR details, comments, and reviews ghstack PR base: https://github.com/pytorch/executorch/tree/gh/mcr229/31/base ghstack PR head: https://github.com/pytorch/executorch/tree/gh/mcr229/31/head Merge bot PR base: https://github.com/pytorch/executorch/tree/main Merge bot PR head: https://github.com/pytorch/executorch/tree/gh/mcr229/31/orig @diff-train-skip-merge --------- Co-authored-by: Max Ren <maxren@meta.com> Co-authored-by: Gregory Comer <gjcomer@meta.com>
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.
This PR was created by the merge bot to help merge the original PR into the main branch.
ghstack PR number: #11730 by @mcr229
^ Please use this as the source of truth for the PR details, comments, and reviews
ghstack PR base: https://github.com/pytorch/executorch/tree/gh/mcr229/31/base
ghstack PR head: https://github.com/pytorch/executorch/tree/gh/mcr229/31/head
Merge bot PR base: https://github.com/pytorch/executorch/tree/main
Merge bot PR head: https://github.com/pytorch/executorch/tree/gh/mcr229/31/orig
@diff-train-skip-merge