Skip to content

Commit ef250c4

Browse files
committed
Correct wrong is_geodetic crs attribute
1 parent 61e7b0f commit ef250c4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

climada/util/coordinates.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ def infer_unit_coords(coords):
134134
unit cannot be inferred.
135135
"""
136136

137-
if coords.crs.is_geodetic():
137+
if coords.crs.is_geographic:
138138
unit = "degree"
139139
elif coords.crs.is_projected:
140140
unit = "m"
@@ -1549,7 +1549,7 @@ def _nearest_neighbor_antimeridian(centroids, coordinates, threshold, assigned):
15491549
if np.any(cent_strip_bool):
15501550
cent_strip = centroids[cent_strip_bool]
15511551
strip_assigned = _nearest_neighbor_haversine(
1552-
cent_strip, coord_strip, threshold
1552+
cent_strip, coord_strip, "degree", threshold
15531553
)
15541554
new_coords = cent_strip_bool.nonzero()[0][strip_assigned]
15551555
new_coords[strip_assigned == -1] = -1

0 commit comments

Comments
 (0)