spectral invariance under daylight illumination changes

9
Spectral invariance under daylight illumination changes John A. Marchant and Christine M. Onyango Image Analysis and Control Group, Silsoe Research Institute, Wrest Park, Silsoe, Bedford MK45 4HS, UK Received June 26, 2001; revised manuscript received October 12, 2001; accepted October 15, 2001 We develop a method for calculating invariant spectra of light reflected from surfaces under changing daylight illumination conditions. A necessary part of the method is representing the illuminant in a suitable form. We represent daylight by a function E( l , T) 5 h ( l )exp@u(l)f (T)#, where l is the wavelength, T is the color temperature, h ( l ) and u ( l ) are any functions of l but not T, and f ( T) is any function of T but not l. We use an eigenvalue decomposition on the logarithm of the CIE daylight standard at various color temperatures to obtain the necessary functions and show that this gives an extremely good fit to CIE daylight over our experi- mental range. We obtain experimental data over the range 350830 nm from a range of standard colored surfaces for 50 daylight conditions covering a wide range of illumination spectra. Despite a considerable variation in the spectra of the reflected light, we show only small variations when the transformation is used. We investigate the possible causes of the residual variation and conclude that using the above approximation to daylight is unlikely to be a major cause. Some variation is caused by local daylight conditions being dif- ferent from the CIE standard and the rest by measurement and modeling errors. © 2002 Optical Society of America OCIS codes: 150.2950, 120.6200, 330.1690, 330.6180, 150.0150. 1. INTRODUCTION It is well known that the color of the light reflected from a surface will change as the incident illumination changes. Humans have an innate ability to compensate for this and scarcely notice the changes. However, endowing an arti- ficial device with a similar competence has proved rather difficult. This characteristic becomes a problem when we wish to distinguish between surfaces by using color differ- ences. It is especially troublesome when we wish to work under natural illumination conditions, which are subject to much variability in both intensity and spectral content. The recent availability of portable devices that can form spectral images (as opposed to conventional measure- ments over single areas) has prompted interest in appli- cations under natural illumination (e.g., agriculture). 1,2 A typical way of achieving invariance is to use a uniformly reflecting reference surface, such as a barium sulfate block or a probe pointing away from the surface, to esti- mate the illumination, whereupon the spectral reflectance (a property of the surface) can be obtained by division. This is easy under laboratory conditions, 1 but it is diffi- cult to ensure that the reference surface or the probe ex- periences the same illumination as the target in real situ- ations. An extreme example occurs when the reference is in sun and the target is in shadow. Extracting illumination-invariant information from (typically) three-band color-camera images has received considerable attention. 35 In these studies, researchers used information from a small number of nearby locations and effectively canceled out illumination dependence by assuming that the locations had the same illumination and orientation. Thus these methods suffer from occlu- sions and also depend on having different surface colors at the locations. Gevers et al. 6 used a similar method (al- though removing the requirement for locally constant ori- entation) to extend these ideas to spectral images. How- ever, spectral imagers are line-scan devices and depend on the known motion of the imager to build up the image. Poor registration between lines (which would affect the necessary spatial integrity of the data) could easily occur as a result of errors in the estimated motion, including those due to vibration. A different approach to invariance was adopted by Hea- ley and Slater. 7 The measurement space is of dimension (i.e., number of spectrometer wavelength channels) W, whereas both illumination and surface spectral reflectiv- ity can be represented by a fairly small number of basis functions, certainly much fewer than W. Therefore any measured spectra of reflected light from a single surface should be contained in a much lower N-dimensional sub- space. Healey and Slater found by simulation that N 5 9 was sufficient for a wide range of materials under daylight illumination. What is invariant about their treatment is the particular subspace occupied by any one surface. As they say, because W is much larger than N it should be possible to identify a large set of materials un- der a range of conditions. However, it is necessary to identify the particular subspace for classification, and they used a separate measurement of the spectral reflec- tivity of their target surfaces coupled with a comprehen- sive simulation of the illumination to do this. Recent work 8,9 has shown that invariants can be calcu- lated at a single pixel (i.e., not requiring spatial context) if the illumination is constrained to a particular family. The family used was the Wien approximation to Planck’s formula, 10 which is a reasonable approximation to the im- portant family of illuminants, daylight. More recent work 11 has shown that the constraints on the illuminants 840 J. Opt. Soc. Am. A/Vol. 19, No. 5/May 2002 J. A. Marchant and C. M. Onyango 0740-3232/2002/050840-09$15.00 © 2002 Optical Society of America

Upload: christine-m

Post on 03-Oct-2016

212 views

Category:

Documents


0 download

TRANSCRIPT

840 J. Opt. Soc. Am. A/Vol. 19, No. 5 /May 2002 J. A. Marchant and C. M. Onyango

Spectral invariance under daylightillumination changes

John A. Marchant and Christine M. Onyango

Image Analysis and Control Group, Silsoe Research Institute, Wrest Park, Silsoe, Bedford MK45 4HS, UK

Received June 26, 2001; revised manuscript received October 12, 2001; accepted October 15, 2001

