lsst.pipe.tasks g584c84fe5e+111e082d69
Classes | Functions
lsst.pipe.tasks.coaddBase Namespace Reference

Classes

class  CoaddBaseConfig
 
class  CoaddBaseTask
 

Functions

def getSkyInfo (coaddName, patchRef)
 
def makeSkyInfo (skyMap, tractId, patchId)
 
def scaleVariance (maskedImage, maskPlanes, log=None)
 
def reorderAndPadList (inputList, inputKeys, outputKeys, padWith=None)
 

Function Documentation

◆ getSkyInfo()

def lsst.pipe.tasks.coaddBase.getSkyInfo (   coaddName,
  patchRef 
)
Return the SkyMap, tract and patch information, wcs, and outer bbox of the patch to be coadded.

Parameters
----------
coaddName : `str`
    Coadd name; typically one of deep or goodSeeing.
patchRef : `Unknown`
    Data reference for sky map. Must include keys "tract" and "patch".

Returns
-------
makeSkyInfo : `lsst.pipe.base.Struct`
    pipe_base Struct with attributes:

    ``skyMap``
        Sky map (`lsst.skyMap.SkyMap`).
    ``tractInfo``
        Information for chosen tract of sky map (`lsst.skyMap.TractInfo`).
    ``patchInfo``
        Information about chosen patch of tract (`lsst.skyMap.PatchInfo`).
    ``wcs``
        WCS of tract (`lsst.afw.image.SkyWcs`).
    ``bbox``
        Outer bbox of patch, as an geom Box2I (`lsst.afw.geom.Box2I`).

Definition at line 190 of file coaddBase.py.

◆ makeSkyInfo()

def lsst.pipe.tasks.coaddBase.makeSkyInfo (   skyMap,
  tractId,
  patchId 
)
Constructs SkyInfo used by coaddition tasks for multiple
patchId formats.

Parameters
----------
skyMap : `lsst.skyMap.SkyMap`
    Sky map.
tractId : `int`
    The ID of the tract.
patchId : `str` or `int` or `tuple` of `int`
    Either Gen2-style comma delimited string (e.g. '4,5'),
    tuple of integers (e.g (4, 5), Gen3-style integer.

Returns
-------
makeSkyInfo : `lsst.pipe.base.Struct`
    pipe_base Struct with attributes:

    ``skyMap``
        Sky map (`lsst.skyMap.SkyMap`).
    ``tractInfo``
        Information for chosen tract of sky map (`lsst.skyMap.TractInfo`).
    ``patchInfo``
        Information about chosen patch of tract (`lsst.skyMap.PatchInfo`).
    ``wcs``
        WCS of tract (`lsst.afw.image.SkyWcs`).
    ``bbox``
        Outer bbox of patch, as an geom Box2I (`lsst.afw.geom.Box2I`).

Definition at line 220 of file coaddBase.py.

◆ reorderAndPadList()

def lsst.pipe.tasks.coaddBase.reorderAndPadList (   inputList,
  inputKeys,
  outputKeys,
  padWith = None 
)
Match the order of one list to another, padding if necessary

Parameters
----------
inputList : `list`
    List to be reordered and padded. Elements can be any type.
inputKeys :  `iterable`
    Iterable of values to be compared with outputKeys. Length must match `inputList`.
outputKeys : `iterable`
    Iterable of values to be compared with inputKeys.
padWith : `Unknown`
    Any value to be inserted where inputKey not in outputKeys.

Returns
-------
outputList : `list`
    Copy of inputList reordered per outputKeys and padded with `padWith`
    so that the length matches length of outputKeys.

Definition at line 303 of file coaddBase.py.

◆ scaleVariance()

def lsst.pipe.tasks.coaddBase.scaleVariance (   maskedImage,
  maskPlanes,
  log = None 
)
Scale the variance in a maskedImage

This is deprecated. Use the ScaleVarianceTask instead.

Parameters
----------
maskedImage : `lsst.afw.image.MaskedImage`
    MaskedImage to operate on; variance will be scaled.
maskPlanes : `list`
    List of mask planes for pixels to reject.
log : `Unknown`
    Log for reporting the renormalization factor; or None.

Returns
-------
task.run : `Unknown`
    Renormalization factor.

Notes
-----
The variance plane in a convolved or warped image (or a coadd derived
from warped images) does not accurately reflect the noise properties of
the image because variance has been lost to covariance. This function
attempts to correct for this by scaling the variance plane to match
the observed variance in the image. This is not perfect (because we're
not tracking the covariance) but it's simple and is often good enough.

Definition at line 269 of file coaddBase.py.