Skip to content

make FFTW a soft dependence #106

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

Merged
merged 3 commits into from
Dec 29, 2019
Merged

make FFTW a soft dependence #106

merged 3 commits into from
Dec 29, 2019

Conversation

johnnychen94
Copy link
Member

@johnnychen94 johnnychen94 commented Dec 19, 2019

This can reduce loading time ~50%:

  • This PR: 1.280366 seconds (1.50 M allocations: 87.844 MiB, 0.82% gc time)
  • Before: 2.707802 seconds (6.70 M allocations: 350.225 MiB, 1.67% gc time)

I do have two questions wrt Requires:

  • will indirect loading of FFTW( e.g. using ImageFiltering) trigger this?
  • does loading order matters? (e.g., using ImageCore; using FFTW vs using FFTW; using ImageCore)

My understanding is yes to both.

@johnnychen94
Copy link
Member Author

In the nightly test there's a package warning:

┌ Warning: Package ImageCore does not have FFTW in its dependencies:
│ - If you have ImageCore checked out for development and have
│   added FFTW as a dependency but haven't updated your primary
│   environment's manifest file, try `Pkg.resolve()`.
│ - Otherwise you may need to report an issue with ImageCore
└ Loading FFTW into ImageCore from project dependency, future warnings for ImageCore are suppressed.

@RalphAS
Copy link
Contributor

RalphAS commented Dec 19, 2019

You can suppress the warning by using

import .FFTW

in src/functions.jl (note the "dot")

@codecov
Copy link

codecov bot commented Dec 19, 2019

Codecov Report

Merging #106 into master will increase coverage by 0.07%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #106      +/-   ##
==========================================
+ Coverage   66.19%   66.27%   +0.07%     
==========================================
  Files           9        9              
  Lines         426      427       +1     
==========================================
+ Hits          282      283       +1     
  Misses        144      144
Impacted Files Coverage Δ
src/functions.jl 100% <ø> (ø) ⬆️
src/ImageCore.jl 63.15% <100%> (+2.04%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a66027f...1795320. Read the comment docs.

@timholy
Copy link
Member

timholy commented Dec 29, 2019

Great idea!

I do have two questions wrt Requires:

  • will indirect loading of FFTW( e.g. using ImageFiltering) trigger this?

Yes

  • does loading order matters? (e.g., using ImageCore; using FFTW vs using FFTW; using ImageCore)

No

@timholy timholy merged commit 6602a45 into JuliaImages:master Dec 29, 2019
@johnnychen94 johnnychen94 deleted the jc/fftw branch January 2, 2020 09:00
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