Implementation of Barcode Localization Technique using Morphological Operations

Similar documents
A novel method for accurate and efficient barcode detection with morphological operations

Improved 1D and 2D barcode detection with morphological operations

License Plate Localisation based on Morphological Operations

Reading Barcodes from Digital Imagery

Content Based Image Retrieval Using Color Histogram

An Efficient Method for Vehicle License Plate Detection in Complex Scenes

VEHICLE LICENSE PLATE DETECTION ALGORITHM BASED ON STATISTICAL CHARACTERISTICS IN HSI COLOR MODEL

INDIAN VEHICLE LICENSE PLATE EXTRACTION AND SEGMENTATION

8.2 IMAGE PROCESSING VERSUS IMAGE ANALYSIS Image processing: The collection of routines and

International Journal of Advanced Research in Computer Science and Software Engineering

Preprocessing and Segregating Offline Gujarati Handwritten Datasheet for Character Recognition

Detection of Defects in Glass Using Edge Detection with Adaptive Histogram Equalization

PRACTICAL IMAGE AND VIDEO PROCESSING USING MATLAB

Image Processing for feature extraction

Automatic Morphological Segmentation and Region Growing Method of Diagnosing Medical Images

BARCODE DETECTION WITH MORPHOLOGICAL OPERATIONS AND CLUSTERING

Lane Detection in Automotive

Quality Control of PCB using Image Processing

An Automatic System for Detecting the Vehicle Registration Plate from Video in Foggy and Rainy Environments using Restoration Technique

COMPARATIVE PERFORMANCE ANALYSIS OF HAND GESTURE RECOGNITION TECHNIQUES

Image Forgery Detection Using Svm Classifier

Detection of Faults Using Digital Image Processing Technique

SYLLABUS CHAPTER - 2 : INTENSITY TRANSFORMATIONS. Some Basic Intensity Transformation Functions, Histogram Processing.

Malaysian Car Number Plate Detection System Based on Template Matching and Colour Information

An Improved Bernsen Algorithm Approaches For License Plate Recognition

Global and Local Quality Measures for NIR Iris Video

Abstract. 2. SmartCamBCR: A Low Cost Barcode Reader. 1. Introduction

Image Quality Assessment for Defocused Blur Images

Keywords: Image segmentation, pixels, threshold, histograms, MATLAB

Tan-Hsu Tan Dept. of Electrical Engineering National Taipei University of Technology Taipei, Taiwan (ROC)

Color Image Segmentation Using K-Means Clustering and Otsu s Adaptive Thresholding

Digital Image Processing 3/e

Image Enhancement in Spatial Domain

Digital Image Processing

2D Barcode Localization and Motion Deblurring Using a Flutter Shutter Camera

Carmen Alonso Montes 23rd-27th November 2015

Teaching Scheme. Credits Assigned (hrs/week) Theory Practical Tutorial Theory Oral & Tutorial Total

Wheeler-Classified Vehicle Detection System using CCTV Cameras

An Effective Method for Removing Scratches and Restoring Low -Quality QR Code Images

An Improved Binarization Method for Degraded Document Seema Pardhi 1, Dr. G. U. Kharat 2

Image processing for gesture recognition: from theory to practice. Michela Goffredo University Roma TRE

SRI VENKATESWARA COLLEGE OF ENGINEERING. COURSE DELIVERY PLAN - THEORY Page 1 of 6

Number Plate recognition System

MAV-ID card processing using camera images

AN IMPROVED NO-REFERENCE SHARPNESS METRIC BASED ON THE PROBABILITY OF BLUR DETECTION. Niranjan D. Narvekar and Lina J. Karam

International Journal of Innovative Research in Engineering Science and Technology APRIL 2018 ISSN X

Implementation of License Plate Recognition System in ARM Cortex A8 Board

Contrast adaptive binarization of low quality document images

More image filtering , , Computational Photography Fall 2017, Lecture 4

Vision Review: Image Processing. Course web page:

Color Image Encoding Using Morphological Decolorization Noura.A.Semary

Linear Gaussian Method to Detect Blurry Digital Images using SIFT

Digital Image Processing

INSTITUTE OF AERONAUTICAL ENGINEERING Dundigal, Hyderabad

