Image Segmentation Longin Jan Latecki CIS 601. Image Segmentation Segmentation divides an image into its constituent regions or objects. Segmentation.

Slides:



Advertisements
Similar presentations
Types of Image Enhancements in spatial domain
Advertisements

1 ECE 495 – Integrated System Design I Introduction to Image Processing ECE 495, Spring 2013.
Segmentation by Morphological Watersheds
Histograms! Histograms group data that is close together into “classes” and shows how many or what percentage of the data fall into each “class”. It.
M ATLAB L ECTURE 3 Histogram Processing. H ISTOGRAM E QUALIZATION The imhist function create a histogram that show the distribution of intensities in.
Laboratory of Image Processing Pier Luigi Mazzeo
November 12, 2013Computer Vision Lecture 12: Texture 1Signature Another popular method of representing shape is called the signature. In order to compute.
Robust statistical method for background extraction in image segmentation Doug Keen March 29, 2001.
Image Processing in Matlab An Introductory Approach by Sabih D. Khan
Segmentation in color space using clustering Student: Yijian Yang Advisor: Longin Jan Latecki.
嵌入式視覺 Feature Extraction
Sliding Window Filters and Edge Detection Longin Jan Latecki Computer Graphics and Image Processing CIS 601 – Fall 2004.
Computer Vision Lecture 16: Texture
Chapter 8 Content-Based Image Retrieval. Query By Keyword: Some textual attributes (keywords) should be maintained for each image. The image can be indexed.
Digital Image Processing Lecture11: Histogram Processing.
Automatic Histogram Threshold Using Fuzzy Measures 呂惠琪.
Automatic Thresholding
LING 111 Teaching Demo By Tenghui Zhu Introduction to Edge Detection Image Segmentation.
Image Segmentation Image segmentation (segmentace obrazu) –division or separation of the image into segments (connected regions) of similar properties.
電腦視覺 Computer and Robot Vision I Chapter2: Binary Machine Vision: Thresholding and Segmentation Instructor: Shih-Shinh Huang 1.
Segmentation and Region Detection Defining regions in an image.
EE 7730 Image Segmentation.
Chapter 10 Image Segmentation.
Segmentation Divide the image into segments. Each segment:
Image Segmentation. Introduction The purpose of image segmentation is to partition an image into meaningful regions with respect to a particular application.
Chapter 10 Image Segmentation.
CS292 Computational Vision and Language Segmentation and Region Detection.
Image Segmentation CIS 601 Fall 2004 Longin Jan Latecki.
Image segmentation by clustering in the color space CIS581 Final Project Student: Qifang Xu Advisor: Dr. Longin Jan Latecki.
Edge Detection Hao Huy Tran Computer Graphics and Image Processing CIS 581 – Fall 2002 Professor: Dr. Longin Jan Latecki.
Chapter 10: Image Segmentation
Digital Image Processing In The Name Of God Digital Image Processing Lecture8: Image Segmentation M. Ghelich Oghli By: M. Ghelich Oghli
S EGMENTATION FOR H ANDWRITTEN D OCUMENTS Omar Alaql Fab. 20, 2014.
Lecture 6-1CS251: Intro to AI/Lisp II I can see clearly now May 4th, 1999.
Texture. Texture is an innate property of all surfaces (clouds, trees, bricks, hair etc…). It refers to visual patterns of homogeneity and does not result.
Segmentation.
Chap. 9: Image Segmentation Jen-Chang Liu, Motivation Segmentation subdivides an image into its constituent regions or objects Example: 生物細胞在影像序列中的追蹤.
September 5, 2013Computer Vision Lecture 2: Digital Images 1 Computer Vision A simple two-stage model of computer vision: Image processing Scene analysis.
Image Similarity Longin Jan Latecki CIS Dept. Temple Univ., Philadelphia
Digital Image Processing Lecture 18: Segmentation: Thresholding & Region-Based Prof. Charlene Tsai.
Chapter 10 Image Segmentation.
Image Segmentation Chapter 10.
Chapter 10, Part II Edge Linking and Boundary Detection The methods discussed in the previous section yield pixels lying only on edges. This section.
CS654: Digital Image Analysis Lecture 18: Image Enhancement in Spatial Domain (Histogram)
CS 376b Introduction to Computer Vision 03 / 21 / 2008 Instructor: Michael Eckmann.
Presented By: ROLL No IMTIAZ HUSSAIN048 M.EHSAN ULLAH012 MUHAMMAD IDREES027 HAFIZ ABU BAKKAR096(06)
Pixel Connectivity Pixel connectivity is a central concept of both edge- and region- based approaches to segmentation The notation of pixel connectivity.
1 Euler Number Computation By Kishore Kulkarni (Under the Guidance of Dr. Longin Jan Latecki)
Image Transforms Transforming images to images. Classification of Image Transforms Point transforms –modify individual pixels –modify pixels’ locations.
Image Segmentation by Histogram Thresholding Venugopal Rajagopal CIS 581 Instructor: Longin Jan Latecki.
Image Segmentation Dr. Abdul Basit Siddiqui. Contents Today we will continue to look at the problem of segmentation, this time though in terms of thresholding.
Digital Image Processing
Digital Topology CIS 601 Fall 2004 Longin Jan Latecki.
Machine Vision ENT 273 Regions and Segmentation in Images Hema C.R. Lecture 4.
Evaluation of Image Segmentation algorithms By Dr. Rajeev Srivastava.
Wonjun Kim and Changick Kim, Member, IEEE
Image Segmentation Nitin Rane. Image Segmentation Introduction Thresholding Region Splitting Region Labeling Statistical Region Description Application.
Chapter 8 Computer Vision. Artificial IntelligenceChapter 92 Contents What is Image Processing? Digital Image Processing Electromagnetic Spectrum Steps.
Thresholding Foundation:. Thresholding In A: light objects in dark background To extract the objects: –Select a T that separates the objects from the.
Lecture 02 Point Based Image Processing Lecture 02 Point Based Image Processing Mata kuliah: T Computer Vision Tahun: 2010.
Digital Image Processing CCS331 Relationships of Pixel 1.
1.2 Displaying Quantitative Data with Graphs.  Each data value is shown as a dot above its location on the number line 1.Draw a horizontal axis (a number.
COMP 9517 Computer Vision Binary Image Analysis 4/15/2018
IMAGE SEGMENTATION USING THRESHOLDING
Image Segmentation – Edge Detection
Computer Vision Lecture 16: Texture II
Fall 2012 Longin Jan Latecki
Efficient Distribution-based Feature Search in Multi-field Datasets Ohio State University (Shen) Problem: How to efficiently search for distribution-based.
Chapter 10 – Image Segmentation
Image Segmentation.
Presentation transcript:

Image Segmentation Longin Jan Latecki CIS 601

Image Segmentation Segmentation divides an image into its constituent regions or objects. Segmentation of non trivial images is one of the difficult task in image processing. Still under research. Segmentation accuracy determines the eventual success or failure of computerized analysis procedure.

Segmentation Algorithms Segmentation algorithms are based on one of two basic properties of intensity values discontinuity and similarity. First category is to partition an image based on abrupt changes in intensity, such as edges in an image. Second category are based on partitioning an image into regions that are similar according to a predefined criteria. Histogram thresholding approach falls under this category.

 Domain spaces  spatial domain (row-column (rc) space)  histogram spaces  color space  other complex feature space

Histograms Histogram are constructed by splitting the range of the data into equal-sized bins (called classes). Then for each bin, the number of points from the data set that fall into each bin are counted. Vertical axis: Frequency (i.e., pixel counts for each bin) Horizontal axis: Response variable In image histograms the pixels form the horizontal axis

Thresholding - Foundation Suppose that the gray-level histogram corresponds to an image f(x,y) composed of dark objects on the light background, in such a way that object and background pixels have gray levels grouped into two dominant modes. One obvious way to extract the objects from the background is to select a threshold ‘T’ that separates these modes. Then any point (x,y) for which f(x,y) < T is called an object point, otherwise, the point is called a background point.

Example

Gray Scale Image - bimodal Image of a Finger Print with light background

Segmented Image Image after Segmentation

In Matlab histograms for images can be constructed using the imhist command. I = imread('pout.tif'); figure, imhist(I) %look at the hist to get a threshold, e.g., 110 BW=roicolor(I, 110, 255); % makes a binary image figure, imshow(BW) % all pixels in (110, 255) will be 1 and white % the rest is 0 which is black roicolor returns a region of interest selected as those pixels in I that match the values in the gray level interval. BW is a binary image with 1's where the values of I match the values of the interval.

Bimodal Histogram If two dominant modes characterize the image histogram, it is called a bimodal histogram. Only one threshold is enough for partitioning the image. If for example an image is composed of two types of dark objects on a light background, three or more dominant modes characterize the image histogram.

Multimodal Histogram In such a case the histogram has to be partitioned by multiple thresholds. Multilevel thresholding classifies a point (x,y) as belonging to one object class if T1 < (x,y) <= T2, if T1 < (x,y) <= T2, to the other object class to the other object class if f(x,y) > T2 if f(x,y) > T2 and to the background and to the background if f(x,y) <= T1. if f(x,y) <= T1.

Thresholding Bimodal Histogram Basic Global Thresholding: 1)Select an initial estimate for T 1)Select an initial estimate for T 2)Segment the image using T. This will produce two groups of pixels. G1 consisting of all pixels with gray level values >T and G2 consisting of pixels with values T and G2 consisting of pixels with values <=T. 3)Compute the average gray level values mean1 and mean2 for the pixels in regions G1 and G2. 3)Compute the average gray level values mean1 and mean2 for the pixels in regions G1 and G2. 4)Compute a new threshold value 4)Compute a new threshold value T=(1/2)(mean1 +mean2) T=(1/2)(mean1 +mean2) 5)Repeat steps 2 through 4 until difference in T in successive iterations is smaller than a predefined parameter T0. 5)Repeat steps 2 through 4 until difference in T in successive iterations is smaller than a predefined parameter T0. Basic Adaptive Thresholding: Images having uneven illumination makes it difficult to segment using histogram, this approach is to divide the original image into sub images and use the above said thresholding process to each of the sub images.

