CIEDE2000 color difference

I’ve implemented the CIEDE2000 color difference operator in G’MIC, which is able to compute a perceptual difference between colors. It is based on some complicated formula involving the color channels in Lab (see Wikipedia page about CIEDE2000).
It’s apparently better than just using the eucidean distance in Lab.

There are two ways of using it :

  1. With the command ciede2000 :
$ gmic h ciede2000

  gmic: GREYC's Magic for Image Computing. 
        (https://gmic.eu) 
 
        Version 2.8.0 (pre-release #191114) 
        Copyright (c) 2008-2019, David Tschumperle / GREYC Lab / CNRS. 
        (https://www.greyc.fr)

    ciede2000:

      Compute images of CIEDE2000 color difference between all selected images, assumed to be in Lab 
        color space.
      This function returns N*(N-1)/2 images, where N is the number of images in the selection.
      
      Example: [#1]  image.jpg +blur 2 srgb2lab ciede2000
  1. Or, if you want to use it in as a function in some math expression, there is function ciede2000() in math_lib :
foo : 
   f ${-math_lib}" ciede2000(I,I+2)"  # <- This is useless but shows how it can be used 

Next week, I’m planning to do some experiments to introduce this perceptual error as a criterion for my CLUT compression, with the hope it will become more perceptually aware :slight_smile:

4 Likes

great, thanks for implementing.

i’m not a big fan of this distance computation, however. the reason being

  1. man invents a “perceptually uniform” colour space, Lab, with the one property that taking the euclidean distances in this space corresponds to perceptual differences. as it turns out this isn’t the case. in the following, instead of fixing the colour space, man invents new difference computation schemes in this space (DE2000 etc). seems broken.

  2. the DE2000 distance computation is discontinuous (https://www.researchgate.net/publication/221501912_Mathematical_Discontinuities_in_CIEDE2000_Color_Difference_Computations) sorry for stupid link can’t find a better one now.

the second item may not matter for small differences, but may well cause any optimisation scheme to be confused in the process. i’d go for the simpler and smooth (and not any more or less broken) DE76.

I’m planning to do the test with DE2000 and DE76 indeed, and compare them to what I obtained with the MSE in sRGB I used before.

1 Like

Wonder whether this is relevant.

Slides:

Paper:

1 Like

I don’t know what I might use this for, but have a upvote anyway for the new command/function.