Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not perceptually uniform? #16

Open
endolith opened this issue Aug 12, 2018 · 5 comments
Open

Not perceptually uniform? #16

endolith opened this issue Aug 12, 2018 · 5 comments

Comments

@endolith
Copy link
Owner

endolith commented Aug 12, 2018

Instead of JCh, it looks like this should be constructed in CAM02-UCS space (expressed in cylindrical coordinates) which has a different lightness curve and chroma(/colorfulness?) curve.

matplotlib/matplotlib#6033 (comment) and matplotlib/matplotlib#6033 (comment)

("the new uniform colour spaces based on CIECAM02 by Luo et al. (CAM02-UCS, CAM02-SCD and CAM02-LCD)", so CIECAM02 itself is not a uniform color space)

and even after fixing that, it might still not be technically correct to call it "perceptually uniform", but I think "perceptually uniform in lightness and hue" would be correct.

@endolith
Copy link
Owner Author

endolith commented Aug 16, 2018

@njsmith Is it correct to say that colorspacious.cspace_converter("sRGB1", "CAM02-UCS") returns J′a′b′ triples, and that when I convert them to cylindrical coordinates they become J′M′h?

Mʹ = np.sqrt(aʹ**2 + bʹ**2)
h = np.degrees(np.arctan2(bʹ, aʹ))

aʹ = Mʹ * np.cos(np.radians(h))
bʹ = Mʹ * np.sin(np.radians(h))

Kruse 2018:

kruse 2018 quote

Masaoka 2013:

masaoka 2013

So then my colormap will be linear J′ ("lightness") vs linear h ("hue"), while maximizing M′ ("colorfulness") (in various ways).

@njsmith
Copy link

njsmith commented Aug 17, 2018

Is it correct to say that colorspacious.cspace_converter("sRGB1", "CAM02-UCS") returns J′a′b′ triples, and that when I convert them to cylindrical coordinates they become J′M′h?

Yes. The J′a′b′ and J′M′h terminology isn't quite standard, but I know what you mean and what you mean is correct :-).

@endolith
Copy link
Owner Author

@njsmith Is there a more standard terminology?

@njsmith
Copy link

njsmith commented Aug 17, 2018

Not really :-/. The Luo et al paper uses more cumbersome terminology where J′ refers to an intermediate value instead of the final result, just to make everyone's life difficult. What colorspacious call J′ matches what Luo et al call "J′ / K_L". (Though for CAM02-UCS specifically, K_L is 1, so these are the same again...)

I would ignore all this and just use J′, but since you were asking about the terminology specifically I wanted to give you a heads up that others could possibly get confused.

@endolith
Copy link
Owner Author

@njsmith Ok, thanks,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants