create_gridded_psf_model

romancal.lib.psf.create_gridded_psf_model(path_prefix, filt, detector, oversample=11, fov_pixels=9, sqrt_n_psfs=2, overwrite=False, buffer_pixels=100, instrument_options=None, logging_level=None)[source]

Compute a gridded PSF model for one SCA via CreatePSFLibrary.

Parameters:
  • path_prefix (str or Path-like) – Prefix to the output file path for the gridded PSF model FITS file. A suffix denoting the detector name will be appended.

  • filt (str) – Filter name, starting with “F”. For example: "F184".

  • detector (str) – Computed gridded PSF model for this SCA. Examples include: "SCA01" or "SCA18".

  • oversample (int, optional) – Oversample factor, default is 11. See WebbPSF docs for details [1]. Choosing an odd number makes the pixel convolution more accurate.

  • fov_pixels (int, optional) – Field of view width [pixels]. Default is 12. See WebbPSF docs for details [1].

  • sqrt_n_psfs (int, optional) – Square root of the number of PSFs to calculate, distributed uniformly across the detector. Default is 4.

  • overwrite (bool, optional) – Overwrite output file if one already exists. Default is False.

  • buffer_pixels (int, optional) – Calculate a grid of PSFs distributed uniformly across the detector at least buffer_pixels away from the detector edges. Default is 100.

  • instrument_options (dict, optional) – Instrument configuration options passed to WebbPSF. For example, WebbPSF assumes Roman pointing jitter consistent with mission specs by default, but this can be turned off with: {'jitter': None, 'jitter_sigma': 0}.

  • logging_level (str, optional) – Set logging level by name if not None, otherwise inherit from the romancal logger.

Returns:

  • gridmodel (photutils.psf.GriddedPSFModel) – Gridded PSF model evaluated at several locations on one SCA.

  • model_psf_centroids (list of tuples) – Pixel locations of the PSF models calculated for gridmodel.

References