## Bsoft program

# bflood

### Usage: bflood [options] input.img/input.star [output.img]

Segments images using the watershed or flooding algorithm.
Note: -series, -peaks and -threshold are mutually exclusive.

### Actions:

-invert | Invert density in the image before other operations.
-series 1.3,4.7,0.05 | Segment through a series of thresholds: start,finish,increment.
-peaks 12,0.65,1,1 | Find peaks within a kernel of a given size, above a threshold,
| with optional flooding to the threshold and wrapping.
-threshold 3.4,0.6,-0.03 | Segment by flooding from a high to a low threshold,
| with a given increment (default increment = (high - low)/100).
-addmodel | Add input model components as additional regions (use with -threshold).
-list | List regions or regions (use with -threshold).
-color | Generate a color image based on region size.

### Parameters:

-verbose 7 | Verbose output.
-datatype u | Force writing of a new data type.
-fill | Fill in borders between regions or regions.
-multilevel | Flag for multi-level output for extracted segments.

### Input:

-Map map.pif | Replacement for the map specified in the model file.
-Mask mask.tif | Mask for flooding (use with -threshold, must be integer and same size as input image).
-Model mod.star | Seed model for flooding (use with -threshold).

### Output:

-Extract mask.pif | Extract regions marked by the model (see flag for multi-level).
-Region region.pif | Base name to generate numbered output file names.
-Postscript his.ps | Output plot file of level size histogram.

Bsoft version 2.0.3-20180917 (64 bit)