Spectral Transforms Spectral Transforms

25
1 ECE/OPTI 531 – Image Processing Lab for Remote Sensing Fall 2005 Spectral Transforms Reading: Chapter 5 Fall 2005 Spectral Transforms 2 Spectral Transforms Feature Spaces Spectral Band Ratios and VIs Principal and Tasseled-Cap Components Contrast Enhancement

Transcript of Spectral Transforms Spectral Transforms

Page 1: Spectral Transforms Spectral Transforms

1

ECE/OPTI 531 – Image Processing Lab for Remote Sensing Fall 2005

Spectral Transforms

Reading: Chapter 5

Fall 2005Spectral Transforms 2

Spectral Transforms

• Feature Spaces• Spectral Band Ratios and VIs• Principal and Tasseled-Cap Components• Contrast Enhancement

Page 2: Spectral Transforms Spectral Transforms

2

Fall 2005Spectral Transforms 3

Multispectral Data Spaces

• Three “spaces” associated with multispectralimages:– image space – the DNb(x,y) space, i.e. an “image” in

band b– spectral (data) space – the DN = (DN1, DN2, . . ., DNK)

vector space– feature space – derived from the image or spectral

space

Fall 2005Spectral Transforms 4

Feature Spaces

• Good features reduce effects that hinder theextraction of information

• Nonlinear spectral transform

– multispectral ratios are one example• Linear spectral transform

– corresponds to a coordinate rotation of the DN space tothe DN´ space

– principal components transform is an example

Page 3: Spectral Transforms Spectral Transforms

3

Fall 2005Spectral Transforms 5

Spectral Transforms

• Feature Spaces• Spectral Band Ratios and VIs• Principal and Tasseled-Cap Components• Contrast Enhancement

Fall 2005Spectral Transforms 6

Simple Ratio:

Modulation Ratio:

Spectral Band Ratios

• Benefits– reduce topographic shading– emphasize spectral differences– correlate with geophysical variables

• Multispectral ratios

Page 4: Spectral Transforms Spectral Transforms

4

Fall 2005Spectral Transforms 7

Calibrated Spectral Ratios

• Simple physical model for radiometriccalibration

• Band-specific gain factor includes– sensor gain– solar spectral irradiance– atmospheric transmittance (2-way)

• is the solar irradiance projectionfactor due to surface topography (Chapter 2)

• Band-specific bias includes– atmospheric path radiance– sensor offset

Fall 2005Spectral Transforms 8

Calibrated Ratios (cont.)

• Partially-calibrated data– estimate DN offset and subtract

– topographic shading due to goes awaybecause it is the same in every band

• Fully-calibrated data– proportionality constant also goes away

Page 5: Spectral Transforms Spectral Transforms

5

Fall 2005Spectral Transforms 9

Partial Calibration

TM1 uncalibrated DN1 TM2 uncalibrated DN2

DN1 – b1 DN2 – b2

Fall 2005Spectral Transforms 10

Shading Reduction

DN band ratio TM2/TM1

DN offset bk removed before ratio

topographic

shading reduced

by bk removal

retainstopographic

shading

Suppression of topographic shading by partial calibration

Page 6: Spectral Transforms Spectral Transforms

6

Fall 2005Spectral Transforms 11

Geologic Discrimination

TM7/TM5 (uncalibrated)

TM5/TM4 (uncalibrated)partial

calibration

less important

in NIR and SWIR

Ratios for geologic discrimination in the SWIR

Fall 2005Spectral Transforms 12

Vegetation Indices

• All VIs defined in terms of reflectance, not DN• VIs therefore require scene calibrated data

• Soil-Adjusted Vegetation Index (Huete)

– L is an empirical constant, typically about 0.5– reduces to NDVI for L = 0– superior to NDVI for low vegetation cover

Ratio Vegetation Index:

Normalized Difference Vegetation Index:

Page 7: Spectral Transforms Spectral Transforms

7

Fall 2005Spectral Transforms 13

VI Interpretation

RVI NDVI

CIRcomposite

crops

wet soil

dry soil(Landsat TM) !red

!NIRRVI = 3 2 1

NDVI = 0.5 0.33 0

NDVI correlates better withvegetation density than does RVI

Fall 2005Spectral Transforms 14

Spectral Transforms

• Feature Spaces• Spectral Band Ratios and VIs• Principal and Tasseled-Cap Components• Contrast Enhancement

Page 8: Spectral Transforms Spectral Transforms

8

Fall 2005Spectral Transforms 15

Principal Components

• Principal Components Transform (PCT) is a linearmatrix transform

