As of IM 6.8.9.1, Imagemagick will include the mean shift technique for noise removal and color reduction/segmentation

The mean shift algorithm is iterative and thus slower the larger the window size. For each pixel, it gets all the pixels in the window centered at the pixel and excludes those that are outside the squared radius=(width-1)(height-1)/4 surrounding the pixel. From those pixels, it finds which of them are within the specified squared color distance from the current mean. It then computes a new x,y centroid from those coordinates and a new mean. This new x,y centroid is used as the center for a new window. This process is iterated until it converges and the final mean is then used to replace the original pixel value. It repeats this process for the next pixel, etc, until it processes all pixels in the image. Results are better when using other colorspaces rather than RGB. Recommend YIQ, YUV or YCbCr, which seem to give equivalent results.

Gosh! Canny, Hough and now mean-shift. IM goes from strength to strength.

I don't quite understand:

fmw42 wrote:From those pixels, it then computes the new mean color (for each channel) and the new center x,y from those pixels that are within the specified color distance from the (center) pixel. This process is iterated ...

Perhaps this means (correct me if I'm wrong):

From those pixels, it then computes the new mean color (for each channel). It finds which of those pixels are within the specified color distance from this mean, and computes the center (centroid?) of those. This new x,y is used as the center of a new window. This process is iterated ...