Two uniform spaces disagree about between
Assumes The straight line is not the shortest gradient, A distance raised to a power has no length and A model judged in another model's unit.
The straight line is not the shortest gradient built ΔE₀₀’s own local metric out of six evaluations of the formula, found the shortest path between two colours under it, and reported that the path bows by tens of CIELAB units. It noted at the end that what is coordinate-free about a geodesic is its length, and that the same geodesic expressed in another space is another curve.
There is another space. CAM16-UCS is the other thing in daily use that claims to be uniform — a unit rests on a space that was ranked is how both came to be carried here — and it has its own opinion about which colours lie between two colours.
They disagree, and by more than either disagrees with the naive answer
Both published uniform spaces are used to decide what lies between two colours and they do not agree — on some gradients by more than either differs from the straight line, and on one of those a metric would rather have the straight line than the other’s answer.
- On cyan to magenta the two shortest paths run 15.7 CIELAB units apart, against bows from the straight line of 9.9 and 12.2.
- On red to blue they run 28.3 apart, the largest gap of the six, against bows of 14.4 and 42.5.
- On cyan to magenta ΔE₀₀ measures CAM16-UCS’s path as longer than the straight line — 72.0 against 69.4 — and on red to blue 69.9 against 66.8, so the two do not merely disagree about how far to bow.
- CAM16-UCS’s published difference has no local metric. Taken by finite differences it reads 3.37 units per CIELAB unit at a step of a tenth and 43.46 at a ten-thousandth, rising as the inverse square root of the step.
- The Euclidean distance underneath it does, at 1.0328 at every step, and it is what the geodesics here are found in.
One of them has no local metric
The comparison cannot be made naively, and the obstruction is worth meeting first because it is a result rather than a technicality.
A local metric is what a difference formula has when its answer for a small step is proportional to the step’s length in some direction-dependent way. ΔE₀₀ has one: evaluate it at a thousandth of a unit in each direction and the six numbers assemble into a quadratic form that does not move if the step is changed.
CAM16-UCS’s published colour difference does not. It is 1.41 · d^0.63 with d the Euclidean distance in the uniform space’s own J′a′b′ coordinates, and a power below one has an infinite derivative at zero.
At a step of a tenth of a CIELAB unit the published difference reads 3.37 units per unit; at a hundredth 7.91; at a thousandth 18.54; at a ten-thousandth 43.46. It rises as the inverse square root of the step and has no limit. The Euclidean distance underneath gives 1.0328 at every step.
That is a distance raised to a power has no length arriving as an obstruction rather than as a curiosity. That essay found that a ramp cut into more steps measures longer without end under such a difference; here the same fact stops the local metric existing at all, so there is nothing to find a geodesic in.
The repair is available and is not a compromise. The power is a monotone function of the Euclidean distance, so the two have exactly the same shortest paths and differ only in what those paths’ lengths are called. Every geodesic below is found in the Euclidean space, and the published difference would rank them in the same order.
How far apart the two answers are
With both metrics in hand the comparison is a distance between two curves: how far the furthest point of one is from the nearest point of the other, in CIELAB units.
On cyan to magenta the gap between the two answers is the largest of the three numbers: 15.7 apart against bows of 9.9 and 12.2. On red to blue the gap is larger still, 28.3, and there it is CAM16-UCS’s own bow of 42.5 that is larger — the appearance model moves that gradient three times as far as ΔE₀₀ does. On the other four the two answers are closer to each other than either is to the straight line, by margins from a few tenths of a unit on the greys to twenty on blue to yellow.
On the neutral axis all three are near zero, which is the check that both relaxations are doing their job — the same null a neutral has no grid uses for a different machine: symmetry requires the straight line between black and white, and both find it.
The reading is uncomfortable and it is the point. Two spaces whose whole purpose is to say that equal distances look equally different disagree about which colours are between two colours by more than either differs from the answer they were both meant to improve on. A designer choosing between them is not choosing a refinement; they are choosing a different set of colours.
Each prefers the straight line to the other’s answer
There is a stronger version of the disagreement and it shows up in the lengths rather than in the shapes.
If the two metrics merely bowed the same way by different amounts, each would still rank the other’s path above the straight line: a path that goes part of the way towards a better answer is better than one that does not go at all.
On cyan to magenta it does not. ΔE₀₀ measures its own path at 66.6, the straight line at 69.4, and CAM16-UCS’s path at 72.0 — so by ΔE₀₀’s own reckoning the appearance model’s gradient is worse than the naive one, and CAM16-UCS returns the judgement, measuring ΔE₀₀’s path at 90.1 against the straight line’s 88.5. The same happens on red to blue in one direction: ΔE₀₀ measures CAM16-UCS’s path at 69.9 against the straight line’s 66.8.
So the two spaces do not disagree about how far to bow. They disagree about which way, on gradients where the bow is largest, and a path that improves matters under one can make them worse under the other.
What each space is measuring when it bows
The two curves bow for reasons that can be named, and naming them says why they disagree rather than merely that they do.
ΔE₀₀’s metric is cheapest where chroma is low, because its chroma weighting divides a chroma difference by one plus 0.045 times the chroma — so a step taken at chroma 80 counts for less than the same step at chroma 10. A path that dips towards the neutral axis is therefore buying cheaper steps, and a tolerance has a grain measured how far that grain runs across the whole cube.
CAM16-UCS’s metric is cheapest where its own compression is steepest, and its compression is in colourfulness rather than in chroma: M′ is a logarithm of M, so the space is squeezed at high colourfulness and stretched at low. That is a different function of a different quantity, computed through an appearance model with a viewing condition in it.
So the two are both bowing towards their own cheap regions and their cheap regions are not the same region. The disagreement is not noise in two fits; it is two different compressions of two different quantities, and the reason it is largest on the most saturated gradients is that both compressions are largest there.
There is one more reading of the two curves worth taking. Both bow away from the straight line on the same side on every gradient here — neither ever chooses the outside of the bend — so the two spaces agree about the direction the naive answer is wrong in and differ about how far and where along the path to correct it. That is a weaker disagreement than it would be if they bowed oppositely, and it is still large enough that on two gradients one of them would rather have the naive answer than the other’s correction.
Which of the two to believe
Nothing here decides it, and the honest position is worth stating precisely because it is not a shrug.
Both are fitted to judgements of pairs, and a pair judgement constrains a metric only at the separation the pairs were at — which is a threshold is not a unit applied to a whole formula rather than to one number. ΔE₀₀ was fitted to small differences, mostly near threshold and mostly on textile and paint samples; CAM16-UCS is derived from an appearance model fitted to corresponding-colour and magnitude-estimation data at much larger separations. Neither was fitted to a question about paths at all, and a geodesic is an integral of the local behaviour over a whole gradient — which is to say it is an extrapolation from what either was measured on.
A model judged in another model’s unit made the neighbouring point about comparing the two spaces’ numbers. This is the same problem for their shapes, and it is worse: two formulae can be brought into agreement about a number by a scale factor, and two curves through a colour space cannot.
What can be said is which question is being asked. For a tolerance the two spaces disagree by a factor and the disagreement is calibrated; for a path they disagree by tens of units and nobody has asked an observer. The experiment is the one the earlier essay named and has still not been run — show the two gradients and ask which looks more even — and it would now be a three-way comparison rather than a two-way one. Which mixture bows most depends on the ruler is the neighbouring case where two units disagreed about a ranking rather than about a shape.
What this does to the advice a drawing program could take
The earlier essay ended with three things a program could do with a geodesic, in increasing order of ambition. Two of them survive this and one does not.
Respacing an existing gradient survives. Keeping the straight line and redistributing its stops so that consecutive stops are equal in the metric changes no colour that was not already on the path, and the two metrics disagree only about how to space it rather than about which colours to use. The disagreement is a smaller one and it is bounded: both metrics agree that the straight line drawn in equal coordinate steps has a fast part and a slow part, and they would put the boundary between them in slightly different places.
Re-routing does not survive. Choosing the geodesic changes which colours appear, the two spaces choose different colours, and on some gradients each would rather have the straight line than the other’s choice. A program that re-routed would have to say which space it used, and the difference between two such programs on the same gradient would be larger than the difference between either and a program that did nothing.
And the third piece of advice is unchanged and is now better supported. It also gains a corollary worth stating: the earlier essay noticed that on red to green the geodesic happens to stay inside sRGB where the straight line does not, and called it a coincidence of mechanism. Two metrics bowing towards two different cheap regions and both ending up inside the gamut is a stronger version of the same coincidence, and it is the subject of the next measurement rather than of this one. Neither of these is gamut mapping. Most of this diagram cannot be shown is the standing reminder that a colour outside the gamut has to be marked or moved, and a geodesic moves a path for reasons that have nothing to do with a display — which is why what the two spaces disagree about is not what a display would have decided anyway.
How the two geodesics were found
Both metrics are taken by finite differences at the colour, in CIELAB coordinates, so that the two geodesics are two curves through the same space and can be compared as sets of colours rather than as two parameterisations. ΔE₀₀ is used as published; CAM16-UCS is used as the Euclidean distance in its own J′a′b′ coordinates, for the reason above.
A path is twenty segments. Its length is the sum over segments of the metric’s form at each segment’s midpoint applied to that segment’s displacement, and the shortest is found by gradient descent with a backtracking step, so the length falls monotonically. The points are respaced after every accepted step, because minimising a length says nothing about where the points on it sit.
Each relaxation is run three times: from the straight line in CIELAB, from the other metric’s answer, and from the straight line in Oklab, and the shortest result is kept — together with the seeds themselves as candidates. That is what makes “each metric prefers its own path” a check on convergence rather than a hope: a descent that ends above a path it was shown has not converged, and without the seed the neutral axis returned a CAM16-UCS path longer than the ΔE₀₀ one, which is a failed relaxation wearing the clothes of a result.
The third start was added after this essay was first written, and it changed one answer. With two starts, both CAM16-UCS relaxations on red to blue settled in the same local minimum, bowing 16.9 units, and the path Oklab calls straight turned out to be shorter under CAM16-UCS than that supposed geodesic. Relaxed from Oklab’s line, CAM16-UCS’s path is 82.8 long against 86.5 and bows 42.5. A third space breaks the tie only once is where that was found, and it is the reason the red-to-blue numbers above are not the ones this essay first reported. The distances between curves are also now measured from each point to the other curve’s polyline rather than to its nearest point, which removes a floor of up to half a step from every gap.
What this does not settle
The geodesics are numerical and there is no closed form to check them against. What can be checked is the neutral axis, where symmetry requires the straight line under both metrics and both find it, and the mutual-preference test above.
The comparison is in CIELAB coordinates, which belong to one of the two spaces. A geodesic is a curve through colours rather than through coordinates, so the curves are comparable and the distances between them are in CIELAB units and would be different numbers in another parameterisation. The ordering — which gradients disagree most — is what survives.
And six gradients between primaries and secondaries are not a census. The straight line is not the shortest gradient ran forty random pairs for its own question; the same over both metrics is a larger computation and would give the distribution rather than the examples.
Still open: whether a third space agrees with either
Two spaces disagreeing is a fact about two spaces. What would make it a fact about the problem is a third, and there is one to hand: Oklab is in wide use, it is Euclidean by construction, and it takes a colour in the same tristimulus values the other two start from.
The measurement is this one with a third metric added. Three outcomes are worth distinguishing. If Oklab’s geodesics sit near one of the two, the odd one out is the one to be suspicious of. If they sit between the two, then the three are sampling a family and the disagreement is a spread rather than a contradiction. And if Oklab’s sit outside both, the honest conclusion is that a geodesic under a uniform colour space is not constrained by anything any of them was fitted to — which is the reading this essay’s numbers already lean towards and which a third space would settle.
The computation needs nothing new: a metric here is a distance function between two CIELAB triples, and Oklab’s is a conversion and a Euclidean norm.
A derived quantity inherits what it was not fitted to
The habit is about how far a fitted thing can be pushed.
A colour difference formula is fitted to pairs, and a pair is two colours and a judgement. Everything else the formula is used for — a tolerance region, a ranking, a path length, a gradient’s evenness — is derived from it by arithmetic, and the arithmetic is sound. What the arithmetic cannot supply is data: a derived quantity is constrained by the fit only where the fit had samples, and a geodesic integrates the formula’s behaviour over regions where it had very few.
The move is to derive the same quantity from two independently fitted formulae and compare. Where they agree, the quantity is probably a property of colour; where they disagree by more than either differs from the naive answer, it is a property of the fits. That is a cheap test and it needs no observers.
The failure mode is to treat a derivation as a measurement. The shortest path under ΔE₀₀ is a fact about ΔE₀₀, not about looking at gradients, and the way to find that out is to ask a second formula the same question.
What this makes readable
Essays that name this one as a prerequisite.
Named alongside this one
Essays reaching for the same objects. Nobody chose these; they are what the index of named objects makes visible.
- A gradient is a path cielab · gradient · interpolation · metric axioms · perceptual uniformity
- A deviation is not a difference ciede2000 · cielab · colour difference · metric axioms
- A difference is not a distance ciede2000 · cielab · metric axioms · perceptual uniformity
- A press makes the cheap route a search ciede2000 · cielab · gradient · interpolation
- The mixture line bows cielab · colour difference · gradient · interpolation
- A colour has a name ciede2000 · cielab · perceptual uniformity
What links here
Every essay whose body links to this one.
The objects this essay names
Each one links to every other essay that touches it.
CIEDE2000CIELABColour appearanceColour differenceConventionGradientInterpolationMetric axiomsPerceptual uniformityQuadratic form