Lab Session 9: Object Detection and Counting Using Region Properties With Image Region Analyzer
Lab Session 9: Object Detection and Counting Using Region Properties With Image Region Analyzer
Problem Statement:
Machine vision systems can be used to automate objects detection and recognition.
Develop and implement MV-based application that can detect and count the
number of Saudi metal coins in an image. Your application should label each coin
piece by its weight and printout the total value of the coins in an image. Use the
given three images to test your developed application.
Img1, Img2, Img3
Output Image
Introduction to Image region Analyzer App in Matlab:
The Image Region Analyzer app measures a set of properties for each
connected component (also called an object or region) in a binary image and
displays this information in a table. You can also use this app to create other
binary images by filtering the image on region properties.
In this object detection method, it is necessary to have approximated Area
of each coin, Image Region Analyzer helps to interactively solve this issue. When
you click on any entry in the table on right, respective object would be
highlighted.
∙ Run a loop and use Area properties of coins to threshold different objects
i. count 1Halala, 5 Halala and 10 Halala coins and increment that coin
counter and place object annotation using centroid and radius value
coinImg = insertObjectAnnotation(coin1,'circle',[x y rad],...
'5 HALALS','LineWidth',3,'Color','red','FontSize',10);
SR5 = SR5+1;
ii. Place titles on image as shown in result.