Image Definition and point operation g p p WHAT IS AN IMAGE? - - PowerPoint PPT Presentation

image definition and point operation g p p what is an
SMART_READER_LITE
LIVE PREVIEW

Image Definition and point operation g p p WHAT IS AN IMAGE? - - PowerPoint PPT Presentation

VIDEO SIGNALS VIDEO SIGNALS Image Definition and point operation g p p WHAT IS AN IMAGE? WHAT IS AN IMAGE? Ideally, we think of an image Id ll hi k f i i mage as a 2-di 2 di di dimens mensiona i onal l li l li li h light


slide-1
SLIDE 1

VIDEO SIGNALS VIDEO SIGNALS

Image Definition and point operation g p p

slide-2
SLIDE 2

WHAT IS AN IMAGE? WHAT IS AN IMAGE?

Id ll hi k f i i 2 di di i l li li h

 Ideally, we think of an image

mage as a 2-di dimens mensiona

  • nal

l li light int intensity function ity function, f(x,y), where x and y are spatial coordinates, and f at (x,y) is related to the brightness or , ( ,y) g color of the image at that point.

 In practice, most images are defined over a rectangle.

C ti i lit d ( ti t “)

 Continuous in amplitude („continuous-tone“)  Continuous in space: no pixels!

slide-3
SLIDE 3

DIGITAL IMAGES AND PIXELS DIGITAL IMAGES AND PIXELS

A digit digit l i i g i i th th t ti f f ti ti

 A digit

digital i l ima mage i is th the represen representati tion

  • n of

f a con conti tinuous nuous image image f(x,y) by a 2-d array of discrete samples. The amplitude of each sample is quantized to be amplitude of each sample is quantized to be represented by a finite number of bits.

 Each element of the 2-d array of samples is called a  Each element of the 2 d array of samples is called a

pix pixel l or pel pel (fr from “picture element”)

  • m “picture element”)

 Pixels are point samples, without extent.

p p ,

 A pixel is not:

 Round, square, or rectangular

  • u d, squa e, o

ecta gu a

 An element of an image sensor  m An element of a display

slide-4
SLIDE 4

A DIGITAL IMAGE IS REPRESENTED BY NUMBERS A DIGITAL IMAGE IS REPRESENTED BY NUMBERS

slide-5
SLIDE 5

AN IMAGE CAN BE REPRESENTED AS A MATRIX AN IMAGE CAN BE REPRESENTED AS A MATRIX

Th i l l f( ) t d i t th t i i t l“

 The pixel values f(x,y) are sorted into the matrix in „natural“

  • rder, with x corresponding to the column and y to the row

index index.

 Matlab, instead, uses matrix convention. This results in f(x,y) =

fyx, where fyx denotes an individual element in common matrix fyx, where fyx denotes an individual element in common matrix notation.

 For a color image, f

f might be one of the components. g g p

slide-6
SLIDE 6

IMAGE SIZE AND RESOLUTION IMAGE SIZE AND RESOLUTION

 These images were produced by simply picking

every n-th sample horizontally and vertically y p y y and replicating that value nxn times.

 We can do better

 prefiltering before subsampling to avoid aliasing  Smooth interpolation

slide-7
SLIDE 7

IMAGE OF DIFFERENT SIZE IMAGE OF DIFFERENT SIZE

slide-8
SLIDE 8

FEWER PIXELS MEAN LOWER SPATIAL RESOLUTION

slide-9
SLIDE 9

COLOR COMPONENTS COLOR COMPONENTS

slide-10
SLIDE 10

DIFFERENT NUMBERS OF GRAY LEVELS DIFFERENT NUMBERS OF GRAY LEVELS

slide-11
SLIDE 11

HOW MANY GRAY LEVELS ARE REQUIRED? HOW MANY GRAY LEVELS ARE REQUIRED?

?

 How many gray levels are required?  Digital images typically are quantized to 256 gray

