-
Notifications
You must be signed in to change notification settings - Fork 359
make float8 a1x128_w128x128 granularity serializeable #3279
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: gh/vkuzo/161/head
Are you sure you want to change the base?
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/ao/3279
Note: Links to docs will display an error until the docs builds have been completed. ❗ 1 Active SEVsThere are 1 currently active SEVs. If your PR is affected, please view them below: ✅ No FailuresAs of commit e6b16a3 with merge base f856d36 ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
Summary: Change the granularity for this scaling type from `PerBlock((1, 128)), PerBlock((128, 128))` to `PerBlock([1, 128]), PerBlock([128, 128])`, to get around the current limitation of config serialization not supporting tuples. Error when serializing tuples: https://gist.github.com/vkuzo/ab4d6aec83cb98ad9417898d2c024a2c Supporting tuples and lists would be a better long term fix, but the workaround will unblock further work in the short term. Test Plan: ``` pytest test/quantization/quantize_/workflows/float8/test_float8_tensor.py -s -x ``` Reviewers: Subscribers: Tasks: Tags: ghstack-source-id: e150e2a ghstack-comment-id: 3480842282 Pull-Request: #3279
Summary: Change the granularity for this scaling type from `PerBlock((1, 128)), PerBlock((128, 128))` to `PerBlock([1, 128]), PerBlock([128, 128])`, to get around the current limitation of config serialization not supporting tuples. Error when serializing tuples: https://gist.github.com/vkuzo/ab4d6aec83cb98ad9417898d2c024a2c Supporting tuples and lists would be a better long term fix, but the workaround will unblock further work in the short term. Test Plan: ``` pytest test/quantization/quantize_/workflows/float8/test_float8_tensor.py -s -x ``` Reviewers: Subscribers: Tasks: Tags: ghstack-source-id: 68799cc ghstack-comment-id: 3480842282 Pull-Request: #3279
| KernelPreference.AUTO, | ||
| KernelPreference.TORCH, | ||
| ), "unimplemented" | ||
| assert self.mm_config is None, "unimplemented" |
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.
is this supported now?
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.
yes, this is tested with the serialization flow. When the object is created a default value of mm_config is set, and then when object is saved and reloaded, that value then makes it to the constructor.
Summary:
Change the granularity for this scaling type from
PerBlock((1, 128)), PerBlock((128, 128))toPerBlock([1, 128]), PerBlock([128, 128]),to get around the current limitation of config serialization not
supporting tuples.
Error when serializing tuples:
https://gist.github.com/vkuzo/ab4d6aec83cb98ad9417898d2c024a2c
Supporting tuples and lists would be a better long term fix, but the
workaround will unblock further work in the short term.
Test Plan:
Reviewers:
Subscribers:
Tasks:
Tags: