Getting latest images and changing image directories