Thresholding multimodal histograms A method based on Discrete Curve Evolution to find thresholds in the histogram. The histogram is treated as a polyline and is simplified until a few vertices remain. Thresholds are determined by vertices that are local minima.

Discrete Curve Evolution (DCE) u v w u v w It yields a sequence: P=P 0,..., P m P i+1 is obtained from P i by deleting the vertices of P i that have minimal relevance measure K(v, P i ) = |d(u,v)+d(v,w)-d(u,w)| >

Example

Thresholding – Colour Images In colour images each pixel is characterized by three RGB values. Here we construct a 3D histogram, and the basic procedure is analogous to the method used for one variable. Histograms plotted for each of the colour values and threshold points are found.

Displaying objects in the Segmented Image The objects can be distinguished by assigning a arbitrary pixel value or average pixel value to the regions separated by thresholds.

Experiments by Venugual Rajagupal Type of images used: 1) Two Gray scale image having bimodal histogram structure. 1) Two Gray scale image having bimodal histogram structure. 2) Gray scale image having multi-modal histogram structure. 2) Gray scale image having multi-modal histogram structure. 3) Colour image having bimodal histogram structure. 3) Colour image having bimodal histogram structure.

Gray Scale Image - bimodal Image of rice with black background

Segmented Image Image after segmentation Image histogram of rice

