EECS490: Digital Image Processing. Lecture #22

Similar documents
Image Analysis Image Segmentation (Basic Methods)

Image segmentation. Stefano Ferrari. Università degli Studi di Milano Methods for Image Processing. academic year

CS 490: Computer Vision Image Segmentation: Thresholding. Fall 2015 Dr. Michael J. Reale

Digital Image Analysis and Processing

EECS490: Digital Image Processing. Lecture #21

Segmentation

Segmentation

Region & edge based Segmentation

Image Segmentation. Schedule. Jesus J Caban 11/2/10. Monday: Today: Image Segmentation Topic : Matting ( P. Bindu ) Assignment #3 distributed

REGION & EDGE BASED SEGMENTATION

Today INF How did Andy Warhol get his inspiration? Edge linking (very briefly) Segmentation approaches

C E N T E R A T H O U S T O N S C H O O L of H E A L T H I N F O R M A T I O N S C I E N C E S. Image Operations II

Chapter 10: Image Segmentation. Office room : 841

Digital Image Processing Lecture 7. Segmentation and labeling of objects. Methods for segmentation. Labeling, 2 different algorithms

Region-based Segmentation

ECEN 447 Digital Image Processing

Image Segmentation! Thresholding Watershed. Hodzic Ernad Seminar Computa9onal Intelligence

Image Processing. Bilkent University. CS554 Computer Vision Pinar Duygulu

Lecture: Segmentation I FMAN30: Medical Image Analysis. Anders Heyden

Ulrik Söderström 16 Feb Image Processing. Segmentation

ECG782: Multidimensional Digital Signal Processing

Segmentation algorithm for monochrome images generally are based on one of two basic properties of gray level values: discontinuity and similarity.

Image Segmentation. Selim Aksoy. Bilkent University

Image Segmentation. Selim Aksoy. Bilkent University

Bioimage Informatics

Chapter 3: Intensity Transformations and Spatial Filtering

Computer Vision. Image Segmentation. 10. Segmentation. Computer Engineering, Sejong University. Dongil Han

Image Processing. BITS Pilani. Dr Jagadish Nayak. Dubai Campus

Idea. Found boundaries between regions (edges) Didn t return the actual region

Image Enhancement in Spatial Domain (Chapter 3)

Biomedical Image Analysis. Mathematical Morphology

Final Review. Image Processing CSE 166 Lecture 18

Basic Algorithms for Digital Image Analysis: a course

Topic 4 Image Segmentation

Introduction to Medical Imaging (5XSA0) Module 5

(10) Image Segmentation

Digital Image Processing. Prof. P.K. Biswas. Department of Electronics & Electrical Communication Engineering

Binary Image Analysis. Binary Image Analysis. What kinds of operations? Results of analysis. Useful Operations. Example: red blood cell image

EE795: Computer Vision and Intelligent Systems

Histograms. h(r k ) = n k. p(r k )= n k /NM. Histogram: number of times intensity level rk appears in the image

Chapter 10 Image Segmentation. Yinghua He

Lecture 9: Hough Transform and Thresholding base Segmentation

Image Segmentation Based on Watershed and Edge Detection Techniques

Biometrics Technology: Image Processing & Pattern Recognition (by Dr. Dickson Tong)

C E N T E R A T H O U S T O N S C H O O L of H E A L T H I N F O R M A T I O N S C I E N C E S. Image Operations I

Dr. Ulas Bagci

Binary Image Processing. Introduction to Computer Vision CSE 152 Lecture 5

1. What are the derivative operators useful in image segmentation? Explain their role in segmentation.

Filtering and Enhancing Images

Sampling and Reconstruction

Digital Image Processing

Processing of binary images

Image Segmentation. Segmentation is the process of partitioning an image into regions

EE 701 ROBOT VISION. Segmentation

CITS 4402 Computer Vision

Part 3: Image Processing

CHAPTER 3 IMAGE ENHANCEMENT IN THE SPATIAL DOMAIN

In this lecture. Background. Background. Background. PAM3012 Digital Image Processing for Radiographers

Operators-Based on Second Derivative double derivative Laplacian operator Laplacian Operator Laplacian Of Gaussian (LOG) Operator LOG

