-
Notifications
You must be signed in to change notification settings - Fork 349
[not4land] Some fixes for MXFP8 #3183
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: main
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/3183
Note: Links to docs will display an error until the docs builds have been completed. ❌ 1 New FailureAs of commit acfd12d with merge base ff16308 ( NEW FAILURE - The following job has failed:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
x = torch.randn(128, 32, device="cuda", dtype=torch.bfloat16) | ||
y_ref = m(x) | ||
y_mx = m_mx(x) | ||
with torch.inference_mode(): |
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 what makes the test fail, without changes to the product code?
return _addmm_mx_dispatch(a, b, func, bias=bias) | ||
|
||
@implements([aten.linear.default]) | ||
def mx_linear(func, types, args, kwargs): |
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.
I think the reshape should live here, the addmm
op is supposed to have 2d inputs
a = args[0] | ||
b = args[1] | ||
bias = args[2] if len(args) > 2 else None | ||
return _addmm_mx_dispatch(a, b.t(), func, bias=bias) |
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.
IMO either don't pass func
into addmm_mx_dispatch
, or we should rename it to something like addmm_or_linear_mx_dispatch
No description provided.