Every photograph is a cloud of colored dots. Somewhere in that cloud, pixels group naturally: the blue sky clusters together, the green grass forms its own crowd, the red barn stands apart. Segmentation is the task of finding those groups without being told how many there are.
Mean-shift â introduced for image analysis by Dorin Comaniciu and Peter Meer in 2002 â solves segmentation the way a ball rolls downhill in reverse. Instead of falling to a valley, each pixel climbs toward the nearest density peak in color space. Pixels that share the same peak end up in the same segment.
The method needs no preset number of clusters. It estimates the local density at each point using a kernel (typically a Gaussian bell), then shifts each point toward the center of mass of its neighborhood. After enough steps, nearby points converge to the same mode. The result is a posterized image: regions of uniform color, as if the palette had been reduced to its most popular shades.
This is closely related to non-convex optimization: the algorithm climbs a surface riddled with local maxima, and different starting points may reach different peaks. Understanding which peaks it finds â and how many â is the heart of the problem.
Comments
Loading comments...