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.
Currently there only exists scalar methods for atomic operations. This PR adds more methods for parity with Python, plus convenience methods to make e.g. atomic addition through
ct.atomic_addas simple asct.store, using tile-space indices (tuple of indices) that get converted and broadcasted to index tiles. This would be particularly convenient for the backward pass of Multi-Head Attention with query groups (see #16), but I'm ok with removing it if it is deemed unnecessary.Since the atomic methods work with indices in tiles, I added broadcasting methods to allow the broadcasted
Oneto be used on integer tiles.Also adds tests for 2D gather/scatter that I should've added in #23.
Closes #50