From e16203a4e5877d3ad196d5e23bb15e4f382d08c6 Mon Sep 17 00:00:00 2001 From: BENR0 Date: Fri, 14 Jun 2024 11:16:56 +0200 Subject: [PATCH] refactor: import WGS parameters from cartopy --- pyresample/utils/cartopy.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/pyresample/utils/cartopy.py b/pyresample/utils/cartopy.py index 128a8c6c..29dea4e4 100644 --- a/pyresample/utils/cartopy.py +++ b/pyresample/utils/cartopy.py @@ -33,9 +33,6 @@ import cartopy.crs as ccrs import shapely.geometry as sgeom -WGS84_SEMIMAJOR_AXIS = 6378137.0 -WGS84_SEMIMINOR_AXIS = 6356752.3142 - class Projection(ccrs.Projection): """Flexible generic Projection with optionally specified bounds.""" @@ -81,8 +78,8 @@ def __init__(self, satellite_height = 35785831 false_easting = 0 false_northing = 0 - a = float(WGS84_SEMIMAJOR_AXIS) - b = float(WGS84_SEMIMINOR_AXIS) + a = float(ccrs.WGS84_SEMIMAJOR_AXIS) + b = float(ccrs.WGS84_SEMIMINOR_AXIS) h = float(satellite_height) # To find the bound we trace around where the line from the satellite