Very often, one wants to detect objects or specific regions in images. After connected_components, the image is divided in background and foreground pixels. The next step is a connected components analysis, where spatially connected regions of foreground pixels are assigned as being part of one region.