We develop a method for calculating invariant spectra of light reflected from surfaces under changing daylightillumination conditions. A necessary part of the method is representing the illuminant in a suitable form.We represent daylight by a function E(l, T) 5 h(l)exp@u(l)f (T)#, where l is the wavelength, T is the colortemperature, h(l) and u(l) are any functions of l but not T, and f (T) is any function of T but not l. We usean eigenvalue decomposition on the logarithm of the CIE daylight standard at various color temperatures toobtain the necessary functions and show that this gives an extremely good fit to CIE daylight over our experi-mental range. We obtain experimental data over the range 350–830 nm from a range of standard coloredsurfaces for 50 daylight conditions covering a wide range of illumination spectra. Despite a considerablevariation in the spectra of the reflected light, we show only small variations when the transformation is used.We investigate the possible causes of the residual variation and conclude that using the above approximationto daylight is unlikely to be a major cause. Some variation is caused by local daylight conditions being dif-ferent from the CIE standard and the rest by measurement and modeling errors. © 2002 Optical Society ofAmerica

OCIS codes: 150.2950, 120.6200, 330.1690, 330.6180, 150.0150.

1. INTRODUCTIONIt is well known that the color of the light reflected from asurface will change as the incident illumination changes.Humans have an innate ability to compensate for this andscarcely notice the changes. However, endowing an arti-ficial device with a similar competence has proved ratherdifficult. This characteristic becomes a problem when wewish to distinguish between surfaces by using color differ-ences. It is especially troublesome when we wish to workunder natural illumination conditions, which are subjectto much variability in both intensity and spectral content.The recent availability of portable devices that can formspectral images (as opposed to conventional measure-ments over single areas) has prompted interest in appli-cations under natural illumination (e.g., agriculture).1,2

A typical way of achieving invariance is to use a uniformlyreflecting reference surface, such as a barium sulfateblock or a probe pointing away from the surface, to esti-mate the illumination, whereupon the spectral reflectance(a property of the surface) can be obtained by division.This is easy under laboratory conditions,1 but it is diffi-cult to ensure that the reference surface or the probe ex-periences the same illumination as the target in real situ-ations. An extreme example occurs when the reference isin sun and the target is in shadow.

Extracting illumination-invariant information from(typically) three-band color-camera images has receivedconsiderable attention.3–5 In these studies, researchersused information from a small number of nearby locationsand effectively canceled out illumination dependence byassuming that the locations had the same illuminationand orientation. Thus these methods suffer from occlu-sions and also depend on having different surface colorsat the locations. Gevers et al.6 used a similar method (al-

0740-3232/2002/050840-09$15.00 ©

though removing the requirement for locally constant ori-entation) to extend these ideas to spectral images. How-ever, spectral imagers are line-scan devices and dependon the known motion of the imager to build up the image.Poor registration between lines (which would affect thenecessary spatial integrity of the data) could easily occuras a result of errors in the estimated motion, includingthose due to vibration.

A different approach to invariance was adopted by Hea-ley and Slater.7 The measurement space is of dimension(i.e., number of spectrometer wavelength channels) W,whereas both illumination and surface spectral reflectiv-ity can be represented by a fairly small number of basisfunctions, certainly much fewer than W. Therefore anymeasured spectra of reflected light from a single surfaceshould be contained in a much lower N-dimensional sub-space. Healey and Slater found by simulation that N5 9 was sufficient for a wide range of materials underdaylight illumination. What is invariant about theirtreatment is the particular subspace occupied by any onesurface. As they say, because W is much larger than N itshould be possible to identify a large set of materials un-der a range of conditions. However, it is necessary toidentify the particular subspace for classification, andthey used a separate measurement of the spectral reflec-tivity of their target surfaces coupled with a comprehen-sive simulation of the illumination to do this.

Recent work8,9 has shown that invariants can be calcu-lated at a single pixel (i.e., not requiring spatial context) ifthe illumination is constrained to a particular family.The family used was the Wien approximation to Planck’sformula,10 which is a reasonable approximation to the im-portant family of illuminants, daylight. More recentwork11 has shown that the constraints on the illuminants

2002 Optical Society of America

J. A. Marchant and C. M. Onyango Vol. 19, No. 5 /May 2002/J. Opt. Soc. Am. A 841

can be considerably relaxed, which gives a family that isextremely close to daylight. These methods do not de-grade with occlusion or loss of spatial integrity and do notrequire a range of colors in the image. In this paper weseek to extend our previous methods8 for calculating in-variants for color-camera images to spectral sensors. Asin this previous work, our intended practical applicationis in crop sensing and classification from ground-basedsources. This will always require cheap systems basedon mass-market applications, and so we have concen-trated on the wavelength range available to silicon sen-sors, i.e., visible and near infrared.

2. THEORETICAL DEVELOPMENTA. AssumptionsIn the following we make a number of assumptions aboutthe physical processes that apply in our work. First weassume that the materials behave as inhomogeneous di-electrics, where incident light enters a pigment colorantlayer below the material surface, it is scattered, and acomponent emerges from the surface after undergoing aspectral change. We further assume that the ratio be-tween the spectral composition of the light that enters thematerials and the light that leaves them is the same forall angles, part of what Tominaga and Wandell12 call thestandard reflectance model. In addition, we assume thatthere is no specular reflection13 from the surfaces, i.e., thesurfaces are matte.

