-
Notifications
You must be signed in to change notification settings - Fork 239
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
Fix mean subtraction in layer norm kernels #519
base: main
Are you sure you want to change the base?
Conversation
Let's increase hidden_size in the unit test of layernorm to see whether the issue occurs. |
Thank you for the comment! I guess this might be a problem when hidden_size is not the power of 2 (e.g., 1536) rather than in case of just a huge hidden_size, since in such cases |
Yes, you're right. The scenario you mentioned would probably happen when n_cols is less than BLOCKSIZE (not power of 2). Feel free to add weird shape to layernorm unit test like other kernels have. |
I've tested the main branch with an additional weird shape test case, can confirm that the issue exists.
|
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.
Enhance unit test by adding a weird shape to test cases, then we can merge it!
I really appreciate your elaborating on this topic! I'd also check this and will commit the weird-shape test cases. Please wait for a while 🙇 |
Summary
This PR is the possible proposal to the Issue: #518
I've confirmed neither that the issue is really a issue nor that this PR can pass tests, so made this as a draft PR.
I'd like someone interested in this to check them please... 🙇