Program Studi S-1 Teknik Informatika FMIPA Universitas Padjadjaran COMPUTER VISION D10K-7C02 CV08: Binary Image Analysis: Moments and CCL Dr. Setiawan Hadi, M.Sc.CS. Program Studi S-1 Teknik Informatika FMIPA Universitas Padjadjaran
Citra Biner Citra yang hanya mengandung 2 macam intensitas, umumnya HITAM (0) atau PUTIH (1 atau 255) Merepresentasikan Background (0) dan Objek (1) Metode Pembuatan Preprocessing: Konversi Warna ke Gray Level Thresholding: Simple Thresholding Multilevel/Adaptive Thresholding OTSU Thresholding
Representasi Citra Biner
Histogram Citra Biner
Metode Pembuatan Citra Biner Simple Thresholding
Metode Pembuatan Citra Biner Multilevel/Adaptive Thresholding
Metode Pembuatan Citra Biner OTSU Thresholding Nobuyuki Otsu, A Threshold Selection Method from Gray-Level Histograms, IEEE Transactions on System, Man, and Cybernetics. SMC-9(1), 1979, Electro-Technical Laboratory, Tokyo University(2007), Tokyo, Japan http://www.codeproject.com/Articles/38319/Famous-Otsu-Thresholding-in-C
Analisis Citra Biner Image Enhancement Image Analysis Filter Morfologis (Preprocessing) Image Analysis Metode Moments Connected Component Labelling
MOMENTS
Moment Digunakan untuk mendapatkan properti geometris dari objek : Ukuran (size) Posisi (pusat objek) Orientasi (kemiringan) Formula Moment
Coba cari nilai moment ini ! Momen Ordo 0 Untuk Mencari Luas Objek Coba cari nilai moment ini ! Momen Ordo 1 Untuk Mencari Pusat Objek
Contoh Perhitungan Moment Tentukan Zeroth dan First Order Moment dari objek berikut ini:
Contoh Perhitungan Moment Zeroth Order Moment Luas objek = A =m00 13 First Order Moment Posisi Objek (x,y) m10 = x = m01 = y =
Second Order Moment Digunakan untuk mencari orientasi atau kemiringan objek
Moments Invarian Moment dapat digunakan untuk menentukan karakteristik geometric dari sebuah objek Karakteristik ini bersifat invariant Tidak berubah walau objek mengalami transformasi Translasi Dilatasi Rotasi Refleksi Tujuh nilai moment yang menunjukkan karakteristik invariant (Hu, 1961)
http://www. codeproject http://www.codeproject.com/Articles/35895/Computer-Vision-Applications-with-C-Part-II
Tugas ‘ATM’ program berikut: http://www.codeproject.com/Articles/35895/Computer-Vision-Applications-with-C-Part-II
CONNECTED COMPONENT LABELLING
Apa itu Connected Component Labeling Istilah lain connected-component analysis blob extraction region labeling blob discovery region extraction is an algorithmic application of graph theory, where subsets of connected components are uniquely labeled based on a given heuristic. Connected-component labeling is not segmentation. Connected-component labeling is used in computer vision to detect connected regions in binary digital images, although color images and data with higher-dimensionality can also be processed. When integrated into an image recognition system or human-computer interaction interface, connected component labeling can operate on a variety of information. Blob extraction is generally performed on the resulting binary image from a thresholding step. Blobs may be counted, filtered, and tracked.
Ilustrasi
Aplikasi: Aircraft Identification by Silhoute
Ilustrasi Cara Kerja CCL In the beginning, we have this image, we start with currentLabelCount = 1.
Ilustrasi Cara Kerja CCL Found non-background pixel
Ilustrasi Cara Kerja CCL Gets its non-background pixel neighbours
Ilustrasi Cara Kerja CCL Set the current pixel to the currentLabelCount and increment it , we also set the label's parent to itself
Ilustrasi Cara Kerja CCL on to the next pixel, this one has a neighbour which is already labeled:
Ilustrasi Cara Kerja CCL assigns the pixel's parent label to that of the neighbour
Ilustrasi Cara Kerja CCL Continue on, none of the neighbours of this pixel is labeled:
Ilustrasi Cara Kerja CCL We increment currentLabelCount and assign it to the pixel, again its parent is set to itself:
Ilustrasi Cara Kerja CCL It gets interesting here, when neighbors have different labels:
Ilustrasi Cara Kerja CCL Choose main label, i.e.: that would be the smallest label in the discovered list--> (1) Set it to be the parent of the other labels
Ilustrasi Cara Kerja CCL Continue the process. Notice the blue number in the upper right corner, that's the parent label
Algorithm CCL First pass, assigning labels
Algorithm CCL Second pass, aggregating labels
8-CCL
Tugas ‘ATM ‘ program CCL http://www.codeproject.com/Articles/336915/Connected-Component-Labeling-Algorithm
EULER NUMBER
What is Euler Number in Binary Image Euler Number = the number of objects minus the number of holes.
Ilustrasi 7 objects 3 holes Euler = 4
Ilustrasi
Ilustrasi
Ilustrasi All the circles touch so they create one object. The object contains four "holes", which are the black areas created by the touching circles. Thus the Euler number is 1 minus 4, or -3.
The Euler Number is not a good shape descriptor. About Euler Number The Euler Number is not a good shape descriptor.
Program CCL