levels.

slide-12
SLIDE 12

STORAGE REQUIREMENTS FOR DIGITAL IMAGES STORAGE REQUIREMENTS FOR DIGITAL IMAGES

 Image LxN pixels 2B gray levels c color  Image LxN pixels, 2B gray levels, c color

components Size = LxNxBxc Size = LxNxBxc

 Example: L=N=512 B=8 c=1 (i e monochrome) Size  Example: L=N=512, B=8, c=1 (i.e., monochrome) Size

= 2,097,152 bits (or 256 kByte)

 Example: LxN=1024x1280, B=8, c=3 (24 bit RGB

p 0, , ( image) Size = 31,457,280 bits (or 3.75 MByte)

 Much less with (lossy) compression!  For a video multiply by the frame rate and by the

number of seconds of its lenght.

slide-13
SLIDE 13

BRIGHTNESS DISCRIMINATION EXPERIMENT BRIGHTNESS DISCRIMINATION EXPERIMENT

C h i l ?

 Can you see the circle?  Visibility threshold

slide-14
SLIDE 14

CONTRAST WITH 8 BIT CONTRAST WITH 8 BITS A ACCORDING T CCORDING TO WEBER WEBER‘S LA S LAW CONTRAST WITH 8 BIT CONTRAST WITH 8 BITS A ACCORDING T CCORDING TO WEBER WEBER S LA LAW

A th t th l i diff b t t i

 Assume that the luminance difference between two successive

representative levels is just at visibility threshold

 For  Typical display contrast

 Cathode ray tube 100:1  Cathode ray tube 100:1 

Print on paper 10:1

 Suggests uniform quantization in the log(I) domain

slide-15
SLIDE 15

MOST COMMON POINT OPERATIONS ON IMAGES MOST COMMON POINT OPERATIONS ON IMAGES

 Intensity scaling  Brightness/Contrast adjustment

Brightness/Contrast adjustment

 Gamma adjustment  Histogram equalization  Image averaging  Image averaging  High-dynamic range from multiple exposures  Image subtraction

slide-16
SLIDE 16

HISTOGRAMS HISTOGRAMS

 Distribution of gray levels can be judged by measuring a histogram:  Distribution of gray-levels can be judged by measuring a histogram:

 For B-bit image, initialize 2B counters with 0  Loop over all pixels x,y

 When encountering gray level f(x,y)=i, increment counter #i 

Histogram can be interpreted as an estimate of the probability density function (pdf) of an underlying random process.

 You can also use fewer, larger bins to trade off amplitude resolution

against sample size.

slide-17
SLIDE 17

EXAMPLE HISTOGRAM EXAMPLE HISTOGRAM

slide-18
SLIDE 18

EXAMPLE HISTOGRAM EXAMPLE HISTOGRAM

slide-19
SLIDE 19

HISTOGRAM COMPARISON HISTOGRAM COMPARISON

 Both these images present the same

Histogram

slide-20
SLIDE 20

HISTOGRAM COMPARISON HISTOGRAM COMPARISON

 Histogram as an invariant feature

slide-21
SLIDE 21

HISTOGRAM COMPARISON HISTOGRAM COMPARISON

slide-22
SLIDE 22

HISTOGRAM EQUALIZATION HISTOGRAM EQUALIZATION

 Idea: find a non linear transformation  Idea: find a non-linear transformation

g g = = T(f) to be applied to each pixel of the input image f(x,y) f(x,y), such that a if di t ib ti f l l i th ti lt f th uniform distribution of gray levels in the entire range results for the

  • utput image g(x,y).

g(x,y).

 Analyze ideal, continuous case first, assuming

0 ≤ f f ≤1 1 0 ≤ g g ≤1

 T(f)

T(f) is strictly monotonically increasing, hence, there exists f = T f = T −1(g) (g) 0 ≤ g g ≤1

 Goal: pdf (probability density function) pg(g)

(g) = cons

  • const. over the range

 Goal: pdf (probability density function) pg(g)

(g) cons

  • const. over the range
slide-23
SLIDE 23

HISTOGRAM EQUALIZATION FOR CONTINUOUS CASE CONTINUOUS CASE

 From basic probability theory  Consider the transformation function  Then

slide-24
SLIDE 24

HISTOGRAM EQUALIZATION FOR CONTINUOUS CASE

slide-25
SLIDE 25

HISTOGRAM EQUALIZATION FOR DISCRETE CASE

 Now, f only assumes discrete amplitude values f0, f1, …,fL-1,

with probabilities:

 Discrete approximation of

 The resulting values gk are in the range [0,1] and need to be scaled and

rounded appropriately rounded appropriately

slide-26
SLIDE 26

HISTOGRAM EQUALIZATION EXAMPLE HISTOGRAM EQUALIZATION EXAMPLE

slide-27
SLIDE 27

HISTOGRAM EQUALIZATION EXAMPLE HISTOGRAM EQUALIZATION EXAMPLE

slide-28
SLIDE 28

HISTOGRAM EQUALIZATION EXAMPLE HISTOGRAM EQUALIZATION EXAMPLE

slide-29
SLIDE 29

HISTOGRAM EQUALIZATION EXAMPLE HISTOGRAM EQUALIZATION EXAMPLE

slide-30
SLIDE 30

ADAPTIVE HISTOGRAM EQUALIZATION ADAPTIVE HISTOGRAM EQUALIZATION

 Apply histogram equalization based on a

histogram obtained from a portion of the image

 Must limit contrast expansion in flat regions of

the image, e.g. by clipping individual histogram the image, e.g. by clipping individual histogram values to a maximum

slide-31
SLIDE 31

ADAPTIVE HISTOGRAM EQUALIZATION ADAPTIVE HISTOGRAM EQUALIZATION

slide-32
SLIDE 32

ADAPTIVE HISTOGRAM EQUALIZATION ADAPTIVE HISTOGRAM EQUALIZATION

slide-33
SLIDE 33

POINT OPERATIONS BETWEEN IMAGES POINT OPERATIONS BETWEEN IMAGES

 Image averaging for noise reduction  Combination of different exposure for high-

Combination of different exposure for high dynamic range imaging I g bt ti f h g d t ti

 Image subtraction for change detection  Accurat

ccurate ali alignment is nment is alw always a s a re requirement uirement g y g y q

slide-34
SLIDE 34

IMAGE AVERAGING FOR NOISE REDUCTION IMAGE AVERAGING FOR NOISE REDUCTION

slide-35
SLIDE 35

IMAGE AVERAGING FOR NOISE REDUCTION IMAGE AVERAGING FOR NOISE REDUCTION

T k N li d i

 Take N aligned images

A I

 Average Image:  Mean squared error vs. noise-free image g

slide-36
SLIDE 36

HIGH DYNAMIC RANGE IMAGING HIGH-DYNAMIC RANGE IMAGING

 16 exposures, one f-stop (2X) apart

slide-37
SLIDE 37

IMAGE SUBTRACTION IMAGE SUBTRACTION

 Find differences/changes

Find differences/changes between 2 mostly identical images f C

 Example from IC

manufacturing: defect detection in photomasks detection in photomasks by die-to-die comparison

slide-38
SLIDE 38

WHERE IS THE DEFECT? WHERE IS THE DEFECT?

 Image A without defect

Image B with defect

slide-39
SLIDE 39

ABSOLUTE DIFFERENCE BETWEEN TWO IMAGES ABSOLUTE DIFFERENCE BETWEEN TWO IMAGES

 Without alignment

With Alignment

slide-40
SLIDE 40

DIGITAL SUBTRACTION ANGIOGRAPHY DIGITAL SUBTRACTION ANGIOGRAPHY