gtaylor / python-colormath

A python module that abstracts common color math operations. For example, converting from CIE L*a*b to XYZ, or from RGB to CMYK
python-colormath.readthedocs.org
BSD 3-Clause "New" or "Revised" License
456 stars 83 forks source link

delta_e_cie2000 give me a wrong answer #88

Closed huskykurt closed 6 years ago

huskykurt commented 6 years ago

c1 = LabColor(76.3579, -74.6209, 72.3887) c2 = LabColor(58.4946, 93.7608, -44.7122) d = delta_e_cie2000(c1, c2) print(d)

d = 104.360757933

I checked with a online calculator and it says the answer is 84.5747

Tested in colormath version 3.0.0

KelSolaar commented 6 years ago

Colour yields the same result (104.36075793251435) and the code is tested against Sharma (2004) dataset.

huskykurt commented 6 years ago

This java library also yields the same result (104.3607579). Do you know why this happens? Is the online calculator wrong? (I took a look the formula it is using and could not find any difference with yours)

KelSolaar commented 6 years ago

No sorry @rkmwiaim !

huskykurt commented 6 years ago

Anyway, thanks for your quick reply!