Add RMSNorm (part of parallel_attn_blocks) - #448
Open
lessw2020 wants to merge 8 commits into
Open
Conversation
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #448 +/- ##
==========================================
+ Coverage 69.11% 69.17% +0.06%
==========================================
Files 170 170
Lines 11524 11547 +23
==========================================
+ Hits 7965 7988 +23
Misses 3559 3559
☔ View full report in Codecov by Sentry. |
rohan-varma
approved these changes
Aug 16, 2023
rohan-varma
left a comment
Contributor
There was a problem hiding this comment.
LG! I would just absorb the fp32 type check test into the other one for brevity.
ankitade
reviewed
Aug 16, 2023
ankitade
approved these changes
Aug 17, 2023
Contributor
|
@rohan-varma has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
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
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.
Summary:
This PR adds RMSNorm.
It is used in parallel_attention_blocks but moving the earlier mono PR for that into smaller chunks for easier review and landing.
Test plan:
added two units tests:
test_rms_norm_fp32
test_rms_core_algo (compares F.norm version vs PR version)
Fixes:
Adds requested doc string to RMSNorm from earlier PR review.