LSST Applications  21.0.0-172-gfb10e10a+18fedfabac,22.0.0+297cba6710,22.0.0+80564b0ff1,22.0.0+8d77f4f51a,22.0.0+a28f4c53b1,22.0.0+dcf3732eb2,22.0.1-1-g7d6de66+2a20fdde0d,22.0.1-1-g8e32f31+297cba6710,22.0.1-1-geca5380+7fa3b7d9b6,22.0.1-12-g44dc1dc+2a20fdde0d,22.0.1-15-g6a90155+515f58c32b,22.0.1-16-g9282f48+790f5f2caa,22.0.1-2-g92698f7+dcf3732eb2,22.0.1-2-ga9b0f51+7fa3b7d9b6,22.0.1-2-gd1925c9+bf4f0e694f,22.0.1-24-g1ad7a390+a9625a72a8,22.0.1-25-g5bf6245+3ad8ecd50b,22.0.1-25-gb120d7b+8b5510f75f,22.0.1-27-g97737f7+2a20fdde0d,22.0.1-32-gf62ce7b1+aa4237961e,22.0.1-4-g0b3f228+2a20fdde0d,22.0.1-4-g243d05b+871c1b8305,22.0.1-4-g3a563be+32dcf1063f,22.0.1-4-g44f2e3d+9e4ab0f4fa,22.0.1-42-gca6935d93+ba5e5ca3eb,22.0.1-5-g15c806e+85460ae5f3,22.0.1-5-g58711c4+611d128589,22.0.1-5-g75bb458+99c117b92f,22.0.1-6-g1c63a23+7fa3b7d9b6,22.0.1-6-g50866e6+84ff5a128b,22.0.1-6-g8d3140d+720564cf76,22.0.1-6-gd805d02+cc5644f571,22.0.1-8-ge5750ce+85460ae5f3,master-g6e05de7fdc+babf819c66,master-g99da0e417a+8d77f4f51a,w.2021.48
LSST Data Management Base Package
Public Member Functions | Static Public Attributes | List of all members
lsst.pipe.tasks.processCcd.ProcessCcdTask Class Reference

Assemble raw data, fit the PSF, detect and measure, and fit WCS and zero-point. More...

Inheritance diagram for lsst.pipe.tasks.processCcd.ProcessCcdTask:

Public Member Functions

def __init__ (self, butler=None, psfRefObjLoader=None, astromRefObjLoader=None, photoRefObjLoader=None, **kwargs)
 
def runDataRef (self, sensorRef)
 

Static Public Attributes

 ConfigClass = ProcessCcdConfig
 
 RunnerClass = pipeBase.ButlerInitializedTaskRunner
 

Detailed Description

Assemble raw data, fit the PSF, detect and measure, and fit WCS and zero-point.

@anchor ProcessCcdTask_

@section pipe_tasks_processCcd_Contents  Contents

 - @ref pipe_tasks_processCcd_Purpose
 - @ref pipe_tasks_processCcd_Initialize
 - @ref pipe_tasks_processCcd_IO
 - @ref pipe_tasks_processCcd_Config
 - @ref pipe_tasks_processCcd_Debug
 - @ref pipe_tasks_processCcd_Example

@section pipe_tasks_processCcd_Purpose  Description

Perform the following operations:
- Call isr to unpersist raw data and assemble it into a post-ISR exposure
- Call charImage subtract background, fit a PSF model, repair cosmic rays,
    detect and measure bright sources, and measure aperture correction
- Call calibrate to perform deep detection, deblending and single-frame measurement,
    refine the WCS and fit the photometric zero-point

@section pipe_tasks_processCcd_Initialize  Task initialisation

@copydoc \_\_init\_\_

@section pipe_tasks_processCcd_IO  Invoking the Task

This task is primarily designed to be run from the command line.

The main method is `runDataRef`, which takes a single butler data reference for the raw input data.

@section pipe_tasks_processCcd_Config  Configuration parameters

See @ref ProcessCcdConfig

@section pipe_tasks_processCcd_Debug  Debug variables

ProcessCcdTask has no debug output, but its subtasks do.

@section pipe_tasks_processCcd_Example   A complete example of using ProcessCcdTask

The following commands will process all raw data in obs_test's data repository.
Note: be sure to specify an `--output` that does not already exist:

    setup obs_test
    setup pipe_tasks
    processCcd.py $OBS_TEST_DIR/data/input --output processCcdOut --id

The data is read from the small repository in the `obs_test` package and written `./processCcdOut`
(or whatever output you specified). Specifying `--id` with no values processes all data.
Add the option `--help` to see more options.

Definition at line 78 of file processCcd.py.

Constructor & Destructor Documentation

◆ __init__()

