Skip to content
This repository was archived by the owner on Jun 2, 2025. It is now read-only.

Commit 890d6e0

Browse files
committed
Remove comments
1 parent 6451ed9 commit 890d6e0

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

ocf_datapipes/training/common.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1221,12 +1221,8 @@ def potentially_coarsen(xr_data: xr.Dataset):
12211221
"""Coarsen the data, if it is separated by 0.05 degrees each"""
12221222
if "latitude" in xr_data.coords and "longitude" in xr_data.coords:
12231223
if np.isclose(np.abs(xr_data.latitude.values[1] - xr_data.latitude.values[0]), 0.05):
1224-
# Take every second latitude and longitude point, no interpolation, from the first point, or second,
1225-
# Check if the first point is 0.05 degrees or not, only take ones that are 0.1
1226-
# Check if the first point rounds to the same 0.1 as itself, otherwise take the second point
12271224
if np.isclose(np.round(xr_data.latitude.values[0], 1), xr_data.latitude.values[0]):
12281225
xr_data = xr_data.isel(latitude=slice(0, None, 2), longitude=slice(0, None, 2))
12291226
else:
12301227
xr_data = xr_data.isel(latitude=slice(1, None, 2), longitude=slice(1, None, 2))
1231-
# xr_data = xr_data.coarsen(latitude=2, longitude=2, coord_func="").mean()
12321228
return xr_data

0 commit comments

Comments
 (0)