-
Notifications
You must be signed in to change notification settings - Fork 4.5k
[Feature] Zigzag Ring attention #5905
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
Merged
Merged
Changes from all commits
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
519818f
halfway
Edenzzzz 04b14a2
fix cross-PP-stage position id length diff bug
Edenzzzz 45b9ac1
fix typo
Edenzzzz 3047c4e
fix typo
Edenzzzz c0a5048
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] 748b0a1
unified cross entropy func for all shardformer models
Edenzzzz 0262e6b
remove redundant lines
Edenzzzz 7dfdac1
add basic ring attn; debug cross entropy
Edenzzzz a4d4e6a
fwd bwd logic complete
Edenzzzz 7a4e284
fwd bwd logic complete; add experimental triton rescale
Edenzzzz f8be40d
precision tests passed
Edenzzzz c3d7a86
precision tests passed
Edenzzzz 313bc48
fix typos and remove misc files
Edenzzzz 98627e8
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] a3bb451
add sp_mode to benchmark; fix varlen interface
Edenzzzz b104530
update softmax_lse shape by new interface
Edenzzzz 6cbc5f6
change tester name
Edenzzzz bf00238
remove buffer clone; support packed seq layout
Edenzzzz bd2d642
add varlen tests
Edenzzzz ea11927
fix typo
Edenzzzz 2f8e188
all tests passed
Edenzzzz 919eff5
add dkv_group; fix mask
Edenzzzz 04d2f88
remove debug statements
Edenzzzz 392bde6
add comments
Edenzzzz e760507
q1 index only once
Edenzzzz e90e984
remove events to simplify stream sync
Edenzzzz e26c910
clarify kv_comm.wait()
Edenzzzz b6b2333
use torch.compile; add nsys
Edenzzzz d3831b4
simplify forward/backward logic
Edenzzzz 0094bc0
2d ring forward passed
Edenzzzz 581ec0f
2d ring backward passed
Edenzzzz 1344849
fixes
Edenzzzz e6bcde2
fix ring attn loss
Edenzzzz b4c0809
2D ring backward + llama passed
Edenzzzz 26b008e
follow conventions
Edenzzzz a68dd2f
fix dist logger
Edenzzzz be5fed5
add a manual inner ring size option
Edenzzzz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
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
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
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
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.