-
Notifications
You must be signed in to change notification settings - Fork 251
[FX][AWQ][Scale Estimation][Mixed Precision] Add Data Aware Algorithm Support for FX Backend #3409
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
base: develop
Are you sure you want to change the base?
Conversation
@anzr299 , please share conformance test results for these methods |
for node in next_nodes: | ||
target_points.append( | ||
PTTargetPoint( | ||
PTWeightCompressionAlgoBackend.TARGET_TYPE_TO_PT_INS_TYPE_MAP[TargetType.PRE_LAYER_OPERATION], |
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.
Could you please specify the actual target type without the dict?
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.
Done, my reasoning behind this approach was that it will be less modular if we directly define it in case of changes to the target type in the future
class FXMixedPrecisionAlgoBackend(MixedPrecisionAlgoBackend, FXWeightCompressionAlgoBackend): | ||
@staticmethod |
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.
Do we have a plan on how to reuse the same classes across all the PyTorch backends? If not, could you please create a ticket for that?
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.
Maybe we can set a flag in a common backend class (such as FX=False) when initializing it.
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.
@anzr299, It would be great if you would open a ticket and implement a make a proposal which we could discuss with the team
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.
Alright, I will do that
Changes
The following algorithms were added for Torch FX backend:
Tests
TemplateWeightCompression
was extended for torch FX backend for the above algorithms intests/torch/fx/test_compress_weights.py