PLT 425 VISION SYSTEM CHAPTER 2 DIGITAL IMAGE
- Slides: 31
PLT 425 VISION SYSTEM CHAPTER 2: DIGITAL IMAGE FUNDAMENTALS (PART 2) 1
GENERATING A DIGITAL IMAGE Ø A digital image is a 2 - dimensional array of pixels. Ø Each pixel has an intensity value (represented by a digital number) and a location address (referenced by its row and column numbers). Ø The value of an image at any coordinate (x, y) is denoted as f(x, y) where x and y are integers. 2
GENERATING A DIGITAL IMAGE Pixel Ø Pixel is a smallest component of digital image. Ø A digital image of M rows and N columns of pixels each storing a value. 3
4
Pixels and Values Ø Pixel is a color point of digital image. Ø Pixels values are most often gray levels in the range of 0 -255 (black – white). Grayscale/intensity image 5
6
Binary image RGB image (red-green-blue) 7
Pixel Array Ø Row and column indices [i, j] are integer values. Ø With regard to spatial resolution, we will map the intensity in our image onto a two-dimensional finite array: n [0, 0] n [1, 0] n [2, 0] n [0, 1] n [0, 2] n [0, 3] n [1, 1] n [1, 2] n [2, 1] n [1, 3] n [2, 2] n [2, 3] Pixel [3, 3] ↓i →j 8
Pixel Array 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Pixel [i, j] at the 4 th row and 7 th column is yellow Zoom 1600% 9
IMAGE RESOLUTION Ø Image resolution is described in PPI, number of pixels per inch of an image. Ø Resolution (how much you can see the detail of the image) depends on sampling and gray levels. Ø The bigger the sampling rate and the grayscale, the better the approximation of the digitized image from the original. 10
Spatial Resolution Ø The spatial resolution of an image is determined by how sampling was carried out and number of samples used to generate image. Ø Vision specialists will often talk about pixel size. 11
Spatial Resolution - Subsampling Problem? What are some problems that may occur if your images are sampled (or subsampled) to a lower resolution? 12
Checkerboard Effect Ø If the resolution is decreased too much, the checkerboard effect can occur. 13
Intensity Level Resolution Ø Intensity level resolution refers to the number of intensity levels used to represent the image. Ø The more intensity levels used, the finer the level of detail discernible in an image. Ø Intensity level resolution is usually given in terms of the number of bits used to store each intensity level. Ø Most common number of bits used is 8 bits, i. e. Number of gray levels = 28 = 256 levels. 14
Intensity Level Resolution 15
FOREGROUND AND BACKGROUND 16
NEIGHBORS OF A PIXEL 4 -Neighbors of Pixel Ø A pixel p at coordinate (x, y) has four horizontal and vertical neighbors. (x+1, y), (x-1, y), (x, y+1), (x, y-1) (x-1, y) (x, y-1) (x, y) (x+1, y) (x, y+1) Ø Each pixel is a unit distance from (x, y), and some of the neighbor locations of p lie outside the digital image if (x, y) is on the border of the image. 17
8 -Neighbors of Pixel Ø 8 -neighbors of a pixel p are its (x-1, y-1) (x-1, y) (x-1, y+1) (x, y+1) (x+1, y-1) (x+1, y+1) vertical, horizontal and 4 diagonal neighbors (x-1, y-1), (x+1, y-1), (x-1, y), (x+1, y), (x-1, y+1), (x+1, y+1) Ø Each pixel is a unit distance from (x, y), and some of the neighbor locations of p lie outside the digital image if (x, y) is on the border of the image. 18
Neighbors of a Pixel For a pixel [i, j] in an image : [i-1, j] [i, j-1] [i, j] [i-1, j-1] [i-1, j+1] [i, j-1] [i, j+1] [i+1, j-1] [i+1, j+1] 4 -neighbors (4 -neighborhood) 8 -neighbors (8 -neighborhood) 19
Neighbors of a Pixel • N 4 - 4 -neighbors • ND - diagonal neighbors • N 8 - 8 -neighbors (N 4 U ND) 20
ADJACENCY Ø Two pixels are connected if they are neighbors and their gray levels satisfy some specified criterion of similarity. Ø A pixel p is adjacent to pixel q if they are connected. Ø Example: In a binary image, two pixels are connected if they are 4 -neighbors and have same values (0/1). 21
CONNECTIVITY Ø To determine whether the pixels are adjacent in some sense. Ø Group the same region by assumption that the pixels being the same color or equal intensity will are the same region. Ø Let C is the set of colors used to define. Ø Types of connectivity: - 4 -Connectivity : 2 pixels (p and q) with value in C are 4 -connectivity if q is in the set N 4(p) - 8 -Connectivity : 2 pixels (p and q) with value in C are 8 -connectivity if q is in the set N 8(p) 22
Example: 4 -Connectivity Set of color consists of color 1 ; C ={1} 0 1 1 0 1 0 0 1 1 23
Example: 8 -Connectivity Set of color consists of color 1 ; C ={1} 0 1 1 0 1 0 0 1 1 24
PATH & CONNECTED COMPONENTS Ø Path: A sequence of distinct pixels that are adjacent to each. Ø Connected component: Is a set of pixels that are adjacent to each other. 25
Pop Quiz #1 Determine the neighborhood of the pixel A to F. Allocated time: 5 minutes. 26
DISTANCE MEASURES Ø Distance measurements are commonly used in image processing applications. Ø Distance may show a pixel is close to other pixel. Ø Among the famous and enormously used are: - Euclidean distance - City-block distance (also known as Manhattan distance) - Chessboard distance 27
Distance Function 28
29
Exercise: Distance Measures Calculate the distance from pixel p (1, 2) to pixel q (13, 26) using: a) Euclidean distance b) City-block distance c) Chessboard distance 30
Task Done Using Neighborhood Processing Ø Smoothing / averaging Ø Noise removal / filtering Ø Edge detection Ø Contrast enhancement 31
- Image transform in digital image processing
- Linear position invariant degradation
- Fundamentals of image compression
- Image segmentation in digital image processing
- Analog image and digital image
- Lossless image compression matlab source code
- Image sharpening in digital image processing
- Image geometry in digital image processing
- Steps in digital image processing
- Digital image processing
- Imtransform matlab
- Image restoration in digital image processing
- Wbc abn scattergram
- Plt-o sysmex
- Plt 404
- Istogramma rbc
- Plt scheme
- Plt fuzzy set
- Plt electronics
- Plt 106
- Extra high voltage
- Fcps my plt
- Plt in cbc
- Uts plt
- คืออะไร
- Plt morphology
- Import numpy as np import matplotlib.pyplot as plt
- Anu gdlp
- Plt
- How to draw an ye
- Billy b and plt
- Plt skills