Movatterモバイル変換


[0]ホーム

URL:


CN112364876A - Efficient bar code binarization method and system - Google Patents

Efficient bar code binarization method and system
Download PDF

Info

Publication number
CN112364876A
CN112364876ACN202011337507.8ACN202011337507ACN112364876ACN 112364876 ACN112364876 ACN 112364876ACN 202011337507 ACN202011337507 ACN 202011337507ACN 112364876 ACN112364876 ACN 112364876A
Authority
CN
China
Prior art keywords
binarization
sampling
unit
bar code
suspicious
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202011337507.8A
Other languages
Chinese (zh)
Other versions
CN112364876B (en
Inventor
黄金煌
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Unigroup Tsingteng Microsystems Co Ltd
Original Assignee
Beijing Unigroup Tsingteng Microsystems Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Unigroup Tsingteng Microsystems Co LtdfiledCriticalBeijing Unigroup Tsingteng Microsystems Co Ltd
Priority to CN202011337507.8ApriorityCriticalpatent/CN112364876B/en
Publication of CN112364876ApublicationCriticalpatent/CN112364876A/en
Application grantedgrantedCritical
Publication of CN112364876BpublicationCriticalpatent/CN112364876B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Images

Classifications

Landscapes

Abstract

The invention provides a high-efficiency bar code binarization method and system. The method constructs a sampling image based on a sampling grid, and completes sampling point binarization through a secondary verification method. The method comprises the following steps: constructing a sampling grid, wherein the sampling grid covers the center of a corresponding bar code minimum module; generating a sampling graph by adopting an interpolation method according to the sampling grid position; performing binarization on the sampling image by adopting a first binarization method; performing binarization on the sampled image by adopting a second binarization method; judging whether each sampling point is the same based on the first binarization result and the second binarization result, if the judgment result is yes, storing the binarization result of the sampling point, and if the judgment result is no, marking the sampling point as a suspicious point; and carrying out binarization again on the suspicious sampling points according to a third binarization method, and storing binarization results. The invention also provides an efficient bar code binarization system. The efficient barcode binarization method and the efficient barcode binarization system provided by the invention can quickly solve the problem that the barcode binarization with blur, low contrast and low precision is inaccurate, and have better robustness.

Description

Efficient bar code binarization method and system
Technical Field
The invention relates to the technical field of electronic science, in particular to a bar code binarization method and a bar code binarization system.
Background
The advent of barcode technology has greatly facilitated the rapid development of industrial society. The barcode identification technology remarkably improves the completion efficiency of each task no matter production and transportation, logistics storage, or product part tracking and the like.
The barcode identification technology appears earlier, but the research in the field starts later in China, and although the technology has already advanced, the technology has a certain gap compared with the foreign barcode identification technology. In practical application, the barcode recognition environment is more complex and changeable, so that low-quality barcode images such as blur, low contrast, low precision and the like can be more easily acquired, the low-quality images can seriously affect the barcode binarization effect, and the accuracy of barcode binarization is the key for determining the performance of a barcode recognition algorithm.
Therefore, in order to solve the above problems, an efficient and stable binarization method is needed to improve the barcode recognition efficiency.
Disclosure of Invention
Aiming at the problem that the existing fuzzy, low-contrast and low-precision bar code binaryzation is inaccurate, the invention provides a bar code binaryzation method and a bar code binaryzation system, which can ensure that the bar code binaryzation is completed efficiently and accurately.
One of the present invention is realized by: an efficient bar code binarization method is used for constructing a sampling image based on a sampling grid and completing binarization of sampling points by a secondary verification method, and comprises the following steps:
step 1, constructing a sampling grid;
step 2, generating a sampling graph by adopting an interpolation method according to the grid position;
step 3, performing binarization on the sampling image by adopting a first binarization method;
step 4, performing binarization on the sampled image by adopting a second binarization method;
step 5, judging whether two binarization results of each sampling point in the step 4 and thestep 5 are the same, if the judgment result is yes, storing the binarization result of the sampling point, and if the judgment result is no, marking the sampling point as a suspicious point;
and 6, re-performing binarization on the suspicious points according to a third binarization method, and storing binarization results.
Further, in step 1, the sampling grid needs to cover the central point of the corresponding barcode minimum module.
Further, in the step 2, the interpolation method may be nearest neighbor interpolation, bilinear interpolation, weighted average, or other interpolation methods.
Further, the binarization method can map the sampling image into a black-and-white binary image;
further, in thesteps 5 and 6, the first, second and third binarization methods are different from each other, and the three binarization methods may be completed based on different principles or different manners. The precision of the third binarization method is higher than the precision of the first binarization method and the second binarization method, and the execution efficiency of the first binarization method and the second binarization method is obviously better than that of the third binarization method;
further, the two binarization methods adopt different design ideas and can be global binarization methods, local binarization methods and the like;
further, the two binarization modes adopt the same principle, but different modes, and can be image binarization based on waveform analysis line by line, and the like.
The second invention is realized by the following steps: an efficient barcode binarization system, comprising: the device comprises a sampling grid construction unit, a gray value sampling unit, a binarization unit I, a binarization unit II, a binarization result comparison unit, a suspicious binarization result screening unit, a binarization unit III, a correct binarization result screening unit and a binary image storage unit.
The sampling grid construction unit is used for establishing a sampling grid according to the position of the bar code symbol;
the gray value sampling unit completes the gray value sampling of the minimum module of the bar code by any interpolation method according to the sampling grid position;
a first binarization unit for performing first binarization processing on the sampling matrix;
a second binarization unit which executes second binarization processing on the sampling matrix;
the binarization result comparison unit is used for performing comparison operation on output results of the first binarization unit and the second binarization unit, wherein the output results are marked as 1 in the same way and are marked as 0 in different ways;
the suspicious binarization screening unit screens out the sampling points marked as 0 and marks the sampling points as suspicious binarization sampling points;
a third binarization unit, which is used for carrying out third binarization processing on the suspicious binarization sampling points;
a correct binarization screening unit for screening out the sampling points marked as 1 and marking the sampling points as correct binarization sampling points;
and the binary image storage unit is used for storing the sampling result of the correct binary sampling point and the binary result of the suspicious binary sampling point after the third binary operation.
Furthermore, the sampling grid needs to be covered to the central position of the corresponding bar code minimum module;
furthermore, the gray value sampling unit completes the gray value sampling of the minimum module of the bar code by any interpolation method according to the sampling grid position, and constructs a gray sampling matrix;
the bar code binarization method and the bar code binarization system comprehensively consider the balance between time and performance, the adopted first binarization method and the adopted second binarization method have high execution efficiency, and most sampling points are ensured to have correct binarization results. And (4) screening out suspicious binary sampling points by comparing two binary results, and further completing binary processing on the suspicious sampling points by adopting a third binary method with high accuracy so as to complete the binarization of the whole sampling matrix. On the premise of ensuring the binarization accuracy, the invention improves the system operation efficiency and solves the problem that the precision and the efficiency can not be considered at the same time to a certain extent.
[ description of the drawings ]
Fig. 1 shows a flow chart of a bar code binarization method of the present invention.
Fig. 2 is a schematic structural diagram of a bar code binarization system of the invention.
Fig. 3 illustrates an alternative binarization method in accordance with an embodiment of the present invention.
Fig. 4 illustrates an alternative suspicious node binarization determination method according to an embodiment of the present invention.
[ detailed description ] embodiments
With regard to the features and technical content of the present invention, reference is made to the following detailed description and accompanying drawings, which are provided for reference and illustration only and are not intended to limit the invention.
Referring to fig. 1, a flowchart of a barcode binarization method of the present invention is shown, and the barcode binarization method specifically includes the following steps:
and S100, constructing sampling grids, wherein each independent grid can accurately cover the central point of the bar code module.
And step S200, extracting a sampling point gray value of the bar code module on a sampling grid according to an interpolation algorithm to obtain a sampling image.
And step S300, performing binarization operation once on the sampled image to obtain a binarized image A.
In step S400, another binarization operation is performed on the sampled image to obtain a binarized image B.
Step S500, initializing i =0, comparing whether the binarization attributes of the i-th module in the a/B are the same, if the result is yes, executing S700, and if the result is no, executing S600.
In step S600, the binarization is re-executed for the i-th module.
And S700, storing the binary attribute of the ith module, i plus 1.
Step S800, determining whether the i-th module is the last unprocessed module in the sampling graph, if the determination result is "yes", executing step S900, and if the determination result is "no", executing step S500.
Step S900: and after traversing all the sampling modules, completing the binaryzation of the bar code.
Referring to fig. 2, a schematic structural diagram of a barcode binarization system of the present invention is shown, wherein the system structure includes the following units:
and the sampling grid construction unit 100 is used for establishing a sampling grid according to the position of the bar code symbol, wherein the sampling grid needs to cover the central position of the corresponding bar code minimum module.
And the gray value sampling unit 200 completes the gray value sampling of the minimum module of the bar code by any interpolation method according to the sampling grid position.
The binarization unit one 300 performs a first binarization process on the sampling matrix.
And asecond binarization unit 400 for performing a second binarization process on the sampling matrix.
And the binarization result comparing unit 500 is used for performing comparison operation on the output results of the first binarization unit and the second binarization unit, wherein the same mark is 1, and the different marks are 0.
And the suspicious binarization screening unit 600 screens out the sampling points marked as 0 and marks the sampling points as suspicious binarization sampling points.
And athird binarization unit 700 for carrying out third binarization processing on the suspicious binarization sampling points.
The correctbinarization screening unit 800 screens out the sampling points marked as 1, and marks the sampling points as correct binarization sampling points.
The binaryimage storage unit 900 stores the sampling result of the correct binary sampling point and the binary result of the suspicious binary sampling point after the third binary operation.
Referring to fig. 3, an alternative binarization method is shown in the embodiment of the present invention. The first binarization method in the method is to traverse the sampled image line by line, perform waveform analysis operation on each one-dimensional data, and determine the binary attribute of the current module according to the peak-trough attribute of each module. Due to image noise, the sampled image binarization result is seriously influenced by gray value fluctuation caused by factors such as local gray level unevenness of the image, and the reliability of the binarization result is reduced. According to the present invention, a second binarization method may be performed, i.e., traversing the sampled image again column by column, and performing a waveform analysis operation. After the binarization based on waveform analysis in the row and column direction, if the two binarization results are different, the module is determined to be a suspicious binarization module.
Referring to fig. 4, a method for binary determination of a selectable suspicious point is disclosed. Due to the problems of image noise, uneven local gray level of an image and the like, the binary attribute of the module cannot be determined by a single threshold, and the binary attribute of the module highly depends on the gray value distribution of the local neighborhood.
As shown in fig. 4, 3 examples of determining the binary attribute of the suspect module are listed.
As shown in fig. 4(a), the attribute of the vertical analysis display center module is "white", the horizontal analysis display center module is in the gray transition area, but the gray value of the center module is similar to the gray value of the left module, and the left module is obviously "white", and the module can be determined to be "white".
As shown in fig. 4(b), the attribute of the central module is "black" in the vertical analysis display, the central module is in the excessive gray level region in the horizontal analysis display, but the gray level value of the central module is similar to the gray level value of the left module, and the left module is obviously "black", and the module can be judged to be "black".
As shown in fig. 4(c), the attribute of the vertical analysis display center module is "white", and the attribute of the horizontal analysis display center module is "white", so that it can be determined that the module attribute is "white".
The foregoing is merely a preferred embodiment of the present invention, and various modifications and changes in form can be made by those skilled in the art without departing from the spirit and scope of the present invention, and it is within the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the appended claims.

Claims (10)

CN202011337507.8A2020-11-252020-11-25Efficient bar code binarization method and systemActiveCN112364876B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN202011337507.8ACN112364876B (en)2020-11-252020-11-25Efficient bar code binarization method and system

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN202011337507.8ACN112364876B (en)2020-11-252020-11-25Efficient bar code binarization method and system

Publications (2)

Publication NumberPublication Date
CN112364876Atrue CN112364876A (en)2021-02-12
CN112364876B CN112364876B (en)2024-05-14

Family

ID=74533258

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN202011337507.8AActiveCN112364876B (en)2020-11-252020-11-25Efficient bar code binarization method and system

Country Status (1)

CountryLink
CN (1)CN112364876B (en)

Citations (11)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
KR19990034030A (en)*1997-10-281999-05-15윤종용 One-dimensional local adaptive image binarization apparatus and method
CN101727582A (en)*2008-10-222010-06-09富士通株式会社Method and device for binarizing document images and document image processor
CN101789081A (en)*2009-01-222010-07-28佳能株式会社Binaryzation method for blurry document image and equipment thereof
CN101840499A (en)*2010-06-012010-09-22福建新大陆电脑股份有限公司Bar code decoding method and binarization method thereof
CN103839031A (en)*2014-02-272014-06-04杭州晟元芯片技术有限公司Special embedded type two-dimensional code recognition method
WO2018081929A1 (en)*2016-11-012018-05-11深圳大学Hyperspectral remote sensing image feature extraction and classification method and system thereof
CN108460389A (en)*2017-02-202018-08-28阿里巴巴集团控股有限公司A kind of the type prediction method, apparatus and electronic equipment of identification objects in images
CN108960222A (en)*2017-05-262018-12-07深圳怡化电脑股份有限公司Image binaryzation method, device, equipment and storage medium
CN109273000A (en)*2018-10-112019-01-25河南工学院 Speech recognition method
CN110263610A (en)*2019-02-282019-09-20重庆大学A kind of degeneration file and picture binary coding method and system based on deep learning
RU2718571C1 (en)*2019-10-252020-04-08Общество С Ограниченной Ответственностью "Конструкторское Бюро "Дорс" (Ооо "Кб "Дорс")Method for binarisation of images of symbols on a banknote based on histogram of length of boundaries

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
KR19990034030A (en)*1997-10-281999-05-15윤종용 One-dimensional local adaptive image binarization apparatus and method
CN101727582A (en)*2008-10-222010-06-09富士通株式会社Method and device for binarizing document images and document image processor
CN101789081A (en)*2009-01-222010-07-28佳能株式会社Binaryzation method for blurry document image and equipment thereof
CN101840499A (en)*2010-06-012010-09-22福建新大陆电脑股份有限公司Bar code decoding method and binarization method thereof
CN103839031A (en)*2014-02-272014-06-04杭州晟元芯片技术有限公司Special embedded type two-dimensional code recognition method
WO2018081929A1 (en)*2016-11-012018-05-11深圳大学Hyperspectral remote sensing image feature extraction and classification method and system thereof
CN108460389A (en)*2017-02-202018-08-28阿里巴巴集团控股有限公司A kind of the type prediction method, apparatus and electronic equipment of identification objects in images
CN108960222A (en)*2017-05-262018-12-07深圳怡化电脑股份有限公司Image binaryzation method, device, equipment and storage medium
CN109273000A (en)*2018-10-112019-01-25河南工学院 Speech recognition method
CN110263610A (en)*2019-02-282019-09-20重庆大学A kind of degeneration file and picture binary coding method and system based on deep learning
RU2718571C1 (en)*2019-10-252020-04-08Общество С Ограниченной Ответственностью "Конструкторское Бюро "Дорс" (Ооо "Кб "Дорс")Method for binarisation of images of symbols on a banknote based on histogram of length of boundaries

