OTB.Segmentation: Performs segmentation of an image, and output either a raster or a vector file. In vector mode, large input datasets are supported.

This application allows one to perform various segmentation algorithms on a multispectral image.Available segmentation algorithms are two different versions of Mean-Shift segmentation algorithm (one being multi-threaded), simple pixel based connected components according to a user-defined criterion, and watershed from the gradient of the intensity (norm of spectral bands vector). The application has two different modes that affects the nature of its output.In raster mode, the output of the application is a classical image of unique labels identifying the segmented regions. The labeled output can be passed to the ColorMapping application to render regions with contrasted colours. Please note that this mode loads the whole input image into memory, and as such can not handle large images. To segment large data, one can use the vector mode. In this case, the output of the application is a vector file or database. The input image is split into tiles (whose size can be set using the tilesize parameter), and each tile is loaded, segmented with the chosen algorithm, vectorized, and written into the output file or database. This piece-wise behavior ensure that memory will never get overloaded, and that images of any size can be processed. There are few more options in the vector mode. The simplify option allows simplifying the geometry (i.e. remove nodes in polygons) according to a user-defined tolerance. The stitch option tries to stitch together the polygons corresponding to segmented region that may have been split by the tiling scheme.

Inputs

The input image to segment

format
href
Please set a value for in.

Choice of segmentation algorithm (mean-shift by default)

string
Please set a value for filter.

Spatial radius of the neighborhood.

integer
Please set a value for filter.meanshift.spatialr.

Range radius defining the radius (expressed in radiometry unit) in the multispectral space.

number
Please set a value for filter.meanshift.ranger.

Algorithm iterative scheme will stop if mean-shift vector is below this threshold or if iteration number reached maximum number of iterations.

number
Please set a value for filter.meanshift.thres.

Algorithm iterative scheme will stop if convergence hasn't been reached after the maximum number of iterations.

integer
Please set a value for filter.meanshift.maxiter.

Minimum size of a region (in pixel unit) in segmentation. Smaller clusters will be merged to the neighboring cluster with the closest radiometry. If set to 0 no pruning is done.

integer
Please set a value for filter.meanshift.minsize.

User defined connection condition, written as a mathematical expression. Available variables are p(i)b(i), intensity_p(i) and distance (example of expression : distance < 10 )

string
Please set a value for filter.cc.expr.

Depth threshold Units in percentage of the maximum depth in the image.

number
Please set a value for filter.watershed.threshold.

flood level for generating the merge tree from the initial segmentation (between 0 and 1)

number
Please set a value for filter.watershed.level.

Size of the profiles

integer
Please set a value for filter.mprofiles.size.

Initial radius of the structuring element (in pixels)

integer
Please set a value for filter.mprofiles.start.

Radius step along the profile (in pixels)

integer
Please set a value for filter.mprofiles.step.

Profiles values under the threshold will be ignored.

number
Please set a value for filter.mprofiles.sigma.

Choice of processing mode, either raster or large-scale.

string
Please set a value for mode.

This allows one to set the writing behaviour for the output vector file. Please note that the actual behaviour depends on the file format.

string
Please set a value for mode.vector.outmode.

Only pixels whose mask value is strictly positive will be segmented.

format
href
Please set a value for mode.vector.inmask.

Activate 8-Neighborhood connectivity (default is 4).

boolean
Please set a value for mode.vector.neighbor.

Scan polygons on each side of tiles and stitch polygons which connect by more than one pixel.

boolean
Please set a value for mode.vector.stitch.

Objects whose size is below the minimum object size (area in pixels) will be ignored during vectorization.

integer

Simplify polygons according to a given tolerance (in pixel). This option allows reducing the size of the output file or database.

number

Name of the layer in the vector file or database (default is Layer).

string
Please set a value for mode.vector.layername.

Name of the field holding the geometry index in the output vector file or database.

string
Please set a value for mode.vector.fieldname.

User defined tiles size for tile-based segmentation. Optimal tile size is selected according to available RAM if null.

integer
Please set a value for mode.vector.tilesize.

Starting value of the geometry index field

integer
Please set a value for mode.vector.startlabel.

A list of layer creation options in the form KEY=VALUE that will be passed directly to OGR without any validity checking. Options may depend on the file format, and can be found in OGR documentation.

string

The output labeled image.

string
Please set a value for mode.raster.out.

Outputs

The output vector file or database (name can be anything understood by OGR)

format
transmission

