datacube.utils.geometry.CRS¶
- class datacube.utils.geometry.CRS(crs_str)[source]¶
Wrapper around pyproj.CRS for backwards compatibility.
- Parameters
crs_str (
Any) – string representation of a CRS, often an EPSG code like ‘EPSG:4326’- Raises
pyproj.exceptions.CRSError
Methods
__init__(crs_str)to_epsg()Return EPSG Code of the CRS or None.
to_wkt([pretty, version])WKT representation of the CRS
transformer_to_crs(other[, always_xy])Return a function that maps x, y -> x’, y’.
Attributes
DEFAULT_WKT_VERSIONDEPRECATED
List dimension names of the CRS.
epsggeographicinverse_flatteningAccess proj.CRS object that this wraps.
projectedsemi_major_axissemi_minor_axisList of dimension units of the CRS.
Return valid region of this CRS.
wktAttributes:
DEPRECATED
List dimension names of the CRS.
Access proj.CRS object that this wraps.
List of dimension units of the CRS.
Return valid region of this CRS.
Methods:
to_epsg()Return EPSG Code of the CRS or None.
to_wkt([pretty, version])WKT representation of the CRS
transformer_to_crs(other[, always_xy])Return a function that maps x, y -> x’, y’.
- property dimensions: Tuple[str, str]¶
List dimension names of the CRS.
The ordering of the names is intended to reflect the numpy array axis order of the loaded raster.
- property proj: pyproj.crs.crs.CRS¶
Access proj.CRS object that this wraps.
- Return type
CRS
- transformer_to_crs(other, always_xy=True)[source]¶
Return a function that maps x, y -> x’, y’.
Where x, y are coordinates in this stored either as scalars or ndarray objects and x’, y’ are the same points in the other CRS.
- property units: Tuple[str, str]¶
List of dimension units of the CRS.
The ordering of the units is intended to reflect the numpy array axis order of the loaded raster.