Also Published As

Publication numberPublication date
CN112364876B (en)2024-05-14

Similar Documents

PublicationPublication DateTitle
CN109002824B (en)OpenCV-based building drawing label information detection method
CN113343740B (en)Table detection method, device, equipment and storage medium
CN112183511A (en)Method, system, storage medium and equipment for deriving table from image
CN102243704A (en)Positioning system for two-dimension bar code and two-dimension bar code identification method and equipment
CN110647795A (en)Form recognition method
CN104463795A (en)Processing method and device for dot matrix type data matrix (DM) two-dimension code images
CN111626145B (en)Simple and effective incomplete form identification and page-crossing splicing method
US20120148101A1 (en)Method and apparatus for extracting text area, and automatic recognition system of number plate using the same
CN111582000B (en)Bar code positioning method, bar code positioning device and related equipment
CN115376149A (en) A method for identifying reimbursement invoices
CN116612280A (en)Vehicle segmentation method, device, computer equipment and computer readable storage medium
CN112801960A (en)Image processing method and device, storage medium and electronic equipment
CN119399465B (en)Roof photovoltaic identification and evaluation method based on key point detection enhanced semantic segmentation
CN114140620B (en) A method for detecting straight line contour of an object
CN113392455B (en)House pattern scale detection method and device based on deep learning and electronic equipment
CN114863129A (en)Instrument numerical analysis method, device, equipment and storage medium
JPH10307889A (en)Character recognition method, its device and recording medium recording character recognition program
CN114140336A (en)Infrared image-based dead pixel processing method and device
CN202267974U (en)Positioning system used for two-dimension code and two-dimension code identification device
CN112364876B (en)Efficient bar code binarization method and system
CN114511862B (en)Form identification method and device and electronic equipment
CN111753842A (en)Bill text region detection method and device
Wang et al.Road extraction from high-spatial-resolution remotely sensed imagery by combining multi-profile analysis and extended Snakes model
CN117765541B (en) Passport image alignment method and device
CN105513044B (en)A kind of digital direct straight line segments recognition method based on statistical measures linear feature

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination
GR01Patent grant
GR01Patent grant

[8]ページ先頭

©2009-2025 Movatter.jp