B. Illumination modelThe development of a spectral invariant follows closelythat for the color invariant in Ref. 8. To represent stan-dard daylight, the data published by the Commission In-ternationale de l’Eclairage (CIE)14 are normally used.These spectra are published in the form of tables ofwavelength10 and are derived from the extensive work ofJudd et al.15 Variations in daylight can be representedby changing a parameter, the correlated color tempera-ture (CCT), which changes the particular spectrumwithin the daylight family. In our original color work wemade the assumption that daylight could be approxi-mated by

E~l, T ! 5 c1l25 exp~2c2 /Tl! (1)

(see Ref. 10 but note the missing negative sign there).This is the Wien approximation to Planck’s formula,where T is the blackbody temperature. The approxima-tion is reasonable for the filter bands used in conventionalcolor cameras, as their center wavelengths are generallyin the range 440–610 nm. However, the differences inradiant power for the CIE daylight standard14 and Eq. (1)are actually quite significant for high CCTs at the blueend of the spectrum and at the near-infrared end. Al-though this may not matter for color cameras, spectral in-vestigations are likely to extend over a wider range, andso a more satisfactory representation is required.

In more recent work11 we showed that the CIE daylightfamily could be generated much more closely by the rela-tionship

E~l, T ! 5 h~l!exp@u~l!f~T !#, (2)

where T is a parameter, equivalent to the CCT, thatchanges the particular spectrum within the family of day-light spectra. h(l) and u(l) are any functions of l butnot T; f(T) is any function of T but not l. It can be seenthat Eq. (1) is a special case of Eq. (2), i.e., where h5 c1l25, u 5 1/l, and f 5 2c2 /T.

C. Reflection and Sensor ModelThe spectrum of light reflected from a surface and inter-cepted by a sensor under the above assumptions can bemodeled as13

CI 5 GIE SI~l!r~l!E~l, T !dl, (3)

where CI is the response for a particular wavelengthchannel, SI(l) is the spectral sensitivity of the channel,and r(l) is the spectral reflectance of the surface.E(l, T) is the illumination, where l is the wavelengthand T is the CCT, and GI is a gain factor, independent ofl, that is a product of two components. The first compo-nent depends on the spectrometer (for example, on theelectronics, the aperture, and the sensor integrationtime), and the second component depends on the relativeangles of the surface, the illumination, and the observer.The integration is taken over the (small) bandwidth of thechannel.

If we assume that the spectrometer is calibrated (butsee the remark about calibration in Subsection 4.C be-low), this effectively makes SI constant for each channel.In addition, the bandwidth for each channel will be small,so we can reasonably approximate Eq. (3) by

Cl 5 gr~l!E~l, T !, (4)

where l is used to label the channel (for example, by thecenter wavelength) and g is a scalar that, like GI , de-pends on the spectrometer settings and the photometricangles.

D. Derivation of the InvariantIn our previous work8,11 we showed that a simple ratio

F 5 r/gA (5)

was invariant to daylight illumination changes. r and gare the red and green band ratios, i.e., the red/blue andgreen/blue ratios, respectively, of the camera output. Forthe illumination model of Eq. (2) the exponent A is givenby11

A 5u~lcR! 2 u~lcB!

u~lcG! 2 u~lcB!, (6)

where the lc’s are the center frequencies of the three cam-era filters.

We now extend the idea to more channels and definethe band ratio of any wavelength channel of the spectrom-eter as

yl 5Cl

Cln

5r~l!E~l, T !

r~ln!E~ln , T !, (7)

where ln is a normalizing wavelength, analogous to theblue channel in the color work. Note that g is canceledout, which makes the following independent of the spec-

842 J. Opt. Soc. Am. A/Vol. 19, No. 5 /May 2002 J. A. Marchant and C. M. Onyango

trometer settings and, more important, independent ofthe photometric angles. In contrast to a three-channelcolor camera, there are now many band ratios, i.e., thenumber of wavelength channels minus one.

In a way analogous to the color invariant of Eq. (5), weform a function of any two band ratios yl1

and yl2as

F12 5 yl1/yl2

A12, (8)

where

A12 5u~l1! 2 u~ln!

u~l2! 2 u~ln!. (9)

Substituting from Eqs. (7), (2), and (9) into Eq. (8), we ob-tain

F12 5 a1 /a2A12, (10)

where

a1 5r~l1!h~l1!

r~ln!h~ln!; a2 5

r~l2!h~l2!

r~ln!h~ln!. (11)

Thus F12 is independent of T, i.e., independent of illumi-nation changes, provided that the illumination comesfrom a family represented by Eq. (2).

If we fix l2 and allow l1 to take on any value, we obtaina spectrum,

Fl 5 yl /yl2

Al, (12)

that is characteristic of a surface but independent of theillumination. l2 can be seen as a second normalizingwavelength. Since l1 is now regarded as any value ofwavelength, we have replaced the suffixes on F, y, and Aby l. Using the language of Healey and Slater,7 we haveconfined our measurement of reflected light under vari-able daylight illumination to a subspace consisting of asingle point in the measurement space for any one sur-face.

