Color Difference calculation in iQ-Analyzer, Imatest

Allen Tsou
4 min readJun 22, 2023

--

A study of ΔE, ΔC standard and programing implementation.

1. Color Differences

We consider color differences in Lab color space, because Lab tends to describe color value linearly as human eyes perceived colors.

1.1 Basic color data collection
There are two ways for our device to get color value, RGB or wavelength.
For device like camera, we get RGB values after calculate with color filter.
Other device, for example, spectrometer can get wavelength to tristimulus XYZ data.

1.2 Lab Color space
We describe Lab meaning CIE1976 L* a* b* color space. L states for luminance, a* is color on the green-red scale, and b* is color on the blue-yellow scale.

L* = 50 Lab space demo

Transforming any kinds of color space to anther color space, we need to adapt OETF to linearize color data first. Then turn linearize data to XYZ space that using the reference white point of the source color space (ex: most sRGB using D65). After we get XYZ, then we consider the target color space white point. If the target white point is different from the source white point, we need to do the Chroma Apaption (ex: Bradford Transform), so turn source XYZ to target XYZ. After that, we convert target XYZ to the target color space.

For iQ Analyzer, sRGB Chroma Adaption to D50 XYZ by Bradford transform data. But for Imatest, they only transform sRGB to D65 reference whitepoint XYZ. The reason why Imatest not apply Chroma Adaption is questionable. So the overall workflow for iQ and imatest are:
a. IQ-Analyzer: sRGB ➝ D65 XYZ ➝ D50 XYZ (Bradford transform)➝Lab
b. Imatest: sRGB ➝ D65 XYZ ➝ Lab

Personally, I considered IQ-Analyzer is more accurate, since Lab reference white point is D50 and we calculate ΔE, ΔC with Lab reference data.

2. Delta E

The most common way we calculate color difference, there are different versions formula by year and by material texture. Both iQ Analyzer and imatest follow these formulas.
In the begining, we simply calculate CIE 1976 ΔE with Euclidean distance.

After 1994, we combined a*, b* to C (chroma) and H(Hue).

3. Delta C

To ignore exposure errors for checking color errors independently, we adapt this Chroma difference. There are different formulas by definition and by years.
But notice that it didn’t fully remove the effect of exposure since a, b still affected by exposure.

3.1 Imatest
Imatest can choose different standards, or view all formula by running multitest color checker.

3.2 iQ Analyzer
In iQ, ΔC is not same as definition, iQ only consider Chroma difference. They only keep ΔC item from ΔE formulas, means they also ignore the Hue difference. Then assign positive and negative by C sample is larger than C reference or not.

4. Accurate Process

In conclusion, both IQ-Analyzer and Imatest have calculation that doesn’t make sense. I sum up the process that is more accurate for calculating Color difference.

4.1 Workflow:
sRGB ➝ D50 XYZ ➝ D65 XYZ (Bradford transform)➝Lab➝ ΔE, ΔC

4.2 Formulas:

5. Color Difference Calculator

I have create an GUI program to execute these color space transformation and ΔE, ΔC calculation for demo. Welcome to check my GitHub.
LUN000/ColorCalculator: Package exe of color space transformation, ΔE and ΔC claculator. (github.com)

6. Reference

  1. https://www.imatest.com/docs/colorcheck_ref/#colorerr
  2. Color space transformation math: http://www.brucelindbloom.com/
  3. ICC How to interpret the sRGB color space (specified in IEC 61966–2–1) for ICC profile:
    https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=&ved=2ahUKEwif8Pqr9-D_AhWE4GEKHaNICCIQFnoECBMQAQ&url=https%3A%2F%2Fwww.color.org%2Fsrgb.pdf&usg=AOvVaw0PApwL7eU6dc-hpbjMZ-et&opi=89978449
  4. iQ Color formula: https://wiki.image-engineering.de/doku.php?id=en:iq-analyzerx:product_manual#color
  5. iQ ColorChecker data: https://www.image-engineering.de/products/charts/sort-by-category/color
  6. Imatest ColorChekcer reference table: https://www.imatest.com/docs/colorcheck
  7. The CIEDE2000 color-difference formula: Implementation notes, supplementary test data, and mathematical observations (rochester.edu)

7. Note

For notification, Imatest Colorchecker Classic reference data apply 1.2.b for RGB to Lab, except no.18.

--

--

Allen Tsou
0 Followers

Color Science, Image Processing, Machine Learning and Deep Learning. https://www.linkedin.com/in/lun0000/