SkyRegion

class regions.SkyRegion[source]

Bases: Region

Base class for all regions defined in celestial coordinates.

Methods Summary

contains(skycoord, wcs)

Check whether a sky coordinate falls inside the region.

intersection(other)

Return a region representing the intersection of this region with other.

symmetric_difference(other)

Return the union of the two regions minus any areas contained in the intersection of the two regions.

to_pixel(wcs)

Return the equivalent region defined in pixel coordinates.

union(other)

Return a region representing the union of this region with other.

Methods Documentation

contains(skycoord, wcs)[source]

Check whether a sky coordinate falls inside the region.

Parameters:
skycoordSkyCoord

The position or positions to check.

wcsWCS

The world coordinate system transformation to use to convert between sky and pixel coordinates.

intersection(other)[source]

Return a region representing the intersection of this region with other.

symmetric_difference(other)[source]

Return the union of the two regions minus any areas contained in the intersection of the two regions.

abstract to_pixel(wcs)[source]

Return the equivalent region defined in pixel coordinates.

Parameters:
wcsWCS

The world coordinate system transformation to use to convert between sky and pixel coordinates.

Returns:
pixel_regionPixelRegion

A pixel region.

union(other)[source]

Return a region representing the union of this region with other.