add functions to select key images from a cluster of images.