LSST Applications  21.0.0-172-gfb10e10a+18fedfabac,22.0.0+297cba6710,22.0.0+80564b0ff1,22.0.0+8d77f4f51a,22.0.0+a28f4c53b1,22.0.0+dcf3732eb2,22.0.1-1-g7d6de66+2a20fdde0d,22.0.1-1-g8e32f31+297cba6710,22.0.1-1-geca5380+7fa3b7d9b6,22.0.1-12-g44dc1dc+2a20fdde0d,22.0.1-15-g6a90155+515f58c32b,22.0.1-16-g9282f48+790f5f2caa,22.0.1-2-g92698f7+dcf3732eb2,22.0.1-2-ga9b0f51+7fa3b7d9b6,22.0.1-2-gd1925c9+bf4f0e694f,22.0.1-24-g1ad7a390+a9625a72a8,22.0.1-25-g5bf6245+3ad8ecd50b,22.0.1-25-gb120d7b+8b5510f75f,22.0.1-27-g97737f7+2a20fdde0d,22.0.1-32-gf62ce7b1+aa4237961e,22.0.1-4-g0b3f228+2a20fdde0d,22.0.1-4-g243d05b+871c1b8305,22.0.1-4-g3a563be+32dcf1063f,22.0.1-4-g44f2e3d+9e4ab0f4fa,22.0.1-42-gca6935d93+ba5e5ca3eb,22.0.1-5-g15c806e+85460ae5f3,22.0.1-5-g58711c4+611d128589,22.0.1-5-g75bb458+99c117b92f,22.0.1-6-g1c63a23+7fa3b7d9b6,22.0.1-6-g50866e6+84ff5a128b,22.0.1-6-g8d3140d+720564cf76,22.0.1-6-gd805d02+cc5644f571,22.0.1-8-ge5750ce+85460ae5f3,master-g6e05de7fdc+babf819c66,master-g99da0e417a+8d77f4f51a,w.2021.48
LSST Data Management Base Package
Public Member Functions | Properties | List of all members
lsst.skymap.cellInfo.CellInfo Class Reference

Public Member Functions

def __init__ (self, index, innerBBox, outerBBox, sequentialIndex, tractWcs)
 
def getIndex (self)
 
def getSequentialIndex (self)
 
def getWcs (self)
 
def getInnerBBox (self)
 
def getOuterBBox (self)
 
def getInnerSkyPolygon (self, tractWcs=None)
 
def inner_sky_polygon (self)
 
def getOuterSkyPolygon (self, tractWcs=None)
 
def outer_sky_polygon (self)
 
def __eq__ (self, rhs)
 
def __ne__ (self, rhs)
 
def __str__ (self)
 
def __repr__ (self)
 

Properties

 index = property(getIndex)
 
 sequential_index = property(getSequentialIndex)
 
 wcs = property(getWcs)
 
 inner_bbox = property(getInnerBBox)
 
 outer_bbox = property(getOuterBBox)
 

Detailed Description

Information about a cell within a patch of a tract of a sky map.

See `PatchInfo` and `TractInfo` for more information.

Parameters
----------
index : `lsst.skymap.Index2D`
    x,y index of a cell (a pair of ints)
innerBBox : `lsst.geom.Box2I`
    Inner bounding box.
outerBBox : `lsst.geom.Box2I`
    Outer bounding box.
sequentialIndex : `int`
    Cell sequential index.
tractWcs : `lsst.afw.geom.SkyWcs`
    Tract WCS object.

Definition at line 28 of file cellInfo.py.

Constructor & Destructor Documentation

◆ __init__()

def lsst.skymap.cellInfo.CellInfo.__init__ (   self,
  index,
  innerBBox,
  outerBBox,
  sequentialIndex,
  tractWcs 
)

Definition at line 46 of file cellInfo.py.

46  def __init__(self, index, innerBBox, outerBBox, sequentialIndex, tractWcs):
47  self._index = index
48  self._sequentialIndex = sequentialIndex
49  self._innerBBox = innerBBox
50  self._outerBBox = outerBBox
51  self._wcs = tractWcs
52  if not outerBBox.contains(innerBBox):
53  raise RuntimeError("outerBBox=%s does not contain innerBBox=%s" % (outerBBox, innerBBox))
54 

Member Function Documentation

◆ __eq__()

def lsst.skymap.cellInfo.CellInfo.__eq__ (   self,
  rhs 
)

Definition at line 155 of file cellInfo.py.

155  def __eq__(self, rhs):
156  return (self.getIndex() == rhs.getIndex()) \
157  and (self.getInnerBBox() == rhs.getInnerBBox()) \
158  and (self.getOuterBBox() == rhs.getOuterBBox())
159 

◆ __ne__()

def lsst.skymap.cellInfo.CellInfo.__ne__ (   self,
  rhs 
)

Definition at line 160 of file cellInfo.py.

160  def __ne__(self, rhs):
161  return not self.__eq__(rhs)
162 

◆ __repr__()

def lsst.skymap.cellInfo.CellInfo.__repr__ (   self)

Definition at line 166 of file cellInfo.py.

166  def __repr__(self):
167  return "CellInfo(index=%s, innerBBox=%s, outerBBox=%s)" % \
168  (self.getIndex(), self.getInnerBBox(), self.getOuterBBox())

◆ __str__()

def lsst.skymap.cellInfo.CellInfo.__str__ (   self)

Definition at line 163 of file cellInfo.py.

163  def __str__(self):
164  return "CellInfo(index=%s)" % (self.getIndex(),)
165 

◆ getIndex()

def lsst.skymap.cellInfo.CellInfo.getIndex (   self)
Return cell index: a tuple of (x, y)

Returns
-------
result : `lsst.skymap.Index2D`
    Patch index (x, y).

