Skip to content

Commit 2f6bb5e

Browse files
luseverinchahank
andauthored
Remove mention to calling functions in error message in _nearest_neighbor_haversine
Co-authored-by: Chahan M. Kropf <chahan.kropf@usys.ethz.ch>
1 parent a260848 commit 2f6bb5e

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

climada/util/coordinates.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1386,10 +1386,8 @@ def _nearest_neighbor_haversine(centroids, coordinates, unit, threshold):
13861386
# first check that unit is in degree
13871387
if unit != "degree":
13881388
raise ValueError(
1389-
"Only degree unit is supported for nearest neighbor matching using"
1390-
"'haversine' distance. Please use euclidean distance by setting "
1391-
"'distance=euclidean' in the match_coordinates or match_centroids "
1392-
"function when using units that are not degrees."
1389+
"Only coordinates in degree units are supported for nearest neighbor matching using"
1390+
"'haversine' distance."
13931391
)
13941392
# Construct tree from centroids
13951393
tree = BallTree(np.radians(centroids), metric="haversine")

0 commit comments

Comments
 (0)