PatchInfo¶
- class lsst.skymap.PatchInfo(index, innerBBox, outerBBox, sequentialIndex, tractWcs, cellInnerDimensions=(0, 0), cellBorder=0, numCellsPerPatchInner=0, numCellsInPatchBorder=0)¶
Bases:
object
Information about a patch within a tract of a sky map.
If cellInnerDimensions and cellBorder are set then the patch will be gridded with cells.
See
TractInfo
for more information.- Parameters:
- index
lsst.skymap.Index2D
x,y index of patch (a pair of ints)
- innerBBox
lsst.geom.Box2I
inner bounding box
- outerBBox
lsst.geom.Box2I
inner bounding box
- sequentialIndex
int
Patch sequential index
- tractWcs
lsst.afw.geom.SkyWcs
Tract WCS object.
- cellInnerDimensions
Iterable
of 2int
orlsst.geom.Extent2I
, optional Inner dimensions of each cell (x,y pixels).
- cellBorder
int
, optional Cell border size (pixels).
- numCellsPerPatchInner
int
, optional Number of cells per inner patch region.
- numCellsInPatchBorder
int
, optional Number of cells in the patch border.
- index
Attributes Summary
Get dimensions of inner region of the cells (all are the same)
Return patch index: a tuple of (x, y)
Get inner bounding box.
Get the number of cells in x, y.
Get outer bounding box.
Return patch sequential index.
Return the associated tract wcs
Methods Summary
getCellIndexPair
(sequentialIndex)Convert a sequential index into an index pair.
getCellInfo
(index)Return information for the specified cell.
Get dimensions of inner region of the cells (all are the same)
getIndex
()Return patch index: a tuple of (x, y)
Get inner bounding box.
getInnerSkyPolygon
([tractWcs])Get the inner on-sky region.
Get the number of cells in x, y.
Get outer bounding box.
getOuterSkyPolygon
([tractWcs])Get the outer on-sky region.
getSequentialCellIndex
(cellInfo)Return a single integer that uniquely identifies the given cell within this patch.
Return a single integer that uniquely identifies the given cell within this patch.
Return patch sequential index.
getWcs
()Return the associated tract wcs
Attributes Documentation
- cell_border¶
- cell_inner_dimensions¶
Get dimensions of inner region of the cells (all are the same)
- index¶
Return patch index: a tuple of (x, y)
- Returns:
- result
lsst.skymap.Index2D
Patch index (x, y).
- result
- inner_bbox¶
Get inner bounding box.
- Returns:
- bbox
lsst.geom.Box2I
The inner bounding Box.
- bbox
- inner_sky_polygon¶
- num_cells¶
Get the number of cells in x, y.
May return (0, 0) if no cells are defined.
- Returns:
- result
lsst.skymap.Index2D
The number of cells in x, y.
- result
- outer_bbox¶
Get outer bounding box.
- Returns:
- bbox
lsst.geom.Box2I
The outer bounding Box.
- bbox
- outer_sky_polygon¶
- wcs¶
Return the associated tract wcs
- Returns:
- wcs
lsst.afw.geom.SkyWcs
Tract WCS.
- wcs
Methods Documentation
- getCellBorder()¶
- getCellIndexPair(sequentialIndex)¶
Convert a sequential index into an index pair.
- Parameters:
- sequentialIndex
int
- sequentialIndex
- Returns:
- Raises:
- IndexError
Raised if index is out of range.
- getCellInfo(index)¶
Return information for the specified cell.
- Parameters:
- index
lsst.skymap.Index2D
orIterable
of 2int
Index of cell, as
Index2D
,or two integers, or a sequential index as returned by getSequentialCellIndex; negative values are not supported.
- index
- Returns:
- result
lsst.skymap.CellInfo
The cell info for that index.
- result
- Raises:
- IndexError
Raised if index is out of range.
- getCellInnerDimensions()¶
Get dimensions of inner region of the cells (all are the same)
- getIndex()¶
Return patch index: a tuple of (x, y)
- Returns:
- result
lsst.skymap.Index2D
Patch index (x, y).
- result
- getInnerBBox()¶
Get inner bounding box.
- Returns:
- bbox
lsst.geom.Box2I
The inner bounding Box.
- bbox
- getInnerSkyPolygon(tractWcs=None)¶
Get the inner on-sky region.
- Parameters:
- tractWcs
lsst.afw.image.SkyWcs
, optional WCS for the associated tract.
- tractWcs
- Returns:
- result
lsst.sphgeom.ConvexPolygon
The inner sky region.
- result
- getNumCells()¶
Get the number of cells in x, y.
May return (0, 0) if no cells are defined.
- Returns:
- result
lsst.skymap.Index2D
The number of cells in x, y.
- result
- getOuterBBox()¶
Get outer bounding box.
- Returns:
- bbox
lsst.geom.Box2I
The outer bounding Box.
- bbox
- getOuterSkyPolygon(tractWcs=None)¶
Get the outer on-sky region.
- Parameters:
- tractWcs
lsst.afw.image.SkyWcs
, optional WCS for the associated tract.
- tractWcs
- Returns:
- result
lsst.sphgeom.ConvexPolygon
The outer sky region.
- result
- getSequentialCellIndex(cellInfo)¶
Return a single integer that uniquely identifies the given cell within this patch.
- Parameters:
- cellInfo
lsst.skymap.CellInfo
- cellInfo
- Returns:
- sequentialIndex
int
- sequentialIndex
- Raises:
- IndexError
Raised if index is out of range.
- getSequentialCellIndexFromPair(index)¶
Return a single integer that uniquely identifies the given cell within this patch.
- Parameters:
- index
lsst.skymap.Index2D
- index
- Returns:
- sequentialIndex
int
- sequentialIndex
- Raises:
- IndexError
Raised if index is out of range.
- getWcs()¶
Return the associated tract wcs
- Returns:
- wcs
lsst.afw.geom.SkyWcs
Tract WCS.
- wcs