Gray Scale Image - Multimodal Original Image of lena

Multimodal Histogram Histogram of lena

Segmented Image Image after segmentation – we get a outline of her face, hat, shadow etc

Colour Image - bimodal Colour Image having a bimodal histogram

Histogram Histograms for the three colour spaces

Segmented Image Segmented image – giving us the outline of her face, hand etc

Clustering in Color Space Each image point is mapped to a point in a color space, e.g.: Color(i, j) = (R (i, j), G(i, j), B(i, j)) The points in the color space are grouped to clusters. The clusters are then mapped back to regions in the image.

Resluts 1 Mnp: 30, percent 0.05, cluster number 4 Mnp : 20, percent 0.05, cluster number 7 Original pictures segmented pictures

k-means Clustering An algorithm for partitioning (or clustering) N data points into K disjoint subsets S j containing N j data points so as to minimize the sum-of-squares criterion S j where x n is a vector representing the nth data point and  j is the geometric centroid of the data points in S j

The algorithm consists of a simple re-estimation procedure: First, K centroid points are selected  j, e.g., at random. S jSecond, each data points is assigned to the cluster S j of the closest centroid  j. Third, the centroid  j is recomputed for each cluster set. The steps two and three are alternated until a stopping criterion is met, i.e., when there is no further change in the assignment of the data points. In general, the algorithm does not achieve a global minimum of J over the assignments. In fact, since the algorithm uses discrete assignment rather than a set of continuous parameters, the "minimum" it reaches cannot even be properly called a local minimum. Despite these limitations, the algorithm is used frequently as a result of its ease of implementation. Homework: Implement in Matlab and test on some example images the clustering in the color space. You can use k-means or some other clustering algorithm.

Matlab example Matlab programs are in data=load('irises1.dat'); % loads a classic data set of Irises [distance,cluster,tse] = kmeans1(data,3); %starts k-means clustering showcluster(cluster,'irises1.dat'); % shows clusters in 3D projection obtained by PCA [output_matrix] = test_tableform('ireses_gt.txt',cluster,3); %if the ground truth is know, this function compares the clustering result to it

Conclusion After segmenting the image, the contours of objects can be extracted using edge detection and/or border following techniques. Image segmentation techniques are extensively used in Similarity Searches, e.g.: