Skip to content
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

Remove arrays of scaling factors #116

Merged
merged 3 commits into from
Aug 22, 2023
Merged

Remove arrays of scaling factors #116

merged 3 commits into from
Aug 22, 2023

Conversation

devmotion
Copy link
Member

@devmotion devmotion commented Aug 9, 2023

Alternative to #114 that avoids the computation of the array of scaling factors completely.

Tested locally with regular arrays and static arrays. Using broadcast instead of map (potentially including d etc. as broadcasted arguments) would return SizedArrays instead of StaticArrays for SArray inputs, hence I went with map instead.

Has to be tested with Zygote and CUDA as well (for the latter it might be useful to set up GPU tests with buildkite and for the former downstream tests with Zygote, limited to FFTs, would be useful).

Edit: Tests of Zygote#master pass locally with this PR.

@codecov
Copy link

codecov bot commented Aug 9, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.30% 🎉

Comparison is base (ee9f1b8) 93.57% compared to head (3bb61b6) 93.87%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #116      +/-   ##
==========================================
+ Coverage   93.57%   93.87%   +0.30%     
==========================================
  Files           5        5              
  Lines         420      441      +21     
==========================================
+ Hits          393      414      +21     
  Misses         27       27              
Files Changed Coverage Δ
ext/AbstractFFTsChainRulesCoreExt.jl 100.00% <100.00%> (ø)
ext/AbstractFFTsTestExt.jl 100.00% <100.00%> (ø)
src/definitions.jl 84.07% <100.00%> (+0.96%) ⬆️

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@gaurav-arya
Copy link
Contributor

gaurav-arya commented Aug 9, 2023

What do you think of adding tests of view inputs? E.g. see #117 (made a PR to this branch rather than a code suggestion since I cannot code suggest on unchanged files).

@gaurav-arya
Copy link
Contributor

Bump on merge?

@stevengj stevengj merged commit fae1170 into master Aug 22, 2023
@stevengj stevengj deleted the dw/scale branch August 22, 2023 15:50
@gaurav-arya
Copy link
Contributor

Can we get a release, mainly in order to include this PR and fix Zygote tests? (FluxML/Zygote.jl#1452)

@devmotion
Copy link
Member Author

I think there are some problems with #113 which is included in the master branch. Would be good to fix those first, or revert #113, before tagging a new release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants