LSSTDESC / imSim

GalSim based Rubin Observatory image simulation package
https://lsstdesc.org/imSim
BSD 3-Clause "New" or "Revised" License
36 stars 15 forks source link

Fix various aspects of the make_fft_psf code. #392

Closed rmjarvis closed 1 year ago

rmjarvis commented 1 year ago

This PR fixes a number of things.

  1. First, the PSF we use for FFT drawing needs to be achromatic, so the new ChromaticAtmosphere PSF needs to be evaluated at the bandpass effective wavelength before we do further processing in make_fft_psf.
  2. The unit test I wrote to test this discovered that our modified FFT PSF (to make sure not to use the atmospheric screens in FFT mode, which is super slow) doesn't end up with a good match to the one with screens. There were a few things to change to make it work better: a. Get rid of the SecondKick, which we don't need. b. Add back in an Airy, which is implicitly part of a SecondKick piece. c. Use VonKarman with the L0 from the screen, rather than Kolmogorov
  3. The LSST_Silicon stamp type was implicitly dependent on there being an output field using LSST_CCD, which we don't want. All it needed from that was the det_name. So now it's a required parameter in LSST_Silicon, where the template config gets that from the output field.
  4. It also got the camera from the output field, which again we don't want. So that's now an optional parameter as per how we set this elsewhere in imsim.

I also added a run of the new examples/imsim-user.yaml to our CI tests to make sure that runs, which is what triggered this bug fix. Now CI should notice when that breaks.