1. A method for generating a representation of an image comprising: receiving an image for which a representation is to be generated; for each of a plurality of regions of the image, computing a runlength histogram; generating a representation of the image based on the runlength histograms; and outputting the representation of the image.