Interpolation from hazard to exposure layers.
Provides interpolation functionality to assign values from one layer instance to another irrespective of layer types.
Assign hazard values to exposure data.
This is the high level wrapper around interpolation functions for different combinations of data types.
Parameters: |
|
---|---|
Returns: | Layer representing the exposure data with hazard levels assigned. |
Raises: | Underlying exceptions are propagated |
Admissible combinations of input layer types are:
Exposure Raster Polygon Line Point Hazard Polygon Y Y Y Y Raster Y Y Y Y
with the following methodologies used:
- Polygon-Point: Clip points to polygon and assign polygon attributes
- to them.
Polygon-Line: * Not Implemented *
Polygon-Polygon: * Not Implemented *
- Polygon-Raster: Convert raster to points, clip to polygon,
- assign values and return point data
- Raster-Point: Bilinear (or constant) interpolation as currently
- implemented
Raster-Line: * Not Implemented *
Raster-Polygon: Calculate centroids and use Raster - Point algorithm
Raster-Raster: Exposure raster is returned as is
The data type of the resulting layer depends on the combination of input types as follows:
Polygon-Point: Point data
Polygon-Line: N/A
Polygon-Polygon: N/A
Polygon-Raster: Point data
Raster-Point: Point data
Raster-Line: N/A
Raster-Polygon: Polygon data
Raster-Raster: Raster data
Check inputs and establish default values
Interpolate from polygon vector layer to line vector data
source: Vector data set (polygon)
target: Vector data set (lines)
If None the name of target is used for the returned layer.
Attributes are combined from polygon they fall into and line that was clipped.
Lines not in any polygon are ignored.
Interpolate from polygon vector layer to point vector data
source: Vector data set (polygon)
target: Vector data set (points)
If None the name of target is used for the returned layer.
Interpolate from polygon layer to raster data.
Parameters: |
|
---|---|
Returns: | Tuple of Vector (points located as target with values interpolated from source) and Raster (raster data that are coincide with the source) |
Return type: | Vector |
Interpolate from polygon vector layer to vector data
source: Vector data set (polygon)
target: Vector data set (points or polygons) - TBA also lines
If None the name of target is used for the returned layer.
Check for alignment and returns target layer as is
Interpolate from raster layer to vector data
source: Raster data set (grid)
target: Vector data set (points or polygons)
If None the name of V is used for the returned layer.
If None (default) the name of R is used
Note: If target geometry is polygon, data will be interpolated to its centroids and the output is a point data set.
Interpolate from raster layer to point data
source: Raster data set (grid)
target: Vector data set (points)
If None the name of target is used for the returned layer.
If None (default) the name of layer source is used
from grid to points should be bilinear or piecewise constant
Tag polygons by raster values