The output labeled image.

format
transmission

Execution options

successUri
inProgressUri
failedUri

format

mode

Execute End Point

View the execution endpoint of a process.

View the alternative version in HTML.

{"id": "OTB.Segmentation", "title": "Performs segmentation of an image, and output either a raster or a vector file. In vector mode, large input datasets are supported.", "description": "This application allows one to perform various segmentation algorithms on a multispectral image.Available segmentation algorithms are two different versions of Mean-Shift segmentation algorithm (one being multi-threaded), simple pixel based connected components according to a user-defined criterion, and watershed from the gradient of the intensity (norm of spectral bands vector). The application has two different modes that affects the nature of its output.In raster mode, the output of the application is a classical image of unique labels identifying the segmented regions. The labeled output can be passed to the ColorMapping application to render regions with contrasted colours. Please note that this mode loads the whole input image into memory, and as such can not handle large images. To segment large data, one can use the vector mode. In this case, the output of the application is a vector file or database. The input image is split into tiles (whose size can be set using the tilesize parameter), and each tile is loaded, segmented with the chosen algorithm, vectorized, and written into the output file or database. This piece-wise behavior ensure that memory will never get overloaded, and that images of any size can be processed. There are few more options in the vector mode. The simplify option allows simplifying the geometry (i.e. remove nodes in polygons) according to a user-defined tolerance. The stitch option tries to stitch together the polygons corresponding to segmented region that may have been split by the tiling scheme. ", "version": "1.0.0", "jobControlOptions": ["sync-execute", "async-execute", "dismiss"], "outputTransmission": ["value", "reference"], "links": [{"rel": "http://www.opengis.net/def/rel/ogc/1.0/execute", "type": "application/json", "title": "Execute End Point", "href": "http://demo.mapmint.com/ogc-api/processes/OTB.Segmentation/execution"}, {"rel": "alternate", "type": "text/html", "title": "Execute End Point", "href": "http://demo.mapmint.com/ogc-api/processes/OTB.Segmentation/execution.html"}], "inputs": {"in": {"title": "The input image to segment", "description": "The input image to segment", "extended-schema": {"oneOf": [{"allOf": [{"$ref": "http://zoo-project.org/dl/link.json"}, {"type": "object", "properties": {"type": {"enum": ["image/tiff", "image/jpeg", "image/png"]}}}]}, {"type": "object", "required": ["value"], "properties": {"value": {"oneOf": [{"type": "string", "contentEncoding": "base64", "contentMediaType": "image/tiff"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/jpeg"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/png"}]}}}]}, "schema": {"oneOf": [{"type": "string", "contentEncoding": "base64", "contentMediaType": "image/tiff"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/jpeg"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/png"}]}, "id": "in"}, "filter": {"title": "Choice of segmentation algorithm (mean-shift by default)", "description": "Choice of segmentation algorithm (mean-shift by default)", "schema": {"type": "string", "default": "meanshift", "enum": ["meanshift", "cc", "watershed", "mprofiles"]}, "id": "filter"}, "filter.meanshift.spatialr": {"title": "Spatial radius of the neighborhood.", "description": "Spatial radius of the neighborhood.", "schema": {"type": "integer", "default": 5}, "id": "filter.meanshift.spatialr"}, "filter.meanshift.ranger": {"title": "Range radius defining the radius (expressed in radiometry unit) in the multispectral space.", "description": "Range radius defining the radius (expressed in radiometry unit) in the multispectral space.", "schema": {"type": "number", "default": 15, "format": "double"}, "id": "filter.meanshift.ranger"}, "filter.meanshift.thres": {"title": "Algorithm iterative scheme will stop if mean-shift vector is below this threshold or if iteration number reached maximum number of iterations.", "description": "Algorithm iterative scheme will stop if mean-shift vector is below this threshold or if iteration number reached maximum number of iterations.", "schema": {"type": "number", "default": 0.1, "format": "double"}, "id": "filter.meanshift.thres"}, "filter.meanshift.maxiter": {"title": "Algorithm iterative scheme will stop if convergence hasn't been reached after the maximum number of iterations.", "description": "Algorithm iterative scheme will stop if convergence hasn't been reached after the maximum number of iterations.", "schema": {"type": "integer", "default": 100}, "id": "filter.meanshift.maxiter"}, "filter.meanshift.minsize": {"title": "Minimum size of a region (in pixel unit) in segmentation. Smaller clusters will be merged to the neighboring cluster with the closest radiometry. If set to 0 no pruning is done.", "description": "Minimum size of a region (in pixel unit) in segmentation. Smaller clusters will be merged to the neighboring cluster with the closest radiometry. If set to 0 no pruning is done.", "schema": {"type": "integer", "default": 100}, "id": "filter.meanshift.minsize"}, "filter.cc.expr": {"title": "User defined connection condition, written as a mathematical expression. Available variables are p(i)b(i), intensity_p(i) and distance (example of expression : distance < 10 )", "description": "User defined connection condition, written as a mathematical expression. Available variables are p(i)b(i), intensity_p(i) and distance (example of expression : distance < 10 )", "schema": {"type": "string", "default": "Any value"}, "id": "filter.cc.expr"}, "filter.watershed.threshold": {"title": "Depth threshold Units in percentage of the maximum depth in the image.", "description": "Depth threshold Units in percentage of the maximum depth in the image.", "schema": {"type": "number", "default": 0.01, "format": "double"}, "id": "filter.watershed.threshold"}, "filter.watershed.level": {"title": "flood level for generating the merge tree from the initial segmentation (between 0 and 1)", "description": "flood level for generating the merge tree from the initial segmentation (between 0 and 1)", "schema": {"type": "number", "default": 0.1, "format": "double"}, "id": "filter.watershed.level"}, "filter.mprofiles.size": {"title": "Size of the profiles", "description": "Size of the profiles", "schema": {"type": "integer", "default": 5}, "id": "filter.mprofiles.size"}, "filter.mprofiles.start": {"title": "Initial radius of the structuring element (in pixels)", "description": "Initial radius of the structuring element (in pixels)", "schema": {"type": "integer", "default": 1}, "id": "filter.mprofiles.start"}, "filter.mprofiles.step": {"title": "Radius step along the profile (in pixels)", "description": "Radius step along the profile (in pixels)", "schema": {"type": "integer", "default": 1}, "id": "filter.mprofiles.step"}, "filter.mprofiles.sigma": {"title": "Profiles values under the threshold will be ignored.", "description": "Profiles values under the threshold will be ignored.", "schema": {"type": "number", "default": 1, "format": "double"}, "id": "filter.mprofiles.sigma"}, "mode": {"title": "Choice of processing mode, either raster or large-scale.", "description": "Choice of processing mode, either raster or large-scale.", "schema": {"type": "string", "default": "vector", "enum": ["vector", "raster"]}, "id": "mode"}, "mode.vector.outmode": {"title": "This allows one to set the writing behaviour for the output vector file. Please note that the actual behaviour depends on the file format.", "description": "This allows one to set the writing behaviour for the output vector file. Please note that the actual behaviour depends on the file format.", "schema": {"type": "string", "default": "ulco", "enum": ["ulco", "ovw", "ulovw", "ulu"]}, "id": "mode.vector.outmode"}, "mode.vector.inmask": {"title": "Only pixels whose mask value is strictly positive will be segmented.", "description": "Only pixels whose mask value is strictly positive will be segmented.", "extended-schema": {"oneOf": [{"allOf": [{"$ref": "http://zoo-project.org/dl/link.json"}, {"type": "object", "properties": {"type": {"enum": ["image/tiff", "image/jpeg", "image/png"]}}}]}, {"type": "object", "required": ["value"], "properties": {"value": {"oneOf": [{"type": "string", "contentEncoding": "base64", "contentMediaType": "image/tiff"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/jpeg"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/png"}]}}}], "nullable": true}, "schema": {"oneOf": [{"type": "string", "contentEncoding": "base64", "contentMediaType": "image/tiff"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/jpeg"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/png"}]}, "id": "mode.vector.inmask"}, "mode.vector.neighbor": {"title": "Activate 8-Neighborhood connectivity (default is 4).", "description": "Activate 8-Neighborhood connectivity (default is 4).", "schema": {"type": "boolean", "default": false}, "id": "mode.vector.neighbor"}, "mode.vector.stitch": {"title": "Scan polygons on each side of tiles and stitch polygons which connect by more than one pixel.", "description": "Scan polygons on each side of tiles and stitch polygons which connect by more than one pixel.", "schema": {"type": "boolean", "default": false}, "id": "mode.vector.stitch"}, "mode.vector.minsize": {"title": "Objects whose size is below the minimum object size (area in pixels) will be ignored during vectorization.", "description": "Objects whose size is below the minimum object size (area in pixels) will be ignored during vectorization.", "schema": {"type": "integer", "default": 1, "nullable": true}, "id": "mode.vector.minsize"}, "mode.vector.simplify": {"title": "Simplify polygons according to a given tolerance (in pixel). This option allows reducing the size of the output file or database.", "description": "Simplify polygons according to a given tolerance (in pixel). This option allows reducing the size of the output file or database.", "schema": {"type": "number", "default": 0.1, "format": "double", "nullable": true}, "id": "mode.vector.simplify"}, "mode.vector.layername": {"title": "Name of the layer in the vector file or database (default is Layer).", "description": "Name of the layer in the vector file or database (default is Layer).", "schema": {"type": "string", "default": "Any value"}, "id": "mode.vector.layername"}, "mode.vector.fieldname": {"title": "Name of the field holding the geometry index in the output vector file or database.", "description": "Name of the field holding the geometry index in the output vector file or database.", "schema": {"type": "string", "default": "Any value"}, "id": "mode.vector.fieldname"}, "mode.vector.tilesize": {"title": "User defined tiles size for tile-based segmentation. Optimal tile size is selected according to available RAM if null.", "description": "User defined tiles size for tile-based segmentation. Optimal tile size is selected according to available RAM if null.", "schema": {"type": "integer", "default": 1024}, "id": "mode.vector.tilesize"}, "mode.vector.startlabel": {"title": "Starting value of the geometry index field", "description": "Starting value of the geometry index field", "schema": {"type": "integer", "default": 1}, "id": "mode.vector.startlabel"}, "mode.vector.ogroptions": {"title": "A list of layer creation options in the form KEY=VALUE that will be passed directly to OGR without any validity checking. Options may depend on the file format, and can be found in OGR documentation.", "description": "A list of layer creation options in the form KEY=VALUE that will be passed directly to OGR without any validity checking. Options may depend on the file format, and can be found in OGR documentation.", "maxOccurs": 1024, "schema": {"type": "string", "default": "Any value", "nullable": true}, "id": "mode.vector.ogroptions"}, "mode.raster.out": {"title": "The output labeled image.", "description": "The output labeled image.", "schema": {"type": "string", "default": "uint8", "enum": ["uint8", "uint16", "int16", "int32", "int32", "float", "double"]}, "id": "mode.raster.out"}}, "outputs": {"mode.vector.out": {"title": "The output vector file or database (name can be anything understood by OGR)", "description": "The output vector file or database (name can be anything understood by OGR)", "extended-schema": {"oneOf": [{"allOf": [{"$ref": "http://zoo-project.org/dl/link.json"}, {"type": "object", "properties": {"type": {"enum": ["text/xml", "application/vnd.google-earth.kml+xml", "application/json", "application/zip"]}}}]}, {"type": "object", "required": ["value"], "properties": {"value": {"oneOf": [{"type": "string", "contentEncoding": "utf-8", "contentMediaType": "text/xml"}, {"type": "string", "contentEncoding": "utf-8", "contentMediaType": "application/vnd.google-earth.kml+xml"}, {"type": "object"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "application/zip"}]}}}]}, "schema": {"oneOf": [{"type": "string", "contentEncoding": "utf-8", "contentMediaType": "text/xml"}, {"type": "string", "contentEncoding": "utf-8", "contentMediaType": "application/vnd.google-earth.kml+xml"}, {"type": "object"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "application/zip"}]}, "id": "mode.vector.out"}, "mode.raster.out": {"title": "The output labeled image.", "description": "The output labeled image.", "extended-schema": {"oneOf": [{"allOf": [{"$ref": "http://zoo-project.org/dl/link.json"}, {"type": "object", "properties": {"type": {"enum": ["image/tiff", "image/jpeg", "image/png"]}}}]}, {"type": "object", "required": ["value"], "properties": {"value": {"oneOf": [{"type": "string", "contentEncoding": "base64", "contentMediaType": "image/tiff"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/jpeg"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/png"}]}}}]}, "schema": {"oneOf": [{"type": "string", "contentEncoding": "base64", "contentMediaType": "image/tiff"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/jpeg"}, {"type": "string", "contentEncoding": "base64", "contentMediaType": "image/png"}]}, "id": "mode.raster.out"}}}

http://demo.mapmint.com/ogc-apihttp://localhost/ogc-api/processes/OTB.Segmentation.html
Last modified: Sat Feb 19 15:43:34 CET 2022