CutoutResult#
- class lsst.ts.wep.blitz.CutoutResult(det_name, catalog, rejected_catalog, isr_run, bkg_run, diam_run, detect_run, wcs_refit_run, catalog_select_run, stamp_cut_run, scatter_arcsec, wcs_refit_error, cat_select_error, selection_source, n_quarter, wcs, pair_path='n/a', visit_id=None, dispatch_to_arrival=nan, view=None)#
Bases:
objectOne exposure of one detector, as
_cutout_one_exposurereturns it.Corner mode produces one per detector, full-array mode two – one per exposure of the pair, each tagged with its own
visit_id. Consumed by both tasks’ logging and by_build_donut_catalog, which turns most of these fields into that detector’stable.meta["det_meta"]entry.Every
*_runfield is seconds, and a stage that never ran is NaN rather than 0.0: a detector that bailed out early must not read as one whose remaining stages were instantaneous. The stage fields are keyed bylsst.ts.wep.blitz.utils._CUTOUT_STAGE_KEYS, which is where their order comes from – everything reporting them iterates that mapping rather than spelling them out.- isr_run, bkg_run, diam_run, detect_run
Per-stage wall-clock in seconds; NaN for a stage that never ran.
- Type:
- wcs_refit_run, catalog_select_run, stamp_cut_run
Per-stage wall-clock in seconds; NaN for a stage that never ran.
- Type:
- scatter_arcsec#
On-sky scatter of the refit WCS in arcseconds, None where no refit ran.
- Type:
float or None
- wcs_refit_error, cat_select_error
Error messages from the WCS refit and catalog selection, empty on success.
- Type:
- selection_source#
Where this detector’s donut ids came from, and so whether they are comparable across the two exposures of a pair.
- Type:
- wcs#
The WCS actually used, or None.
- Type:
lsst.afw.geom.SkyWcs or None
- visit_id#
The exposure this result covers, set by full-array mode; None in corner mode.
- Type:
int or None, optional
- dispatch_to_arrival#
Dispatch-to-arrival latency of the work unit, set in corner mode only.
- Type:
float, optional
- view#
The binned image and overlay sources for the focal-plane plot, or None where not built.
- Type:
DetectorView or None, optional
- Parameters:
det_name (
str)isr_run (
float)bkg_run (
float)diam_run (
float)detect_run (
float)wcs_refit_run (
float)catalog_select_run (
float)stamp_cut_run (
float)wcs_refit_error (
str)cat_select_error (
str)selection_source (
str)n_quarter (
int)wcs (
Any)pair_path (
str, default:'n/a')dispatch_to_arrival (
float, default:nan)view (
DetectorView|None, default:None)
Attributes Summary
Methods Summary
dead(det_name, reason)Stand-in for a detector whose worker was killed outright.
no_detections(det_name, n_quarter, isr_run, ...)Result for a detector on which blitz detection found nothing.
Attributes Documentation
-
view:
DetectorView|None= None#
Methods Documentation
- classmethod dead(det_name, reason)#
Stand-in for a detector whose worker was killed outright.
_cutout_one_exposurereports its own failures inwcs_refit_error/cat_select_errorand always returns one of these, but it cannot report a SIGKILL – no Python runs in a process the kernel has already destroyed. So the parent synthesizes the same shape on the worker’s behalf, letting the visit proceed on the surviving detectors instead of being lost entirely.Every timing is NaN and both catalogs empty, matching
no_detections: a stage that never ran must not read as one that was instantaneous.- Parameters:
- Returns:
A result with empty catalogs, every timing NaN, and
selection_source="worker_died".- Return type:
- classmethod no_detections(det_name, n_quarter, isr_run, bkg_run, diam_run, detect_run)#
Result for a detector on which blitz detection found nothing.
The four stages that did run are reported; the three below them never ran and stay NaN.
selection_sourceis"no_detections", which is distinct from the selector running and rejecting everything ("blitz_failed").- Parameters:
det_name (str) – Detector name.
n_quarter (int) – Detector orientation as a count of 90-degree rotations.
isr_run (float) – Wall-clock in seconds for the four stages that did run.
bkg_run (float) – Wall-clock in seconds for the four stages that did run.
diam_run (float) – Wall-clock in seconds for the four stages that did run.
detect_run (float) – Wall-clock in seconds for the four stages that did run.
- Returns:
A result with empty catalogs, the four reported timings, and every later stage NaN.
- Return type: