add missing mul! methods with transpose#56
Merged
mcabbott merged 3 commits intoFluxML:mainfrom May 6, 2025
Merged
Conversation
mcabbott
reviewed
May 6, 2025
Member
mcabbott
left a comment
There was a problem hiding this comment.
Thanks!
I think some tests on GPU are in order, as the ones here pass before the PR. (Which is still good, to check that it doesn't break things which worked.)
Also tests for various ways to provide the wrong-sized arrays to this method. (IIRC NNlib.scatter! might be @inbounds.)
mcabbott
reviewed
May 6, 2025
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #56 +/- ##
==========================================
- Coverage 96.26% 95.18% -1.09%
==========================================
Files 3 3
Lines 134 166 +32
==========================================
+ Hits 129 158 +29
- Misses 5 8 +3 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
2 tasks
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.
This adds the missing
mul!methods that break the initial (minimal) example in #55. The*method now falls back to this instead of having a separate definition with mutatingNNlib.scatter.It is undoubtedly inefficient to make a separate call to
fill!before executing theNNlibkernel, but I have verified thatNNlibalready does this, so this shouldn't be any different than usingscatter.PR Checklist