I have an implementation of the K-Means algorithm in C# that needs some serious performance tuning. The code is pasted in the message below.
There are two classes used Image and DominantColor
Image simply openes up image files and retrieves the RGB/HSV/HSV values while the DominantColor class computes clusters.
Any ideas would be appreciated.