lsst.afw  14.0-49-g535656444+1
Functions
lsst.afw.coord.utils Namespace Reference

Functions

def assertCoordsAlmostEqual (testCase, coord0, coord1, maxDiff=0.001 *afwGeom.arcseconds, msg="Coords differ")
 Assert that two coords represent almost the same point on the sky. More...
 
def assertCoordListsAlmostEqual (testCase, coordlist0, coordlist1, maxDiff=0.001 *afwGeom.arcseconds, msg=None)
 Assert that two lists of IcrsCoords represent almost the same point on the sky. More...
 
def assertCoordsNearlyEqual (args, kwargs)
 

Function Documentation

◆ assertCoordListsAlmostEqual()

def lsst.afw.coord.utils.assertCoordListsAlmostEqual (   testCase,
  coordlist0,
  coordlist1,
  maxDiff = 0.001*afwGeom.arcseconds,
  msg = None 
)

Assert that two lists of IcrsCoords represent almost the same point on the sky.

Warning
the coordinate systems are not compared; instead both sets of angles are converted to ICRS and the angular separation measured.
Parameters
[in]testCaseunittest.TestCase instance the test is part of; an object supporting one method: fail(self, msgStr)
[in]coordlist0list of IcrsCoords 0
[in]coordlist1list of IcrsCoords 1
[in]maxDiffmaximum angular separation, an lsst.afw.geom.Angle
[in]msgexception message prefix; details of the error are appended after ": "

Definition at line 60 of file utils.py.

◆ assertCoordsAlmostEqual()

def lsst.afw.coord.utils.assertCoordsAlmostEqual (   testCase,
  coord0,
  coord1,
  maxDiff = 0.001*afwGeom.arcseconds,
  msg = "Coords differ" 
)

Assert that two coords represent almost the same point on the sky.

Warning
the coordinate systems are not compared; instead both angles are converted to ICRS and the angular separation measured.
Parameters
[in]testCaseunittest.TestCase instance the test is part of; an object supporting one method: fail(self, msgStr)
[in]coord0coord 0 (an lsst.afw.geom.Coord)
[in]coord1coord 1 (an lsst.afw.geom.Coord)
[in]maxDiffmaximum angular separation between the two coords (an lsst.afw.geom.Angle)
[in]msgexception message prefix; details of the error are appended after ": "
Exceptions
AssertionErrorif the unwrapped difference is greater than maxDiff

Definition at line 38 of file utils.py.

◆ assertCoordsNearlyEqual()

def lsst.afw.coord.utils.assertCoordsNearlyEqual (   args,
  kwargs 
)

Definition at line 86 of file utils.py.