It must be noted that F12 is not invariant to any illu-minant changes, only those within an illuminant familywhere h and u remain constant functions of l. Swappingfrom one family to another (e.g., by placing a filter overthe spectrometer probe), will give a different value of F12for the same reflecting surface.

E. Representation of CIE DaylightIn order to use the invariant, we must know u(l). Notethat we do not need to know the other parameters of theillumination model [Eq. (2)], i.e., h(l) and f(T), since nei-ther Eq. (8) nor Eq. (9) contains them. However, it is in-formative to investigate how accurately a model of the re-quired form [Eq. (2)] can represent daylight. We use aprincipal components analysis (PCA) of the CIE daylightspectra to find u(l) and to investigate accuracy.

Full details of the PCA used for the investigation aregiven in our previous work,11 but the important points aresummarized here for completeness. We first take loga-rithms of Eq. (2) and obtain

L~l, T ! 5 a~l! 1 u~l!f~T !, (13)

where L is the log of the spectrum and a 5 log(h). Wethen calculate logarithms of CIE daylight spectra for arange of CCTs, T. We have chosen T to range from4000 °K to 20000 °K in steps of 2000 °K. PCA allows thespectra to be expressed as

L 5 Lm 1 p1b1 1 p2b2 1 p3b3 1 ..., (14)

where L is the logarithm of a spectrum, Lm is the meanspectrum over the range of T, and the p’s are the eigen-vectors of the matrix of covariances as spectra vary withT. The b’s are weighting factors. With appropriatechoice of b’s, any spectrum in the input data set L can bereconstructed, and, if all the eigenvectors are used, ex-actly.

PCA ensures that Lm and the p’s are functions of lalone and that the b’s are functions of T alone. Hence,comparing Eq. (13) with Eq. (14), we see that the PCA de-composition truncated after the first p term would satisfythe requirements on the illumination model where a(l)5 Lm , u(l) 5 p1 , f(T) 5 b1 . The first five eigenvaluesare (to three decimal places) 5.705, 0.036, 0.002, 0.000,0.000. This shows that the vast majority of the variancefrom the decomposition [Eq. (14)] is accounted for by thefirst eigenvector, and so we should be able represent thelog of CIE daylight by

L 5 Lm 1 p1b1 (15)

with little error.Plots of the mean and the first eigenvector from such a

decomposition are shown in Fig. 1. It is not necessary to

Fig. 1. (a) Mean and (b) first eigenvector of log(E) for CIE data.

J. A. Marchant and C. M. Onyango Vol. 19, No. 5 /May 2002/J. Opt. Soc. Am. A 843

Fig. 2. (a) Derived values of b1 plotted against CCT along with fitted curve. (b) CIE daylight (heavy curves) and reconstructions (lightcurves) calculated with the mean and the first eigenvector of log(E).

derive f(T) in order to calculate the invariant spectrum.However, knowing f(T) (which equals b1) is useful forcomparing CIE spectra with reconstructions using Eq.(15). b1 can be calculated from L (from the CIE spectra),and Lm and p1 (from the PCA) by rearranging Eq. (15).The result is shown in Fig. 2(a) along with the fitted curve

b1 5 2.3 2 21.0 exp~2T/4000.0 !. (16)

If f(T) were independent of l, the group of values of b1 ateach CCT would all be equal. The spread indicates thatthere is a dependence on l when the series in Eq. (14) istruncated after the first eigenvector. However, thisspread is reasonably small compared with the spread overthe values of T.

With Eq. (16), a family of illuminant spectra can begenerated for various values of T. Examples are shownin Fig. 2(b), which shows excellent agreement betweenthe CIE standard family and the reconstructed family.The root mean square error between the CIE and the re-constructed values is 0.034 for the three values of CCTshown.

3. EXPERIMENTAL WORKA. Data CollectionSpectral data were collected with an Ocean Optics S2000fiber optic spectrometer at Silsoe, Bedfordshire, UK (lati-tude 52.009° N, longitude 0.409° W), during the periodMarch–May 2001. The time of day ranged from 7.40a.m. to 7.30 p.m. The target surfaces were the individualchips from a Macbeth ColorChecker rendition chart (ig-noring the grays) plus two chips (2.5 G 6/6 and 7.5 G 6/6)from the green part of the Munsell set of plant tissue col-ors. We also added a barium sulfate block to the set, giv-ing 21 surfaces in all. Measurements were made lookingnormal to the surfaces. The surfaces cover a wide rangeof reflectance characteristics, and the two plant tissue col-ors add extra data in the areas we are interested in forour general work. Sky conditions during the data collec-tion ranged from bright sun with blue sky, through partialcloud cover, to complete cloud cover with gray sky. In all,50 sets of data were collected, where a set consisted ofmeasured spectra from all 21 surfaces with one sky con-dition. The time taken to collect each set varied in the

range of 5 to 15 min; most time was taken up moving theinstrument from surface to surface and storing the datafiles. The sensor integration time ranged from 30 to 500ms.

