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

Fixes to test suite to support CUDA arrays #118

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

gaurav-arya
Copy link
Contributor

@gaurav-arya gaurav-arya commented Sep 4, 2023

Implemented changes:

  • A more generic construction of the random array in test_plan_adjoint
  • An option to disable testing wrapper types (in our case, views), since we do not support them correctly when it comes to avoiding ambiguities with * (see Handling wrapper array inputs #119. I don't expect it to be solved in the immediate future, which is why I prefer to work around it for now).
  • Tests correctness of fftdims as an iterable rather than its specific form, in accordance with the function contract.

@codecov
Copy link

codecov bot commented Sep 4, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (511d56b) 93.70% compared to head (2db1545) 93.73%.
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #118      +/-   ##
==========================================
+ Coverage   93.70%   93.73%   +0.02%     
==========================================
  Files           5        5              
  Lines         445      447       +2     
==========================================
+ Hits          417      419       +2     
  Misses         28       28              
Files Coverage Δ
ext/AbstractFFTsTestExt.jl 100.00% <100.00%> (ø)
src/TestUtils.jl 50.00% <ø> (ø)

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

Copy link
Contributor Author

@gaurav-arya gaurav-arya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove Random.rand! usage

Project.toml Outdated Show resolved Hide resolved
ext/AbstractFFTsTestExt.jl Outdated Show resolved Hide resolved
ext/AbstractFFTsTestExt.jl Outdated Show resolved Hide resolved
@gaurav-arya
Copy link
Contributor Author

Bump on review:) It should hopefully be an easy review, especially because this does not touch the core functionality, only the test utilities, which I have verified continue to work with FFTW and after this also with CUDA on JuliaGPU/CUDA.jl#2073

@gaurav-arya
Copy link
Contributor Author

Bump

@gaurav-arya
Copy link
Contributor Author

Bump on review. @devmotion raised in #118 (comment)) the issue of map not being contractually obligated to preserve the array type. But it does so in practice for all the cases I want to add these downstream tests, we didn't come up with a better solution, and we could easily improve the test suite with a backwards compatible solution in the future if that edge case does crop up.

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.

2 participants