xugrid.NetworkGridder#
- class xugrid.NetworkGridder(source: Ugrid1d, target: Ugrid2d, method: str | Callable = 'mean')[source]#
Network gridder for 2D unstructured grids.
- Parameters:
grid (Ugrid1d) – The grid to be used for the regridding.
Methods
__init__
(source, target[, method])from_dataset
(dataset)Reconstruct the regridder from a dataset with source, target indices and weights.
from_weights
(weights, target[, method])regrid
(data)Regrid the data from a DataArray from its old grid topology to the new target topology.
regrid_dataarray
(source, source_dims)to_dataset
()Store the computed weights and target in a dataset for re-use.
weights_as_dataframe
()Return the weights as a three column dataframe:
Attributes
weights