Shadow conditions were obtained by placing the tar-gets in a cuboid box with the top and one side open to thesky. The inside of the box was painted matte black. Thehorizontal base, on which the targets were placed, wasslightly bigger than the ColorChecker board (approxi-mately 300 mm 3 200 mm), and the side walls were ap-proximately 200 mm high. The spectrometer probe wasfitted with a collimating lens so that only a single coloredchip was in view at each measurement. Casting shadowswith the box often gave us the opportunity to obtain anumber of different illumination conditions in each ses-sion by varying the orientation of the box, thus exposingthe targets to different parts of the sky. Typically, asmall number of sets of data (i.e., measurements from all21 surfaces) were collected in each session.

The spectrometer was calibrated before each sessionwith the procedure and equipment recommended by theinstrument manufacturers. The procedure consists ofmeasuring the spectrum produced by a tungsten halogenlamp unit, which is supplied with a calibration certificateby the manufacturers. The offset (i.e., the ‘‘dark’’ spec-trum) is measured by covering the collimating lens withan opaque cap. The sensitivity for each wavelengthchannel is established by subtracting the offset. Beforeeach set of data was collected, we checked the outputspectrum (before the calibration was applied) on the chipthat gave the largest single output value at any wave-length (chip 16, yellow) and set the integration time of thesensor to avoid saturation while maintaining sufficientrange. Finally we remeasured the dark spectrum and re-corded the set of data.

The spectrometer gives raw output data at 0.35-nm in-tervals. These data were collected into 10-nm-wavelength bins in the range of 350 to 830 nm, giving 49wavelengths for each spectrum.

B. Results

1. Qualitative TreatmentFigure 3(a) shows seven sets of 50 spectra of light re-flected from the test surfaces. There are too many sets to

844 J. Opt. Soc. Am. A/Vol. 19, No. 5 /May 2002 J. A. Marchant and C. M. Onyango

Fig. 3. Spectra of light reflected from a sample of seven surfaces from the experimental set. (a) Original spectra; (b) invariant spectra.Row 1 (top), barium sulfate block; row 2, blue representative; row 3, red representative; row 4, green representative; row 5, blue/greenrepresentative; row 6, yellow representative, row 7, red/blue representative.

J. A. Marchant and C. M. Onyango Vol. 19, No. 5 /May 2002/J. Opt. Soc. Am. A 845

show them all, so they have been selected to illustrate re-sults from gray, blue, red, green, blue/green, yellow, andred/blue surfaces. The representatives are barium sul-fate, Macbeth No. 3 (ISCC/NBS name ‘‘moderate blue’’),Macbeth No. 9 (‘‘moderate red’’), Munsell 7.5 G 6/6, Mac-beth No. 6 (‘‘light bluish green’’), Macbeth No. 16 (‘‘vividyellow’’), and Macbeth No. 17 (‘‘strong reddish purple’’).The reflection from the barium sulfate block can be takento represent the spectrum of the illumination, as this sur-face has a nearly constant spectral reflectance over a widespectral range.10 It can be seen that a large variation indaylight spectral content was encountered during datagathering.

Figure 3(b) shows the invariant spectrum from eachsurface, Fl , calculated from Eq. (12) with ln 5 650 nmand l2 5 450 nm. It can be seen that the spectra of col-umn (a) show large variations for the same surface. Onthe other hand the spectra in column (b) are much moreconsistent for the same surface when the illuminant spec-trum is changed. Results from the other 13 surfaces aresimilarly variable for the original spectrum and similarlyless variable for the invariant.

2. Quantitative Treatment of Invariant EffectivenessTo assess quantitatively the performance of the invariantcalculation, we follow Healey and Slater7 and use thespectral angle as a measure of closeness of two spectra.This angle, g, is defined as

cos~l! 5Ca • Cb

iCaiiCbi, (17)

where Ca and Cb are two vectors of spectral values.Table 1 shows the standard deviation of g for each sur-

face, where angle differences are measured from themean for the particular surface. As expected, there arelarge variations for all surfaces when the original spectraare used. With the invariant, the variations are muchsmaller. In fact the pooled standard deviation of thespectral angles from their individual means for all groupsis 0.163 for the original spectra and 0.046 for the invari-ants.

When invariants are formed, the residual variation isnot the only measure of performance. The ability of theinvariant spectrum to discriminate between surfacesmust also be considered. As a trivial example, an ex-tremely effective invariant is the transformation

Fl 5 1.0. (18)

This is completely invariant to illumination (and every-thing else) but has no discriminating power at all. Al-though our invariant is not quite so inflexible as thatspecified in Eq. (18), it is forced to equal 1.0 at two points,the normalizing wavelengths ln and l2 , and so is likelyto compromise discriminating ability.

To characterize discrimination potential, we measurethe angles between the mean spectra for each surface.There are 200 possible pairwise combinations of differentsurfaces. The average angle over these combinations is0.637 rad for the original spectra and 0.619 rad for the in-

variants. Thus the discriminating ability is hardly com-promised despite the significant reduction in variationwith illumination.

