PerHealpixInput¶
- class lsst.drp.tasks.update_visit_summary.PerHealpixInput(catalogs_by_pixel: list[int, tuple[int, lsst.geom.SpherePoint, lsst.afw.table.ExposureCatalog]])¶
Bases:
PossiblyMultipleInput
Wrapper class for input
ExposureCatalog
datasets that are per-healpix pixel.This selects the best pixel based on which one contains the detector centroid. Since the pixel regions are ConvexPolygons that do not perfectly describe the pixel borders, in case of ambiguity, the pixel is chosen via the minimum distance (on the sky) from the detector’s centroid to the pixel centroid.
Methods Summary
best_for_detector
(detector_id[, center, bbox])Return the exposure record for this detector that is the best match for this detector.
load
(butler, refs)Load and wrap input catalogs.
Methods Documentation
- best_for_detector(detector_id: int, center: SpherePoint | None = None, bbox: Box2I | None = None) tuple[int, lsst.afw.table.ExposureRecord | None] ¶
Return the exposure record for this detector that is the best match for this detector.
- Parameters:
- detector_id
int
Detector ID; used to find the right row in the catalog or catalogs.
- center
lsst.geom.SpherePoint
orNone
Center of the detector in sky coordinates. If not provided, one will be computed via
compute_center_for_detector_record
.- bbox
lsst.geom.Box2I
, optional Bounding box for the detector in its own pixel coordinates.
- detector_id
- Returns:
- tract_id
int
ID of the tract that supplied this record, or
-1
ifrecord
isNone
or if the input was not per-tract.- record
lsst.afw.table.ExposureRecord
orNone
Best record for this detector, or
None
if there either were no records for this detector or no WCS available to compute a center.
- tract_id
- classmethod load(butler: QuantumContext | Butler, refs: Iterable[DatasetRef]) PerHealpixInput ¶
Load and wrap input catalogs.
- Parameters:
- butler
lsst.pipe.base.QuantumContext
Butler proxy used in
runQuantum
.- refs
Iterable
[lsst.daf.butler.DatasetRef
] References to the catalog datasets to load.
- butler
- Returns:
- wrapper
PerHealpixInput
Wrapper object for the loaded catalogs.
- wrapper