(Digital bildbehandling grundkurs). M i M ... 7 and quantization. Continuous.
Image. Line from image. After quantization. After ... ent contrast windows e ls n.
p. 1
Digital Image Processing (Digital bildbehandling grundkurs)
Digital Image Processing Lecture 1
Properties of the digital image The digital image sensor and image acquisition Sampling and quantization Spatial and Intensity resolution The electromagnetic spectrum, imaging and examples of images from different sources Gray scale and color images Color maps The eye and two visual phenomena Application examples
Gonzales & Woods:
Maria Magnusson, Computer Vision Laboratory, CVL Department of Electrical Engineering (EE) Linköping University
Maria Magnusson, Avdelningen för Datorseende Institutionen för Systemteknik (ISY) Tekniska Högskolan Linköpings Universitet
A continuous image is 2D function
1D: f(t) is a function f that depends on the time t. 2D: f(x,y) is a function f that depends on the spatial (room) coordinates x and y.
Ex)
f x, y sin x y 1 f x, y 0 black
f x, y 2 white
p. 2
Chapter 1: pp. 1-34 (Paperback 2013: Add 22 to the page numbers) Chapter 2: pp. 35-64 (Paperback 2013: Add 22 to the page numbers) Extra
Maria Magnusson, Computer Vision Lab., Dept. of Electrical Engineering, Linköping University
p. 3
An example of a digital image pixel = picture element
zoom
Original image size: 720x240 pixels
p. 4
p. 5
The digital image sensor
p. 6
The digital image acquisition process
Single sensor element:
Line sensor:
Array sensor:
typically a camera
Fig. 2.12
p. 7
Continuous Image
Line from image
After sampling
After quantization Fig. 2.16
The digital image sensor
For a color image, there are 3 different types of sensor elements: red, green and blue
p. 8
Senseorelement
Image sampling and quantization
Fig. 2.15
A continuous image projected onto the sensor array
Result after sampling and quantization
Fig. 2.17
p. 9
Representation of a digital image
p. 10
Saturation and noise Saturation is the highest value beyond which all intensity levels are clipped.
3D surface plot
Noise appears often as a grainy texture. Intensity image
Numerical matrix
Fig. 2.18
p. 11
Spatial resolution
Spatial resolution is a measure of the smallest discernible detail in the image. Two common measures: lp/mm, dpi
5 discernible line pairs (lp) per mm, 5 lp/mm
Newspaper: 75 dpi Magazine: 133 dpi Glossy brochures: 175 dpi Gonzalez & Woods:2400 dpi
6 dots per inch, 6 dpi
1 inch 0.1 mm 1 mm
Fig. 2.19
Spatial resolution
p. 12
1250 dpi 3692 x 2812 pixels
300 dpi 886 x 675 pixels
150 dpi 443 x 337 pixels
72 dpi 213 x 162 pixels
A newspaper image 6 pixels
Fig. 4.22
Fig. 2.20
p. 13
Intensity resolution 28 intensity levels
Fig. 2.21
24
23
212 intensity levels
27
p. 14
The same CT image, shown in 2 different contrast windows
26
22
25
21
p. 15
The electromagnetic spectrum
Intensity resolution
26=64
We can only resolve (or intensity levels on an ordinary computer screen. Based on hardware considerations, gray scale images are usually stored with 8 bits per pixels, i.e. 28=256 intensity levels. Some images are stored with more than 8 bits per pixels. CT images, for example, are stored with 12 bits per pixels, i.e. 212=4096 intensity levels. During calculation and image processing, pixels can preferably be stored with more than 8 bits or floating point numbers. Special hardware utilized for fast calculation sometimes store a pixel with less than 8 bits. Color images are usually stored with 3x8 bits per pixels, 28 red intensity levels, 28 green intensity levels and 28 blue intensity levels giving 224 = 16 million different colors.
micro waves
p. 16
radio waves
27=128?)
Visible light
Common Cameras Se also Fig. 2.10 blue: around 0.445mm , green: around 0.535mm, red: around 0.575mm IR: 8-14 mm Thermal bands in NASA’s LANDSAT satellite 1. Visible blue, 0.45-0.52mm. Maximum water penetration. 2. Visible green, 0.52-0.60mm. Good for measuring plant vigor. 3. Visible red, 0.63-0.69mm. Vegetation discrimination. 4. Near infrared, 0.76-0.90mm. Biomass and shoreline mapping. 5. Middle infrared, 1.55-1.75mm. Moisture content of soil & vegetation. 6. Thermal infrared, 10.4-12.5mm. Soil moisture; thermal mapping. 7. Middle infrared 2.08-2.35mm. Mineral mapping.
p. 17
Images from NASA’s LANDSAT satellite Fig. 1.10
Imaging – the creation of images Examples of different sources
Electromagnetic radiation
6. Thermal infrared
4. Near infrared
1. Visible blue
2. Visible green
3. Visible red
p. 19
Image Reconstruction:
To compute an image from the in-signal. Ex: Computed Tomography (CT). X-ray Source
Curved detector with projection data
Patient Rotation
Reconstruction algorithm (mathematics) Reconstructed image
p. 18
Transmitted gamma-rays, fig. 1.6a Transmitted and reconstructed gamma-rays, Single Photon Emission Tomography, SPECT Emitted and reconstructed gamma-rays, Positron Emission Tomography, PET, fig. 1.6b, slide 28 Transmitted X-rays, fig 1.7a,b Transmitted and reconstructed X-rays, Computed Tomography, fig. 1.7c, slide 14, 19 Excitation rays from ultraviolet light, fluorescence microscopy, fig. 1.8a,b Reflected rays from visible light, slide 4, 10, 12, 23 Reflected infrared rays, slide 17, Emitted radio waves + magnetic fields and reconstruction => magnetic resonance imaging (MRI), fig 1.17
Ultrasound
Transmitted and reflected ultrasound, fig 1.20
Examples of different images from different sources
p. 20
Fig. 1.6a
Fig. 1.6b
Transmitted gammarays
PET
Examples of different images from different sources Fig. 1.7ab
p. 21
Examples of different images from different sources
p. 22
Fig. 1.8ab
Transmitted X-rays
Fluorescence microscopy
Fig. 1.17 MRI
Fig. 1.20ab Transmitted and reflected ultrasound
Gray scale image compared to true color image Matlab : Colim zeros(450, 600,3); Colim(:, :,1) R; Colim(:, ; ,2) G; Colim(:, :,3) B; True color image: Colim
p. 23
Landsat’s images combined to color images
p. 24
Fig. 6.27
Fig. 2.38 B G R Gray scale image: Grayim
Grayim 0.2989 R 0.5870 G 0.1140 B; Grayim rgb2gray(Colim);
3, 2, 1 = R,G,B combined to color image
4, 2, 1 = R,G,B combined to pseudo-color image
p. 25
Color maps
Sometimes, the pixels are quantified to the interval [0,255]. These values are transformed through a color map in the computer to
Gray scale values, i.e. 0->black and 255->white or Arbitrary colors (pseudo colors)
Sometimes, the pixels are floating point values. These values are transformed to the interval [0,255] and further through a color map in the computer. A true color image has 3 values per pixel. These values are transformed individually through 3 color maps in the computer and further to the red, green and blue channel of the screen.
True Color map Pixel value [fr(x,y),fg(x,y),fb(x,y)]
Normal gray scale color map
Linear transformation
0: 1: 2:
255:
255
To D/A-converter and further to the red channel of the screen.
Linear transformation
0: 1: 2:
255:
G 0 1 2
255
To D/A-converter and further to the green channel of the screen.
Linear transformation
256 colors
Pixel value f(x,y) 0: 1: 2:
Linear transformation
A D/A-converter converts a digital value to an analog value, an electrical voltage.
255:
R 0 1 2
G 0 1 2
B 0 1 2
255
255
255
To D/A-converter and further to the screen.
p. 27
Over 16 million colors
p. 28
256 colors
Pseudo-color map Pixel value f(x,y)
R 0 1 2
p. 26
0: 1: 2:
255:
B 0 1 2
255
To D/A-converter and further to the blue channel of the screen.
Linear transformation
R
G
B
?
?
?
0: 1: 2:
255: To D/A-converter and further to the screen.
Ex) A PET-image shows where it is activity in the brain. High activity is shown red and low activity is shown blue.
p. 29
Additive color mixing.
CRT LCD plasma
Basically, the eye works rather much like a camera… Reflected light from the palm tree
yellow red green
Lens
p. 30
The retina is the sensor
cyan green blue magenta red blue Lab 5 Lecture 11: More on color
Focal length
But the brain performs some more processing that gives rise to visual phenomena…
Fig. 6.4
Visual phenomenon 1: The Mach band effect
p. 31
Fig. 2.3
Visual phenomenon 2: Simultaneous contrast
p. 32
All the inner squares have the same intensity, but they appear progressively darker as the background becomes brighter, which are seen when the red frames are removed.
Gray scale Image:
Actual intensity:
Perceived intensity: Fig. 2.7
Fig. 2.8
p. 33
Application examples: Automated visual inspection of manufactured goods
p. 34
Some more application examples Paper currency
Finger print Controller board
Pill container
Bottles filling level
Automated license plate reading
Air pockets in plastic
Fig. 1.15
Fig. 1.14
The book and the course Multidimensional Signal Analysis TSBB06 included partly included not included Image sensors TSBB09
Image and Audio Coding TSBK02
p. 35
Fig. 1.23
Reconstruction
p. 36
Question for G f g t g t e j 2p f t dt next lecture: What is negative frequency in the Fourier transform?
1. sin(−2pu) is an example of a signal with negative frequency. 2.− sin(2pu) is an example of a signal with negative frequency. 3. The frequencies in the Fourier transform have no relation to real frequencies. 4. …