Skip to content

Commit

Permalink
NamedTuple fix
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenworsley committed Nov 19, 2024
1 parent e33555e commit 4a56d2c
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions esmf_regrid/schemes.py
Original file line number Diff line number Diff line change
Expand Up @@ -472,9 +472,16 @@ def copy_coords(src_coords, add_method):
return new_cube


RegridInfo = NamedTuple("RegridInfo", ["dims", "target", "regridder"])
GridRecord = NamedTuple("GridRecord", ["grid_x", "grid_y"])
MeshRecord = NamedTuple("MeshRecord", ["mesh", "location"])
class RegridInfo(NamedTuple):
dims: int
target: any
regridder: any
class GridRecord(NamedTuple):
grid_x: any
grid_y: any
class MeshRecord(NamedTuple):
mesh: any
location: str


def _make_gridinfo(cube, method, resolution, mask):
Expand Down

0 comments on commit 4a56d2c

Please sign in to comment.