– Principal Component (PC) vector is K-dimensional, justlike DN vector

– Each PCk is a weighted sum of all spectral bands;weights are the rows of K×K WPC matrix

– Also known as the Karhonen-Loeve Transformation (KLT)and the Hotelling transformation

Fall 2005Spectral Transforms 16

PCT Properties

• Covariance matrix of PC bands CPC is related to originalcovariance matrix C by,

– By matrix properties, WPC diagonalizes C, i.e. CPC is a diagonalmatrix

– Since CPC is diagonal, the PC bands are uncorrelated• Diagonal elements of CPC are the data eigenvalues

– Each eigenvalue λk is equal to the variance of thecorresponding PCk

– The total data variance is preserved,

Page 9: Spectral Transforms Spectral Transforms

9

Fall 2005Spectral Transforms 17

PCT Calculation

• The rows of WPC are the eigenvectors of the data,

– Each eigenvector ek contains the weights applied to theoriginal bands to obtain PCk and is found by solving theequation,

– Eigenvalues are found by solving the characteristicequation

Fall 2005Spectral Transforms 18

• Original data in DN-space

0

1

2

3

4

5

0 1 2 3 4 5

DN2

DN1

556455344433322221DN2DN1Pixel

PCT Example

Page 10: Spectral Transforms Spectral Transforms

10

Fall 2005Spectral Transforms 19

PCT Example (cont.)

• Step 1. Find eigenvalues– Solve the characteristic equation (two solutions)

– Therefore,

– Note that PC1 contains 89% of the total data variance,and PC2 contains 11%, i.e.

Fall 2005Spectral Transforms 20

PCT Example (cont.)

• Step 2. Find eigenvectors– Substitute eigenvalues into

• First eigenvalue yields dependent equations

• Solving either equation

• PCT requires orthonormality of the eigenvectors

– Solve simultaneous equations to yield eigenvectors, andthe PCT weight matrix

Page 11: Spectral Transforms Spectral Transforms

11

Fall 2005Spectral Transforms 21

PCT Example (cont.)

• Step 3. Transform DN data to PC-space– For Pixel 1:

– Final PC data and scatterplot

1.256.9560.436.3850.184.9941.574.7431.323.3520.502.781

PC2PC1Pixel

0

1

2

2 3 4 5 6 7

PC2

PC1

Fall 2005Spectral Transforms 22

PCT Benefits

• Why use the PCT?– Decorrelates spectral data

• Multispectral bands areoften highly-correlatedbecause of

– material spectralcorrelation

– topography– sensor band overlap

• Decorrelation separatesindependent componentsinto separate “bands”

– Compresses the variance

• Compression canpotentially reduce datacomputation burden

DN1

PC1

PC2

DN2

DN3

DN4

PC1

PC2

0

200

400

600

800

1 2 3 4 5 6

TM bands

PC bands

DN

vari

ance

band or PC index

Correlated

Uncorrelated

Page 12: Spectral Transforms Spectral Transforms

12

Fall 2005Spectral Transforms 23

TM1 TM2 TM3

TM4 TM5 TM7

PC1 PC2 PC3

PC4 PC5 PC6

PCT Decorrelation

• Non-vegetated scene– PCT removes spectral redundancy

Fall 2005Spectral Transforms 24

PCT Contrast Extraction

• Vegetated scene– PCT extracts contrast between bands 3 and 4 (red and

NIR) due to the vegetation “red edge”

TM1 TM2 TM3

TM4 TM5 TM7

PC1 PC2 PC3

PC4 PC5 PC6

Page 13: Spectral Transforms Spectral Transforms

13

Fall 2005Spectral Transforms 25

PCT Noise Detection

• PCT can isolate spectrally-uncorrelated noise

TM2 TM3 TM4

PC1 PC2 PC3

Fall 2005Spectral Transforms 26

PCT Drawbacks

• Why not use the PCT?– It is data-dependent

• W coefficients change from scene-to-scene• Makes consistent interpretation of PC images difficult

– Spectral details, particularly in small areas, may be lostif higher-order PCs are ignored

– Computationally expensive for large images or formany spectral bands

• Calculation of covariance matrix is the culprit

Page 14: Spectral Transforms Spectral Transforms

14

Fall 2005Spectral Transforms 27

Tasseled-Cap Components

• Linear spectraltransform like the PCT

• In this case, the WTCmatrix is fixed for agiven sensor

Tasseled-cap components for MSS and TM

Fall 2005Spectral Transforms 28

TCT Benefits

• Why use the TCT?– It is a fixed reference