def lsst.pipe.tasks.processCcd.ProcessCcdTask.__init__ (   self,
  butler = None,
  psfRefObjLoader = None,
  astromRefObjLoader = None,
  photoRefObjLoader = None,
**  kwargs 
)
Parameters
[in]butlerThe butler is passed to the refObjLoader constructor in case it is needed. Ignored if the refObjLoader argument provides a loader directly.
[in]psfRefObjLoaderAn instance of LoadReferenceObjectsTasks that supplies an external reference catalog for image characterization. May be None if the desired loader can be constructed from the butler argument or all steps requiring a catalog are disabled.
[in]astromRefObjLoaderAn instance of LoadReferenceObjectsTasks that supplies an external reference catalog for astrometric calibration. May be None if the desired loader can be constructed from the butler argument or all steps requiring a reference catalog are disabled.
[in]photoRefObjLoaderAn instance of LoadReferenceObjectsTasks that supplies an external reference catalog for photometric calibration. May be None if the desired loader can be constructed from the butler argument or all steps requiring a reference catalog are disabled.
[in,out]kwargsother keyword arguments for lsst.pipe.base.CmdLineTask

Definition at line 136 of file processCcd.py.

137  **kwargs):
138  """!
139  @param[in] butler The butler is passed to the refObjLoader constructor in case it is
140  needed. Ignored if the refObjLoader argument provides a loader directly.
141  @param[in] psfRefObjLoader An instance of LoadReferenceObjectsTasks that supplies an
142  external reference catalog for image characterization. May be None if the desired
143  loader can be constructed from the butler argument or all steps requiring a catalog
144  are disabled.
145  @param[in] astromRefObjLoader An instance of LoadReferenceObjectsTasks that supplies an
146  external reference catalog for astrometric calibration. May be None if the desired
147  loader can be constructed from the butler argument or all steps requiring a reference
148  catalog are disabled.
149  @param[in] photoRefObjLoader An instance of LoadReferenceObjectsTasks that supplies an
150  external reference catalog for photometric calibration. May be None if the desired
151  loader can be constructed from the butler argument or all steps requiring a reference
152  catalog are disabled.
153  @param[in,out] kwargs other keyword arguments for lsst.pipe.base.CmdLineTask
154  """
155  pipeBase.CmdLineTask.__init__(self, **kwargs)
156  self.makeSubtask("isr")
157  self.makeSubtask("charImage", butler=butler, refObjLoader=psfRefObjLoader)
158  self.makeSubtask("calibrate", butler=butler, icSourceSchema=self.charImage.schema,
159  astromRefObjLoader=astromRefObjLoader, photoRefObjLoader=photoRefObjLoader)
160 

Member Function Documentation

◆ runDataRef()

def lsst.pipe.tasks.processCcd.ProcessCcdTask.runDataRef (   self,
  sensorRef 
)
Process one CCD

The sequence of operations is:
- remove instrument signature
- characterize image to estimate PSF and background
- calibrate astrometry and photometry

@param sensorRef: butler data reference for raw data

@return pipe_base Struct containing these fields:
- charRes: object returned by image characterization task; an lsst.pipe.base.Struct
    that will include "background" and "sourceCat" fields
- calibRes: object returned by calibration task: an lsst.pipe.base.Struct
    that will include "background" and "sourceCat" fields
- exposure: final exposure (an lsst.afw.image.ExposureF)
- background: final background model (an lsst.afw.math.BackgroundList)

Definition at line 162 of file processCcd.py.

162  def runDataRef(self, sensorRef):
163  """Process one CCD
164 
165  The sequence of operations is:
166  - remove instrument signature
167  - characterize image to estimate PSF and background
168  - calibrate astrometry and photometry
169 
170  @param sensorRef: butler data reference for raw data
171 
172  @return pipe_base Struct containing these fields:
173  - charRes: object returned by image characterization task; an lsst.pipe.base.Struct
174  that will include "background" and "sourceCat" fields
175  - calibRes: object returned by calibration task: an lsst.pipe.base.Struct
176  that will include "background" and "sourceCat" fields
177  - exposure: final exposure (an lsst.afw.image.ExposureF)
178  - background: final background model (an lsst.afw.math.BackgroundList)
179  """
180  self.log.info("Processing %s", sensorRef.dataId)
181 
182  exposure = self.isr.runDataRef(sensorRef).exposure
183 
184  charRes = self.charImage.runDataRef(
185  dataRef=sensorRef,
186  exposure=exposure,
187  doUnpersist=False,
188  )
189  exposure = charRes.exposure
190 
191  if self.config.doCalibrate:
192  calibRes = self.calibrate.runDataRef(
193  dataRef=sensorRef,
194  exposure=charRes.exposure,
195  background=charRes.background,
196  doUnpersist=False,
197  icSourceCat=charRes.sourceCat,
198  )
199 
200  return pipeBase.Struct(
201  charRes=charRes,
202  calibRes=calibRes if self.config.doCalibrate else None,
203  exposure=exposure,
204  background=calibRes.background if self.config.doCalibrate else charRes.background,
205  )
206 

Member Data Documentation

◆ ConfigClass

lsst.pipe.tasks.processCcd.ProcessCcdTask.ConfigClass = ProcessCcdConfig
static

Definition at line 132 of file processCcd.py.

◆ RunnerClass

lsst.pipe.tasks.processCcd.ProcessCcdTask.RunnerClass = pipeBase.ButlerInitializedTaskRunner
static

Definition at line 133 of file processCcd.py.


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