Repository navigation
Conversation
… from STPSF sources
… thermal backgrounds
…than separately testing allowedPos
rmjarvis
force-pushed
the
roman_cycle10
branch
from
December 3, 2026 19:37
a093c50 to
0a9aa3c
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is a pretty huge PR. Apologies to the reviewers...
It was meant to just involve updating the reference files to the latest versions. Cycle 10 and in some cases later updates. But the way the reference data has changed since the versions we had in galsim.roman meant that we needed quite a few code updates to use the data appropriately.
The biggest change is that we no longer ship any roman reference files with the galsim repo. Instead, there is a new
galsim_download_roman, which users can run to download the reference files, process them as needed, and write the files in the galsim.share directory. This is analogous togalsim_download_cosmos, which is required to use the RealGalaxy class and related functionality. So now, you need to run the roman downloader to be able to use the functions ingalsim.roman.A lot of the data come from the STPSF reference files. The latest version there is 2.3.0, which is where we get pupil plane masks, aberration files, bandpasses, and IPC kernels. The pupil plane masks in that collection have 25 images per SCA in a 5x5 grid. However, they are half the resolution that they used to be. For applications where you want the diffraction spikes to look really good at large distances, this is a regression. So I also download the high-resolution images from the 2.2.0 version of the data. These only have one image per SCA per filter though. So there is a tradeoff between spatial fidelity (only available for pupil_bin>=2) and quality of diffraction spikes on bright stars (for pupil_bin=1).
The STPSF data don't include the WCS. For Piff (the application I most care about for this stuff), this doesn't matter, since we get the real WCS from the asdf file. But I made the downloader script get the latest WCS solution from CRDS. This will (by default) always get the latest solution, so you can keep running this to get updates when they are available. You can also specify a particular CRDS context if you want a specific one.
I also updated the sky background files. These don't really have a super current version, but I realized that the version we were using is just zodiacal light. I updated the file using the original STScI cache to get the galactic emission and CIB component as well. This takes a moderately long time to build (~6 min) because the data is spread over thousands of files each requiring its own url request. So rather than build that in the downloader, I did the whole thing once and uploaded it as a fixture on one of our release branches, just like I did the des_data file recently. This file also stores spectra rather than surface brightness now, so
roman.getSkyLevelnow integrates the spectrum over the bandpass to get the right sky level on each SCA.Some other things come from other URLS. The thermal background numbers and the effective area curves come from Roman project technical information pages. The latter is used to compute a better estimate of the collecting_area number we have stored in galsim.roman.
There are other numbers that were hard-coded constants in galsim.roman, which are now derived from something in the download data. These are stored in a file by the downloader and accessed when people use the attribute.