11/10/2011 small set, B, to probe the image under study for each SE, define origo & pixels in SE

Image Enhancement: To improve the quality of images

Digital Image Processing

Lecture 3 - Intensity transformation

EECS490: Digital Image Processing. Lecture #23

PPKE-ITK. Lecture

Lecture 4 Image Enhancement in Spatial Domain

Chapter - 2 : IMAGE ENHANCEMENT

Lecture #13. Point (pixel) transformations. Neighborhood processing. Color segmentation

2%34 #5 +,,% ! # %& ()% #% +,,%. & /%0%)( 1 ! # %& % %()# +(& ,.+/ +&0%//#/ &

Introduction to Digital Image Processing

MR IMAGE SEGMENTATION

Image Processing and Image Analysis VU

EECS490: Digital Image Processing. Lecture #20

Segmentation Region-based processing. Feature extraction Gonzalez-Woods Chapt. 10 Pratt Chapt. 16 and 17

(Refer Slide Time: 0:32)

09/11/2017. Morphological image processing. Morphological image processing. Morphological image processing. Morphological image processing (binary)

Image Analysis Lecture Segmentation. Idar Dyrdal

REGION BASED SEGEMENTATION

Schedule for Rest of Semester

Object Segmentation. Jacob D. Furst DePaul CTI

Content-based Image and Video Retrieval. Image Segmentation

UNIT - 5 IMAGE ENHANCEMENT IN SPATIAL DOMAIN

EECS490: Digital Image Processing. Lecture #19

Analysis of Binary Images

Lecture 4. Digital Image Enhancement. 1. Principle of image enhancement 2. Spatial domain transformation. Histogram processing

Contents Edge Linking and Boundary Detection

Lecture #5. Point transformations (cont.) Histogram transformations. Intro to neighborhoods and spatial filtering

Part 3: Image Processing

Digital Image Processing. Image Enhancement in the Spatial Domain (Chapter 4)

Morphology-form and structure. Who am I? structuring element (SE) Today s lecture. Morphological Transformation. Mathematical Morphology

EXAM SOLUTIONS. Image Processing and Computer Vision Course 2D1421 Monday, 13 th of March 2006,

Computer Vision & Digital Image Processing. Image segmentation: thresholding

Image Processing: Final Exam November 10, :30 10:30

Image Analysis. Morphological Image Analysis

Digital Image Processing, 2nd ed. Digital Image Processing, 2nd ed. The principal objective of enhancement

Broad field that includes low-level operations as well as complex high-level algorithms

Biomedical Image Analysis. Point, Edge and Line Detection

Massachusetts Institute of Technology. Department of Computer Science and Electrical Engineering /6.866 Machine Vision Quiz I

Processing and Others. Xiaojun Qi -- REU Site Program in CVMA

Digital Image Processing COSC 6380/4393

Transcription:

Lecture #22 Gold Standard project images Otsu thresholding Local thresholding Region segmentation Watershed segmentation Frequency-domain techniques

Project Images 1

Project Images 2

Project Images 3

Project Images 4

Project Images 5

Project Images 6

Optimum Thresholding probability 1 T 2 intensity Simple bimodal distribution with two homogeneous classes probability Class 1 1 T 2 Class 2 intensity If there is no valley one method of determining T is to minimize the total variance within both classes. 1999-2007 by Richard Alan Peters II

Image Thresholding Otsu method minimizes the overall within-class variance by minimizing the weighted sum of class variances w 2 ()= t q 1 () t 2 1 ()+ t q 2 () t 2 2 () t Class 1 Class 2 q 1 q 2 () ()= t Pi t i=0 L 1 () ()= t Pi i=t CDF for each class 1 2 2 2 ()= t 1 t q 1 () ()= t 1 t q 2 () t i=0 L 1 i=t +1 i μ 1 i μ 2 () t 2 Pi () () t 2 Pi () Standard deviation of the intensities within each class normalized by the probability of that class 1999-2007 by Richard Alan Peters II