• Same reference for everyimage from a given sensorpermits consistentinterpretation

– Components are related togeophysical properties ofthe scene

• First component is “soilbrightness”

• Second component is“greeness”

Brightness

Greeness

DN3

DN4PC2

PC1

TCT axes alignbetter with thesoil and vegetationdirections

Page 15: Spectral Transforms Spectral Transforms

15

Fall 2005Spectral Transforms 29

TCT Drawbacks

• Why not use the TCT?– Nonoptimal compression of data– Derivation of WTC requires multitemporal data for each

sensor

PC1 PC2 PC3

PC4 PC5 PC6

TC1 TC2 TC3

TC4 TC5 TC6

Comparison of PC and TC images

Fall 2005Spectral Transforms 30

Spectral Transforms

• Feature Spaces• Spectral Band Ratios and VIs• Principal and Tasseled-Cap Components• Contrast Enhancement

Page 16: Spectral Transforms Spectral Transforms

16

Fall 2005Spectral Transforms 31

Contrast Enhancement

• Two problems– Most images do not fill the dynamic range of the sensor

– Most images also do not fill the dynamic range of the displaysystem

• Contrast enhancement means “stretching” the data rangeto fill the display system range GL = T(DN)– Parameters of transformation T based on global or local

image statistics

signal rangerequired at

A/D input for fullrange DN output

ab

eb

anticipated range

optional high gainb

offsetb

all scenes

standard gainb

of detected signals low radiance scenes

Fall 2005Spectral Transforms 32

Global Single-Band Transforms

• Linear stretch– min-max

• scale range of image DNs to range of display GLs• sensitive to outliers

– saturation• scale a smaller range of DNs to range of display GLs• saturation of 1–3% pixels at each end usually acceptable

• Nonlinear stretch– piecewise-linear

• different contrast “gain” over different DN ranges– histogram equalization

• use scaled CDF of original image as the transformation

Page 17: Spectral Transforms Spectral Transforms

17

Fall 2005Spectral Transforms 33

DN-to-GL Transformations

Fall 2005Spectral Transforms 34

Contrast Stretch Examples

original min-max

3% saturation 8% saturation

piecewise linear histogram equalization

0

1000

2000

3000

4000

5000

6000

7000

8000

num

ber

of

pix

els

DN

0 63 127 191 2550

1000

2000

3000

4000

5000

6000

7000

8000

num

ber

of

pix

els

DN

0 63 127 191 255

0

1000

2000

3000

4000

5000

6000

7000

8000

num

ber

of

pix

els

DN

0 63 127 191 2550

1000

2000

3000

4000

5000

6000

7000

8000

num

ber

of

pix

els

DN

0 63 127 191 255

0

20

40

60

80

100

120

140

160

num

ber

of

pix

els

DN

0 63 127 191 2550

1000

2000

3000

4000

5000

6000

7000

8000

num

ber

of

pix

els

DN

0 63 127 191 255

original min-max

3% saturation 8% saturation

piecewise linear histogram equalization

Application to GOES image of North America

Page 18: Spectral Transforms Spectral Transforms

18

Fall 2005Spectral Transforms 35

Normalization Stretch

• Linear scale of DN mean and sigma to specifiedvalues, followed by saturation

• Consistent behavior (robust) over wide range ofimages

original µ = 128, σ = 32

µ = 128, σ = 64µ = 128, σ = 48

Fall 2005Spectral Transforms 36

Reference Stretch

• Match the CDF of the image being processed to areference CDF, for example from another image– useful for

• multitemporal or multisensor radiance matching• matching image to reference contrast

DN

0

1

CDF

DNref

0

1

CDFref

Reference stretch is a double transformation

Page 19: Spectral Transforms Spectral Transforms

19

Fall 2005Spectral Transforms 37

Multitemporal Normalization

0 100

2 103

4 103

6 103

8 103

1 104

nu

mb

er

of

pix

els

DN0 12763

0 100

5 102

1 103

1.5 103

2 103

2.5 103

3 103

3.5 103

4 103

nu

mb

er

of

pix

els

DN0 12763

0 100

2 103

4 103

6 103

8 103

1 104

nu

mb

er

of

pix

els

DN0 12763

0 100

2 103

4 103

6 103

8 103

1 104

nu

mb

er

of

pix

els

DN0 12763

0

50

100

150

200

250

0 50 100 150 200 250

GL

DN

0

50

100

150

200

250

0 50 100 150 200 250

GL

DN

TM band 3, Dec 31, 1982 TM band 3, Aug 12, 1983

dark-light targetlinear stretch

CDF referencestretch

Reference

