InstallGaussianPsfTask¶
InstallGaussianPsfTask
installs a Gaussian PSF model in an exposure.
Processing summary¶
InstallGaussianPsfTask
installs a Gaussian PSF model in an exposure, creating a new PSF with the same sigma and width if a PSF already exists for the exposure. If there is not a PSF model for the exposure, the sigma and width are taken from the config.
Python API summary¶
from lsst.meas.algorithms.installGaussianPsf import InstallGaussianPsfTask
-
class
(config: Optional[Config] = None, name: Optional[str] = None, parentTask: Optional[Task] = None, log: Optional[Union[logging.Logger, lsst.utils.logging.LsstLogAdapter]] = None)InstallGaussianPsfTask
Install a Gaussian PSF model in an exposure
...
-
attribute
config
Access configuration fields and retargetable subtasks.
-
method
(exposure)run
Set exposure’s PSF to a simple PSF model
...
See also
See the InstallGaussianPsfTask
API reference for complete details.
Retargetable subtasks¶
No subtasks.
Configuration fields¶
fwhm¶
Estimated FWHM of simple Gaussian PSF model, in pixels. Ignored if input exposure has a PSF model.
width¶
- Default
11
- Field type
int
RangeField
- Range
- [1,inf)
Width and height of PSF model, in pixels. Must be odd.
Examples¶
from lsst.afw.image import ExposureF
from lsst.meas.algorithms.installGaussianPsf import InstallGaussianPsfTask, FwhmPerSigma
exposure = ExposureF(100, 100)
task = InstallGaussianPsfTask()
task.run(exposure=exposure)
# This particular exposure had no PSF model to begin with, so the new PSF model
# uses the config's FWHM. However, measured FWHM is based on the truncated
# PSF image, so it does not exactly match the input
measFwhm = exposure.getPsf().computeShape().getDeterminantRadius() * FwhmPerSigma
assert abs(measFwhm - task.config.fwhm) < 1e-3