A function that reduces the colors in a picture to a number of randomized, defined, or picture-dependent color palette. Uses the palette of color "centroids" to group pixels in picture, average the color values, and recluster.