lsst.pipe.tasks  21.0.0-57-g387f8f07+a17748c3dc
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask Class Reference
Inheritance diagram for lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask:

Public Member Functions

def __init__ (self, **kwds)
 
def buildSkyMap (self, butler)
 
def buildTruthCatalog (self, butler=None, skyMap=None, tract=0)
 
def buildObservationCatalog (self, butler=None, skyMap=None, tract=0, camera=None)
 
def buildInputImages (self, butler, obsCatalog=None, truthCatalog=None, tract=0)
 
def buildAllInputs (self, butler)
 
def makeCoaddTask (self, cls, assemblePsfMatched=False)
 
def iterPatchRefs (self, butler, tractInfo)
 
def buildCoadd (self, butler, skyMap=None, tract=0)
 
def buildMockCoadd (self, butler, truthCatalog=None, skyMap=None, tract=0)
 

Public Attributes

 schema
 
 objectIdKey
 
 exposureIdKey
 
 centroidInBBoxKey
 
 partialOverlapKey
 

Static Public Attributes

 ConfigClass = MockCoaddConfig
 

Detailed Description

MockCoaddTask is a driver task for creating mock coadds.  As opposed to more realistic
simulations, MockCoadd generates and uses extremely simple "toy" data that can be used to more
rigorously test the behavior of high-level task code because the expected results are
more easily predicted.  In particular, calexps are generated directly from the truth catalog,
and contain only zero-noise stars that are created using the same Psf, PhotoCalib, and Wcs that will
be attached to the mock calexp.

In addition to creating the mock calexps and truth catalogs, MockCoadd also contains driver
code to run the MakeSkyMap, MakeCoaddTempExp, and AssembleCoadd tasks on the mock calexps,
and code to directly create a mock coadd image using CoaddPsf, which can be compared to the
output of the regular coadd tasks to check that the coadd code and CoaddPsf are consistent.

Note that aside from MakeSkyMapTask, the coadd tasks are *not* subtasks of MockCoaddTasks,
and their configs are not part of MockCoaddConfig; these are created locally within
MockCoaddTask methods when needed, as not all coadd task config options are appropriate
for the mock data generated by MockCoadd.

Definition at line 91 of file mockCoadd.py.

Constructor & Destructor Documentation

◆ __init__()

def lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.__init__ (   self,
**  kwds 
)
Construct a MockCoaddTask and the subtasks used for generating skymaps, objects,
and observations (i.e. calexp parameters).

Definition at line 114 of file mockCoadd.py.

Member Function Documentation

◆ buildAllInputs()

def lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.buildAllInputs (   self,
  butler 
)
Convenience function that calls buildSkyMap, buildObservationCatalog, buildTruthCatalog,
and buildInputImages.

Definition at line 217 of file mockCoadd.py.

◆ buildCoadd()

def lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.buildCoadd (   self,
  butler,
  skyMap = None,
  tract = 0 
)
Run the coadd tasks (MakeCoaddTempExp and AssembleCoadd) on the mock data.

Must be run after buildInputImages.
Makes both direct and PSF-matched coadds

Definition at line 270 of file mockCoadd.py.

◆ buildInputImages()

def lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.buildInputImages (   self,
  butler,
  obsCatalog = None,
  truthCatalog = None,
  tract = 0 
)
Use the truth catalog and observation catalog to create and save (if butler is not None)
mock calexps and an ExposureCatalog ('simsrc') that contains information about which objects
appear partially or fully in each exposure.

Must be run after buildTruthCatalog and buildObservationCatalog.

Definition at line 173 of file mockCoadd.py.

◆ buildMockCoadd()

def lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.buildMockCoadd (   self,
  butler,
  truthCatalog = None,
  skyMap = None,
  tract = 0 
)
Directly create a simulation of the coadd, using the CoaddPsf (and ModelPsf)
of the direct (and psfMatched) coadd exposure and the truth catalog.

Must be run after buildCoadd.

Definition at line 291 of file mockCoadd.py.

◆ buildObservationCatalog()

def lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.buildObservationCatalog (   self,
  butler = None,
  skyMap = None,
  tract = 0,
  camera = None 
)
Create and save (if butler is not None) an ExposureCatalog of simulated observations,
containing the Psfs, Wcss, PhotoCalibs, etc. of the calexps to be simulated.

Must be run after buildSkyMap.

Most of the work is delegated to the mockObservation subtask.

Definition at line 153 of file mockCoadd.py.

◆ buildSkyMap()

def lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.buildSkyMap (   self,
  butler 
)
Build the skymap for the mock dataset.

Definition at line 135 of file mockCoadd.py.

◆ buildTruthCatalog()

def lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.buildTruthCatalog (   self,
  butler = None,
  skyMap = None,
  tract = 0 
)
Create and save (if butler is not None) a truth catalog containing all the mock objects.

Must be run after buildSkyMap.

Most of the work is delegated to the mockObject subtask.

Definition at line 139 of file mockCoadd.py.

◆ iterPatchRefs()

def lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.iterPatchRefs (   self,
  butler,
  tractInfo 
)
Generator that iterates over the patches in a tract, yielding dataRefs.

Definition at line 259 of file mockCoadd.py.

◆ makeCoaddTask()

def lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.makeCoaddTask (   self,
  cls,
  assemblePsfMatched = False 
)
Helper function to create a Coadd task with configuration appropriate for the simulations.

MockCoaddTask does not include MakeCoaddTempExpTask or AssembleCoaddTask as subtasks, because
we want explicit control over their configs, rather than leaving this up to the user.
However, we have to install our own SelectImages task for both of these, so it made sense
to have a single method that would create one of these two tasks, set the config values we
want, and install the custom SelectImagesTask.

Definition at line 226 of file mockCoadd.py.

Member Data Documentation

◆ centroidInBBoxKey

lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.centroidInBBoxKey

Definition at line 126 of file mockCoadd.py.

◆ ConfigClass

lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.ConfigClass = MockCoaddConfig
static

Definition at line 110 of file mockCoadd.py.

◆ exposureIdKey

lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.exposureIdKey

Definition at line 124 of file mockCoadd.py.

◆ objectIdKey

lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.objectIdKey

Definition at line 123 of file mockCoadd.py.

◆ partialOverlapKey

lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.partialOverlapKey

Definition at line 130 of file mockCoadd.py.

◆ schema

lsst.pipe.tasks.mocks.mockCoadd.MockCoaddTask.schema

Definition at line 122 of file mockCoadd.py.


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