lsst.pipe.tasks  21.0.0-65-g9ea87ca1+87d0d175cc
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask Class Reference
Inheritance diagram for lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask:

Public Member Functions

def __init__ (self, butler=None, initInputs=None, *args, **kwargs)
 
def applySkyCorr (self, calexp, skyCorr)
 
def extractStamps (self, inputExposure, refObjLoader=None)
 
def warpStamps (self, stamps, pixCenters)
 
def run (self, inputExposure, refObjLoader=None, dataId=None, skyCorr=None)
 
def runDataRef (self, dataRef)
 
def runQuantum (self, butlerQC, inputRefs, outputRefs)
 

Public Attributes

 modelStampSize
 
 modelCenter
 

Static Public Attributes

 ConfigClass = ProcessBrightStarsConfig
 
 RunnerClass = pipeBase.ButlerInitializedTaskRunner
 

Detailed Description

The description of the parameters for this Task are detailed in
:lsst-task:`~lsst.pipe.base.PipelineTask`.

Notes
-----
`ProcessBrightStarsTask` is used to extract, process, and store small
image cut-outs (or "postage stamps") around bright stars. It relies on
three methods, called in succession:

`extractStamps`
    Find bright stars within the exposure using a reference catalog and
    extract a stamp centered on each.
`warpStamps`
    Shift and warp each stamp to remove optical distortions and sample all
    stars on the same pixel grid.
`measureAndNormalize`
    Compute the flux of an object in an annulus and normalize it. This is
    required to normalize each bright star stamp as their central pixels
    are likely saturated and/or contain ghosts, and cannot be used.

Definition at line 175 of file processBrightStars.py.

Constructor & Destructor Documentation

◆ __init__()

def lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.__init__ (   self,
  butler = None,
  initInputs = None,
args,
**  kwargs 
)

Definition at line 200 of file processBrightStars.py.

Member Function Documentation

◆ applySkyCorr()

def lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.applySkyCorr (   self,
  calexp,
  skyCorr 
)
Apply correction to the sky background level.

Sky corrections can be generated with the 'skyCorrection.py'
executable in pipe_drivers. Because the sky model used by that
code extends over the entire focal plane, this can produce
better sky subtraction.
The calexp is updated in-place.

Parameters
----------
calexp : `lsst.afw.image.Exposure` or `lsst.afw.image.MaskedImage`
    Calibrated exposure.
skyCorr : `lsst.afw.math.backgroundList.BackgroundList` or None,
          optional
    Full focal plane sky correction, obtained by running
    `lsst.pipe.drivers.skyCorrection.SkyCorrectionTask`.

Definition at line 216 of file processBrightStars.py.

◆ extractStamps()

def lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.extractStamps (   self,
  inputExposure,
  refObjLoader = None 
)
 Read position of bright stars within `inputExposure` from refCat
and extract them.

Parameters
----------
inputExposure : `afwImage.exposure.exposure.ExposureF`
    The image from which bright star stamps should be extracted.
refObjLoader : `LoadIndexedReferenceObjectsTask`, optional
    Loader to find objects within a reference catalog.

Returns
-------
result : `lsst.pipe.base.Struct`
    Result struct with components:

    - ``starIms``: `list` of stamps
    - ``pixCenters``: `list` of corresponding coordinates to each
        star's center, in pixels.
    - ``GMags``: `list` of corresponding (Gaia) G magnitudes.
    - ``gaiaIds``: `np.ndarray` of corresponding unique Gaia
        identifiers.

Definition at line 238 of file processBrightStars.py.

◆ run()

def lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.run (   self,
  inputExposure,
  refObjLoader = None,
  dataId = None,
  skyCorr = None 
)
Identify bright stars within an exposure using a reference catalog,
extract stamps around each, then preprocess them. The preprocessing
steps are: shifting, warping and potentially rotating them to the same
pixel grid; computing their annular flux and normalizing them.

Parameters
----------
inputExposure : `afwImage.exposure.exposure.ExposureF`
    The image from which bright star stamps should be extracted.
refObjLoader : `LoadIndexedReferenceObjectsTask`, optional
    Loader to find objects within a reference catalog.
dataId : `dict` or `lsst.daf.butler.DataCoordinate`
    The dataId of the exposure (and detector) bright stars should be
    extracted from.
skyCorr : `lsst.afw.math.backgroundList.BackgroundList` or ``None``,
          optional
    Full focal plane sky correction, obtained by running
    `lsst.pipe.drivers.skyCorrection.SkyCorrectionTask`.

Returns
-------
result :  `lsst.pipe.base.Struct`
    Result struct with component:

    - ``brightStarStamps``: ``bSS.BrightStarStamps``

Definition at line 412 of file processBrightStars.py.

◆ runDataRef()

def lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.runDataRef (   self,
  dataRef 
)
Read in required calexp, extract and process stamps around bright
stars and write them to disk.

Parameters
----------
dataRef : `lsst.daf.persistence.butlerSubset.ButlerDataRef`
    Data reference to the calexp to extract bright stars from.

Definition at line 472 of file processBrightStars.py.

◆ runQuantum()

def lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.runQuantum (   self,
  butlerQC,
  inputRefs,
  outputRefs 
)

Definition at line 488 of file processBrightStars.py.

◆ warpStamps()

def lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.warpStamps (   self,
  stamps,
  pixCenters 
)
Warps and shifts all given stamps so they are sampled on the same
pixel grid and centered on the central pixel. This includes rotating
the stamp depending on detector orientation.

Parameters
----------
stamps : `collections.abc.Sequence`
             [`afwImage.exposure.exposure.ExposureF`]
    Image cutouts centered on a single object.
pixCenters : `collections.abc.Sequence` [`geom.Point2D`]
    Positions of each object's center (as obtained from the refCat),
    in pixels.

Returns
-------
warpedStars : `list` [`afwImage.maskedImage.maskedImage.MaskedImage`]

Definition at line 335 of file processBrightStars.py.

Member Data Documentation

◆ ConfigClass

lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.ConfigClass = ProcessBrightStarsConfig
static

Definition at line 196 of file processBrightStars.py.

◆ modelCenter

lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.modelCenter

Definition at line 211 of file processBrightStars.py.

◆ modelStampSize

lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.modelStampSize

Definition at line 203 of file processBrightStars.py.

◆ RunnerClass

lsst.pipe.tasks.processBrightStars.ProcessBrightStarsTask.RunnerClass = pipeBase.ButlerInitializedTaskRunner
static

Definition at line 198 of file processBrightStars.py.


The documentation for this class was generated from the following file: