STScI Logo

Wide Field Infrared Survey Telescope
PSF Simulation

Point-spread function for a G0V star imaged at the Wide Field Instrument of WFIRST, viewed in six filters. (Intensity is shown in log scale. Axes are labeled in arcseconds.) Point-spread function for a G0V star imaged at the Wide Field Instrument of WFIRST, viewed in six filters.
(Intensity is shown in log scale. Axes are labeled in arcseconds.)

Introduction to WebbPSF for WFIRST

WebbPSF-WFIRST provides a customizable interface to perform point-spread function (PSF) simulations and calculations for the Wide-Field Instrument (WFI) planned for WFIRST. A simulated PSF provides a useful tool for predicting the observatory's performance at a particular combination of wavelength (or bandpass), field position, and pixel scale. PSFs are also an important input to simulate astronomical scenes. For example, WebbPSF-WFIRST PSFs are used by the Pandeia and STIPS toolkits developed at STScI.

Functionality

PSFs are simulated in the far-field limit (Fraunhofer domain) using the same optical simulation library as the existing WebbPSF software. WebbPSF was developed to simulate JWST instrument PSFs, and its accuracy has been checked against ground test data for JWST (see the references listed below). The WebbPSF-WFIRST WFI model is based on the Cycle 5 WFIRST design revision, and it incorporates information from GSFC Instrument Reference Information files.

WebbPSF-WFIRST allows users to calculate PSFs both in the bandpasses defined in the Final Report of the WFIRST-AFTA Science Definition Team (Table 3-2) and for the monochromatic case (which can be useful as an input to other calculations). For broad-band PSFs, WebbPSF allows the user to select an input spectrum (e.g. a stellar spectral type or a galaxy spectral energy distribution) which then weights the individual monochromatic components of the PSF appropriately.

The software provides several built-in analysis tools to compute a radial profile, an encircled energy curve, or the difference image of two PSFs. All of these analysis tools work with standard FITS files with appropriate header keywords, and the PSF calculation results from WebbPSF can be written directly to FITS files for export to other tools.

Compared to the current WebbPSF instrument models for JWST, WebbPSF-WFIRST adds support for field-dependent PSF aberrations both within a single detector and among the eighteen detectors in the WFI focal plane. These are modeled as Zernike coefficients, using the instrument reference data from the Cycle 5 design revision.

Getting Started with WebbPSF-WFIRST

The same functionality is available to users in two ways. Users may log in (via their web browsers) to a server maintained by STScI, and run their calculations in a Jupyter Notebook interface that combines interactive controls with Python code for analysis. (A demonstration notebook is provided to show off the capabilities of WebbPSF-WFIRST.)

Alternatively, all the same functionality is available in a Python package for installation on the user's own computer.

Using the WFIRST Tools Server

STScI is providing a new tool called JupyterHub for running select WFIRST software tools, including WebbPSF. This provides the convenience to run calculations through a web browser on an STScI server that has the necessary software pre-installed. This removes the need for installing software locally (although we do provide that as an alternative for WebbPSF). Access to the JupyterHub server is offered upon request, but is restricted to people connected to the WFIRST Project and Science Teams. To get started, refer to these instructions.

When logging in to the WFIRST Tools Server for the first time, there will be a list with some demonstration notebooks showing the sorts of calculations that can be performed. The demonstration notebook for WebbPSF-WFIRST offers a graphical interface to the basic functionality of WebbPSF-WFIRST for those who don't wish to write their own Python code, as well as code samples illustrating the use of the Python scripting interface for more advanced calculations.

Screenshot of the WebbPSF-WFIRST Jupyter notebook GUI Screenshot of the WebbPSF-WFIRST notebook GUI

Installing WebbPSF-WFIRST on your own computer

The latest WebbPSF package includes both JWST and WFIRST instrument models and is available for download and installation on your own computer.

The instructions for installation for WebbPSF are the same whether you are using the JWST or WFIRST functionality, so users should refer to the WebbPSF installation documentation for installation options.

After WebbPSF is installed, the WebbPSF-WFIRST tutorial notebook discussed above can be downloaded from here (or previewed here). Users of a scientific Python distribution like Ureka or Anaconda can simply download the notebook file to a folder and launch "ipython notebook" (or "jupyter notebook") in that folder from the command line. (Note that the graphical interface in the notebook depends on the "ipywidgets" package, which you may have to install with "pip install ipywidgets".)


Example calculation showing the high-spatial-frequency wavefront error map, the addition of field dependent aberrations, and the final PSF. Example calculation showing the assumed high-spatial-frequency wavefront error map due to the telescope assembly, the addition of field dependent aberrations in the instrument focal plane, and the calculated PSF (before sampling on the detector pixels).

Citing WebbPSF

A technical report that discusses the assumptions underlying WebbPSF-WFIRST, and that compares its model PSFs to those calculated with alternative tools, is in preparation. For now, users are encouraged to cite one of the following publications covering WebbPSF's JWST functionality:

Assumptions and Caveats

The WFIRST functionality of WebbPSF is still in continued development. The present implementation is made available to the community as a beta version.

The WFIRST Mission is not yet in development, and observatory designs continue to evolve. Hence, WebbPSF-WFIRST simulations may not accurately reflect the actual future observatory.

At this stage, the model for the WFI makes several approximations beyond the basic assumption of far-field diffraction-based PSF calculation:

Future Improvements

We are planning many additions and improvements for future WebbPSF-WFIRST versions, including the following:

Credits, Acknowledgements, and Feedback

WebbPSF is developed by Marshall Perrin, Joseph Long, and collaborators in support of STScI's involvement in both the JWST and WFIRST missions. Software development takes place on GitHub at https://github.com/mperrin/webbpsf. Contributions of bug reports or code are welcome!

Users are encouraged to address questions, suggestions, and bug reports to help@stsci.edu with "WebbPSF-WFIRST question" in the subject line, where they will be directed to the appropriate members of the WebbPSF-WFIRST team at STScI.