TinyOpenFold: fix V3 Triton correctness, add torch.compile, validate on ROCm 7.13#171
Open
asitav wants to merge 2 commits into
Open
TinyOpenFold: fix V3 Triton correctness, add torch.compile, validate on ROCm 7.13#171asitav wants to merge 2 commits into
asitav wants to merge 2 commits into
Conversation
…on ROCm 7.13 - Fix V3 Triton LayerNorm (correct fwd+bwd with autograd wrappers so gradients flow) and use fused SDPA + QKV fusion; test_correctness now passes 4/4 - Add --enable-torch-compile to V1 and V3 as an orthogonal optimization axis (V2 already had it) - Update README with ROCm 7.13 (TheRock) setup and refresh tutorial performance numbers measured on MI300X / ROCm 7.13
Contributor
Author
|
@gcapodagAMD, @bobrobey please note. |
gcapodagAMD
reviewed
Jul 21, 2026
| ```bash | ||
| # ROCm 7.13 requires Python 3.14 from the module system. | ||
| # (The module ships libpython3.14.so.1.0, which pyenv/system Python 3.14 lacks.) | ||
| module load python/3.14 |
Collaborator
There was a problem hiding this comment.
@asitav what system did you work on? we do not have a python module on aac6. we do have a rocm/7.13.0 module but it is not a nightly build
Contributor
Author
There was a problem hiding this comment.
@gcapodagAMD OK, I simply built it from the prepackaged python libs that comes with every release, e.g., https://github.com/ROCm/TheRock/blob/therock-7.13/RELEASES.md . But, I agree I will have to correct the text that it may come as a module also.
Contributor
Author
There was a problem hiding this comment.
Corrected the narrative in the next commit.
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
raw kernels bypassed autograd (no gradients flowed). Added
autograd.Functionwrapperswith correct backward passes and switched attention to fused SDPA + QKV fusion.
version3_triton/test_correctness.pynow passes 4/4 (LayerNorm numerics, MSA attention,full-model forward, gradient flow).
--enable-torch-compileto V1 and V3 (V2 already had it) as an orthogonaloptimization axis available across all versions.
and refresh the tutorial's performance tables with numbers measured on MI300X / ROCm 7.13.
Test plan
version3_triton/test_correctness.py→ 4/4version2_pytorch_fused/tiny_openfold_v2.py --verify-accuracy→ pass--enable-torch-compile(small + medium)