ReprocessVisitImageTask#

class lsst.drp.tasks.reprocess_visit_image.ReprocessVisitImageTask(schema=None, **kwargs)#

Bases: PipelineTask

Use the visit-level calibrations to perform detection and measurement on the single frame exposures and produce a “final” exposure and catalog.

Methods Summary

run(*, exposures, initial_photo_calib, psf, ...)

Detect and measure sources on the exposure(s) (snap combined as necessary), and make a "final" Processed Visit Image using all of the supplied metadata, plus a catalog measured on it.

runQuantum(butlerQC, inputRefs, outputRefs)

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

Methods Documentation

run(*, exposures, initial_photo_calib, psf, background, ap_corr, photo_calib, wcs, calib_sources, preliminary_mask=None, id_generator=None, background_to_photometric_ratio=None, result=None)#

Detect and measure sources on the exposure(s) (snap combined as necessary), and make a “final” Processed Visit Image using all of the supplied metadata, plus a catalog measured on it.

Parameters#

exposureslsst.afw.image.Exposure or

list [lsst.afw.image.Exposure]

Post-ISR exposure(s), with an initial WCS, VisitInfo, and Filter. Modified in-place during processing if only one is passed. If two exposures are passed, treat them as snaps and combine before doing further processing.

initial_photo_caliblsst.afw.image.PhotoCalib or None

Photometric calibration that was applied to exposure during the measurement of the background. Should be None if and only if ``config.remove_initial_photo_calib` is false.

psflsst.afw.detection.Psf

PSF model for this exposure.

backgroundlsst.afw.math.BackgroundList

Total background that had been fit to the exposure so far; modified in place to include background fit when detecting sources.

ap_corrlsst.afw.image.ApCorrMap

Aperture Correction model for this exposure.

photo_caliblsst.afw.image.PhotoCalib

Photometric calibration model for this exposure.

wcslsst.afw.geom.SkyWcs

World Coordinate System model for this exposure.

calib_sourcesastropy.table.Table

Per-visit catalog of measurements to get ‘calib_*’ flags from.

preliminary_masklsst.afw.image.Mask, optional

An input Mask to copy individual mask planes from.

id_generatorlsst.meas.base.IdGenerator, optional

Object that generates source IDs and provides random seeds.

background_to_photometric_ratiolsst.afw.image.ImageF, optional

Background to photometric ratio image, to convert between photometric flattened and background flattened image.

resultlsst.pipe.base.Struct, optional

Result struct that is modified to allow saving of partial outputs for some failure conditions. If the task completes successfully, this is also returned.

Returns#

resultlsst.pipe.base.Struct

Results as a struct with attributes:

exposure

Calibrated exposure, with pixels in nJy units. (lsst.afw.image.Exposure)

sources

Sources that were measured on the exposure, with calibrated fluxes and magnitudes. (astropy.table.Table)

sources_footprints

Footprints of sources that were measured on the exposure. (lsst.afw.table.SourceCatalog)

background

Total background that was fit to, and subtracted from the exposure when detecting sources, in the same nJy units as exposure. (lsst.afw.math.BackgroundList)

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.