wradlib.georef.projection.GeorefProjectionMethods.get_earth_radius#
- GeorefProjectionMethods.get_earth_radius(*, crs=None)[source]#
Get the radius of the Earth (in m) for a given Spheroid model (crs) at a given position.
\[R^2 = \frac{a^4 \cos(f)^2 + b^4 \sin(f)^2} {a^2 \cos(f)^2 + b^2 \sin(f)^2}\]- Parameters:
obj (
xarray.DataArray|xarray.Dataset)- Keyword Arguments:
crs –
Coordinate Reference System (CRS) of the coordinates. Can be one of:
A
pyproj.crs.CoordinateSysteminstanceA
cartopy.crs.CRSinstanceA
osgeo.osr.SpatialReferenceinstanceA type accepted by
pyproj.crs.CRS.from_user_input(e.g., EPSG code, PROJ string, dictionary, WKT, or any object with a to_wkt() method)
Defaults to EPSG(4326).
- Returns:
radius (
float) – earth radius in meter