WriteRecalibratedSourceTableTask#

class lsst.pipe.tasks.postprocess.WriteRecalibratedSourceTableTask(*, config: PipelineTaskConfig | None = None, log: logging.Logger | LsstLogAdapter | None = None, initInputs: dict[str, Any] | None = None, **kwargs: Any)#

Bases: WriteSourceTableTask

Write source table to DataFrame Parquet format.

Methods Summary

addCalibColumns(catalog, exposure, **kwargs)

Add replace columns with calibs evaluated at each centroid

prepareCalibratedExposure(exposure, detectorId)

Prepare a calibrated exposure and apply external calibrations if so configured.

runQuantum(butlerQC, inputRefs, outputRefs)

Do butler IO and transform to provide in memory objects for tasks run method.

Methods Documentation

addCalibColumns(catalog, exposure, **kwargs)#

Add replace columns with calibs evaluated at each centroid

Add or replace ‘base_LocalWcs’ and ‘base_LocalPhotoCalib’ columns in a source catalog, by rerunning the plugins.

Parameters#

cataloglsst.afw.table.SourceCatalog

catalog to which calib columns will be added

exposurelsst.afw.image.exposure.Exposure

Exposure with attached PhotoCalibs and SkyWcs attributes to be reevaluated at local centroids. Pixels are not required.

**kwargs

Additional keyword arguments are ignored to facilitate passing the same arguments to several methods.

Returns#

newCat: lsst.afw.table.SourceCatalog

Source Catalog with requested local calib columns

prepareCalibratedExposure(exposure, detectorId, visitSummary=None)#

Prepare a calibrated exposure and apply external calibrations if so configured.

Parameters#

exposurelsst.afw.image.exposure.Exposure

Input exposure to adjust calibrations. May be an empty Exposure.

detectorIdint

Detector ID associated with the exposure.

visitSummarylsst.afw.table.ExposureCatalog, optional

Exposure catalog with all calibration objects. WCS and PhotoCalib are always applied if visitSummary is provided and those components are not None.

Returns#

exposurelsst.afw.image.exposure.Exposure

Exposure with adjusted calibrations.

runQuantum(butlerQC, inputRefs, outputRefs)#

Do butler IO and transform to provide in memory objects for tasks run method.

Parameters#

butlerQCQuantumContext

A butler which is specialized to operate in the context of a lsst.daf.butler.Quantum.

inputRefsInputQuantizedConnection

Datastructure whose attribute names are the names that identify connections defined in corresponding PipelineTaskConnections class. The values of these attributes are the lsst.daf.butler.DatasetRef objects associated with the defined input/prerequisite connections.

outputRefsOutputQuantizedConnection

Datastructure whose attribute names are the names that identify connections defined in corresponding PipelineTaskConnections class. The values of these attributes are the lsst.daf.butler.DatasetRef objects associated with the defined output connections.