3. Choosing the Normalizing WavelengthsIt is not obvious how to choose the normalizing wave-lengths in any principled way. An approach that seeks tomaximize the ratio of the between-surface spread (the dis-criminating ability) to the within-surface spread (the de-parture from invariance) gives an answer that depends onthe particular set of surfaces used. The maximizationprocess also suffers from a number of ill-conditioningproblems. Another factor that should be taken into ac-count in any ‘‘best’’ choice is the robustness of the solu-tion. For example, it seems unwise to choose normaliz-ing frequencies at points where the spectrum is likely tochange rapidly, e.g., at any of the absorption features, as aslight drift in the wavelength measurement could causecomparatively large perturbations in the band ratios. Anobvious rule is that the eigenvector [Fig. 1(b)] must not

Table 1. Standard Deviation of the Spectral Anglefrom the Mean for Each Surface

Surfacea Spectrum Invariant

0 0.2142 0.04111 0.1642 0.04762 0.1762 0.04063 0.2343 0.03854 0.1776 0.04855 0.2331 0.04306 0.1672 0.04097 0.0886 0.05128 0.2082 0.03729 0.1164 0.0391

10 0.1824 0.036811 0.1286 0.038412 0.1024 0.052013 0.1765 0.035414 0.1290 0.046215 0.0625 0.061516 0.1046 0.054517 0.1788 0.037218 0.1467 0.065019 0.1367 0.048120 0.1645 0.0448

a Surface 0 is barium sulfate, surfaces 1–18 correspond to the MacbethColorChecker chip numbers, and surfaces 19 and 20 are 2.5 G 6/6 and 7.5G 6/6 from the Munsell set.

Table 2. Performance Indicators When theNormalizing Wavelengths Are Changed

ln l2

Standard Deviation of g Mean Pairwise Angle

Spectrum Invariant Spectrum Invariant

650 450 0.163 0.046 0.637 0.619650 400 0.163 0.048 0.637 0.556650 500 0.163 0.050 0.637 0.769600 450 0.163 0.050 0.637 0.690700 450 0.163 0.045 0.637 0.579

846 J. Opt. Soc. Am. A/Vol. 19, No. 5 /May 2002 J. A. Marchant and C. M. Onyango

have equal values at ln and l2 ; otherwise, Al becomesinfinite, leading to the trivial invariants Fl 5 0.0 or Fl

