diff --git a/load_geojson.json b/load_geojson.json new file mode 100644 index 00000000..63f88901 --- /dev/null +++ b/load_geojson.json @@ -0,0 +1,53 @@ +{ + "id": "load_geojson", + "summary": "Converts GeoJSON into a vector data cube", + "description": "Converts GeoJSON data as defined by [RFC 7946](https://www.rfc-editor.org/rfc/rfc7946.html) into a vector data cube. Feature properties are preserved.", + "categories": [ + "import", + "vector" + ], + "experimental": true, + "parameters": [ + { + "name": "data", + "description": "A GeoJSON object to convert into a vector data cube. The GeoJSON type `GeometryCollection` is not supported. Each geometry in the GeoJSON data results in a dimension label in the `geometries` dimension.", + "schema": { + "type": "object", + "subtype": "geojson" + } + }, + { + "name": "properties", + "description": "A list of properties from the GeoJSON file to construct an additional dimension from. A new dimension with the name `properties` and type `other` is created if at least one property is provided. Only applies for GeoJSON Features and FeatureCollections. Missing values are generally set to no-data (`null`).\n\nDepending on the number of properties provided, the process creates the dimension differently:\n\n- Single property with scalar values: A single dimension label with the name of the property and a single value per geometry.\n- Single property of type array: The dimension labels correspond to the array indices. There are as many values and labels per geometry as there are for the largest array.\n- Multiple properties with scalar values: The dimension labels correspond to the property names. There are as many values and labels per geometry as there are properties provided here.", + "schema": { + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + }, + "default": [], + "optional": true + } + ], + "returns": { + "description": "A vector data cube containing the geometries, either one or two dimensional.", + "schema": { + "type": "object", + "subtype": "datacube", + "dimensions": [ + { + "type": "geometry" + } + ] + } + }, + "links": [ + { + "href": "https://www.rfc-editor.org/rfc/rfc7946.html", + "title": "RFC 7946: The GeoJSON Format", + "type": "text/html", + "rel": "about" + } + ] +} \ No newline at end of file diff --git a/missing-processes/resample_spatial.json b/missing-processes/resample_spatial.json deleted file mode 100644 index 91d6bc5f..00000000 --- a/missing-processes/resample_spatial.json +++ /dev/null @@ -1,148 +0,0 @@ -{ - "id": "resample_spatial", - "summary": "Resample and warp the spatial dimensions", - "description": "Resamples the spatial dimensions (x,y) of the data cube to a specified resolution and/or warps the data cube to the target projection. At least `resolution` or `projection` must be specified.\n\nRelated processes:\n\n* Use ``filter_bbox()`` to set the target spatial extent.\n* To spatially align two data cubes with each other (e.g. for merging), better use the process ``resample_cube_spatial()``.", - "categories": [ - "cubes", - "aggregate & resample" - ], - "parameters": [ - { - "name": "data", - "description": "A raster data cube.", - "schema": { - "type": "object", - "subtype": "raster-cube" - } - }, - { - "name": "resolution", - "description": "Resamples the data cube to the target resolution, which can be specified either as separate values for x and y or as a single value for both axes. Specified in the units of the target projection. Doesn't change the resolution by default (`0`).", - "schema": [ - { - "description": "A single number used as the resolution for both x and y.", - "type": "number", - "minimum": 0 - }, - { - "description": "A two-element array to specify separate resolutions for x (first element) and y (second element).", - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "type": "number", - "minimum": 0 - } - } - ], - "default": 0, - "optional": true - }, - { - "name": "projection", - "description": "Warps the data cube to the target projection, specified as as [EPSG code](http://www.epsg-registry.org/), [WKT2 (ISO 19162) string](http://docs.opengeospatial.org/is/18-010r7/18-010r7.html), [PROJ definition (deprecated)](https://proj.org/usage/quickstart.html). By default (`null`), the projection is not changed.", - "schema": [ - { - "title": "EPSG Code", - "type": "integer", - "subtype": "epsg-code", - "minimum": 1000, - "examples": [ - 3857 - ] - }, - { - "title": "WKT2", - "type": "string", - "subtype": "wkt2-definition" - }, - { - "title": "PROJ definition", - "type": "string", - "subtype": "proj-definition", - "deprecated": true - }, - { - "title": "Don't change projection", - "type": "null" - } - ], - "default": null, - "optional": true - }, - { - "name": "method", - "description": "Resampling method to use. The following options are available and are meant to align with [`gdalwarp`](https://gdal.org/programs/gdalwarp.html#cmdoption-gdalwarp-r):\n\n* `average`: average (mean) resampling, computes the weighted average of all valid pixels\n* `bilinear`: bilinear resampling\n* `cubic`: cubic resampling\n* `cubicspline`: cubic spline resampling\n* `lanczos`: Lanczos windowed sinc resampling\n* `max`: maximum resampling, selects the maximum value from all valid pixels\n* `med`: median resampling, selects the median value of all valid pixels\n* `min`: minimum resampling, selects the minimum value from all valid pixels\n* `mode`: mode resampling, selects the value which appears most often of all the sampled points\n* `near`: nearest neighbour resampling (default)\n* `q1`: first quartile resampling, selects the first quartile value of all valid pixels\n* `q3`: third quartile resampling, selects the third quartile value of all valid pixels\n* `rms` root mean square (quadratic mean) of all valid pixels\n* `sum`: compute the weighted sum of all valid pixels\n\nValid pixels are determined based on the function ``is_valid()``.", - "schema": { - "type": "string", - "enum": [ - "average", - "bilinear", - "cubic", - "cubicspline", - "lanczos", - "max", - "med", - "min", - "mode", - "near", - "q1", - "q3", - "rms", - "sum" - ] - }, - "default": "near", - "optional": true - }, - { - "name": "align", - "description": "Specifies to which corner of the spatial extent the new resampled data is aligned to.", - "schema": { - "type": "string", - "enum": [ - "lower-left", - "upper-left", - "lower-right", - "upper-right" - ] - }, - "default": "upper-left", - "optional": true - } - ], - "returns": { - "description": "A raster data cube with values warped onto the new projection. It has the same dimensions and the same dimension properties (name, type, labels, reference system and resolution) for all non-spatial or vertical spatial dimensions. For the horizontal spatial dimensions the name and type remain unchanged, but reference system, labels and resolution may change depending on the given parameters.", - "schema": { - "type": "object", - "subtype": "raster-cube" - } - }, - "links": [ - { - "href": "https://openeo.org/documentation/1.0/datacubes.html#resample", - "rel": "about", - "title": "Resampling explained in the openEO documentation" - }, - { - "rel": "about", - "href": "https://proj.org/usage/projections.html", - "title": "PROJ parameters for cartographic projections" - }, - { - "rel": "about", - "href": "http://www.epsg-registry.org", - "title": "Official EPSG code registry" - }, - { - "rel": "about", - "href": "http://www.epsg.io", - "title": "Unofficial EPSG code database" - }, - { - "href": "https://gdal.org/programs/gdalwarp.html#cmdoption-gdalwarp-r", - "rel": "about", - "title": "gdalwarp resampling methods" - } - ] -} \ No newline at end of file diff --git a/vector_buffer.json b/vector_buffer.json new file mode 100644 index 00000000..5d10bda3 --- /dev/null +++ b/vector_buffer.json @@ -0,0 +1,51 @@ +{ + "id": "vector_buffer", + "summary": "Buffer geometries by distance", + "description": "Buffers each input geometry by a given distance, which can either expand (dilate) or a shrink (erode) the geometry. Buffers can be applied to points, lines and polygons, but the results are always polygons. Empty geometries are passed through and negative buffers may result in empty geometries. Multi-part types (e.g. `MultiPoint`) are also allowed.", + "categories": [ + "vector" + ], + "experimental": true, + "parameters": [ + { + "name": "geometries", + "description": "Geometries to apply the buffer on. Feature properties are preserved.", + "schema": { + "type": "object", + "subtype": "datacube", + "dimensions": [ + { + "type": "geometry" + } + ] + } + }, + { + "name": "distance", + "description": "The distance of the buffer in meters. A positive distance expands the geometries, resulting in outward buffering (dilation), while a negative distance shrinks the geometries, resulting in inward buffering (erosion).\n\nIf the unit of the spatial reference system is not meters, a `UnitMismatch` error is thrown. Use ``vector_reproject()`` to convert the geometries to a suitable spatial reference system.", + "schema": { + "type": "number", + "not": { + "const": 0 + } + } + } + ], + "returns": { + "description": "Returns a vector data cube with the computed new geometries of which some may be empty.", + "schema": { + "type": "object", + "subtype": "datacube", + "dimensions": [ + { + "type": "geometry" + } + ] + } + }, + "exceptions": { + "UnitMismatch": { + "message": "The unit of the spatial reference system is not meters, but the given distance is in meters." + } + } +} \ No newline at end of file diff --git a/vector_reproject.json b/vector_reproject.json new file mode 100644 index 00000000..e808f410 --- /dev/null +++ b/vector_reproject.json @@ -0,0 +1,97 @@ +{ + "id": "vector_reproject", + "summary": "Reprojects the geometry dimension", + "description": "Converts the geometries stored in a geometry dimension to a different coordinate reference system.", + "categories": [ + "cubes", + "reproject", + "vector" + ], + "experimental": true, + "parameters": [ + { + "name": "data", + "description": "A vector data cube.", + "schema": { + "type": "object", + "subtype": "datacube", + "dimensions": [ + { + "type": "geometry" + } + ] + } + }, + { + "name": "projection", + "description": "Coordinate reference system to reproject to. Specified as an [EPSG code](http://www.epsg-registry.org/) or [WKT2 CRS string](http://docs.opengeospatial.org/is/18-010r7/18-010r7.html).", + "schema": [ + { + "title": "EPSG Code", + "type": "integer", + "subtype": "epsg-code", + "minimum": 1000, + "examples": [ + 3857 + ] + }, + { + "title": "WKT2", + "type": "string", + "subtype": "wkt2-definition" + } + ] + }, + { + "name": "dimension", + "description": "The name of the geometry dimension to reproject. If no specific dimension is specified, the filter applies to all geometry dimensions. Fails with a `DimensionNotAvailable` exception if the specified dimension does not exist.", + "schema": { + "type": [ + "string", + "null" + ] + }, + "default": null, + "optional": true + } + ], + "returns": { + "description": "A vector data cube with geometries projected to the new coordinate reference system. The reference system of the geometry dimension changes, all other dimensions and properties remain unchanged.", + "schema": { + "type": "object", + "subtype": "datacube", + "dimensions": [ + { + "type": "geometry" + } + ] + } + }, + "exceptions": { + "DimensionNotAvailable": { + "message": "A dimension with the specified name does not exist." + } + }, + "links": [ + { + "href": "https://openeo.org/documentation/1.0/datacubes.html#resample", + "rel": "about", + "title": "Resampling explained in the openEO documentation" + }, + { + "rel": "about", + "href": "https://proj.org/usage/projections.html", + "title": "PROJ parameters for cartographic projections" + }, + { + "rel": "about", + "href": "http://www.epsg-registry.org", + "title": "Official EPSG code registry" + }, + { + "rel": "about", + "href": "http://www.epsg.io", + "title": "Unofficial EPSG code database" + } + ] +} \ No newline at end of file