Automatic License Plate Recognition System using Histogram Graph Algorithm

Live Hand Gesture Recognition using an Android Device

Adaptive Feature Analysis Based SAR Image Classification

ME 6406 MACHINE VISION. Georgia Institute of Technology

AN EXPANDED-HAAR WAVELET TRANSFORM AND MORPHOLOGICAL DEAL BASED APPROACH FOR VEHICLE LICENSE PLATE LOCALIZATION IN INDIAN CONDITIONS

Blur Estimation for Barcode Recognition in Out-of-Focus Images

IMAGE TYPE WATER METER CHARACTER RECOGNITION BASED ON EMBEDDED DSP

Urban Feature Classification Technique from RGB Data using Sequential Methods

Automatic Number Plate Extraction: A Review

Efficient 2-D Structuring Element for Noise Removal of Grayscale Images using Morphological Operations

Image Enhancement for Astronomical Scenes. Jacob Lucas The Boeing Company Brandoch Calef The Boeing Company Keith Knox Air Force Research Laboratory

Chapter 17. Shape-Based Operations

Research on Pupil Segmentation and Localization in Micro Operation Hu BinLiang1, a, Chen GuoLiang2, b, Ma Hui2, c

Computing for Engineers in Python

An Efficient Color Image Segmentation using Edge Detection and Thresholding Methods

Automated License Plate Recognition for Toll Booth Application

Target detection in side-scan sonar images: expert fusion reduces false alarms

A Proficient Roi Segmentation with Denoising and Resolution Enhancement

EE 5359 MULTIMEDIA PROCESSING. Vehicle License Plate Detection Algorithm Based on Statistical Characteristics in HSI Color Model

[Mohindra, 2(7): July, 2013] ISSN: Impact Factor: 1.852

CS534 Introduction to Computer Vision. Linear Filters. Ahmed Elgammal Dept. of Computer Science Rutgers University

An Adaptive Kernel-Growing Median Filter for High Noise Images. Jacob Laurel. Birmingham, AL, USA. Birmingham, AL, USA

Survey on Impulse Noise Suppression Techniques for Digital Images

COMPARITIVE STUDY OF IMAGE DENOISING ALGORITHMS IN MEDICAL AND SATELLITE IMAGES

Empirical Study on Quantitative Measurement Methods for Big Image Data

Lane Detection in Automotive

A Method of Multi-License Plate Location in Road Bayonet Image

CS6670: Computer Vision Noah Snavely. Administrivia. Administrivia. Reading. Last time: Convolution. Last time: Cross correlation 9/8/2009

Keyword: Morphological operation, template matching, license plate localization, character recognition.

An Analysis of Image Denoising and Restoration of Handwritten Degraded Document Images

PHASE PRESERVING DENOISING AND BINARIZATION OF ANCIENT DOCUMENT IMAGE

Adaptive Gamma Correction With Weighted Distribution And Recursively Separated And Weighted Histogram Equalization: A Comparative Study

Vehicle Number Plate Recognition with Bilinear Interpolation and Plotting Horizontal and Vertical Edge Processing Histogram with Sound Signals

Road Network Extraction and Recognition Using Color

Preparing Remote Sensing Data for Natural Resources Mapping (image enhancement, rectifications )

Anna University, Chennai B.E./B.TECH DEGREE EXAMINATION, MAY/JUNE 2013 Seventh Semester

Feature Extraction Techniques for Dorsal Hand Vein Pattern

Restoration of Motion Blurred Document Images

Blur Detection for Historical Document Images

Table of contents. Vision industrielle 2002/2003. Local and semi-local smoothing. Linear noise filtering: example. Convolution: introduction

MATHEMATICAL MORPHOLOGY AN APPROACH TO IMAGE PROCESSING AND ANALYSIS

Color Image Segmentation in RGB Color Space Based on Color Saliency

Secured Bank Authentication using Image Processing and Visual Cryptography

Traffic Sign Recognition Senior Project Final Report

IMAGE ENHANCEMENT - POINT PROCESSING

A New Scheme for No Reference Image Quality Assessment

Transcription:

