GalSim-developers / GalSim

The modular galaxy image simulation toolkit. Documentation:
http://galsim-developers.github.io/GalSim/
Other
226 stars 107 forks source link

drawFFT_finish vs image.calculate_inverse_fft #1199

Closed jecampagne closed 1 year ago

jecampagne commented 1 year ago

Hi, in the gsobject.drawFFT there is a chain of 3 functions

I was wandering what prevent to use the kImage.calculate_inverse_fft() function in place of the last step (drawFFT_finish) ? Thanks

rmjarvis commented 1 year ago

I'm not sure what you mean by prevent here. The two functions have to do slightly different things before and after the actual call to _galsim.irfft. So we couldn't just replace the drawFFT_finish call with calculate_inverse_fft within drawFFT. But if a user wants to do that for some other use case, there isn't anything preventing you from doing so.