Skip to content

Commit

Permalink
Apply code formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
BSchilperoort committed Sep 2, 2024
1 parent 68b166f commit 1d1c62f
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions src/xarray_regrid/methods/conservative.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ def conservative_regrid(
latitude_coord: str | None,
skipna: bool = True,
nan_threshold: float = 1.0,
) -> xr.DataArray:
...
) -> xr.DataArray: ...


@overload
Expand All @@ -27,8 +26,7 @@ def conservative_regrid(
latitude_coord: str | None,
skipna: bool = True,
nan_threshold: float = 1.0,
) -> xr.Dataset:
...
) -> xr.Dataset: ...


def conservative_regrid(
Expand Down Expand Up @@ -216,9 +214,7 @@ def apply_weights(

else:
# Update the valid points on this dimension
valid_frac = xr.dot(
valid_frac, weights, dim=coord_name, optimize=True
)
valid_frac = xr.dot(valid_frac, weights, dim=coord_name, optimize=True)
valid_frac = valid_frac.rename(coord_map) # type: ignore
valid_frac = valid_frac.clip(0, 1)

Expand Down

0 comments on commit 1d1c62f

Please sign in to comment.