-
Notifications
You must be signed in to change notification settings - Fork 11
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
splitting NuFFT into base and uu,vv cached class. #232
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-
It looks like the pyro tutorial has an outdated called to the nufft.
-
The naming for nufftcached and nufft makes sense, but I would suggest not reusing the name of an old class for a new class with a different functionality and/or call signature. Yes the code is pre-1.0 and you want the new nufft to be the default, but this breaks backwards compatability and will probably be frustrating for some users. Instead, the cached implementation could still be
NuFFT
and the new could beNuFFTdynamic
or something. If the new names are kept as is, I'd suggest the changelog note that the NuFFT is not backwards compatible as of the next release version.
Thanks for the review!
Ah, right. This is in the "large-tutorials" whose cache is not cleared with a
I agree the change of names is unfortunate, but I think the original implementation and naming was enough of a mistake that it should be corrected (especially since we are pre-1.0, the user base is small, and we should take these opportunities for re-organization/consolidation). The new |
…rices to table-based for nufft.
closes #231 when complete.
fourier.NuFFT
-> newfourier.NuFFTCached
. The__init__
call offourier.NuFFTCached
is the same as the oldfourier.NuFFT
. You would use it likenufft = fourier.NuFFTCached(coords=coords, nchan=1, uu=uu, vv=vv)
fourier.NuFFT
that does not require uu or vv on init. You would init it likenufft = fourier.NuFFT(coords=coords, nchan=1)
. The difference comes when using theforward
routine, in that you now supply u and v points. E.g.,nufft(image_cube(), uu, vv)
fourier.NuFFT
should be the go-to routine for most use cases. Thefourier.NuFFTCached
should be used when one expects to make multiple calls toforward
using the exact same set of uu and vv points (but different input images).