A matrix is fitted under one light
Assumes The chart decides the profile, A camera balances in another basis and No matrix is right everywhere.
A chart decides how well a camera matrix is determined. The other half of the calibration is easier to state and is missing from the error figure just as thoroughly: the chart was photographed under a light, and the matrix is a statement about that light.
The claim
A camera matrix is fitted under one illuminant and reports its residual under that illuminant. Used under another it can be eight times worse, and the failure is not the camera’s — it is the difference between two integrals over the same sensitivities.
- The diagonal is uniform: fitted and used under the same light, the matrix delivers between 1.00 and 1.17 ΔE00 across the whole set.
- The corner is not. Fitted under illuminant A and used under a 9000 K daylight, 9.34 — a factor of 7.96.
- The asymmetry is real. A matrix fitted under a cold light degrades less going warm than a warm one does going cold, because the tungsten spectrum has almost nothing at the short-wave end for the blue channel to integrate.
- And the two-matrix scheme is free. Blending the tungsten and daylight matrices at the right weight gives 1.153 ΔE00 at 4000 K, which is what a matrix fitted at 4000 K gives to three decimal places.
- But only at the right weight. Either endpoint alone gives 1.41 or 1.71, so the blend is worth 20 to 30 per cent and the weight is the whole of it.
Why the matrix depends on the light
The matrix is fitted to minimise the difference between what the camera’s three channels report and what the observer’s three functions report, over a set of surfaces. Both sides of that comparison have the illuminant inside them.
raw = ∫ S(λ) E(λ) ρ(λ) dλ and XYZ = ∫ x̄(λ) E(λ) ρ(λ) dλ
The best 3×3 between those two depends on E, and it depends on it because the sensor is not a linear redescription of the observer. If it were — if the Luther condition held — there would be one matrix, exact under every light, and the whole question would vanish.
It is therefore a measurement of how badly the condition fails, in the units a photograph is judged in, and it is a much more legible measurement than the residual usually quoted for it. A sensor that nearly satisfied the condition would have a nearly constant table above; this one has a corner at nine and a half.
Reading the table
The diagonal is boring, which is the point: between 1.00 and 1.17, with no trend. Whatever light a chart is shot under, a matrix fitted there does about equally well there, so the number a profile quotes carries no information about the light it was made under.
Off the diagonal there is a clear structure.
Going cold from a warm calibration is much worse than the reverse. Fitted under A, the matrix delivers 3.18 at D50, 5.98 at D65 and 9.34 at 9000 K. Fitted at 9000 K, it delivers 1.36 at D50 and 2.64 under A. The tungsten spectrum falls away steeply toward the short-wave end, so a fit under it is determined almost entirely by the long-wave half of the band and has very little to say about the blue channel.
Neighbouring lights are cheap. Any two adjacent columns cost a few tenths of a unit, which is why a camera profiled for daylight works acceptably across most of daylight.
And the worst cell is not a pathological case. A tungsten-calibrated camera photographing an overcast sky is an ordinary afternoon.
What the asymmetry costs in practice
The lopsidedness of the table has a practical consequence that is worth drawing out, because it points the wrong way from what a photographer would guess.
The intuition is that a calibration should be made under the light most photographs are taken in. The table says something sharper: it should be made under the light that is hardest to extrapolate from, and that is the tungsten end. A matrix fitted at 9000 K delivers between 1.00 and 2.64 across the whole set — never catastrophic. A matrix fitted under A delivers between 1.17 and 9.34.
The reason is entirely in the spectra. A tungsten lamp puts a few per cent of its visible power below 480 nanometres, so a fit under it is deciding the blue channel’s row from a very small signal, and the resulting row is nearly unconstrained in the way a badly conditioned chart leaves a matrix unconstrained — a different cause with the same consequence. A daylight spectrum is comparatively flat and constrains all three rows.
So the single-calibration advice, if there is to be only one, is to calibrate under the flattest light available, and the two-calibration advice is to make the tungsten one anyway because it is the end that cannot be reached from elsewhere.
The table grows in kelvin, not in mireds
The row fitted under illuminant A has four entries and they are close to a straight line — but only against the right axis, and it is not the one colour temperature is usually measured on.
Taking the excess over that row’s own diagonal of 1.17:
| light | temperature | ΔT | Δ mired | excess | per 1000 K | per mired |
|---|---|---|---|---|---|---|
| A | 2856 | 0 | 0 | 0.00 | — | — |
| D50 | 5003 | 2147 | 150.3 | 2.01 | 0.94 | 0.0134 |
| D65 | 6504 | 3648 | 196.4 | 4.81 | 1.32 | 0.0245 |
| 9000 K | 9000 | 6144 | 239.0 | 8.17 | 1.33 | 0.0342 |
Per kelvin the cost is nearly constant; per mired it nearly triples. Fitting a power law gives an exponent of 1.33 against ΔT and 3.02 against the mired distance, so the second is badly nonlinear and the first is close to a straight line with an offset.
That is a fact worth having, because the mired scale is the one everything else about colour temperature is measured on — it is the scale on which two lights a fixed distance apart look equally different, and it is what a blend weight is usually computed in. The matrix error does not follow it. What the matrix is failing at is not the chromaticity gap between two lights but the change in the shape of the spectrum across the band, and that changes roughly with temperature rather than with its reciprocal.
A least-squares line through the three off-diagonal points reads 1.52 ΔE₀₀ per thousand kelvin, less 1.06 — so the fit has a free range of about 700 kelvin before the cost starts, and then a steady rate. A matrix fitted under a 2856 K lamp is good to roughly 3,550 K for nothing, and costs one and a half units per thousand kelvin after that. That is a rule a photographer can hold, and it is not available from the table read as four numbers.
The asymmetry, as a ratio of rates
Going cold from a warm calibration is much worse than the reverse is right and the table says by how much, once both directions are put in the same units.
The same 6,144-kelvin excursion costs 8.17 ΔE₀₀ starting from illuminant A and 1.64 starting from 9000 K — a factor of 5.0. Per thousand kelvin that is 1.33 against 0.27.
And the mechanism the essay names checks against the spectra. A 2856 K radiator puts 5.5 per cent of its visible power below 480 nanometres; D50 puts 21.5, D65 29.8 and a 9000 K source 38.3. So the warm fit is deciding the blue row from a twentieth of the light and the cold fit from more than a third — a factor of seven in the evidence available, against a factor of five in the resulting asymmetry.
Those two numbers being close is the finding. It says the asymmetry is not some subtlety of the fit but very nearly proportional to how much short-wave light the calibrating lamp supplied, which is a quantity anybody can compute before photographing a chart. A lamp that puts a twentieth of its visible power in the blue will produce a matrix whose blue row is worth about a twentieth of the confidence.
It also gives the single-calibration rule a criterion. Calibrate under the flattest light available is right and hard to act on; calibrate under the light with the most short-wave power is the same advice with a number attached, and it is one integral over a lamp anybody can already measure.
The two-matrix scheme, measured
Real camera profiles carry two matrices — one for a tungsten-class illuminant and one for a daylight-class one — and blend between them by a weight derived from the estimated colour temperature. It is usually described as a pragmatic hack, and the measurement says otherwise.
At weight 0.5 the blend gives 1.153 and the matrix fitted at 4000 K gives 1.153. Two calibrations therefore determine the matrix at every light between them, to the accuracy a third calibration would have given. That is a strong statement and it is not obvious in advance: the best matrix is a nonlinear function of the illuminant, and there is no reason a straight line through the nine coefficients should follow it.
The reason it does is that the illuminants between two daylights are themselves nearly a straight line — the daylight family is three basis functions with two of them doing nearly all the work — and the map from illuminant to best matrix is smooth. Over a short arc, a smooth map of a nearly straight path is nearly straight.
What the measurement does not support is indifference to the weight. At weight zero the blend gives 1.41 and at weight one it gives 1.71, so choosing the wrong end costs a quarter to a half of a unit. Since the weight is derived from an estimated colour temperature, and estimating the illuminant is not a solved problem, the two-matrix scheme inherits the estimator’s error at one remove.
What was computed, and how
The camera is this site’s silicon sensor with its infrared-cut filter and the surfaces are the standard test set at chroma 0.45. The matrix at each light is the least-squares 3×3 from raw to tristimulus values over those surfaces, exactly as colourMatrix computes it, and evaluation is mean ΔE00 in CIELAB with the white point taken as the illuminant in use rather than as a fixed D65.
That last choice is load-bearing and is the one to argue with. Taking the white as the scene’s own light means the comparison is about colour rendering rather than about white balance: a matrix that got the neutral axis wrong would be penalised under a fixed white and is not penalised here. The alternative measurement — which this collection makes elsewhere — is what happens when the balance is applied in the wrong basis, and it is a separate failure with a separate size.
The blend is a straight line through the nine coefficients. Blending in a different parametrisation — the inverse matrices, or the implied primaries — would give a slightly different curve, and the flatness of the one measured here near its optimum means the choice cannot matter much at this precision.
The part a chart does determine
It would be misleading to leave the impression that a chart determines nothing. Asked a different question, it does rather well, and the contrast is the useful part.
The question is what the chart says about the sensitivities rather than about the matrix. The responses are the sensitivities integrated against the illuminated patch spectra, so they determine the projection of each curve onto the span of those spectra and nothing else — which is the same structure as a filtered reading of a lamp, with the patches playing the part of the filters.
The residue is 3.5 per cent of each curve, which is small, and the reason is a design rule worth extracting. These patches differ in where in the spectrum they are dark, which makes the set a crude filter bank and therefore a good probe of a curve. The near-neutral chart that conditions the matrix so badly fails for the mirror-image reason: its patches differ in level rather than in position, so they probe one direction thoroughly and the rest not at all.
A chart can therefore be good for one of these questions and bad for the other, and the two requirements do not conflict — a set of saturated patches at spread wavelengths satisfies both.
Where the model stops
A real profile is more than a matrix. Commercial profiles carry two matrices, two look-up tables and a tone curve, and the tables absorb some of what this essay attributes to the matrix. What they do not absorb is the dependence on the light, because the tables are calibrated under lights too.
The surfaces are constructed and the numbers belong to that set. What does not belong to it is the mechanism: any sensor failing the Luther condition has an illuminant-dependent best matrix, and the size of the dependence is the size of the failure.
And nothing here addresses fluorescent or LED sources. The set is one tungsten lamp and four daylights, which is a smooth one-parameter family. A discharge lamp is not on that path at all, and a blend weight derived from its correlated colour temperature is choosing a point on a line the lamp does not lie on — which is a different and probably larger failure.
Who found it, and when
The illuminant dependence of a camera matrix is not a discovery; it is why the raw formats of the 2000s specified two calibration illuminants rather than one, and the interpolation rule has been in the specification since. What appears not to have been published is the table — the full grid of fitted-under against used-under — which is one page of arithmetic and settles several arguments at once.
The result that a blend equals a fit is the one worth having. It converts a scheme that looks like an approximation into one that is, over the range measured, exact enough to be indistinguishable, and it says where the remaining error actually lives: in the weight, and therefore in the illuminant estimate.
The generalisation
The pattern is a fitted object whose data carry a hidden condition, where the condition is held constant during fitting and varies during use.
It is the same shape as a whiteness figure measured under an unstated lamp and as a tolerance that cannot cross a measurement condition, and the diagnostic is identical: vary the condition and re-evaluate, rather than varying the sample. A grid whose diagonal is flat and whose corners are not is the signature, and the flatness of the diagonal is what makes the quoted number so misleading — it is genuinely reproducible, and it reproduces the wrong thing.
The repair is also the same in all three cases and is cheap: quote the condition beside the number, and quote a second number at a different condition. Two calibrations turn out to be enough here to determine everything between them, which is a better outcome than the argument had any right to expect.
What a profile ought to carry
The list is short and every item is already computed by any pipeline that fits a matrix at two illuminants.
The two calibration illuminants, named. They are in the file format already and are almost never surfaced to the person reading the error figure.
The residual at each of them, which is the diagonal and is what is quoted now.
The residual of the blend at a light between them, which is the number that says whether the interpolation is working for this particular sensor. For the sensor here it is indistinguishable from a third calibration; for a sensor with a more awkward blue channel it might not be, and one evaluation settles it.
And an honest statement of the range. A profile made from a tungsten and a daylight calibration is interpolating between them and extrapolating outside them, and the table above shows what extrapolation costs at the tungsten end.
What a photographer sees
The table is a laboratory measurement and it is worth converting into the situation it describes, because the failure mode has a recognisable look.
A matrix fitted under a warm light and applied to a cold scene errs systematically rather than randomly: the channels it constrained best are the long-wave ones, so the blue end is where the fit is loose, and the error concentrates in saturated blues and violets. Those are the colours photographers describe as rendering badly on a particular camera — flowers that come out the wrong shade of purple, a twilight sky that goes cyan — and the description is usually attached to the camera rather than to the profile.
The white balance is not the problem and cannot fix it. A balance is a diagonal scaling that makes neutrals neutral, and it will make them neutral under any light; what it cannot do is correct a matrix whose off-diagonal terms were determined under a spectrum with almost nothing in the blue. That is the distinction between the two halves of a camera’s colour pipeline, and the second half is the one that carries a light inside it.
Where the ladder goes next
The same structure holds at delivery, with the condition replaced by a position rather than a light: a printer profile is a table exact at its nodes and interpolated everywhere anybody prints, and the interpolation question there has the same shape as the blend question here and a much less comfortable answer.
And the estimate the blend weight depends on is the subject one field over. An image does not determine the light, so the weight is an inference rather than a measurement, and a scheme that is exact given the right weight is only as good as the guess.
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 camera profile is a fit camera raw · colour matrix · the icc profile · illuminant · white balance
- A camera cannot record the excitation camera raw · colour matrix · illuminant · white balance
- Four places to clamp are two pipelines camera raw · colour matrix · identifiability · white balance
- Raw is not a picture camera raw · colour matrix · the icc profile · white balance
- Two lamps decide what one lamp could not camera raw · identifiability · illuminant · white balance
- A black level is multiplied by the balance camera raw · colour matrix · white balance
What links here
The 8 essays that link to this one and share the most of its objects, of 16 that link here.
- A corner is corrected by one row
- Two matrices do not reach a white LED
- One row for every lamp costs the lamps that lose least
- The corner of the frame has another filter
- The chart decides the profile
- Flicker sorts lamps the wrong way
- The chart was measured by an observer too
- A fit can be exact and empty
The objects this essay names
Each one links to every other essay that touches it.
CalibrationCamera rawChromatic adaptationColour matrixCorrelated colour temperatureHeld-out validationThe ICC profileIdentifiabilityIlluminantInterpolationWhite balance