Skip to content

Segmentation tool not working in QGIS Processing

When trying to use Segmentation tool, with default algorithm parameters (Mean-Shift, but also with Watershed and Morphological Profiles), it fails asking for Condition parameter

Wrong or missing parameter value: Condition

Condition is only required for Connected Components, so it should't be a required parameter.

When using Connected Components, and after define the Condition Expression, and selecting Processing Mode to vector output, it fails with

raster.out.tif files are not supported as outputs for this algorithm

This seems to happen because all options/parameters are used for all Segmentation algorithms, Processing Modes, etc.

So, a workaround could be to split the Segmentation tool in several tools, each one corresponding to a Segmentation algorithm, to prevent the parameters of each algorithm interfere with the others.