-
Notifications
You must be signed in to change notification settings - Fork 52
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
Handle NonDynamicallyQuantizableLinear in smoothquant module #30
Comments
Hey, this is unrelated, its a different api. there's just a bug in the swap_linear_with_smooth_fq_linear. |
Merged
HDCharles
added a commit
that referenced
this issue
Jan 3, 2024
Summary: certain custom linear modules add additional inputs to the forward that need to be handled but can be otherwise ignored. Additionally swap_linear_with_smooth_fq_linear had a bug where linear subclasses would get past the if statement and error on the dict key lookup since the actual class wasn't expected. (#30) enabled NonDynamicallyQuantizableLinear to work with smoothquant and fixed bug for other subclasses. At some point this should be brought in line with the other APIs if its getting use. Test Plan: python test/test.py Reviewers: Subscribers: Tasks: Tags: [ghstack-poisoned]
HDCharles
added a commit
that referenced
this issue
Jan 3, 2024
Summary: certain custom linear modules add additional inputs to the forward that need to be handled but can be otherwise ignored. Additionally swap_linear_with_smooth_fq_linear had a bug where linear subclasses would get past the if statement and error on the dict key lookup since the actual class wasn't expected. (#30) enabled NonDynamicallyQuantizableLinear to work with smoothquant and fixed bug for other subclasses. At some point this should be brought in line with the other APIs if its getting use. Test Plan: python test/test.py Reviewers: Subscribers: Tasks: Tags: ghstack-source-id: 059b392376f36bf13be16ec992a52063707b5abc Pull Request resolved: #28
HDCharles
added a commit
that referenced
this issue
Jan 3, 2024
Summary: certain custom linear modules add additional inputs to the forward that need to be handled but can be otherwise ignored. Additionally swap_linear_with_smooth_fq_linear had a bug where linear subclasses would get past the if statement and error on the dict key lookup since the actual class wasn't expected. (#30) enabled NonDynamicallyQuantizableLinear to work with smoothquant and fixed bug for other subclasses. At some point this should be brought in line with the other APIs if its getting use. Test Plan: python test/test.py Reviewers: Subscribers: Tasks: Tags: ghstack-source-id: 059b392376f36bf13be16ec992a52063707b5abc Pull Request resolved: #28
fixoed in linked PR |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Expected:
NonDynamicallyQuantizableLinear
layer is skipped (possibly with a warning), or properly handled.Actual: exception.
It sounds like HDCharles was planning on fixing this more generally: pytorch/pytorch#58969
The text was updated successfully, but these errors were encountered: