WYSIWYG

http://kufli.blogspot.com
http://github.com/karthik20522

Thursday, April 24, 2014

Image Ranking by global feature estimation

Having an automated image ranking process would be very beneficial to companies such as 500px or Gettyimages where 1000's of images are ingested/uploaded every day and are traditionally ranked manually by an editor or by crowdsourcing. This human intervention can be temporarily avoided if images can be ranked by estimating it's quality.

To build an image quality estimator, following image quality properties were used for this proof-of-concept:
  • Blur Estimation:
       Basically, this technique estimates the proportion of blurred pixels. Results are in the range 0-1. A higher number implies a sharper image.
    Example code: Blur-detection
  • Sharpness:
       Sharpness measures the clarity and level of detail of an image.
    Example code: Estimation-of-Image-Sharpness
  • Colorfulness:
       Though there is no real way to estimate the colorfulness of an image but there are various algorithms to measure the quality of image based on compression. One such algorithm is from Hasler and Susstruck's colorfulness metrics. Paper
  • Naturalness:
       Naturalness is basically a single valued summary of how natural the colours in an image are. One such algorithm is Color Naturalness index (CNI) defined by Huang, Qiao & Wu. Paper
  • Image Contrast:
       Estimating the contrast of an image.
  • Colour Contrast:
       This is basically weighted average of the average colour difference of all the segments in the image.
  • Brightness:
       Extract the average brightness of an image.
In this following examples, I have 3 ranks. Rank 1 = Good quality, Rank 2 = Medium and Rank 3 = Bad Quality images. Following is a snippet of my rank calculation.
Image Rank 1 Examples
"blur":0.9660969387755102
"sharpness":0.5067756918923018
"color":0.1462474560577043
"quality":0.8798513615119794
"contrast":0.08234799394638759
"colorContrast":8.328080618896797
"brightness":0.14739056340426107
"blur":0.966530612244898
"sharpness":0.49986904977578045
"color":0.19059606130699966
"quality":0.8476687344507642
"contrast":0.08834899629937157
"colorContrast":25.384664271394108
"brightness":0.24995158193079098
"blur":0.7220025510204081
"sharpness":0.15089643141301262
"color":0.4003952223119604
"quality":0.9609951671164367
"contrast":0.2292792429036637
"colorContrast":32.053295457355276
"brightness":0.4115245849574555
Image Rank 2 Examples
"blur":0.8221428571428572
"sharpness":0.15935783910386503
"color":0.04443692154503701
"quality":0.5085070823398357
"contrast":0.14823618660855284
"colorContrast":26.781796490365295
"brightness":0.27380289202677777
"blur":0.9705484693877551
"sharpness":0.41994123003434913
"color":0.19996393727671855
"quality":0.3153617863913573
"contrast":0.10908353919667178
"colorContrast":43.63807505087183
"brightness":0.18082135350839887
"blur":0.8633290816326531
"sharpness":0.2271008743069167
"color":0.12817043260208896
"quality":0.6680113666484762
"contrast":0.05242860949574584
"colorContrast":44.47249174965709
"brightness":0.222476585047196

From the above results, an simple image ranking system can be automatically performed by estimating the global image features values. More complex algorithms can be used to further improve the image quality estimation process such as Bokeh Estimator which can be used to detect background blur and camera focus[link].
Note: source code to follow soon at my github

Labels: ,