5 ` depending on whether yl2is greater or less than 1.0.

A second rule is that the spectrum must not have zero val-ues at either of the normalizing frequencies. We haveadopted a pragmatic method in which we choose ln andl2 to be reasonably well spaced over the wavelengthrange. Judicious choice ensures that u(l2) and u(ln)are well separated while the invariant has the value 1.0at two points spaced within the range. This latter char-acteristic should mean that the range of values of Fl isnot too great; a large range could lead to difficulties in po-tential classification procedures, where a few wave-lengths having very high values would dominate any dis-tance metric. These considerations have motivated thechoice of values used above. Fortunately, the precisechoice is not critical. Table 2 shows the performance in-dicators for a range of sets of ln and l2 . It can be seenthat in all cases the transformation significantly reducesthe spectral variation while changing the discriminatingability only marginally.

4. REPRESENTATIONAL ANDEXPERIMENTAL ERRORSA. Sources of ErrorAlthough the variations in the spectra are significantlyreduced, there is still some variation remaining. Therecan be many sources for this, the most obvious being thefact that log(E) has been represented by using the meanand only one eigenvector. Other possibilities are that (1)the first eigenvector of log(Silsoe daylight) is differentfrom that of CIE daylight, (2) there are errors in the spec-trometer measurements, and (3) our materials do not con-form with the assumptions in Section 2. With the mea-surements that we have made, we cannot decideunambiguously among these; however, some limited in-vestigation is possible.

B. Representation of DaylightWe have shown that if the illuminant family can be rep-resented by Eq. (2), our transformation, Eq. (12), is in-variant to changes caused by the parameter T. A num-ber of questions are prompted: How well is anyparticular daylight family represented by Eq. (2)? How isthe residual variation affected by deviations of daylightfrom Eq. (2)? How different is our particular daylightfrom the standard CIE daylight? We have investigatedthe first question in Subsection 2.E using CIE daylight asan example. It is not possible to answer the second ques-tion in a general, analytical way, as we have to assumethe way in which the daylight deviates. What we do be-low is to simulate the effect of using the complete repre-sentation of CIE daylight as opposed to the approxima-tion in Eq. (15). We investigate the third question byperforming a PCA on Silsoe daylight and calculating in-variant spectra using the mean and first eigenvector only.

An estimate of r(l) for any surface can be made by di-viding the spectrum by the barium sulfate spectrum ateach wavelength. This assumes that the illuminationconditions do not change between measurements, so datafrom a run with stable conditions were chosen for this cal-culation. A set of simulated spectra can then be gener-ated by calculating CIE illumination spectra over a rangeof CCTs, using Eq. (4) to calculate the spectra of the re-flected light, and normalizing at 560 nm. The result isshown in Fig. 4(a) for two surfaces, the blue representa-tive (corresponding to row 2 of Fig. 3) and the yellow rep-resentative (corresponding to row 6 of Fig. 3). These par-ticular surfaces were chosen because, between them theyshow residual variation over most parts of the spectrum.Figure 4(b) shows the corresponding invariant spectra(whose calculations use only one eigenvector to representthe illumination). It can be seen that residual variationis readily apparent only in a small part of the blue end ofone spectrum. We can tentatively conclude that repre-senting log(E) with only one eigenvector does not contrib-ute significantly to the residual variation. Of course, the

Fig. 4. Simulations of spectra from two surfaces. Top, blue surface; bottom, yellow surface. (a) Reflected light, (b) invariant spectracalculated with the eigenvector from CIE illumination, (c) invariant spectra calculated with the eigenvector from estimated Silsoe illu-mination.

J. A. Marchant and C. M. Onyango Vol. 19, No. 5 /May 2002/J. Opt. Soc. Am. A 847

calculation of r(l) is itself subject to measurement error.However, errors in r(l) would lead to errors in the meanvalues of the simulated spectra, whereas we are inter-ested here in the possible spread caused by incompleterepresentation of the illumination.

To estimate the range of Silsoe illumination conditions,we use the spectra of the light reflected from the bariumsulfate surface. We also note that these spectra are sub-ject to measurement errors just as the data are from anyother surface. The first eigenvector of log(Silsoedaylight) estimated from these data is shown in Fig. 5. Itcan be seen that the values are very similar to those inFig. 1(b) except at the red and blue ends, where there areslight differences. To estimate the effect of these differ-ences in Fig. 4(c), we present the invariants calculated byusing the Silsoe eigenvector instead of the CIE eigenvec-tor. Note that for these simulated spectra, the ‘‘correct’’eigenvector is the CIE one. Figure 4(c) shows the invari-ant calculated using the ‘‘wrong’’ eigenvector (the Silsoeone). For our measured data the sense of correct andwrong would be reversed. However, Fig. 4(c) shows thatusing the wrong eigenvector could lead to residual varia-tion at the red and blue ends. Of course, in practice wewould not have access to the correct eigenvector, as itmight change from place to place and from time to time (itwould also be extremely tedious to collect). What wehave illustrated is that using eigenvectors derived fromsources as different as the CIE locations in the early1960s and Silsoe in 2001 could lead to residual variations,but the extent of these variations would be small.

C. CalibrationIt appears that the above factors (using one eigenvectorand a standard, CIE, rather than a local, Silsoe, illumina-tion set to derive it) could cause some residual variationbut probably not all of it. It seems likely therefore thatthe rest is due to experimental or material modeling er-rors. One possibility is errors in the calibration of thespectrometer. Although the calibration lamp (a tungstenhalogen one) is claimed to be suitable for the range ofwavelengths we used, it does have a relatively low outputat the blue end of the spectrum and could give small er-rors in this band. It is interesting to note that ourmethod could be used with an uncalibrated system: h(l)in Eq. (2) could include the system calibration. Of coursewe would produce a different set of invariants, but theywould still be invariant to daylight illumination changes.

Fig. 5. First eigenvector of log(E) for Silsoe data.

D. Reflection ModelIn Subsection 2.A we assumed that the surfaces werematte. It is possible to investigate the effect of depar-tures from this assumption, (i.e., specular reflection), withuse of the dichromatic reflection model.13 In this modelthe light reflected from a surface can be regarded as beingmade up of two components, the body and the surface re-flections. This allows us to rewrite Eq. (3) as

CI 5 GIE SI~l!E~l, T !dl

1 GIsE SI~l!rs~l!E~l, T !dl (19)

or

CI 5 GIE SI~l!Fr~l! 1GIs

GIrs~l!GE~l, T !dl, (20)

where GIs is similar to GI but varies with the photometricangles in a different way, and rs is the surface reflectivity.r is now regarded as the body reflectivity and accounts forthe reflection in our original model. If we incorporate theneutral interface reflection assumption,16 then the spec-tral composition of the surface reflection component cor-responds to that of the light source; i.e., the surface reflec-tivity rs is independent of wavelength. Then Eq. (20) canbe rewritten as

CI 5 GIE SI~l!@r~l! 1 r#E~l, T !dl. (21)

Thus specularity can be incorporated into the deriva-tion of the invariant in Subsection 2.D by replacing r(l)with r(l) 1 r, where r 5 0 for matte reflection (photo-metric angles such that GIsrs /GI ! r) and r 5 ` for com-plete specular reflection (GIsrs /GI @ r). If the deriva-tion is repeated with this modification, it will be foundthat Fl is still invariant to changes in T. As the degreeof specularity changes, Fl changes from its previous spec-trum (r 5 0) to the spectrum that occurs with a surfacewhose reflectivity is independent of wavelength (r 5 `).Such a surface is approximated by the barium sulfateblock.

To investigate the effect of specularity, in particularwhether Fl changes in an orderly way with specularity,we calculated Fl using the reflectivity of the yellow sur-

Fig. 6. Simulation of spectra from the yellow surface as theamount of specular reflection is changed. Dotted curve, nospecular reflection; heavy solid curve, complete specular reflec-tion; light curves, intermediate values.

848 J. Opt. Soc. Am. A/Vol. 19, No. 5 /May 2002 J. A. Marchant and C. M. Onyango

face derived as in Subsection 4.B and replacing r(l) withr(l) 1 r. Figure 6 is plotted with values of r of 0.0, 0.05,0.1, 0.2, 0.4, 0.8, 1.6, and a very large value, 107. It canbe seen that the spectrum changes smoothly between theextremes. It should be noted how similar the calculatedspectra are at the extremes to the experimental ones forthe barium sulfate block and the yellow surface [Fig. 3(b),rows 1 and 6] even though the first-eigenvector approxi-mation to CIE daylight has been used in the calculation.

5. CONCLUSIONSWe have developed a method for calculating invariantspectra of light reflected from surfaces, which requires ameasurement from a single location.

The resulting spectra are theoretically independent ofdaylight variations, provided that the daylight can be rep-resented in the form E(l, T) 5 h(l)exp@u(l)f(T)#, wherel is wavelength, T is the color temperature, h(l) andu(l) are any functions of l but not T, and f (T) is anyfunction of T but not l. CIE daylight can be representedvery closely by a function of this form.

Measurements taken over a wide range of daylight con-ditions for 21 colored surfaces show that the invarianttransformation used on real data reduces the variation ofthe reflected light spectra significantly. On the otherhand, the differences between the spectra from each sur-face, as measured by the pairwise differences in spectralangles, is hardly reduced. This shows that the ability todistinguish between surfaces by using their reflected lightspectra will be little affected.

We have investigated the possible causes of the re-sidual variation and conclude that using the above ap-proximation to daylight is unlikely to be a major cause.Some variation is caused by local daylight conditions be-ing different from the CIE standard, and the rest iscaused by measurement and modeling errors.

We have assumed that the surfaces reflect in a matteway. Calculations with the dichromatic reflection modelshow that the transformation still leads to spectra thatare invariant to daylight changes if we allow specular re-flection, although they do vary with the degree of specu-larity. As the degree of specularity is increased, thetransformed spectra change in a smooth way from thematte version toward a version appropriate to a surfacewhose reflectivity is independent of wavelength.

ACKNOWLEDGMENTThis work was funded in the United Kingdom by the Bio-technology and Biological Sciences Research Council.

Author contact: [email protected].

REFERENCES1. E. Vrindts and J. de Baerdemaeker, ‘‘Optical discrimination

of crop, weed and soil for on-line weed detection,’’ in Pro-ceedings of the First European Conference on Precision Ag-riculture (Bios Scientific, Oxford, UK, 1997), Vol. 2, pp.537–544.

2. B. J. Erickson, C. J. Johannsen, and J. J. Vorst, ‘‘Using re-mote sensing to quantify weather-induced crop damage,’’Aspects Appl. Biol. 60, 131–138 (2000).

3. B. V. Funt and G. D. Finlayson, ‘‘Color constant color index-ing,’’ IEEE Trans. Pattern Anal. Mach. Intell. 17, 522–529(1995).

4. S. K. Nayar and R. Bolle, ‘‘Computing reflectance ratiosfrom an image,’’ Pattern Recogn. 26, 1529–1542 (1993).

5. G. Healey and D. Slater, ‘‘Global color constancy: recogni-tion of objects by use of illumination-invariant properties ofcolor distributions,’’ J. Opt. Soc. Am. A 11, 3003–3010(1994).

6. T. Gevers, H. M. G. Stokman, and J. van de Weijer, ‘‘Colorconstancy from hyper-spectral data,’’ in Proceedings of theBritish Machine Vision Conference (British Machine VisionAssociation, Malvern, UK, 2000), Vol. 1, pp. 292–301.

7. G. Healey and D. Slater, ‘‘Models and methods for auto-mated material identification,’’ IEEE Trans. Geosci. RemoteSens. 37, 2706–2717 (1999).

8. J. A. Marchant and C. M. Onyango, ‘‘Shadow-invariantclassification for scenes illuminated by daylight,’’ J. Opt.Soc. Am. A 17, 1952–1961 (2000).

9. G. D. Finlayson and S. D. Hordley, ‘‘Color constancy at apixel,’’ J. Opt. Soc. Am. A 18, 253–265 (2001).

10. G. Wyszecki and W. S. Stiles, Color Science: Concepts andMethods, Quantitative Data and Formulae, 2nd ed. (Wiley,New York, 1982).

11. J. A. Marchant and C. M. Onyango, ‘‘A colour invariant fordaylight changes: relaxing the constraints on illumi-nants,’’ J. Opt. Soc. Am. A 18, 2704–2706 (2001).

12. S. Tominaga and B. A. Wandell, ‘‘Standard surface-reflectance model and illuminant estimation,’’ J. Opt. Soc.Am. A 6, 576–584 (1989).

13. S. A. Shafer, ‘‘Using color to separate reflection compo-nents,’’ Color Res. Appl. 10, 210–218 (1985).

14. ‘‘Colorimetry,’’ Tech. Rep., 2nd ed. (Commission Internatio-nale de L’Eclairage, Paris, 1986).

15. D. B. Judd, D. L. MacAdam, and G. W. Wyszecki, ‘‘Spectraldistribution of typical daylight as a function of correlatedcolor temperature,’’ J. Opt. Soc. Am. 54, 1031–1040 (1964).

16. H.-C. Lee, E. J. Breneman, and C. P. Schulte, ‘‘Modelinglight reflection for color computer vision,’’ IEEE Trans. Pat-tern Anal. Mach. Intell. 12, 402–409 (1990).