BestSeeingSelectVisitsTask#
- class lsst.pipe.tasks.selectImages.BestSeeingSelectVisitsTask(*, config: PipelineTaskConfig | None = None, log: logging.Logger | LsstLogAdapter | None = None, initInputs: dict[str, Any] | None = None, **kwargs: Any)#
Bases:
PipelineTaskSelect up to a maximum number of the best-seeing visits.
Don’t exceed the FWHM range specified by configs min(max)PsfFwhm. This Task is a port of the Gen2 image-selector used in the AP pipeline: BestSeeingSelectImagesTask. This Task selects full visits based on the average PSF of the entire visit.
Methods Summary
doesIntersectPolygon(visitSummary, polygon)Return True if sky polygon overlaps visit.
makePatchPolygon(skyMap, dataId)Return True if sky polygon overlaps visit.
run(visitSummaries, skyMap, dataId)Run task.
runQuantum(butlerQC, inputRefs, outputRefs)Do butler IO and transform to provide in memory objects for tasks
runmethod.Methods Documentation
- doesIntersectPolygon(visitSummary, polygon)#
Return True if sky polygon overlaps visit.
Parameters#
- visitSummary
lsst.afw.table.ExposureCatalog Exposure catalog with per-detector geometry.
- polygon :` lsst.sphgeom.ConvexPolygon.convexHull`
Polygon to check overlap.
Returns#
- doesIntersect
bool True if the visit overlaps the polygon.
- visitSummary
- makePatchPolygon(skyMap, dataId)#
Return True if sky polygon overlaps visit.
Parameters#
- skyMap
lsst.afw.table.ExposureCatalog Exposure catalog with per-detector geometry.
- dataId
dictof dataId keys For retrieving patch info.
Returns#
- result
lsst.sphgeom.ConvexPolygon.convexHull Polygon of patch’s outer bbox.
- skyMap
- run(visitSummaries, skyMap, dataId)#
Run task.
Parameters#
- visitSummary
list[lsst.pipe.base.connections.DeferredDatasetRef] List of
lsst.pipe.base.connections.DeferredDatasetRefof visitSummary tables of typelsst.afw.table.ExposureCatalog.- skyMap
lsst.skyMap.SkyMap SkyMap for checking visits overlap patch.
- dataId
dictof dataId keys For retrieving patch info for checking visits overlap patch.
Returns#
- result
lsst.pipe.base.Struct Results as a struct with attributes:
goodVisitsA
dictwith selected visit ids as keys, so that it can be be saved as a StructuredDataDict. StructuredDataList’s are currently limited.
- visitSummary
- runQuantum(butlerQC, inputRefs, outputRefs)#
Do butler IO and transform to provide in memory objects for tasks
runmethod.Parameters#
- butlerQC
QuantumContext A butler which is specialized to operate in the context of a
lsst.daf.butler.Quantum.- inputRefs
InputQuantizedConnection Datastructure whose attribute names are the names that identify connections defined in corresponding
PipelineTaskConnectionsclass. The values of these attributes are thelsst.daf.butler.DatasetRefobjects associated with the defined input/prerequisite connections.- outputRefs
OutputQuantizedConnection Datastructure whose attribute names are the names that identify connections defined in corresponding
PipelineTaskConnectionsclass. The values of these attributes are thelsst.daf.butler.DatasetRefobjects associated with the defined output connections.
- butlerQC