...
Section |
---|
Column |
---|
| ![](/download/thumbnails/197691117/REGRID.png?version=2&modificationDate=1602666625294&api=v2)
|
Column |
---|
This icon takes data from a GRIB source and performs a variety of operations on it, including spectral to grid conversion, regridding using a large variety of powerful and flexible interpolation techniques, nabla operators and special consideration of wind fields. From Metview version 5.12.0, it can also take certain CF-compliant NetCDF files as input, but it will produce GRIB as output (note that metadata such as parameter names will not be preserved). This module is designed with re-use in mind. The first time a particular interpolation is performed, it might take some time to compute, but it will create cache files that can be re-used, meaning that the same interpolation will be much faster on subsequent runs. The macro/python language equivalent is regrid() . |
|
Table of Contents
Input definition
Warning |
---|
NOTE: in the 5.10 releases, the Regrid module is considered to be a beta release, meaning that we may make small changes to the interface in upcoming releases; we welcome feedback. |
|
|
Table of Contents
Table of Contents |
---|
maxLevel | 1 |
---|
exclude | Table of Contents |
---|
|
Input definition
...
Input data may be specified either by giving a path in the Input data may be specified either by giving a path in the Source parameter or by giving a GRIB-based data object in the Data parameter. Note that you should specify either Source or Data, not both.
...
| |
Code Block |
---|
| regrid_lambert_conformal = mv.regrid(
grid_definition_mode = "lambert_conformal",
first_point = [50.88,-1.66],
dx_in_metres = 2500,
dy_in_metres = 2500,
nx = 739,
ny = 949,
lad_in_degrees = 63,
lov_in_degrees = 15,
data = t_2m_rgg
) |
|
Image Removed Image Added
| |
Code Block |
---|
regrid_laea = mv.regrid(
grid_definition_mode = "lambert_azimuthal_equal_area",
first_point = [66.982143,-35.034024],
dx_in_metres = 5000,
dy_in_metres = 5000,
nx = 1000,
ny = 950,
standard_parallel_in_degrees = 52,
central_longitude_in_degrees = 10,
data = t_2m_rgg
) |
|
...
- Finite Element-based interpolation with linear base functions
- Linear: FEM with supporting triangular mesh
- Bilinear: FEM with supporting quadrilateral mesh (for reduced grids, possibly containing triangles instead of highly-distorted quadrilaterals)
- Grid box method (based on Model grid box and time step)
- Grid Box Average: input/output grid box intersections interpolation preserving input value integrals (conservative interpolation)
- Grid Box MaximumStatistics: input/output grid box intersections value maximumstatistics - see parameter Interpolation Statistics for possible computations
- K-nearest neighbours based:
- K-Nearest Neighbours: general method combining nearest method (choice of neighbours) and distance weighting (choice of interpolating neighbour values)
- Nearest Neighbour: parametrised version of K-Nearest Neighbours to chose a nearest neighbouring input point to define output point value
- Nearest LSM: interpolated output point takes input only from input points of the same type (land or sea — requires setting land/sea masks)
- Structured methods, exploiting grid structure and configurable stencil for fast interpolations (non cacheable, so do not benefit from speedups on subsequent runs)
- Structured Bilinear: bilinear interpolation
- Structured Bicubic: bicubic interpolation
- Structured Biquasicubic: computationally economic bicubic interpolation
- Automatic: see above.
...
Associated options supporting Nearest Method Grid Box Statistics (described above):
- Distance: in [m] choice of closest points by distance to input point
- Distance Tolerance: in [m] tolerance checking the farthest from nearest points (when Nearest Method is Nclosest or nearest)
- Nclosest: choice of n-closest input points to input point
Interpolation Statistics
Associated options supporting Nearest Method (described above). Possible values are:
- count
- count_above_upper_limit
- count_below_lower_limit
- maximum
- minimum
- mode_real
- mode_integral
- mode_boolean
- median_integral
- median_boolean
- mean
- variance
- skewness
- kurtosis
- stddev
- automatic
Distance Weighting
Only available if Interpolation is K Nearest Neighbours. General way on how to interpolate input neighbouring point values to output points, including the Inverse Distance Weighting (IDW) class methods (see Wikipedia), which operates over input points returned by Nearest Method. Possible values are:
...