Catalog Fitting

MultiProFit’s third and final layer of data structures is the batch fitting interfaces provided in lsst.multiprofit.fitting. These fitters are designed to fit multiple sources in a co-spatial set of observations one-by-one, given a catalog of detections, and output a catalog of best-fit parameters and errors thereof, along with diagnostics.

As with the Model configuration classes, catalog fitters are configured with lsst.pex.config.Config instances. The base class interfaces are provided in lsst.multiprofit.fitting and begin with lsst.multiprofit.CatalogFitterConfig. Implementations must override subclasses lsst.multiprofit.CatalogExposureABC to define methods to retrieve the data for a single row of the source catalog.

Unlike model configuration classes, though, these configurations have no corresponding Gauss2DFit data structures and need to store intermediate data. Fitters are therefore implemented to take inputs as pydantic.BaseModel instances (providing runtime type checking and validation, amongst other benefits), with lsst.pex.config.Config members for configuration.

PSF Fitting

The lsst.multiprofit.fitting.fit_psf module implements fitting a single Gaussian mixture PSF model at the position of each source in a catalog.

The lsst.multiprofit.CatalogPsfFitter class’ fit function takes two arguments: a lsst.multiprofit.CatalogExposurePsfABC instance as input data and a lsst.multiprofit.CatalogPsfFitterConfigData. The former class must have its abstract methods implemented - which typically involves calling code to render an image of the PSF - while the latter may have functions overridden if needed.

Source Fitting

The lsst.multiprofit.fitting.fit_source module implements fitting a single PSF-convolved Gaussian mixture model at the position of each source in a catalog.

The lsst.multiprofit.CatalogSourceFitter class’ fit function takes two arguments: a lsst.multiprofit.CatalogExposureSourceABC instance as input data and a lsst.multiprofit.CatalogSourceFitterConfigData. Like the PSF fitter, the former class must have its abstract methods implemented and the latter may have functions overridden if needed. The abstract methods must provided an image of the source and also initialize the parameters of the PSF model.

Bootstrap Fitting

The lsst.multiprofit.fitting.fit_bootstrap_model module implements boostrap fitting of multiple random realizations of a single PSF and/or source model. The CatalogExposurePsfBootstrap and CatalogSourceFitterBootstrap classes implement PSF and source fitting, respectively. These are designed to test MultiProFit’s performance in terms of runtime and accuracy of recovered parameters and errors thereof.

Examples

MultiProFit’s catalog fitting interfaces are implemented for Rubin-LSST data in meas_extensions_multiprofit (to be added as a Science Pipelines package in the near future).