Computer Graphics & Image Processing Chapter # 9 Morphological Image Processing
SCCS 4761 Introduction What is Image Processing? Fundamental of Image Processing.
-
Upload
blake-morton -
Category
Documents
-
view
237 -
download
0
Transcript of SCCS 4761 Introduction What is Image Processing? Fundamental of Image Processing.
SCCS 476 1
Introduction
• What is Image Processing?
• Fundamental of Image Processing
SCCS 476 2
Image & Image Processing
• Image and Pictures– An image is a single picture that represents
something
• What is image processing?– Interest in digital image processing methods stems
from two application areas: • Improvement of pictorial information for human interpretation• Processing of image data for storage, transmission, and
representation for autonomous machine perception
SCCS 476 3
Example 1: Contrast Enhancement
BEFORE AFTERGamma = 0.5
http://www.mathworks.com/access/helpdesk/help/toolbox/images/enhanc17.html
SCCS 476 4
Example 2: Sharpening
BEFORE AFTER
SCCS 476 5
Example 3: Denoising
BEFORE AFTER
http://www.mathworks.com/access/helpdesk/help/toolbox/images/enhan23b.html#14283
SCCS 476 6
Example 3: Edge Extraction
http://www.cee.hw.ac.uk/hipr/html/canny.html
SCCS 476 7
Example 4: Blurring
http://www.maths.abdn.ac.uk/~igc/tch/mx4002/notes/node99.html
SCCS 476 8
Example 5: Blurring & Sharpening
http://www.uwec.edu/walkerjs/DSP/sharpening_images.htm
SCCS 476 9
Example 6:Image Enhancement
SCCS 476 10
Example 6: Image Enhancement
SCCS 476 11
1.3 Image Acquisition and Sampling
t
A
How many points must be used to represent this curve?
At least at the rate of Nyquist rate (twice the maximum frequency in the function).
Sampling
SCCS 476 12
Undersampling• Definition: sampling signals with too few points
• Effects: aliasing (jagged edge in image)
SCCS 476 13
1.3.1 Using Light & Other Energy Sources • Light is the predominant energy source for images. • Digital images are captured using visible light, infrared,
ultraviolet, etc.
http://www.yorku.ca/eye/spectrum.gif
SCCS 476 14
1.3.2 Image Acquisition
• Camera: digital camera– CCD (Charge-Coupled Device)– CMOS (Complementary Metal Oxide Semi-
conductor)
• Flat-bed scanner– Scan row by row– Examples: Computed Axial Tomography,
MRI, etc.
SCCS 476 15
Imaging Sensors
(a) Single sensor
(b) Line sensor
(c) Array sensor
SCCS 476 16
Digital image acquisition process
SCCS 476 17
1.4 Images and Digital Images
SCCS 476 18
Image Sampling & Quantization
Quantization
Image Sampling
SCCS 476 19
Pixel
• Picture elements Pixel
SCCS 476 20
Digital Images
SCCS 476 21
Image Representation
• Consider an image as a matrix
• Intensity of pixel (x,y), f(x,y), is the member at row x and column y of the matrix
• Lexicographic ordering:– Rearrange image matrix into 1-D vector
format– Concatenate the row together
– Pixel at (x,y) is at the position x WIDTH + y
SCCS 476 22
Neighborhood
48 50 49 48 0
48 52 55 3 116
44 53 5 110 105
51 0 111 123 112
1 122 120 111 115
3 3 neighborhood
(usually is the odd number)
SCCS 476 23
1.5 Applications of Image Processing• Medicine
– Inspection and investigation of images obtained from x-rays, MRI, CAT scans
– Analysis of cell images and chromosome karyotypes• Agriculture
– Satellite/aerial views of land: determine how much land is being used
– Inspection of fruit and vegetables: distinguish good and fresh produce from old
• Industry– Automatic inspection of items on a production line– Inspection of paper samples
• Law enforcement– Fingerprint analysis
SCCS 476 24
1.6 Aspects of Image Processing (image processing algorithm)
• Image Enhancement: processing an image so that the result is more suitable for a particular application.– sharpening or deblurring– highlighting edges– improving image contrast or brightening
image– removing noise
SCCS 476 25
1.6 Aspects of Image Processing (cont)
• Image Restoration: An image may be restored by the damage done to it by known cause, for example – removing of blur caused by linear motion– removing of optical distortions– removing periodic interference
Note: (i) enhancement – make it look better,
(ii) restoration – remove damage
SCCS 476 26
1.6 Aspects of Image Processing (cont)
• Image Segmentation: Segmentation involves subdividing an image into constitute parts– finding lines, circles, or particular shapes in an
image– Identifying cars, trees buildings, or roads in an
aerial photograph
SCCS 476 27
1.7 Image Processing Task
Real-world application: A system for reading the postal codes from envelopes– Image Acquisition. First we need to produce a digital image
from a paper envelop. This can be done using either CCD camera or a scanner.
– Preprocessing. Use some image processing algorithms to obtain the resulting image more suitable for the later process. In this application it may involve enhancing the contrast, removing noises, or identifying regions likely to contain the postal code.
– Segmentation. Use some image processing algorithms to extract the region that contains postal code from the image
SCCS 476 28
1.7 Image Processing Task (cont)
– Representation and description. Extracting the particular features to differentiate between objects. Here suppose we will be looking for curves, holes, and corners that allow us to distinguish the different digits that constitute a postal code.
– Recognition and interpretation. Assigning labels to objects based on their descriptors (from the previous step) and assigning meanings to these labels. We identify particular digits, and interpret a string of digits at the end of the address as the postal code.
SCCS 476 29
1.8 Types of Digital Images
• Binary– 1 bit/pixel (black & white image)
• Grayscale – 8 bit/pixel (gray image)
• Color image:– true color: 24 bit/pixel (Red, Green Blue, 2553 colors)
• Indexed image: 8 bit/pixel (color image with 256 colors)
SCCS 476 30
Binary Image
• Two color: black and white. No gray.• Value range: 0 : black, 1 : white
http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=4052&objectType=file
SCCS 476 31
Grayscale Image
• Use black (0), white (255) and shades of gray• Value range: 0-255
SCCS 476 32
Color Image• 3 bytes for 1 pixel• R = [0,255], G = [0, 255], B = [0,255]
SCCS 476 33
Indexed Image • Mostly 1 byte for 1 pixel• Good for image composing of less than 256 colors
SCCS 476 34
Indexed Image (cont)
1 3 3 4
5 4 4 3
4 3 4 3
3 3 2 1
0.1211 0.1530 0.1234
0.1807 0.3447 0.1729
0.2627 0.2588 0.2549
0.2197 0.2432 0.2588
0.1611 0.1768 0.1924
0.2432 0.2471 0.1924
.
.
.Indices (value of the pixel)
Color Map (Palette)
Index 0Color: (0.1807, 0.3447, 0.1729)
Color: (0.1611, 0.1768, 0.1924)
SCCS 476 35
1.9 Size of Image File
• Total number of pixel = Width Height
• Size = Total number of pixel size of pixel
= Width Height #bit/pixel [bits]
= Width Height #byte/pixel [byte]
SCCS 476 36
Examples: File Size
• Binary image:– Width = 352– Height = 288– Size = ?
• Grayscale image:– Width = 352– Height = 288– Size = ?
SCCS 476 37
1.10 Image Perception
Much of image processing in concerned with making an image appear better to human beings. Therefore, we should be aware of the limitations of the human visual system.
Image perception consists of – capture the image with the eye– recognize and interpret the image with the visual
cortex in the brain
SCCS 476 38
Limitations of Human Visual System
• Observed intensities vary as to the background
SCCS 476 39
Limitations of Human Visual System (cont)
• Observation of nonexistence intensity as bars in continuously varying gray level
SCCS 476 40
Limitations of Human Visual System (cont)
SCCS 476 41
Limitations of Human Visual System (cont)
False contouring
SCCS 476 42
Limitations of Human Visual System (cont)
• Undershoot or overshoot around the boundary of regions of different intensities
– Boundary appeared brighter when seeing from dark to bright region.
– Boundary appeared darker when seeing from bright to dark region
SCCS 476 43
Limitations of Human Visual System (cont)
Mach bands