## Colorspace for easy color difference comparisons

Discuss digital image processing techniques and algorithms. We encourage its application to ImageMagick but you can discuss any software solutions here.
pipe
Posts: 28
Joined: 2013-04-09T08:32:37-07:00
Authentication code: 6789

### Colorspace for easy color difference comparisons

I'm working on a tool that needs to know how "different" or "close" two colors are to each other. This also includes brightness, saturation and such other properties. Ultimately I want to get this down to one single scalar telling me how different these colors are to the average human eye.

In my tool I want to perform this comparison several billion times, so I was thinking of transforming the source colors into a colorspace that would give me this difference directly using the euclidean distance in three dimensions. Most of my calculations only involves questions like is the difference between these two colors larger than the difference between these other two colors? so that the euclidean distance would not even require calculating the square root.

Does anyone know of any open-access papers about this, or if there is a good colorspace for this readily available? If it is not possible to perform such a transform (I actually don't think it is possible), what other methods could be used to compare colors that takes the human vision into consideration?

fmw42
Posts: 26383
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

### Re: Colorspace for easy color difference comparisons

I found these:

http://en.wikipedia.org/wiki/Color_difference and there are many references there, esp. Poynton and Lindbloom

http://www.mi.tj.chiba-u.jp/~tsumura/Ts ... anobis.pdf

http://en.wikipedia.org/wiki/Absolute_color_space

You should really do any metric such as RMS distance in an orthogonal colorspace.

pipe
Posts: 28
Joined: 2013-04-09T08:32:37-07:00
Authentication code: 6789

### Re: Colorspace for easy color difference comparisons

Thank you. I think I was mistaken about the L*a*b* colorspace, which seems to be what I'm looking for. Possibly with the addition of the CIEDE2000 algorithms.

fmw42
Posts: 26383
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

### Re: Colorspace for easy color difference comparisons

I ran across a paper the other day that I believe did color distance in LAB. But when I tried to find it, I could not. Unfortunately, I did not bookmark it or did so in some folder I do not recall.

snibgo
Posts: 13034
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

### Re: Colorspace for easy color difference comparisons

A very thorough site related to this topic: http://www.handprint.com/LS/CVS/color.html
snibgo's IM pages: im.snibgo.com