Functions dealing with the perceptual hashing of images