CDF reference stretch

dark-light linear stretch

Dec 31, 1982 Aug 12, 1983

Fall 2005Spectral Transforms 38

Thresholding

• Binary “clipping” of DNs to low and high values– Useful for

• segmentation of certain images, e.g. clouds/water,land/water

DNT = 50

DNT = 100 DNT = 150

Page 20: Spectral Transforms Spectral Transforms

20

Fall 2005Spectral Transforms 39

Formulas

Mathematical formulas for contrast enhancement techniques

Fall 2005Spectral Transforms 40

Color Images

• Techniques used for single-band imagery can beextended to color, but . . .– Sensitivity of the human vision system to shifts in color

and saturation require special attention• Min-max stretch

– Stretch the DNs in each band over their respective min-max range

– Good news:• Easy to calculate and implement• No data lost by saturation

– Bad news:• Sensitive to outlier DNs• Color balance can change unpredictably

Page 21: Spectral Transforms Spectral Transforms

21

Fall 2005Spectral Transforms 41

Color Normalization

• Normalization stretch– “Standardized” stretch– Good news:

• Average color is grey• Contrast controlled by

single parameter, thedesired outputstandard deviation

– Bad news:• Some data are lost in

saturation

Normalization Stretch

Linearly stretch each band to same DN mean ( typically 128) and same DN standard deviation (typically 32 – 48)

Clip to [0,255]

RGB RGB

linear stretchto µ, !

clip at [0,255]

linear stretchto µ, !

clip at [0,255]

linear stretchto µ, !

clip at [0,255]

Fall 2005Spectral Transforms 42

Color Decorrelation

• Decorrelation stretch– Enhance small spectral

deviations in highly-correlated spectralbands

– Commonly used ingeology

– Good news:• Decorrelates bands• Emphasizes differences

among bands• Can be applied to any

number of bands– Bad news:

• Produces highlysaturated colors

Decorrelation Stretch

PCT transform

Stretch each PC component to equalize variances

Inverse PCT transform

Clip to [0,255]

image data space PC space

PCT

PCT-1clip at [0,255]

equalizevariances

Page 22: Spectral Transforms Spectral Transforms

22

Fall 2005Spectral Transforms 43

Color Spaces

• HSI color coordinate system• Hexcone model

– similar to a cylindrical coordinatesystem, but based on RGB color cube

– value = max(R,G,B) used instead ofintensity

– efficient CST from RGB to Hue-Saturation-Value (HSV)

intensity

saturation

hue

I

S

H

whiteblack

P

red

yellow

green

cyan

blue

magenta

(255,0,0)

(0,255,0)

(0,0,255)

yellow

magenta

cyan

red

greenblue

black

white

GL3

GL2

GL1

project subcube faces onto orthogonal planeintersection at the vertex of subcube

cylindrical coordinates

Fall 2005Spectral Transforms 44

Color-Space Transforms

• Color-space transforms– Human vision system

perceives hue (H),saturation (S) andintensity (I), not RGB

– Therefore, control overcolor appearance is bestdone in HSI space

Color-Space Transform

Transform RGB to HSI

Modify HSI components as desired

Inverse transform modified HSI to RGB

Clip to [0,255]

RGB space HSI space

CST

CST-1clip at [0,255]

modify

Page 23: Spectral Transforms Spectral Transforms

23

Fall 2005Spectral Transforms 45

Example Ramp Spectrum CSTs

50% intensity

50% saturation

cycle hue

H S I

linear hue100% saturation100% intensity

100% intensity

linear hue

linear hue100% saturation

100% saturation100% intensity

RGB

Fall 2005Spectral Transforms 46

CST for Contrast Enhancement

• Intensity stretch– Good news:

• Improves contrastwithout changing hueor saturation

• Based on human visionsystem model

– Bad news:• Can be applied only to

color (3-band) images• Based on human vision

system model

Intensity Enhanced CST

Do CST

Stretch intensity component as desired

Inverse CST

Clip to [0,255]

Page 24: Spectral Transforms Spectral Transforms

24

Fall 2005Spectral Transforms 47

Color Contrast Enhancement

TM bands 3,2,1 TM bands 7,5,4

min-max stretch

normalization stretch

decorrelation stretch

Fall 2005Spectral Transforms 48

Examples (cont.)

original

histogram equalization stretch

min-max stretch

normalization stretch

HSI intensity stretch

decorrelation stretch

Page 25: Spectral Transforms Spectral Transforms

25

Fall 2005Spectral Transforms 49

3-D Scatterplots

original min-max

histogram equalized normalized

decorrelated HSI