lsst.meas.astrom  14.0-7-g0d69b06+3
Public Member Functions | Static Public Attributes | List of all members
lsst.meas.astrom.fitTanSipWcs.FitTanSipWcsTask Class Reference

Fit a TAN-SIP WCS given a list of reference object/source matches. More...

Inheritance diagram for lsst.meas.astrom.fitTanSipWcs.FitTanSipWcsTask:

Public Member Functions

def fitWcs (self, matches, initWcs, bbox=None, refCat=None, sourceCat=None, exposure=None)
 Fit a TAN-SIP WCS from a list of reference object/source matches. More...
 
def initialWcs (self, matches, wcs)
 
def rejectMatches (self, matches, wcs, rejected)
 
def plotFit (self, matches, wcs, rejected)
 

Static Public Attributes

 ConfigClass = FitTanSipWcsConfig
 

Detailed Description

Fit a TAN-SIP WCS given a list of reference object/source matches.

Contents

Description

Fit a TAN-SIP WCS given a list of reference object/source matches. See CreateWithSip.h for information about the fitting algorithm.

Task initialisation

Invoking the Task

Fit a TAN-SIP WCS from a list of reference object/source matches.

Parameters
[in,out]matchesa list of lsst::afw::table::ReferenceMatch The following fields are read:
  • match.first (reference object) coord
  • match.second (source) centroid The following fields are written:
  • match.first (reference object) centroid,
  • match.second (source) centroid
  • match.distance (on sky separation, in radians)
[in]initWcsinitial WCS
[in]bboxthe region over which the WCS will be valid (an lsst:afw::geom::Box2I); if None or an empty box then computed from matches
[in,out]refCatreference object catalog, or None. If provided then all centroids are updated with the new WCS, otherwise only the centroids for ref objects in matches are updated. Required fields are "centroid_x", "centroid_y", "coord_ra", and "coord_dec".
[in,out]sourceCatsource catalog, or None. If provided then coords are updated with the new WCS; otherwise only the coords for sources in matches are updated. Required fields are "slot_Centroid_x", "slot_Centroid_y", and "coord_ra", and "coord_dec".
[in]exposureIgnored; present for consistency with FitSipDistortionTask.
Returns
an lsst.pipe.base.Struct with the following fields:
  • wcs the fit WCS as an lsst.afw.geom.Wcs
  • scatterOnSky median on-sky separation between reference objects and sources in "matches", as an lsst.afw.geom.Angle

Configuration parameters

See FitTanSipWcsConfig

A complete example of using FitTanSipWcsTask

FitTanSipWcsTask is a subtask of AstrometryTask, which is called by PhotoCalTask. See pipe_tasks_photocal_Example.

Debug variables

FitTanSipWcsTask does not support any debug variables.

Definition at line 62 of file fitTanSipWcs.py.

Member Function Documentation

◆ fitWcs()

def lsst.meas.astrom.fitTanSipWcs.FitTanSipWcsTask.fitWcs (   self,
  matches,
  initWcs,
  bbox = None,
  refCat = None,
  sourceCat = None,
  exposure = None 
)

Fit a TAN-SIP WCS from a list of reference object/source matches.

Parameters
[in,out]matchesa list of lsst::afw::table::ReferenceMatch The following fields are read:
  • match.first (reference object) coord
  • match.second (source) centroid The following fields are written:
  • match.first (reference object) centroid,
  • match.second (source) centroid
  • match.distance (on sky separation, in radians)
[in]initWcsinitial WCS
[in]bboxthe region over which the WCS will be valid (an lsst:afw::geom::Box2I); if None or an empty box then computed from matches
[in,out]refCatreference object catalog, or None. If provided then all centroids are updated with the new WCS, otherwise only the centroids for ref objects in matches are updated. Required fields are "centroid_x", "centroid_y", "coord_ra", and "coord_dec".
[in,out]sourceCatsource catalog, or None. If provided then coords are updated with the new WCS; otherwise only the coords for sources in matches are updated. Required fields are "slot_Centroid_x", "slot_Centroid_y", and "coord_ra", and "coord_dec".
[in]exposureIgnored; present for consistency with FitSipDistortionTask.
Returns
an lsst.pipe.base.Struct with the following fields:
  • wcs the fit WCS as an lsst.afw.geom.Wcs
  • scatterOnSky median on-sky separation between reference objects and sources in "matches", as an lsst.afw.geom.Angle

Definition at line 107 of file fitTanSipWcs.py.

◆ initialWcs()

def lsst.meas.astrom.fitTanSipWcs.FitTanSipWcsTask.initialWcs (   self,
  matches,
  wcs 
)
Generate a guess Wcs from the astrometric matches

We create a Wcs anchored at the center of the matches, with the scale
of the input Wcs.  This is necessary because matching returns only
matches with no estimated Wcs, and the input Wcs is a wild guess.
We're using the best of each: positions from the matches, and scale
from the input Wcs.

Definition at line 195 of file fitTanSipWcs.py.

◆ plotFit()

def lsst.meas.astrom.fitTanSipWcs.FitTanSipWcsTask.plotFit (   self,
  matches,
  wcs,
  rejected 
)
Plot the fit

We create four plots, for all combinations of (dx, dy) against
(x, y).  Good points are black, while rejected points are red.

Definition at line 236 of file fitTanSipWcs.py.

◆ rejectMatches()

def lsst.meas.astrom.fitTanSipWcs.FitTanSipWcsTask.rejectMatches (   self,
  matches,
  wcs,
  rejected 
)
Flag deviant matches

We return a boolean numpy array indicating whether the corresponding
match should be rejected.  The previous list of rejections is used
so we can calculate uncontaminated statistics.

Definition at line 223 of file fitTanSipWcs.py.

Member Data Documentation

◆ ConfigClass

lsst.meas.astrom.fitTanSipWcs.FitTanSipWcsTask.ConfigClass = FitTanSipWcsConfig
static

Definition at line 103 of file fitTanSipWcs.py.


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