LSST Applications g063fba187b+cac8b7c890,g0f08755f38+6aee506743,g1653933729+a8ce1bb630,g168dd56ebc+a8ce1bb630,g1a2382251a+b4475c5878,g1dcb35cd9c+8f9bc1652e,g20f6ffc8e0+6aee506743,g217e2c1bcf+73dee94bd0,g28da252d5a+1f19c529b9,g2bbee38e9b+3f2625acfc,g2bc492864f+3f2625acfc,g3156d2b45e+6e55a43351,g32e5bea42b+1bb94961c2,g347aa1857d+3f2625acfc,g35bb328faa+a8ce1bb630,g3a166c0a6a+3f2625acfc,g3e281a1b8c+c5dd892a6c,g3e8969e208+a8ce1bb630,g414038480c+5927e1bc1e,g41af890bb2+8a9e676b2a,g7af13505b9+809c143d88,g80478fca09+6ef8b1810f,g82479be7b0+f568feb641,g858d7b2824+6aee506743,g89c8672015+f4add4ffd5,g9125e01d80+a8ce1bb630,ga5288a1d22+2903d499ea,gb58c049af0+d64f4d3760,gc28159a63d+3f2625acfc,gcab2d0539d+b12535109e,gcf0d15dbbd+46a3f46ba9,gda6a2b7d83+46a3f46ba9,gdaeeff99f8+1711a396fd,ge79ae78c31+3f2625acfc,gef2f8181fd+0a71e47438,gf0baf85859+c1f95f4921,gfa517265be+6aee506743,gfa999e8aa5+17cd334064,w.2024.51
LSST Data Management Base Package
|
Classes | |
class | GetDcrTemplateConnections |
class | GetTemplateConnections |
Functions | |
run (self, coaddExposures, bbox, wcs, dataIds, physical_filter) | |
_makeExposureCatalog (self, exposures, dataIds) | |
_merge (self, maskedImages, bbox, wcs) | |
_makePsf (self, template, catalog, wcs) | |
checkPatchList (self, patchList) | |
getDcrModel (self, patchList, coaddRefs, visitInfo) | |
_selectDataRef (coaddRef, tract, patch) | |
Variables | |
detectorPolygon = geom.Box2D(inputs['bbox']) | |
int | overlappingArea = 0 |
coaddExposures = collections.defaultdict(list) | |
dataIds = collections.defaultdict(list) | |
skymap = inputs['skyMap'] | |
dataId = coaddRef.dataId | |
patchWcs = skymap[dataId['tract']].getWcs() | |
patchBBox = skymap[dataId['tract']][dataId['patch']].getOuterBBox() | |
patchCorners = patchWcs.pixelToSky(geom.Box2D(patchBBox).getCorners()) | |
patchPolygon = afwGeom.Polygon(wcs.skyToPixel(patchCorners)) | |
list | coaddExposureRefList = [] |
patchList = dict() | |
|
protected |
Make an exposure catalog for one tract. Parameters ---------- exposures : `list` [`lsst.afw.image.Exposuref`] Exposures to include in the catalog. dataIds : `list` [`lsst.daf.butler.DataCoordinate`] Data ids of each of the included exposures; must have "tract" and "patch" entries. Returns ------- images : `list` [`lsst.afw.image.MaskedImage`] MaskedImages of each of the input exposures, for warping. catalog : `lsst.afw.table.ExposureCatalog` Catalog of metadata for each exposure totalBox : `lsst.geom.Box2I` The union of the bounding boxes of all the input exposures.
Definition at line 313 of file getTemplate.py.
|
protected |
Return a PSF containing the PSF at each of the input regions. Note that although this includes all the exposures from the catalog, the PSF knows which part of the template the inputs came from, so when evaluated at a given position it will not include inputs that never went in to those pixels. Parameters ---------- template : `lsst.afw.image.Exposure` Generated template the PSF is for. catalog : `lsst.afw.table.ExposureCatalog` Catalog of exposures that went into the template that contains all of the input PSFs. wcs : `lsst.afw.geom.SkyWcs` WCS of the template, to warp the PSFs to. Returns ------- coaddPsf : `lsst.meas.algorithms.CoaddPsf` The meta-psf constructed from all of the input catalogs.
Definition at line 403 of file getTemplate.py.
|
protected |
Merge the images that came from one tract into one larger image, ignoring NaN pixels and non-finite variance pixels from individual exposures. Parameters ---------- maskedImages : `list` [`lsst.afw.image.MaskedImage`] Images to be merged into one larger bounding box. bbox : `lsst.geom.Box2I` Bounding box defining the image to merge into. wcs : `lsst.afw.geom.SkyWcs` WCS of all of the input images to set on the output image. Returns ------- merged : `lsst.afw.image.MaskedImage` Merged image with all of the inputs at their respective bbox positions.
Definition at line 353 of file getTemplate.py.
|
protected |
Definition at line 620 of file getTemplate.py.
lsst.ip.diffim.getTemplate.checkPatchList | ( | self, | |
patchList ) |
Check that all of the DcrModel subfilters are present for each patch. Parameters ---------- patchList : `dict` Dict of the patches containing valid data for each tract. Raises ------ RuntimeError If the number of exposures found for a patch does not match the number of subfilters.
Definition at line 567 of file getTemplate.py.
lsst.ip.diffim.getTemplate.getDcrModel | ( | self, | |
patchList, | |||
coaddRefs, | |||
visitInfo ) |
Build DCR-matched coadds from a list of exposure references. Parameters ---------- patchList : `dict` Dict of the patches containing valid data for each tract. coaddRefs : `list` [`lsst.daf.butler.DeferredDatasetHandle`] Data references to `~lsst.afw.image.Exposure` representing DcrModels that overlap the detector. visitInfo : `lsst.afw.image.VisitInfo` Metadata for the science image. Returns ------- coaddExposures : `list` [`lsst.afw.image.Exposure`] Coadd exposures that overlap the detector.
Definition at line 588 of file getTemplate.py.
lsst.ip.diffim.getTemplate.run | ( | self, | |
coaddExposures, | |||
bbox, | |||
wcs, | |||
dataIds, | |||
physical_filter ) |
Warp coadds from multiple tracts and patches to form a template to subtract from a science image. Tract and patch overlap regions are combined by a variance-weighted average, and the variance planes are combined with the same weights, not added in quadrature; the overlap regions are not statistically independent, because they're derived from the same original data. The PSF on the template is created by combining the CoaddPsf on each template image into a meta-CoaddPsf. Parameters ---------- coaddExposures : `dict` [`int`, `list` [`lsst.afw.image.Exposure`]] Coadds to be mosaicked, indexed on tract id. bbox : `lsst.geom.Box2I` Template Bounding box of the detector geometry onto which to resample the ``coaddExposures``. Modified in-place to include the template border. wcs : `lsst.afw.geom.SkyWcs` Template WCS onto which to resample the ``coaddExposures``. dataIds : `dict` [`int`, `list` [`lsst.daf.butler.DataCoordinate`]] Record of the tract and patch of each coaddExposure, indexed on tract id. physical_filter : `str` Physical filter of the science image. Returns ------- result : `lsst.pipe.base.Struct` A struct with attributes: ``template`` A template coadd exposure assembled out of patches (`lsst.afw.image.ExposureF`). Raises ------ NoWorkFound If no coadds are found with sufficient un-masked pixels.
Definition at line 202 of file getTemplate.py.
list lsst.ip.diffim.getTemplate.coaddExposureRefList = [] |
Definition at line 538 of file getTemplate.py.
lsst.ip.diffim.getTemplate.coaddExposures = collections.defaultdict(list) |
Definition at line 179 of file getTemplate.py.
lsst.ip.diffim.getTemplate.dataId = coaddRef.dataId |
Definition at line 184 of file getTemplate.py.
Definition at line 180 of file getTemplate.py.
lsst.ip.diffim.getTemplate.detectorPolygon = geom.Box2D(inputs['bbox']) |
Definition at line 177 of file getTemplate.py.
int lsst.ip.diffim.getTemplate.overlappingArea = 0 |
Definition at line 178 of file getTemplate.py.
Definition at line 186 of file getTemplate.py.
lsst.ip.diffim.getTemplate.patchCorners = patchWcs.pixelToSky(geom.Box2D(patchBBox).getCorners()) |
Definition at line 187 of file getTemplate.py.
lsst.ip.diffim.getTemplate.patchList = dict() |
Definition at line 540 of file getTemplate.py.
lsst.ip.diffim.getTemplate.patchPolygon = afwGeom.Polygon(wcs.skyToPixel(patchCorners)) |
Definition at line 188 of file getTemplate.py.
Definition at line 185 of file getTemplate.py.
lsst.ip.diffim.getTemplate.skymap = inputs['skyMap'] |
Definition at line 182 of file getTemplate.py.