Definition at line 55 of file cellInfo.py.

55  def getIndex(self):
56  """Return cell index: a tuple of (x, y)
57 
58  Returns
59  -------
60  result : `lsst.skymap.Index2D`
61  Patch index (x, y).
62  """
63  return self._index
64 

◆ getInnerBBox()

def lsst.skymap.cellInfo.CellInfo.getInnerBBox (   self)
Get inner bounding box.

Returns
-------
bbox : `lsst.geom.Box2I`
    The inner bounding Box.

Definition at line 91 of file cellInfo.py.

91  def getInnerBBox(self):
92  """Get inner bounding box.
93 
94  Returns
95  -------
96  bbox : `lsst.geom.Box2I`
97  The inner bounding Box.
98  """
99  return self._innerBBox
100 

◆ getInnerSkyPolygon()

def lsst.skymap.cellInfo.CellInfo.getInnerSkyPolygon (   self,
  tractWcs = None 
)
Get the inner on-sky region.

Parameters
----------
tractWcs : `lsst.afw.image.SkyWcs`, optional
    WCS for the associated tract.

Returns
-------
result : `lsst.sphgeom.ConvexPolygon`
    The inner sky region.

Definition at line 115 of file cellInfo.py.

115  def getInnerSkyPolygon(self, tractWcs=None):
116  """Get the inner on-sky region.
117 
118  Parameters
119  ----------
120  tractWcs : `lsst.afw.image.SkyWcs`, optional
121  WCS for the associated tract.
122 
123  Returns
124  -------
125  result : `lsst.sphgeom.ConvexPolygon`
126  The inner sky region.
127  """
128  _tractWcs = tractWcs if tractWcs is not None else self._wcs
129  return makeSkyPolygonFromBBox(bbox=self.getInnerBBox(), wcs=_tractWcs)
130 
def makeSkyPolygonFromBBox(bbox, wcs)
Definition: utils.py:61

◆ getOuterBBox()

def lsst.skymap.cellInfo.CellInfo.getOuterBBox (   self)
Get outer bounding box.

Returns
-------
bbox : `lsst.geom.Box2I`
    The outer bounding Box.

Definition at line 103 of file cellInfo.py.

103  def getOuterBBox(self):
104  """Get outer bounding box.
105 
106  Returns
107  -------
108  bbox : `lsst.geom.Box2I`
109  The outer bounding Box.
110  """
111  return self._outerBBox
112 

◆ getOuterSkyPolygon()

def lsst.skymap.cellInfo.CellInfo.getOuterSkyPolygon (   self,
  tractWcs = None 
)
Get the outer on-sky region.

Parameters
----------
tractWcs : `lsst.afw.image.SkyWcs`, optional
    WCS for the associated tract.

Returns
-------
result : `lsst.sphgeom.ConvexPolygon`
    The outer sky region.

Definition at line 135 of file cellInfo.py.

135  def getOuterSkyPolygon(self, tractWcs=None):
136  """Get the outer on-sky region.
137 
138  Parameters
139  ----------
140  tractWcs : `lsst.afw.image.SkyWcs`, optional
141  WCS for the associated tract.
142 
143  Returns
144  -------
145  result : `lsst.sphgeom.ConvexPolygon`
146  The outer sky region.
147  """
148  _tractWcs = tractWcs if tractWcs is not None else self._wcs
149  return makeSkyPolygonFromBBox(bbox=self.getOuterBBox(), wcs=_tractWcs)
150 

◆ getSequentialIndex()

def lsst.skymap.cellInfo.CellInfo.getSequentialIndex (   self)
Return cell sequential index.

Returns
-------
result : `int`
    Sequential cell index.

Definition at line 67 of file cellInfo.py.

67  def getSequentialIndex(self):
68  """Return cell sequential index.
69 
70  Returns
71  -------
72  result : `int`
73  Sequential cell index.
74  """
75  return self._sequentialIndex
76 

◆ getWcs()

def lsst.skymap.cellInfo.CellInfo.getWcs (   self)
Return the associated tract wcs

Returns
-------
wcs : `lsst.afw.geom.SkyWcs`
    Tract WCS.

Definition at line 79 of file cellInfo.py.

79  def getWcs(self):
80  """Return the associated tract wcs
81 
82  Returns
83  -------
84  wcs : `lsst.afw.geom.SkyWcs`
85  Tract WCS.
86  """
87  return self._wcs
88 

◆ inner_sky_polygon()

def lsst.skymap.cellInfo.CellInfo.inner_sky_polygon (   self)

Definition at line 132 of file cellInfo.py.

132  def inner_sky_polygon(self):
133  return self.getInnerSkyPolygon()
134 

◆ outer_sky_polygon()

def lsst.skymap.cellInfo.CellInfo.outer_sky_polygon (   self)

Definition at line 152 of file cellInfo.py.

152  def outer_sky_polygon(self):
153  return self.getOuterSkyPolygon()
154 

Property Documentation

◆ index

lsst.skymap.cellInfo.CellInfo.index = property(getIndex)
static

Definition at line 65 of file cellInfo.py.

◆ inner_bbox

lsst.skymap.cellInfo.CellInfo.inner_bbox = property(getInnerBBox)
static

Definition at line 101 of file cellInfo.py.

◆ outer_bbox

lsst.skymap.cellInfo.CellInfo.outer_bbox = property(getOuterBBox)
static

Definition at line 113 of file cellInfo.py.

◆ sequential_index

lsst.skymap.cellInfo.CellInfo.sequential_index = property(getSequentialIndex)
static

Definition at line 77 of file cellInfo.py.

◆ wcs

lsst.skymap.cellInfo.CellInfo.wcs = property(getWcs)
static

Definition at line 89 of file cellInfo.py.


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