Implementation of Barcode Localization Technique using Morphological Operations Savreet Kaur Student, Master of Technology, Department of Computer Engineering, ABSTRACT Barcode Localization is an extremely important task in Barcode Reading system which depends highly on imaging conditions and methods used for barcode localization. In this paper, we have presented a method for barcode localization which is based on basic morphological operations. The method introduced is implemented in MATLAB 2012 and is then examined for different types of test images such as images with skewed, blurry or multiple barcodes in an image. The method is then compared with some existing methods of literature on the basis of these test images. It has been found that the performance of the algorithm depends upon the proper choice of the switching element. Keywords Barcode Localization, Morphology, Bottom- Hat Filter, Directional Image Opening. 1. INTRODUCTION Barcodes are 1- dimensional group of parallel lines that carry alphanumeric information which can be read using computers, smart phones etc [7]. The main principle behind barcodes is to encode information in bars and spaces of varying widths along with redundant information for error correction. These are a very convenient and an efficient method of data representation and can be of very big help in today s world where amount of information is increasing exponentially. In order to fully utilize the power of barcodes, we need the process of Barcode Localization. Barcode Localization means locating or finding barcodes in simple or complex images. It is mainly based on two main properties of barcodes. First property of barcode is that it contains black bars against a white background. Second property of barcodes states that it has a strong directional continuity. It means that barcodes have very strong continuity at one particular orientation and very low in all other orientations [4]. Many methods for Barcode Localization exist such as method based on basic morphology [2] and Juett and method based on Bottom- Hat filtering [4]. In this paper, we have implemented a Barcode Localization method. It is based on both Bottom- Hat filtering and basic morphology. Our main aim was to devise a method for barcode localization which works well for most of the imaging conditions and different types of test images. This paper is organized as follows: In Section- 2, we will discuss some Related Work to our research work which has been done previously. In Section- 3, we will discuss our improved method using various steps of implementation. Section- 4 covers the Results and Discussion part of the implementation using qualitative and quantitative analysis of Raman Maini, Ph.D Professor, Department of Computer Engineering, Punjabi University, Patiala the resultant images. Finally, Section- 5 covers the conclusion part. 2. RELATED WORK Many methods for Barcode Localization exist; some of which come under Spatial Domain s while others come under Frequency Domain s. In the following paragraphs we will discuss both these categories of Barcode Localization. Spatial Domain s are those which search for group of dark lines on white background and which also have very strong directional continuity at a particular angle so as to locate barcodes [4][8]. For example, method uses basic morphological operations to localize barcodes. It basically relies on the fact that due to high intensity difference between bars and the background, gradient calculation using sobel kernel highlights the bars [2]. method is based on Bottom- Hat filtering instead of edge detection so as to highlight bars. Although, it takes more time than the previous method but its results are more accurate [4]. Telkin and Coughlan s method is based on scanning the image in four directions (0, 90, 180 and 270 ) so as to localize barcodes. It was designed mainly for visually impaired and blind people so as to` help them in their routine tasks [3]. Other methods also exist for barcode localization which are based on Frequency Domain s. For example, methods based on wavelet transformation look at images for barcode like appearance by a cascaded set of weak classifiers. Each classifier works in wavelet domain by searching for areas in the image that may contain barcodes [7]. A. K. Jain and Yao Chen s method is based on multi channel Gabor filtering technique which can locate barcodes at any orientation and can also locate them on both planar and curved surfaces. Other methods also exist which use other types of transformations such as Hough Transformation and Fourier Transform. In this research work, our goal is to implement a barcode localization method which works well under different imaging conditions and for different test images. 3. IMPLEMENTATION OF BARCODE LOCALIZATION METHOD In this section we will discuss the implementation of Barcode Localization. This method based on method based on basic morphological operations and Juett and Barcode Localization method based on Bottom- Hat Filtering. Various steps in this method are given as under: ALGORITHM (i) Initial Pre- processing of Input Image (ii) Bottom- Hat Filtering (iii) Binarizing the resultant image (iv) Dilation using Square Structuring element (v) Erosion using Square Structuring element 42

(vi) Removing Small area objects (vii) Obtaining true shape of the barcodes (viii)finding Barcode Orientation Each of the above steps can be explained as under: Step 1- Initial Pre- processing of Input Image In this method, the input image is first converted to greyscale intensity image. After this contrast stretching is performed to highlight the difference between light and dark areas. Fig. 3: Image after performing Bottom- Hat filtering to highlight bars. Step 3- Binarizing the resultant image After this the resultant image is converted to binary using Otsu s global thresholding method. Fig. 1: Original Image from which barcodes are to be localized [7] Fig. 2: Image after conversion to gray scale and Contrast Stretching Step 2- Bottom- Hat Filtering This method uses two important properties of barcodes i.e. they contain black bars against white background and that they have strong directional continuity, so as to highlight barcodes. In this initially, close of image is taken which expands the white areas in the image, by expanding areas around black bars but does not affect the areas which are already white. So, when we subtract the obtained image from the original image, the resultant image shows highlighted bars of the barcodes. Close of image is performed by using a square structuring element whose side needs to be at least as wide as widest bar in the barcodes. Fig. 4: Image after binarizing the resultant of Bottom- Hat filtering using Otsu s Threshold method Step 4- Dilation using Square Structuring element After this dilation is performed so as to merge the nearby areas so that the barcodes form a region. Fig. 5: Image after Dilation of the Binary Image 43

Step 5- Erosion using Square Structuring element After this erosion is performed using square structuring element having side greater than the square using which dilation was performed so as to discard thin objects. Fig.8: Image after subtracting the resultant from the original image to obtain true shape of the barcodes Step 8- Finding Barcode Orientation After this directional opening is performed using linear structuring element in 20 different directions so as to find the orientation of barcodes. Fig. 6: Image after eroding the resultant so as to eliminate thin objects Step 6- Removing Small area objects After this small area objects, which is mostly noise are removed so that the resultant image contains only barcodes. Fig. 7: Image after removing small area objects Step 7- Obtaining true shape of the barcodes After this the resultant image is subtracted from original image to obtain true shape of the barcode. Fig. 9: Image showing the orientation of the barcodes (90 ) 4. RESULTS AND DISCUSSION 4.1 Test suite, Test Environment and Implementation Experiments were conducted on test images having dimensions as 720 x 480 or 640 x 480 and in PNG format taken from [1] and [4]. Test images included images having multiple barcodes, skewed barcodes, images with complex background and images having noise. We implemented the algorithm given in previous section using MATLAB 2012 with the help of the Image Processing Toolbox. Evaluation was performed on a computer with Intel Core i3 2.40 GHz CPU, 3 GB RAM and Windows 7 (64- bit) operating system. 4.2 Results Proposed method is analyzed both qualitatively and quantitatively so as to find its advantages over existing methods. So, in this section we are comparing the proposed method with existing methods both quantitatively and qualitatively. Qualitative Analysis: In this section we will evaluate the method presented in above section for different types of images such as skewed, blurred, and complex and when there are multiple barcodes in an image as shown in the table below: 44

Table I: Table showing Qualitative analysis of different test images using existing methods and method implemented Original Image Results* Normal Barcodes [7] Skewed Barcodes Multiple Barcodes [4] Blurred Barcodes [4] 45

Complex Image [4] *Images obtained through implementation in MATLAB Quantitative Analysis is analyzed quantitatively on the basis of following parameters: (i) Orientation: The Barcode Localization method discussed gives the orientation of the barcodes in the input image using directional opening in 20 different directions starting from 0 and incrementing successively by 9. (ii) Structural Similarity Index (SSIM) Structural Similarity Index is an image quality metric that assesses the visual impact of three characteristics of an image: luminance, contrast and structure. In other words, the Structural Similarity (SSIM) index is a method for measuring the similarity between two images. The SSIM is used as a quality measure in which one image is compared to another, assuming that the other image is of very good quality [10]. Where, (iii) Coefficient of Correlation (COC) The quantity r, called the linear coefficient of correlation measures the strength and the direction of a linear relationship between two images or variables. The linear correlation coefficient is also called Pearson Product Moment Correlation Coefficient. The mathematical formula for Coefficient of Correlation is [12]: where n is the number of pairs of data. Value of r can be positive, negative or zero. Positive Correlation: In case two variables or images have strong positive relationship then value of r is near +1. Value of r exactly +1 indicates a perfect positive fit. Positive correlation means that with increase in one variable the other variable also increases proportionally [12]. Negative Correlation: In case two variables or images have strong negative relationship then value of r is near -1. An r value of exactly -1 indicates a perfect negative fit. Negative correlation means that with increase in one variable the other variable will decrease proportionally [12]. Table II: Table showing parameter value for Normal Barcodes Results for Normal Barcodes where, μ x, μ y = local means σ x,σ y = standard deviations σ xy = cross- covariance for images x, y If α = β = γ = 1 and C 3 = C 2 /2 (default selection of C 3 ) the index simplifies to: Orientation NA 90 90 SSIM 0.5649 0.7324 0.7339 COC -0.8280-0.8654-0.8579 46

Table III: Table showing parameter value for Skewed Barcodes Results for Skewed Barcodes Orientation NA 135 135 SSIM 0.6308 0.7742 0.7746 COC -0.8195-0.85-0.8534 Table IV: Table showing parameter value for Multiple Barcodes in an image Results for Multiple Barcodes in an image Orientation NA 33.75, 78.75, 168.75 36, 72, 171 SSIM 0.7221 0.8352 0.8627 COC -0.7662-0.7855-0.6644 Table V: Table showing parameter value for Blurred Barcodes Results for Blurred Barcodes Orientation NA 101.25 99 SSIM 0.7299 0.8312 0.8406 COC -0.6822-0.7067-0.6713 Table VI: Table showing parameter value for Complex Image Results for Complex Image Orientation NA 67.5 72 SSIM 0.8230 0.8980 0.8991 COC -0.8745-0.8834-0.8718 5. CONCLUSION In this paper, we have implemented a Barcode Localization algorithm which is based on basic morphological operations. The performance of this algorithm depends upon the proper choice of switching element. It works well for different categories of test images such as images with skewed, blurry, multiple barcodes as well as complex images containing barcodes. Thus, it can be used effectively under different kind of imaging conditions such as industrial set ups as well as using portable devices like mobile phones, laptops etc. Future work includes improving the timing results of the procedure and working on collared images as well as maximizing recall of barcodes in industrial environment and embedding Barcode Localization in camera software of portable mobile phones. 6. ACKNOWLEDGEMENT The authors would like to acknowledge the staff and laboratory attendants of Department of Computer Engineering, Punjabi University Patiala, for the useful inputs, discussion and feedback while writing this paper. 7. REFERENCES [1] Melinda Katona and Laszlo G. Nyul, A novel method for accurate and efficient barcode detection with morphological operations, Eighth International Conference on Signal Image Technology and Internet based Systems, pp. 307-314, 2012 [2] T. R. Tuinstra, Reading barcodes from digital imagery, Ph.D. Dissertation, Cedarville University, 2006. [3] E. Tekin and J. M. Coughlan, An algorithm enabling blind users to find and read barcodes, in Applications of Computer Vision (WACV), Proc IEEE Workshop Appl Comput Vis, 2009, pp. 1 8. [4] X. Q. James Juett, Barcode localization using bottomhat filter, NSF Research Experience for Undergraduates, 2005. [5] Chunhui Zhang, Jian Wang, Shi Han, Mo Yi and Zhengyou Zhang, Automatic Barcode Localization in Complex Scenes, IEEE international conference on Image Processing, pp. 497-500, 2006 [6] N. Otsu, A Threshold Selection from Gray Level Histograms, Automatica, vol 11, pp.- 285-296, 1975 [7] Peter Bodnar and Laszlo G. Nyul, Improving Barcode Detection with combination of Simple Detectors, Eighth International Conference on Signal Image Technology and Internet based Systems, pp. 300-306, 2012 [8] Aliasgar Kutiyanawala, Xiaojun Qi and Jiandong Tian, A Simple and Efficient Approach to Barcode Localization, 2009. [9] Anil K. Jain and Yao Che, Barcode Localization using Texture Analysis, Document Analysis and Recognition, 1993., Proceedings of the Second International Conference, 1993, pp. 41 44. [10] Wikipedia article on SSIM, http://en.wikipedia.org/wiki/structural_similarity [11] Formulae for SSIM, http://www.mathworks.in/help/images/ref/ssim.html [12] Article on Coefficient of Correlation, http://mathbits.com/mathbits/tisection/statistics2/correl ation.html IJCA TM : www.ijcaonline.org 47