23
1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

Embed Size (px)

Citation preview

Page 1: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

1

Digital Image Processing

Dr. Saad M. Saad Darwish Associate Prof. of computer science

Page 2: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

2

What is an image? - The bitmap representation

Also called “raster or pixel maps” representation

An image is broken up into a grid

pixel

Gray level

Original picture Digital image

f(x, y) I[i, j] or I[x, y]

x

y

Page 3: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

3

What is an image? - The vector representation

Object-oriented representationDoes not show information of individual

pixel, but information of an object (circle, line, square, etc.)

Circle(100, 20, 20)Line(xa1, ya1, xa2, ya2)Line(xb1, yb1, xb2, yb2)Line(xc1, yc1, xc2, yc2)Line(xd1, yd1, xd2, yd2)

Page 4: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

4

Comparison

Bitmap– Can represent images with

complex variations in colors, shades, shapes.

– Larger image size

– Fixed resolution

– Easier to implement

Vector– Can only represent simple

line drawings (CAD), shapes, shadings, etc.

– Efficient

– Flexible

– Difficult to implement

Page 5: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

5

Why image processing?

Application

– Fingerprint retrieval

– Automatic target recognition

– Industrial inspection

– Medical imaging

– and more …Can commercial software do all the work?

Page 6: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

6

Some clarification

Image & Graphics Graphics are visual presentations on some surface, examples are

photographs, drawings, graphs, diagrams, symbols, geometric, maps, engineering drawings, or other images.

Image processing & Computer vision Computer vision is a field that includes methods for acquiring, processing,

analyzing, and understanding images. Image processing & Image understanding Image understanding produces descriptions of both the images (extracting

features from images) and the world scenes that the images represent."

Image processing & Pattern recognition

Page 7: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

7

Goals of image processing

Image improvement

– Improving the visual appearance of images to a human viewer

Image analysis

– Preparing images for measurement of the features and structures present

Page 8: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

8

What to learn?

ImageAcquisition

ImageEnhancement

ImageRestoration

ImageCompression

ImageSegmentation

Representation &Description

Recognition& Interpretation

Knowledge Base

Preprocessing – low levelImage Improvement

ImageCoding

MorphologicalImage Processing

WaveletAnalysis

High-level IPImage Analysis

Page 9: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

Video camera Infrared camera Range camera Line-scan camera Hyperspectral camera Omni-directional camera and more …

9

Image acquisition

Page 10: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

10

Some simple operations

Page 11: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

11

Image enhancement

Page 12: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

12

Movie film restoration

Page 13: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

13

Image restoration

The purpose of image restoration is to "compensate for" or "undo" defects which degrade an image.

Page 14: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

14

Image correction

Geometric correction: Operations intended to restore or compensate the distortions of an image in geometry

Radiometric correction: Operations intended to remove systematic or random noise affecting the amplitude (brightness) of an image

Page 15: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

Image warping geometric transformation

Image warping is the process of digitally manipulating an image such that any shapes portrayed in the image have been significantly distorted.

Page 16: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

16

Image warping – another example

Page 17: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

17

Image Segmentation

The result of image segmentation is a set of segments that collectively cover the entire image, or a set of contours extracted from the image The goal of image segmentation is to cluster pixels into salient image regions,

Page 18: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

18

Image description

OCR – Optical character recognition, license plate recognition

Page 19: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

19

Beyond

Content-based image retrievalHuman identificationMulti-sensor data fusionHexagonal pixelSteganography

Page 20: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

20

Image processing for fine arts

Page 21: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

21

Real-world reasoning demo

Page 22: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

22

How to address pixels of an image?

int i, j, k;int nr, // number of rows nc, // number of columns nchan;// number of channels

nr = 128; nc = 128; nchan = 3;for (i=0; i<nr; i++) { for (j=0; j<nc; j++) { for (k=0; k<nchan; j++) { do the processing on (i,j,k); ……… } }}

Page 23: 1 Digital Image Processing Dr. Saad M. Saad Darwish Associate Prof. of computer science

23

j

(i, j) (i, j+1)(i, j-1)

(i-1, j) (i-1, j+1)

(i+1, j+1)(i+1, j)

(i-1, j-1)

(i+1, j-1)i

(row)

(column)

4-neighborhood 8-neighborhood

Types of neighborhoods

Neighbors of a pixel