lsst.meas.astrom  13.0-14-g9415442+26
 All Classes Namespaces Files Functions Variables Typedefs Friends Macros Groups Pages
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
lsst.meas.astrom.astrometry.AstrometryTask Class Reference

Match an input source catalog with objects from a reference catalog and solve for the WCS. More...

Inheritance diagram for lsst.meas.astrom.astrometry.AstrometryTask:

Public Member Functions

def __init__
 Construct an AstrometryTask. More...
 
def run
 Load reference objects, match sources and optionally fit a WCS. More...
 
def solve
 Load reference objects overlapping an exposure, match to sources and fit a WCS. More...
 

Public Attributes

 usedKey
 

Static Public Attributes

 ConfigClass = AstrometryConfig
 

Detailed Description

Match an input source catalog with objects from a reference catalog and solve for the WCS.

Contents

Description

Match input sourceCat with a reference catalog and solve for the Wcs

There are three steps, each performed by different subtasks:

Task initialisation

Construct an AstrometryTask.

Parameters
[in]refObjLoaderA reference object loader object
[in]schemaignored; available for compatibility with an older astrometry task
[in]kwargsadditional keyword arguments for pipe_base Task.__init__

Invoking the Task

Load reference objects, match sources and optionally fit a WCS. This is a thin layer around solve or loadAndMatch, depending on config.forceKnownWcs

Parameters
[in,out]exposureexposure whose WCS is to be fit The following are read only:
  • bbox
  • calib (may be absent)
  • filter (may be unset)
  • detector (if wcs is pure tangent; may be absent) The following are updated:
  • wcs (the initial value is used as an initial guess, and is required)
[in]sourceCatcatalog of sources detected on the exposure (an lsst.afw.table.SourceCatalog)
Returns
an lsst.pipe.base.Struct with these fields:
  • refCat reference object catalog of objects that overlap the exposure (with some margin) (an lsst::afw::table::SimpleCatalog)
  • matches astrometric matches, a list of lsst.afw.table.ReferenceMatch
  • scatterOnSky median on-sky separation between reference objects and sources in "matches" (an lsst.afw.geom.Angle), or None if config.forceKnownWcs True
  • matchMeta metadata needed to unpersist matches (an lsst.daf.base.PropertyList)

Configuration parameters

See AstrometryConfig

A complete example of using AstrometryTask

See pipe_tasks_photocal_Example.

Debug variables

The command line task interface supports a flag -d to import debug.py from your PYTHONPATH; see baseDebug for more about debug.py files.

The available variables in AstrometryTask are:

display (bool)
If True display information at three stages: after finding reference objects, after matching sources to reference objects, and after fitting the WCS; defaults to False
frame (int)
ds9 frame to use to display the reference objects; the next two frames are used to display the match list and the results of the final WCS; defaults to 0

To investigate the Debug variables, put something like

1 import lsstDebug
2 def DebugInfo(name):
3  debug = lsstDebug.getInfo(name) # N.b. lsstDebug.Info(name) would call us recursively
4  if name == "lsst.meas.astrom.astrometry":
5  debug.display = True
6 
7  return debug
8 
9 lsstDebug.Info = DebugInfo

into your debug.py file and run this task with the –debug flag.

Definition at line 72 of file astrometry.py.

Constructor & Destructor Documentation

def lsst.meas.astrom.astrometry.AstrometryTask.__init__ (   self,
  refObjLoader,
  schema = None,
  kwargs 
)

Construct an AstrometryTask.

Parameters
[in]refObjLoaderA reference object loader object
[in]schemaignored; available for compatibility with an older astrometry task
[in]kwargsadditional keyword arguments for pipe_base Task.__init__

Definition at line 146 of file astrometry.py.

Member Function Documentation

def lsst.meas.astrom.astrometry.AstrometryTask.run (   self,
  sourceCat,
  exposure 
)

Load reference objects, match sources and optionally fit a WCS.

This is a thin layer around solve or loadAndMatch, depending on config.forceKnownWcs

Parameters
[in,out]exposureexposure whose WCS is to be fit The following are read only:
  • bbox
  • calib (may be absent)
  • filter (may be unset)
  • detector (if wcs is pure tangent; may be absent) The following are updated:
  • wcs (the initial value is used as an initial guess, and is required)
[in]sourceCatcatalog of sources detected on the exposure (an lsst.afw.table.SourceCatalog)
Returns
an lsst.pipe.base.Struct with these fields:
  • refCat reference object catalog of objects that overlap the exposure (with some margin) (an lsst::afw::table::SimpleCatalog)
  • matches astrometric matches, a list of lsst.afw.table.ReferenceMatch
  • scatterOnSky median on-sky separation between reference objects and sources in "matches" (an lsst.afw.geom.Angle), or None if config.forceKnownWcs True
  • matchMeta metadata needed to unpersist matches (an lsst.daf.base.PropertyList)

Definition at line 164 of file astrometry.py.

def lsst.meas.astrom.astrometry.AstrometryTask.solve (   self,
  exposure,
  sourceCat 
)

Load reference objects overlapping an exposure, match to sources and fit a WCS.

Returns
an lsst.pipe.base.Struct with these fields:
  • refCat reference object catalog of objects that overlap the exposure (with some margin) (an lsst::afw::table::SimpleCatalog)
  • matches astrometric matches, a list of lsst.afw.table.ReferenceMatch
  • scatterOnSky median on-sky separation between reference objects and sources in "matches" (an lsst.afw.geom.Angle)
  • matchMeta metadata needed to unpersist matches (an lsst.daf.base.PropertyList)
Note
ignores config.forceKnownWcs

Definition at line 194 of file astrometry.py.

Member Data Documentation

lsst.meas.astrom.astrometry.AstrometryTask.ConfigClass = AstrometryConfig
static

Definition at line 143 of file astrometry.py.

lsst.meas.astrom.astrometry.AstrometryTask.usedKey

Definition at line 156 of file astrometry.py.


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