Skip to content

Commit 9ce4106

Browse files
author
Chahan Kropf
committed
Revert "Check that lon normalize values are actually proper longitudes"
This reverts commit 86bb4f5.
1 parent 86bb4f5 commit 9ce4106

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

climada/hazard/test/test_tc_tracks.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -967,9 +967,9 @@ def test_interp_track_pass(self):
967967
def test_interp_track_lonnorm_pass(self):
968968
"""Interpolate track with non-normalized longitude to min_time_step."""
969969
tc_track = tc.TCTracks.from_processed_ibtracs_csv(TEST_TRACK)
970-
tc_track.data[0]["lon"].values[1] += 180
970+
tc_track.data[0]["lon"].values[1] += 360
971971
tc_track.equal_timestep(time_step_h=1)
972-
np.testing.assert_array_less(tc_track.data[0]["lon"].values, 180)
972+
np.testing.assert_array_less(tc_track.data[0]["lon"].values, 0)
973973

974974
def test_interp_track_redundancy_pass(self):
975975
"""Interpolate tracks that are already interpolated."""

climada/util/coordinates.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -232,8 +232,6 @@ def lon_normalize(lon, center=0.0):
232232
Normalized longitudinal coordinates. Since the input `lon` is modified in place (!), the
233233
returned array is the same Python object (instead of a copy).
234234
"""
235-
if len(lon) > 0:
236-
check_if_geo_coords([0], lon)
237235
if center is None:
238236
center = 0.5 * sum(lon_bounds(lon))
239237
bounds = (center - 180, center + 180)

0 commit comments

Comments
 (0)