Image Thresholding http://www.mathworks.com/matlabcentral/fileexchange/loadfile.do?objectid=16205 1. Compute the histogram of the image. Let each gray level have probability p i. k 2. Compute the cumulative sum P 1 (k) for k=0,,l-1 P 1 ( k)= p i 3. Compute the cumulative mean m(k) for k=0,,l-1 4. Compute the global intensity mean m G 5. Compute the between class variance B2 (k) for k=0,,l 2 B = P 1 ( k) ( m 1 ( k) m G ) 2 + P 2 ( k) ( m 2 ( k) m G ) 2 6. Compute the Otsu threshold k* as the value of k for which B2 (k) is maximum 7. Obtain the separability measure * * = 2 B ( k *) 1999-2007 by Richard Alan Peters II m G = G 2 L 1 i=0 ip i m 1 ( k)= i=0 P 1 1 k ( ) k i=0 ip i The farther apart the means the larger will be B2 (k) This is a measure of how easily separable the classes are. Uniform distribution is 0 and a clear, bimodal is 1

Image Thresholding Original image. Global thresholding calculating T=0.5*( 1 + 2 ) until T less than some Global thresholding using Otsu algorithm

Image Thresholding Noisy image Smoothed noisy image Averaging greatly improves separability Global thresholding using Otsu algorithm

Image Thresholding Noisy image Smoothed noisy image Averaging does not improve separability Global thresholding using Otsu algorithm

Image Thresholding Basic idea is to look at the histogram of pixels only near edges Noisy image Thresholded gradient image (very high threshold) Produce of thresholded gradient image and original image Edge masking uses only pixels near edges to form histogram Global thresholding of ORIGINAL image using Otsu algorithm on histogram of masked image

Image Thresholding Noisy image of yeast cells want to find bright spots Otsu thresholding of noisy image histogram Product of thresholded Laplacian(high threshold) image and original image Global thresholding of ORIGINAL image using Otsu algorithm on histogram of masked image Edge masking uses only pixels near edges to form histogram

Image Thresholding Global thresholding of ORIGINAL image using Otsu algorithm on histogram of masked image. Only difference from previous slide is that lower threshold for absolute Laplacian was used.

Image Thresholding k 1 k 2 Modify Otsu global thresholding by adding a third class 2 B = P 1 ( m 1 m G ) 2 + P 2 m 2 m G ( ) 2 + P 3 ( m 3 m G ) 2 Compute the between class variance B2 (k 1,k 2 ) for k 1 =0,,L-1 and k 2 =0,,L-1 Otsu optimum thresholds k 1,k 2 when B 2 (k 1,k 2 ) is maximum

Image Thresholding Original dark, noisy image Global thresholding using Otsu algorithm Global thresholding calculating T=0.5*( 1 + 2 ) until T less than some Subimage thresholding using Otsu algorithm Subdivide original image into six subimages and apply Otsu algorithm to histogram of each subimage (next page)

Image Thresholding

Image Thresholding Original image Global thresholding using dual threshold Otsu method Local standard deviations computed for a moving 3x3 mask Local thresholding Predicate (true or false) using local (3x3) std dev g( x, y)= 1 if f( x, y)> 30 ( x, y) AND f ( x, y )> 1.5m G 0 otherwise

Image Thresholding Local thresholding using n=20 moving average Original image with spot illumination Global thresholding using Otsu method g( x, y)= z k n 1 if f ( x, y )> 0.5m xy 0 otherwise z k z k +1 Use local moving average where m(1)=z 1 /n m xy = m( k+ 1)= 1 n k +1 i= k +2 n z i = m( k) z k is the intensity point at scanning sequence k (wraps around image) + 1 ( n z k +1 z k n )

Image Thresholding Original image with spot illumination Global thresholding using Otsu method Local thresholding using n=20 moving average g( x, y)= 1 if f ( x, y )> 0.5m xy 0 otherwise Use local moving average where m 1 =z 1 /n m xy = m( k+ 1)= 1 n k +1 i= k +2 n z i = m( k) + 1 ( n z k +1 z k n )

Region Segmentation Let f(x,y) be the image, S(x,y) is a binary seed image with 1 s at the location of seed points, and Q(x,y) is a predicate function Find all connected components in S(x,y) and erode each connected component to one pixel. Form an image f Q such that at each point f(x,y)=1 if Q(x,y) is true, else f(x,y)=0 Let g be an image formed by appending to each seed point in S all 1-valued points in f Q that are 8- connected to that seed point Label each connected component in g with a unique label (e.g., 1, 2, 3, ) This is the segmented image 1999-2007 by Richard Alan Peters II

