-
Notifications
You must be signed in to change notification settings - Fork 25k
[quant][refactor] Factor out MHA code dup from nn and nn.quantizable #51169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…antizable Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. [ghstack-poisoned]
💊 CI failures summary and remediationsAs of commit 1416aab (more details on the Dr. CI page):
🕵️ 4 new failures recognized by patternsThe following CI failures do not appear to be due to upstream breakages:
|
…n and nn.quantizable" Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. [ghstack-poisoned]
…antizable Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. ghstack-source-id: 33af6f8 Pull Request resolved: #51169
thanks for doing this, high level LGTM if the numerics did not change and it's just copy-pasta. Do we need the fp32 MHA folks to approve? |
The more I think about this PR, the more I think this is a bad idea :) We can discuss it offline |
…n and nn.quantizable" Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. Differential Revision: [D26092530](https://our.internmc.facebook.com/intern/diff/D26092530) [ghstack-poisoned]
…antizable Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. ghstack-source-id: 63fdad7 Pull Request resolved: #51169
…n and nn.quantizable" Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. Differential Revision: [D26092530](https://our.internmc.facebook.com/intern/diff/D26092530) [ghstack-poisoned]
…uantizable" Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. Differential Revision: [D26092530](https://our.internmc.facebook.com/intern/diff/D26092530) [ghstack-poisoned]
Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. ghstack-source-id: 5f49abe Pull Request resolved: #51169
The main con of this refactor is that once we implement the quantized BMM and Softmax, we will have to refactor again. |
…uantizable" Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. Differential Revision: [D26092530](https://our.internmc.facebook.com/intern/diff/D26092530) [ghstack-poisoned]
…uantizable" Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. Differential Revision: [D26092530](https://our.internmc.facebook.com/intern/diff/D26092530) [ghstack-poisoned]
…uantizable" Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. Differential Revision: [D26092530](https://our.internmc.facebook.com/intern/diff/D26092530) [ghstack-poisoned]
Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. ghstack-source-id: e2e150e Pull Request resolved: #51169
…uantizable" Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. Differential Revision: [D26092530](https://our.internmc.facebook.com/intern/diff/D26092530) [ghstack-poisoned]
Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. ghstack-source-id: 065da6e Pull Request resolved: #51169
…uantizable" Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. Differential Revision: [D26092530](https://our.internmc.facebook.com/intern/diff/D26092530) [ghstack-poisoned]
Quantizable MHA shares some code with its FP equivalent. This factors out common parts. Test Plan: Explicit testing is not available, as there is no functional tests for the nn.MHA. However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart. ghstack-source-id: d6f4c3e Pull Request resolved: #51169
what are good next steps here? Are we planning to land this PR, or do something else? |
Looks like this PR hasn't been updated in a while so we're going to go ahead and mark this as |
Stack from ghstack:
Quantizable MHA shares some code with its FP equivalent.
This factors out common parts.
Test Plan:
Explicit testing is not available, as there is no functional tests for the nn.MHA.
However, the functional equivalence of this PR was tested across commits by comparing the numerics of the pre-change and post-change MHA. Similar was done for the quantizable counterpart.
Differential Revision: D26092530