wradlib.ipol.Nearest.__call__

Nearest.__call__(vals, maxdist=None)

Evaluate interpolator for values given at the source points.

You can interpolate multiple datasets of source values (vals) at once: the vals array should have the shape (number of source points, number of source datasets). If you want to interpolate only one set of source values, vals can have the shape (number of source points, 1) or just (number of source points,) - which is a flat/1-D array. The output will have the same number of dimensions as vals, i.e. it will be a flat 1-D array in case vals is a 1-D array.

Parameters
  • vals (numpy.ndarray) – ndarray of float, shape (numsourcepoints, …) Values at the source points which to interpolate

  • maxdist (float) – the maximum distance up to which an interpolated values is assigned - if maxdist is exceeded, np.nan will be assigned If maxdist==None, values will be assigned everywhere

Returns

output (numpy.ndarray) – ndarray of float with shape (numtargetpoints,…)