lsst.pipe.tasks gd5638573c2+392ae78cd2
Loading...
Searching...
No Matches
lsst.pipe.tasks.functors.LocalWcs Class Reference
Inheritance diagram for lsst.pipe.tasks.functors.LocalWcs:
lsst.pipe.tasks.functors.Functor lsst.pipe.tasks.functors.ComputePixelScale lsst.pipe.tasks.functors.ConvertDetectorAngleToPositionAngle lsst.pipe.tasks.functors.ConvertPixelSqToArcsecondsSq lsst.pipe.tasks.functors.ConvertPixelToArcseconds

Public Member Functions

 __init__ (self, colCD_1_1, colCD_1_2, colCD_2_1, colCD_2_2, **kwargs)
 computeDeltaRaDec (self, x, y, cd11, cd12, cd21, cd22)
 computeSkySeparation (self, ra1, dec1, ra2, dec2)
 getSkySeparationFromPixel (self, x1, y1, x2, y2, cd11, cd12, cd21, cd22)
 computePositionAngle (self, ra1, dec1, ra2, dec2)
 getPositionAngleFromDetectorAngle (self, theta, cd11, cd12, cd21, cd22)
Public Member Functions inherited from lsst.pipe.tasks.functors.Functor
 __init__ (self, filt=None, dataset=None, noDup=None)
 noDup (self)
 columns (self)
 multilevelColumns (self, data, columnIndex=None, returnTuple=False)
 __call__ (self, data, dropna=False)
 difference (self, data1, data2, **kwargs)
 fail (self, df)
 name (self)
 shortname (self)

Public Attributes

 colCD_1_1 = colCD_1_1
 colCD_1_2 = colCD_1_2
 colCD_2_1 = colCD_2_1
 colCD_2_2 = colCD_2_2
Public Attributes inherited from lsst.pipe.tasks.functors.Functor
 filt = filt
str dataset = dataset if dataset is not None else self._defaultDataset
 log = logging.getLogger(type(self).__name__)
 name

Additional Inherited Members

Protected Member Functions inherited from lsst.pipe.tasks.functors.Functor
 _get_data_columnLevels (self, data, columnIndex=None)
 _get_data_columnLevelNames (self, data, columnIndex=None)
 _colsFromDict (self, colDict, columnIndex=None)
 _func (self, df, dropna=True)
 _get_columnIndex (self, data)
 _get_data (self, data)
 _setLevels (self, df)
 _dropna (self, vals)
Protected Attributes inherited from lsst.pipe.tasks.functors.Functor
 _noDup = noDup
Static Protected Attributes inherited from lsst.pipe.tasks.functors.Functor
str _defaultDataset = 'ref'
tuple _dfLevels = ('column',)
bool _defaultNoDup = False

Detailed Description

Computations using the stored localWcs.

Member Function Documentation

◆ computeDeltaRaDec()

lsst.pipe.tasks.functors.LocalWcs.computeDeltaRaDec ( self,
x,
y,
cd11,
cd12,
cd21,
cd22 )
Compute the dRA, dDec from dx, dy.

Parameters
----------
x : `~pandas.Series`
    X pixel coordinate.
y : `~pandas.Series`
    Y pixel coordinate.
cd11 : `~pandas.Series`
    [1, 1] element of the local Wcs affine transform.
cd12 : `~pandas.Series`
    [1, 2] element of the local Wcs affine transform.
cd21 : `~pandas.Series`
    [2, 1] element of the local Wcs affine transform.
cd22 : `~pandas.Series`
    [2, 2] element of the local Wcs affine transform.

Returns
-------
raDecTuple : tuple
    RA and Dec conversion of x and y given the local Wcs.
    Returned units are in radians.

Notes
-----
If x and y are with respect to the CRVAL1, CRVAL2
then this will return the RA, Dec for that WCS.

◆ computePositionAngle()

lsst.pipe.tasks.functors.LocalWcs.computePositionAngle ( self,
ra1,
dec1,
ra2,
dec2 )
Compute position angle (E of N) from (ra1, dec1) to (ra2, dec2).

Parameters
----------
ra1 : iterable [`float`]
    RA of the first coordinate [radian].
dec1 : iterable [`float`]
    Dec of the first coordinate [radian].
ra2 : iterable [`float`]
    RA of the second coordinate [radian].
dec2 : iterable [`float`]
    Dec of the second coordinate [radian].

Returns
-------
Position Angle: `~pandas.Series`
    radians E of N

Notes
-----
(ra1, dec1) -> (ra2, dec2) is interpreted as the shorter way around the sphere

For a separation of 0.0001 rad, the position angle is good to 0.0009 rad
all over the sphere.

◆ computeSkySeparation()

lsst.pipe.tasks.functors.LocalWcs.computeSkySeparation ( self,
ra1,
dec1,
ra2,
dec2 )
Compute the local pixel scale conversion.

Parameters
----------
ra1 : `~pandas.Series`
    Ra of the first coordinate in radians.
dec1 : `~pandas.Series`
    Dec of the first coordinate in radians.
ra2 : `~pandas.Series`
    Ra of the second coordinate in radians.
dec2 : `~pandas.Series`
    Dec of the second coordinate in radians.

Returns
-------
dist : `~pandas.Series`
    Distance on the sphere in radians.

◆ getPositionAngleFromDetectorAngle()

lsst.pipe.tasks.functors.LocalWcs.getPositionAngleFromDetectorAngle ( self,
theta,
cd11,
cd12,
cd21,
cd22 )
Compute position angle (E of N) from detector angle (+y of +x).

Parameters
----------
theta : `float`
    detector angle [radian]
cd11 : `float`
    [1, 1] element of the local Wcs affine transform.
cd12 : `float`
    [1, 2] element of the local Wcs affine transform.
cd21 : `float`
    [2, 1] element of the local Wcs affine transform.
cd22 : `float`
    [2, 2] element of the local Wcs affine transform.

Returns
-------
Position Angle: `~pandas.Series`
    Degrees E of N.

◆ getSkySeparationFromPixel()

lsst.pipe.tasks.functors.LocalWcs.getSkySeparationFromPixel ( self,
x1,
y1,
x2,
y2,
cd11,
cd12,
cd21,
cd22 )
Compute the distance on the sphere from x2, y1 to x1, y1.

Parameters
----------
x1 : `~pandas.Series`
    X pixel coordinate.
y1 : `~pandas.Series`
    Y pixel coordinate.
x2 : `~pandas.Series`
    X pixel coordinate.
y2 : `~pandas.Series`
    Y pixel coordinate.
cd11 : `~pandas.Series`
    [1, 1] element of the local Wcs affine transform.
cd12 : `~pandas.Series`
    [1, 2] element of the local Wcs affine transform.
cd21 : `~pandas.Series`
    [2, 1] element of the local Wcs affine transform.
cd22 : `~pandas.Series`
    [2, 2] element of the local Wcs affine transform.

Returns
-------
Distance : `~pandas.Series`
    Arcseconds per pixel at the location of the local WC.

The documentation for this class was generated from the following file:
  • python/lsst/pipe/tasks/functors.py