Skip to content

Commit

Permalink
Fix for failing Dask-test: Use second dimension of 2d-regrid array fo…
Browse files Browse the repository at this point in the history
…r defining blocks of extra dimension(s), use .shape for the topology dimension.
  • Loading branch information
HendrikKok committed Jul 20, 2023
1 parent 1fa665f commit eb987cb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xugrid/regrid/regridder.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ def _regrid_array(self, source):
# in a single contiguous chunk.
contiguous_chunks = (source.chunks[0], (source.shape[-1],))
source = source.rechunk(contiguous_chunks)
chunks = source.chunks[: -source_grid.ndim] + (self._target.shape)
chunks = source.chunks[:-1] + (self._target.size,)
out = dask.array.map_blocks(
self._regrid, # func
source, # *args
Expand Down

0 comments on commit eb987cb

Please sign in to comment.