-
Notifications
You must be signed in to change notification settings - Fork 152
QuantizationModifier refactor #1183
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
Merged
Merged
Conversation
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
… file, add object routing for yaml load (#1059) * move existing ModifierQuantization and tests to legacy file * [QuantizationModifier] refactor base - move deprecated code to legacy file, add object routing for yaml load
…emes to generate QConfigs (#1061) * [QuantizationModifier] pydantic classes for defining quantization schemes to generate QConfigs * review response
…le from QuantizationScheme (#1185) * [QuantizationModifier] base refactor flow - quantize entire module from QuantizationScheme * review response * testing - lifecycle + QAT application * activate qat tests
…ation with schemes and stronger testing (#1198)
…sable module types from quantization (#1199)
…fic submodules by scheme (#1201) * [QuantizationModifier] submodule_schemes property impl - target specific submodules by scheme * generalize helper fn name + quality
…heme by layer type (#1202) * [QuantizationModifier] module_type_schemes - override quantization scheme by layer type * yaml pydoc example
…finetuning support (#1206)
* [QuantizationModifier] logging support * fake quantize bits logging
…1239) * rename modifier default_scheme -> scheme * refactor set_quantization_schemes (tests passing with existing UX) * exclude_module_types -> ignore ; adds submodule exclusion * refactor submodule and module type schemes into unified submodule_overrides
…xes (#1261) * [QuantizationModifier] take ownership of add_observers_, unit test fixes * suggestion from review - with quality override * review - suggested comment * fixes for FloatFunctional support (resnet50 broke)
b805b62
to
b79486e
Compare
KSGulin
approved these changes
Dec 16, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!!
corey-nm
approved these changes
Dec 19, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀 🎉
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.
Main feature branch for the QuantizationModifier refactor project. Goal of the project is to create a new interface that provides more flexibility (via the
QuantizationScheme
config) while including default targets that protect more against future torch default changes.UX
Users have full control over what gets quantized through a default
scheme
, overriding defaults for module types or submodules withscheme_overrides
, and skipping module types or submodules withignore
sample config:
Tasks
Sample section of ResNet-50 quantized with new default flow
Test Plan