wradlib.ipol.RectGrid#
- class wradlib.ipol.RectGrid(src, trg, method='linear')[source]#
Interpolation on a 2d grid in arbitrary dimensions.
The source data must be defined on a regular grid, the grid spacing however may be uneven. Linear, nearest-neighbour and spline interpolation are supported.
Based on
scipy.interpolate.interpn
, uses: - nearestscipy.interpolate.RegularGridInterpolator
- linearscipy.interpolate.RegularGridInterpolator
- splinef2dscipy.interpolate.RectBivariateSpline
- Parameters:
src (
numpy.ndarray
) – 3d array of shape (…, 2) The points defining the regular grid in n dimensions.trg (
numpy.ndarray
) – Array of shape (…, ndim) The coordinates to sample the gridded data at
- Keyword Arguments:
method (
str
) – Method of interpolation used, defaults to ‘linear’.
Methods
__init__
(src, trg[, method])Attributes
grid
image
ipol_grid
ipol_points
is_grid
points
upper
xdim
ydim