Skip to content

Commit

Permalink
moved back reduce_spatial
Browse files Browse the repository at this point in the history
  • Loading branch information
clausmichele committed Jun 25, 2024
1 parent 9517043 commit 9a2ac2c
Showing 1 changed file with 88 additions and 0 deletions.
88 changes: 88 additions & 0 deletions proposals/reduce_spatial.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
{
"id": "reduce_spatial",
"summary": "Reduce spatial dimensions 'x' and 'y'",
"description": "Applies a reducer to a data cube by collapsing all the pixel values along the horizontal spatial dimensions (i.e. axes `x` and `y`) into an output value computed by the reducer. The horizontal spatial dimensions are dropped.\n\nAn aggregation over certain spatial areas can be computed with the process ``aggregate_spatial()``.\n\nThis process passes a list of values to the reducer. The list of values has an undefined order, therefore processes such as ``last()`` and ``first()`` that depend on the order of the values will lead to unpredictable results.",
"categories": [
"aggregate",
"cubes",
"reducer"
],
"experimental": true,
"parameters": [
{
"name": "data",
"description": "A raster data cube.",
"schema": {
"type": "object",
"subtype": "datacube",
"dimensions": [
{
"type": "spatial",
"axis": [
"x",
"y"
]
}
]
}
},
{
"name": "reducer",
"description": "A reducer to apply on the horizontal spatial dimensions. A reducer is a single process such as ``mean()`` or a set of processes, which computes a single value for a list of values, see the category 'reducer' for such processes.",
"schema": {
"type": "object",
"subtype": "process-graph",
"parameters": [
{
"name": "data",
"description": "An array with elements of any type.",
"schema": {
"type": "array",
"items": {
"description": "Any data type."
}
}
},
{
"name": "context",
"description": "Additional data passed by the user.",
"schema": {
"description": "Any data type."
},
"optional": true,
"default": null
}
],
"returns": {
"description": "The value to be set in the new data cube.",
"schema": {
"description": "Any data type."
}
}
}
},
{
"name": "context",
"description": "Additional data to be passed to the reducer.",
"schema": {
"description": "Any data type."
},
"optional": true,
"default": null
}
],
"returns": {
"description": "A data cube with the newly computed values. It is missing the horizontal spatial dimensions, the number of dimensions decreases by two. The dimension properties (name, type, labels, reference system and resolution) for all other dimensions remain unchanged.",
"schema": {
"type": "object",
"subtype": "datacube"
}
},
"links": [
{
"href": "https://openeo.org/documentation/1.0/datacubes.html#reduce",
"rel": "about",
"title": "Reducers explained in the openEO documentation"
}
]
}

0 comments on commit 9a2ac2c

Please sign in to comment.