Region Segmentation Original image 1. Seed image from high percentile thresholding 2. Erode seed image 4. Difference image using dual thresholds T 1 =68, T 2 =126 3. original-seed difference image 5. Difference image using only the lowest threshold. 6. Region growing from seed image (single threshold) using difference image and 8- connectivity

Quadtree Segmentation An alternative to having a seed image and region growing is to partition an image into sub-images. This process continues until each region has a uniform predicate. The process then merges adjacent regions with similar predicates. This is sometimes called quadtree segmentation.

Quadtree Segmentation 566x566 pixel image Quadtree segmentation of image using minimum region sizes of 32x32, 16x16, and 8x8 pixels. Predicate is TRUE if >a and 0<m<b

Watershed Segmentation Original gray scale image Topographical plot of original image Punch holes in bottom of each region and flood.

Watershed Segmentation Punch another region and continue flooding. Start building dam between regions Continue building dams between regions Final watershed

Watershed Segmentation Mi is the set of coordinates of points in the regional minima of an image g(x,y) T[n]={(s,t) g(s,t)<n} is the set of all points lying below the n plane C n (M i ) denotes the set of coordinates of points associated with minimum M i that are flooded at stage n. C n (M i ) T[n] restricts the points associated with M i to those less than n at that stage of the flooding R The union of flooded catchment basements is Cn [ ]= C n M i i=1 Let q be in connected component in C[n]. If q C[n-1] is empty do nothing If q C[n-1] contains one connected component of C[n-1] then incorporate into C[n-1] If q C[n-1] is contains two or more connected components of C[n-1] build a dam by dilating q C[n-1] ( )

Image Segmentation Dilating from lowest points at stage n-1 Dam construction begins when dilations overlap at stage n Dam constructed between basins

Image Segmentation Original image Gradient image Watershed lines in gradient image Watershed lines on top of original image

Image Segmentation Direct application of watershed segmentation typically results in oversegmentation, i.e., too many regions

Image Segmentation We can use other segmentation techniques to define markers which will control the segmentation. Internal markers (light gray regions) define starting points and external markers (gray lines) limit segmentation. Resulting segmented image. 10.57(b)

Motion Segmentation Accumulative Difference Image (ADI) for a moving rectangle. Positive ADI Negative ADI A k ( x, y)= k 1( x, y)+ 1 if R( x, y) f( x, y, k) > T A k 1 ( x, y) otherwise The accumulator is incremented if the absolute difference between the reference frame and each successive frame is above a threshold. We can also have positive and negative accumulator images. P k ( x, y)= P x, y k 1( )+ 1 if R ( x, y ) f x, y,t k P k 1 ( x, y) otherwise ( ) > T N k ( x, y)= N x, y k 1( )+ 1 if R ( x, y ) f x, y,t k N k 1 ( x, y) otherwise ( ) T

Image Segmentation

Image Segmentation There is a small moving object with a 9 pixel Gaussian distribution moving with v x =0.5 and v y =0.5 pixel/frame. This is one of 32 frames. Basic concept: Single one pixel object moving against a uniform background. v x =1 pixel/frame 1. Project image onto x-axis (sum columns) 2. At t=0 multiply columns of projection array by e j2 ax t, x=0,1,2, where a is a positive integer and t is the time interval between frames 3. At t=1 do the same thing except object has moved to x +1 This gives a accumulator array of zeroes except for the moving object projection. If the velocity is constant the projection is e j2 a(x +t) t =cos[2 a(x +t) t]+jsin[2 a(x +t) t], i.e., projections of moving objects give single frequency sinusoids (for constant velocity)

Image Segmentation Moving object Intensity plot of single frame.

Image Segmentation The a s are selected to prevent aliasing in the frequency domain. A rule of thumb is to select a as the integer closest to u max /v max where v max is the maximum velocity and u max is related to the maximum number of frames/second. u 1 =3 a 1 =6 x-velocity of unknown object is v 1 =u 1 /a 1 =3/6=0.5 pixel/frame

Image Segmentation a 2 =4 u 2 =4 y-velocity of moving object is then v 2 =u 2 /a 2 =4/4=1 pixel/frame