-
Notifications
You must be signed in to change notification settings - Fork 72
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
Warn (or fail) on requested field-of-view too large for pupil sampling #180
Comments
Comment by mperrin This is actually the very first thing mentioned at the top of the "Known Issues" documentation section, but I know, nobody reads that. :-) http://pythonhosted.org/webbpsf/relnotes.html#known-issues There is some chance that I will have a very high resolution pupil map available in the not so distant future for calculations that do need this size. On the other hand, at distances like 60" or beyond, incoherent scatter can matter as much as diffraction. We have models for that but it's a different set of physics than what webbpsf is currently set up to simulate. |
Comment by mmechtley Ok guilty as charged on not reading the webbpsf known issues. :x re: NIRCam/JWST pupil maps specifically, the desire to go larger than ~30" was mostly cosmetic in our case. We were simulating some bright stars in candidate deep fields and the edge of the PSF image was obvious. So naturally I just tried going bigger, then ran into this issue. As a PSF aficionado, modeling effects like incoherent scatter sounds interesting to me, but probably me alone. One day. Note: for intermediately-bad sizes (this was 40" diameter) you get aliasing of diffraction spikes but it wasn't immediately obvious what was causing them (the bands in the background). |
Comment by mperrin I've made substantial progress in being able to model very large FOV PSFs, by now having a numerical representation of the JWST complex pupil geometry which I can evaluate on an arbitrary sampling. (I.e. I now have a version of the JWST pupil implemented as a But it also lets me generate gray pixel versions of 1024 pixel pupils by binning down higher resolution pupils. This dramatically cuts down on the aliasing seen at the intermediate scales in your images above. For comparison here are 3 PSFS calculated monochromatically at 2.1 microns, for a FOV=60 arcsec across. I've tried computing a 120 arcsec PSF directly from the 8192 pixel pupil file, but my poor laptop can't handle it and Python's been chugging away for 20 minutes with 40 GB of RAM allocated on a machine with only 16 GB physical. Gonna have to run that on a bigger machine at the office. |
Comment by mperrin Hi @mmechtley I just added a check for requested FOVs that exceed the critical angle for Nyquist sampling of the input pupil. If the user requests too large a FOV, at the very start of the PSF calculation it will issue warnings like this: This check is performed on a per-wavelength basis inside |
Comment by mmechtley Looks excellent! Warning provides exactly the information I'd want. I'd consider the issue resolved. The large FoV PSFs above look great too. The NIRCam folks I'm working with will enjoy that. I assume with the AnalyticOpticalElement approach you don't get to use the OPD maps? Not a big deal for the aesthetics of simulated images of course. |
Comment by mperrin Argh - I was surprised you needed to make any changes in My plan for the next release of |
Comment by josePhoenix Yep, I spotted the |
Issue by mmechtley
Monday Aug 22, 2016 at 19:27 GMT
Originally opened as mperrin/poppy#180
I ran into this the other day when making NIRCam PSFs with webbpsf, though the issue is generic to poppy rather than specific to webbpsf. I put in a stupid-large output size (60"), then realized I was getting aliasing problems when I saw multiple copies of the PSF in my output. I think the problem's cause and its solution won't be obvious to many users -- mostly non-PSF specialists using tools like webbpsf rather than poppy users directly, though see e.g. the same problem in issue #135. TinyTim handled this by just forcing a max size since it knew its pupil sampling, but obviously that doesn't work for a more flexible system like this.
At the simplest (logic-wise) level I guess this would involve something like checking lambda/D and the pixel sampling at the last pupil plane (at least for FFT-based propagation), but warning early before lots of computation would be ideal.
The text was updated successfully, but these errors were encountered: