-
Notifications
You must be signed in to change notification settings - Fork 73
Reference implementation for triangle attention ending #5730
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
+62
−28
Merged
Changes from all commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
8586d6c
Example to use efficient attention
wujingyue 6ad01f1
Builds
wujingyue c206b32
Fix test
wujingyue bfae52a
Fix test_sdpa.py
wujingyue 3a87466
Fix test_alphafold3
wujingyue f0862fa
Move to direct
wujingyue 40c13fd
WIP
wujingyue 460b683
Fix test_sdpa
wujingyue 2f68957
Change bias and mask's argument order
wujingyue 99a235e
Argument order
wujingyue 19a13dd
Data attributes
wujingyue 02a9ede
Use math
wujingyue 5f72622
unnecessary ir_utils
wujingyue 56a438b
Change batch_size and n_tokens to 3 and 5 for debugging
wujingyue 67a9ace
Comment
wujingyue bdb7dc5
Comment
wujingyue c6f122d
Fix multidevice tests
wujingyue b3673b3
Review
wujingyue e4457c9
Merge branch 'main' into wjy/bias
wujingyue ecb515b
Fix comparison
wujingyue b0d4d4d
WIP
wujingyue e293685
Comment and size
wujingyue 7c61b63
Merge remote-tracking branch 'origin/main' into wjy/end
wujingyue 363a62e
Remove duplicated validation
wujingyue 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
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.
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.
@DejunL, what are the sizes people use in practice?
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.
The Boltz reference model typically has:
Bor batch_size of 1Nor token counts of{inference: however many in request but typically ~100 to ~2000, training: {stage1: 256, stage2: 512, stage3: 768}c_zortoken_zor hidden dimension of pair representationzis 128num_headsis 4head_dimorc_hiddenis 32But in some other models they vary but probably within same order of magnitude. Typically structure prediction models are small in model weight counts but large in activation so hidden dimensions are typically small as such but I do see some models experiment with larger hidden dimensions.