Movatterモバイル変換


[0]ホーム

URL:


CN102750637B - The product false proof querying method based on machine vision of To enterprises user and system - Google Patents

The product false proof querying method based on machine vision of To enterprises user and system
Download PDF

Info

Publication number
CN102750637B
CN102750637BCN201210174981.2ACN201210174981ACN102750637BCN 102750637 BCN102750637 BCN 102750637BCN 201210174981 ACN201210174981 ACN 201210174981ACN 102750637 BCN102750637 BCN 102750637B
Authority
CN
China
Prior art keywords
correspondences
numeral
numerical character
ratio
threshold value
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.)
Expired - Fee Related
Application number
CN201210174981.2A
Other languages
Chinese (zh)
Other versions
CN102750637A (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.)
Dongguan Yifeng Lock Co Ltd
Original Assignee
Dongguan Yifeng Lock 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 Dongguan Yifeng Lock Co LtdfiledCriticalDongguan Yifeng Lock Co Ltd
Priority to CN201210174981.2ApriorityCriticalpatent/CN102750637B/en
Publication of CN102750637ApublicationCriticalpatent/CN102750637A/en
Application grantedgrantedCritical
Publication of CN102750637BpublicationCriticalpatent/CN102750637B/en
Expired - Fee Relatedlegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Landscapes

Abstract

Translated fromChinese

面向企业用户的基于机器视觉的产品防伪查询方法及系统,涉及产品防伪查询技术领域,其方法是在生产线安装三个摄像头;三个摄像头分别对产品的密码锁标签、防伪码标签、条形码标签拍照,以分别获取密码锁标签、防伪码标签、条形码标签的数字字符图像;通过计算得到查询表;利用算法并结合查询表处理,得到密码锁密码、防伪码和条形码对应的数字字符串;将该对应的数字字符串形成具有一一对应关系的文档上传至数据库,提供给用户端查询,这种模式在生产上可很好的提高效率,其系统包括具备机器视觉的智能设备和防伪查询终端服务器,智能设备内置防伪码自动识别软件,让用户可做到随时随地进行产品防伪查询,适用性高,可代替传统的人工防伪查询。

The product anti-counterfeiting query method and system based on machine vision for enterprise users relates to the technical field of product anti-counterfeiting query. The method is to install three cameras in the production line; the three cameras take pictures of the combination lock label, anti-counterfeiting code label and barcode label of the product respectively. , to obtain the digital character images of the combination lock label, anti-counterfeiting code label and barcode label respectively; obtain the lookup table through calculation; use the algorithm and combine the lookup table processing to obtain the number string corresponding to the combination lock password, anti-counterfeiting code and barcode; The corresponding digital string forms a document with a one-to-one correspondence and uploads it to the database, which is provided to the client for query. This mode can improve the efficiency of production. Its system includes smart devices with machine vision and anti-counterfeiting query terminal servers , Smart devices have built-in anti-counterfeiting code automatic identification software, allowing users to conduct product anti-counterfeiting inquiries anytime and anywhere. It has high applicability and can replace traditional manual anti-counterfeiting inquiries.

Description

Translated fromChinese
面向企业用户的基于机器视觉的产品防伪查询方法及系统Product anti-counterfeiting query method and system based on machine vision for enterprise users

技术领域technical field

本发明涉及产品防伪查询技术领域,特别是涉及面向企业用户的基于机器视觉的产品防伪查询方法及系统。The invention relates to the technical field of product anti-counterfeiting query, in particular to a machine vision-based product anti-counterfeiting query method and system for enterprise users.

背景技术Background technique

现在产品假冒伪劣问题随着科技发展而层出不穷,目前假冒伪劣对象主要针对名贵烟酒、高档服饰、奢侈品以及一些著名品牌的产品等。很多假冒伪劣产品采用原装正品用过的包装盒/瓶进行伪装,混淆消费者的视线,达到以假乱真的目的。同时在现有技术中,智能手机随着科学技术的发展日新月异,在市场上智能手机占有率比重越来越高,逐步取代功能手机;功能上智能手机逐步实现个人计算机具有的功能;智能手机受消费者的追捧,普及率越来越高。Nowadays, with the development of science and technology, the problem of counterfeit and shoddy products is emerging one after another. At present, the targets of counterfeit and shoddy products are mainly targeted at expensive tobacco and alcohol, high-end clothing, luxury goods and some famous brand products. Many counterfeit and shoddy products are disguised with used packaging boxes/bottles of original genuine products to confuse consumers and achieve the purpose of confusing the real ones. At the same time, in the existing technology, with the development of science and technology, smart phones are taking a higher and higher share in the market, gradually replacing feature phones; in terms of functions, smart phones gradually realize the functions that personal computers have; The popularity of consumers is getting higher and higher.

现有的产品防伪查询服务系统有针对产品真假鉴别,如果采用人工对防伪码进行查询,尤其是老年人出错率极高,导致消费者都不愿意进行真伪查询,效率低。The existing product anti-counterfeiting query service system is aimed at identifying the authenticity of the product. If the anti-counterfeiting code is manually checked, especially the elderly, the error rate is extremely high, which makes consumers unwilling to check the authenticity, and the efficiency is low.

现有技术中,防伪查询终端服务器的数据库形成方法落后,使得企业用户的生产效率低下。In the prior art, the database formation method of the anti-counterfeit query terminal server is backward, which makes the production efficiency of enterprise users low.

发明内容Contents of the invention

本发明的目的之一在于避免现有技术中的不足之处而提供面向企业用户的基于机器视觉的产品防伪查询方法,该面向企业用户的基于机器视觉的产品防伪查询方法可提高生产效率,防伪查询的准确率高,One of the purposes of the present invention is to avoid the deficiencies in the prior art and provide an enterprise user-oriented product anti-counterfeiting query method based on machine vision, which can improve production efficiency and anti-counterfeiting. The accuracy of the query is high,

本发明的目的之二在于避免现有技术中的不足之处而提供面向企业用户的基于机器视觉的产品防伪查询服务系统,该面向企业用户的基于机器视觉的产品防伪查询服务系统,可以做到随时随地进行产品防伪查询,适用性高,可代替传统的人工防伪查询。The second object of the present invention is to avoid the deficiencies in the prior art and provide a product anti-counterfeiting query service system based on machine vision for enterprise users. The product anti-counterfeiting query service system based on machine vision for enterprise users can achieve Product anti-counterfeiting inquiry anytime and anywhere, with high applicability, can replace traditional manual anti-counterfeiting inquiry.

本发明的目的之一通过以下技术方案实现。One of the objectives of the present invention is achieved through the following technical solutions.

提供面向企业用户的基于机器视觉的产品防伪查询方法,包括如下步骤:Provide a product anti-counterfeiting query method based on machine vision for enterprise users, including the following steps:

1)在生产线对应着产品的密码锁标签、防伪码标签、条形码标签的位置安装三个摄像头;三个摄像头分别对产品的密码锁标签、防伪码标签、条形码标签拍照,以分别获取密码锁标签、防伪码标签、条形码标签的数字字符图像;1) Three cameras are installed on the production line corresponding to the combination lock label, anti-counterfeiting code label and barcode label of the product; the three cameras take pictures of the combination lock label, anti-counterfeiting code label and barcode label of the product respectively to obtain the combination lock label , anti-counterfeiting code labels, digital character images of barcode labels;

2)将获取的密码锁标签、防伪码标签、条形码标签的数字字符图像通过计算得到查询表;2) Obtain the lookup table by calculating the digital character images of the acquired combination lock label, anti-counterfeiting code label and barcode label;

3)利用算法并结合步骤2)的查询表处理,得到密码锁密码、防伪码和条形码对应的数字字符串;3) Using the algorithm and combining with the query table processing in step 2), obtain the digital string corresponding to the combination lock password, anti-counterfeiting code and barcode;

4)将密码锁密码、防伪码和条形码对应的数字字符串形成具有一一对应关系的文档;4) Form a document with one-to-one correspondence with the digital strings corresponding to the combination lock password, anti-counterfeiting code and barcode;

5)将步骤4)所生成的文档上传至数据库,提供给用户端查询。5) Upload the document generated in step 4) to the database and provide it to the client for query.

优选的,所述步骤2)中的查询表获取步骤包括:Preferably, the query table acquisition step in step 2) includes:

2.1)通过MATLAB软件将密码锁标签、防伪码标签、条形码标签的数字字符图像进行预处理、去噪、灰度变换和二值化处理;2.1) Perform preprocessing, denoising, grayscale transformation and binarization on digital character images of combination lock labels, anti-counterfeiting code labels, and barcode labels through MATLAB software;

2.2)通过MATLAB软件给每个数字字符定位一个大小相同的的正方形框,框选数字字符图像中的每个数字字符;2.2) Use MATLAB software to locate a square frame of the same size for each digital character, and frame each digital character in the digital character image;

2.3)将正方形框分割为四个部分;2.3) Divide the square frame into four parts;

2.4)通过MATLAB软件计算出矩形方框框选的每个数字字符的左右比例、列集中度、行集中度、宽高比与中心区域的和、上下比例、中心区域和宽高比。2.4) Use MATLAB software to calculate the left-right ratio, column concentration, row concentration, sum of aspect ratio and central area, up-down ratio, central area, and aspect ratio of each digital character selected by a rectangular box.

更优选的,所述步骤3)中的算法处理步骤包括:More preferably, the algorithm processing steps in step 3) include:

3.1)将数字字符3、4、5、9、2、7、6、0、1和8的左右比例与设定阈值A进行比较,大于设定的阈值A,识别出数字字符为3或者数字字符为4;3.1) Compare the left and right ratios of the numeric characters 3, 4, 5, 9, 2, 7, 6, 0, 1, and 8 with the set threshold A, and if it is greater than the set threshold A, the numeric character is recognized as 3 or a number char is 4;

3.1.1)将数字字符为3和数字字符为4的列集中度与设定阈值C比较,大于设定的阈值C,则识别出数字字符为3;小于设定的阈值C,则识别出数字字符为4;3.1.1) Compare the column concentration of the numeric character 3 and the numeric character 4 with the set threshold C, if it is greater than the set threshold C, the numeric character is recognized as 3; if it is less than the set threshold C, it is recognized The numeric character is 4;

3.2)将数字字符5、9、2、7、6、0、1和8的左右比例与设定阈值A和设定的阈值B进行比较,大于设定的阈值A且小于设定的阈值B,识别出数字字符为5或者数字字符为9或者数字字符为2或者数字字符为7;3.2) Compare the left and right ratios of the numeric characters 5, 9, 2, 7, 6, 0, 1 and 8 with the set threshold A and the set threshold B, which is greater than the set threshold A and less than the set threshold B , recognize that the numeric character is 5 or the numeric character is 9 or the numeric character is 2 or the numeric character is 7;

3.2.1)将数字字符5、数字字符9、数字字符2和数字字符7的行集中度与设定的阈值D比较,小于设定的阈值D,则识别出数字字符为5或者数字字符为9;3.2.1) Compare the line concentration of the numeric character 5, the numeric character 9, the numeric character 2 and the numeric character 7 with the set threshold D, if it is less than the set threshold D, then the numeric character is recognized as 5 or the numeric character is 9;

3.2.1.1)将数字字符5和数字字符9的宽高比与中心区域的和与设定的阈值E比较,大于设定的阈值E,则识别出数字字符为9;小于设定的阈值E,则识别出数字字符为5;3.2.1.1) Compare the aspect ratio of the numeric character 5 and the numeric character 9 with the sum of the central area and the set threshold E, if it is greater than the set threshold E, the numeric character is identified as 9; if it is smaller than the set threshold E , the number character is identified as 5;

3.2.2)将数字字符2和数字字符7的行集中度与设定的阈值D比较,3.2.2) Compare the row concentration of numeric character 2 and numeric character 7 with the set threshold D,

大于设定的阈值D,则识别出数字字符为2或者7;If it is greater than the set threshold D, then the number character is recognized as 2 or 7;

3.2.2.1)将数字字符2和数字字符7的上下比例与设定的阈值F比较,大于设定的阈值F,则识别出数字字符为2;小于设定的阈值F,则识别出数字字符为7;3.2.2.1) Compare the upper and lower proportions of the numeric character 2 and the numeric character 7 with the set threshold F, if it is greater than the set threshold F, the numeric character is recognized as 2; if it is smaller than the set threshold F, the numeric character is recognized is 7;

3.3)将数字字符5、9、2、7、6、0、1和8的左右比例与设定阈值B进行比较,小于设定的阈值B,则识别出数字字符为6或者数字字符为0或者数字字符为1或者数字字符为8;3.3) Compare the left and right ratios of the numeric characters 5, 9, 2, 7, 6, 0, 1, and 8 with the set threshold B, if it is less than the set threshold B, then the numeric character is recognized as 6 or the numeric character is 0 Either the numeric character is 1 or the numeric character is 8;

3.3.1)将数字字符6、数字字符0、数字字符1和数字字符8的中心区域与设定的阈值G比较,大于设定的阈值G,则识别出数字字符为0或者数字字符为6;3.3.1) Compare the central area of the numeric character 6, the numeric character 0, the numeric character 1 and the numeric character 8 with the set threshold G, if it is greater than the set threshold G, then the numeric character is recognized as 0 or the numeric character is 6 ;

3.3.1.1)将数字字符0和数字字符6的列集中度与设定的阈值H比较,大于设定的阈值H,则识别出数字字符为6;3.3.1.1) Compare the column concentration of the numeric character 0 and the numeric character 6 with the set threshold H, if it is greater than the set threshold H, then the numeric character is identified as 6;

3.3.1.2)将数字字符0和数字字符6的列集中度与设定的阈值H比较,小于设定的阈值H,则识别出数字字符为0;3.3.1.2) Compare the column concentration of the numeric character 0 and the numeric character 6 with the set threshold H, if it is less than the set threshold H, then the numeric character is identified as 0;

3.3.2)将数字字符1和数字字符8的中心区域与设定的阈值G比较,小于设定的阈值G,则识别出数字字符为1或者数字字符为8;3.3.2) Compare the central area of the numeric character 1 and the numeric character 8 with the set threshold G, if it is smaller than the set threshold G, then the numeric character is recognized as 1 or the numeric character is 8;

3.3.2.1)将数字字符1和数字字符8的宽高比与设定的阈值I比较,大于设定的阈值I,则识别出数字字符为8;小于设定的阈值I,则识别出数字字符为1。3.3.2.1) Compare the aspect ratio of the numeric character 1 and the numeric character 8 with the set threshold I, if it is greater than the set threshold I, then the numeric character is recognized as 8; if it is smaller than the set threshold I, then the number is recognized character is 1.

另一优选的,所述阈值A设定为1.2955;所述阈值B设定为1.0617;所述阈值C设定为0.2122;所述阈值D设定为0.2467;所述阈值E设定为1.3333;所述阈值F设定为0.8803;所述阈值G设定为0.6706;所述阈值H设定为1.0850;所述阈值I设定为0.4621。In another preferred embodiment, the threshold A is set to 1.2955; the threshold B is set to 1.0617; the threshold C is set to 0.2122; the threshold D is set to 0.2467; the threshold E is set to 1.3333; The threshold F is set to 0.8803; the threshold G is set to 0.6706; the threshold H is set to 1.0850; and the threshold I is set to 0.4621.

另一优选的,所述步骤2)的查询表的内容包括:数字0对应的左右比例是009918;数字1对应的左右比例是009866;数字2对应的左右比例是1.1943;数字3对应的左右比例是1.3929;数字4对应的左右比例是1.5071;数字5对应的左右比例是1.1980;数字6对应的左右比例是0.9035;数字7对应的左右比例是1.1722;数字8对应的左右比例是0.9954;数字字符为9对应的左右比例是1.1280。Another preferred, the content of the lookup table in step 2) includes: the left-right ratio corresponding to the number 0 is 009918; the left-right ratio corresponding to the number 1 is 009866; the left-right ratio corresponding to the number 2 is 1.1943; the left-right ratio corresponding to the number 3 is 1.3929; the left-right ratio corresponding to the number 4 is 1.5071; the left-right ratio corresponding to the number 5 is 1.1980; the left-right ratio corresponding to the number 6 is 0.9035; the left-right ratio corresponding to the number 7 is 1.1722; the left-right ratio corresponding to the number 8 is 0.9954; The left-right ratio corresponding to 9 is 1.1280.

另一优选的,所述步骤2)的查询表的内容包括:数字0对应的列集中度为0.2121;数字1对应的列集中度为0.0303;数字2对应的列集中度为0.5606;数字3对应的列集中度为0.409;数字4对应的列集中度为0.0152;数字5对应的列集中度为0.5758;数字6对应的列集中度为0.4394;数字7对应的列集中度为0.6364;数字8对应的列集中度为0.2576;数字字符为9对应的列集中度为0.4394。In another preferred form, the content of the lookup table in step 2) includes: the column concentration corresponding to the number 0 is 0.2121; the column concentration corresponding to the number 1 is 0.0303; the column concentration corresponding to the number 2 is 0.5606; the number 3 corresponds to The column concentration of the number 4 is 0.409; the column concentration corresponding to the number 4 is 0.0152; the column concentration corresponding to the number 5 is 0.5758; the column concentration corresponding to the number 6 is 0.4394; the column concentration corresponding to the number 7 is 0.6364; The column concentration ratio of is 0.2576; the column concentration ratio corresponding to the number character is 9 is 0.4394.

另一优选的,所述步骤2)的查询表的内容包括:数字0对应的行集中度为0.5500;数字1对应的行集中度为0.4583;数字2对应的行集中度为0.1220;数字3对应的行集中度为0.3889;数字4对应的行集中度为0.0000;数字5对应的行集中度为0.3714;数字6对应的行集中度为0.4500;数字7对应的行集中度为0.1026;数字8对应的行集中度为0.4865;数字字符为9对应的行集中度为0.4500。In another preferred form, the content of the lookup table in step 2) includes: the row concentration corresponding to the number 0 is 0.5500; the row concentration corresponding to the number 1 is 0.4583; the row concentration corresponding to the number 2 is 0.1220; the number 3 corresponds to The number 4 corresponds to a row concentration of 0.3889; the number 4 corresponds to a row concentration of 0.0000; the number 5 corresponds to a row concentration of 0.3714; the number 6 corresponds to a row concentration of 0.4500; the number 7 corresponds to a row concentration of 0.1026; The row concentration ratio of is 0.4865; the row concentration ratio corresponding to a numeric character of 9 is 0.4500.

另一优选的,所述步骤2)的查询表的内容包括:数字0对应的上下比例1.0059;数字1对应的上下比例1.0214;数字2对应的上下比例0.9840;数字3对应的上下比例1.0000;数字4对应的上下比例1.1693;数字5对应的上下比例0.8275;数字6对应的上下比例1.1640;数字7对应的上下比例0.7765;数字8对应的上下比例1.0360;数字字符为9对应的上下比例0.8378。Another preferred, the content of the lookup table in step 2) includes: the up-down ratio corresponding to the number 0 is 1.0059; the up-down ratio corresponding to the number 1 is 1.0214; the up-down ratio corresponding to the number 2 is 0.9840; the up-down ratio corresponding to the number 3 is 1.0000; The up-down ratio corresponding to 4 is 1.1693; the up-down ratio corresponding to number 5 is 0.8275; the up-down ratio corresponding to number 6 is 1.1640; the up-down ratio corresponding to number 7 is 0.7765; the up-down ratio corresponding to number 8 is 1.0360;

另一优选的,所述步骤2)的查询表的内容包括:数字0对应的中心区域为1.0000;数字1对应的中心区域为0.3333;数字2对应的中心区域为0.8745;数字3对应的中心区域为0.8266;数字4对应的中心区域为0.4949;数字5对应的中心区域为0.7166;数字6对应的中心区域为0.8197;数字7对应的中心区域为0.7560;数字8对应的中心区域为0.5215;数字字符为9对应的中心区域为0.8136。In another preferred form, the content of the lookup table in step 2) includes: the central area corresponding to the number 0 is 1.0000; the central area corresponding to the number 1 is 0.3333; the central area corresponding to the number 2 is 0.8745; the central area corresponding to the number 3 The central area corresponding to the number 4 is 0.4949; the central area corresponding to the number 5 is 0.7166; the central area corresponding to the number 6 is 0.8197; the central area corresponding to the number 7 is 0.7560; the central area corresponding to the number 8 is 0.5215; The central area corresponding to 9 is 0.8136.

另一优选的,所述步骤2)的查询表的内容包括:数字0对应的宽高比为0.6061;数字1对应的宽高比为0.3636;数字2对应的宽高比为0.6212;数字3对应的宽高比为0.5455;数字4对应的宽高比为0.6364;数字5对应的宽高比为0.5303;数字6对应的宽高比为0.6061;数字7对应的宽高比为0.5909;数字8对应的宽高比为0.5606;数字字符为9对应的宽高比为0.6061;In another preferred form, the content of the lookup table in step 2) includes: the aspect ratio corresponding to the number 0 is 0.6061; the aspect ratio corresponding to the number 1 is 0.3636; the aspect ratio corresponding to the number 2 is 0.6212; the aspect ratio corresponding to the number 3 is The aspect ratio of the number 4 is 0.5455; the aspect ratio corresponding to the number 4 is 0.6364; the aspect ratio corresponding to the number 5 is 0.5303; the aspect ratio corresponding to the number 6 is 0.6061; the aspect ratio corresponding to the number 7 is 0.5909; The aspect ratio of is 0.5606; the aspect ratio corresponding to the number character is 9 is 0.6061;

所述步骤2)的查询表的内容包括:数字0对应的宽高比与中心区域的和为1.6061;数字1对应的宽高比与中心区域的和为0.6969;数字2对应的宽高比与中心区域的和为1.4957;数字3对应的宽高比与中心区域的和为1.3721;数字4对应的宽高比与中心区域的和为1.1313;数字5对应的宽高比与中心区域的和为1.2469;数字6对应的宽高比与中心区域的和为1.4258;数字7对应的宽高比与中心区域的和为1.3469;数字8对应的宽高比与中心区域的和为1.0821;数字字符为9对应的宽高比与中心区域的和为1.4197。The content of the lookup table in step 2) includes: the sum of the aspect ratio corresponding to the number 0 and the central area is 1.6061; the sum of the aspect ratio corresponding to the number 1 and the central area is 0.6969; the aspect ratio corresponding to the number 2 is 0.6969; The sum of the central area is 1.4957; the sum of the aspect ratio corresponding to the number 3 and the central area is 1.3721; the sum of the aspect ratio corresponding to the number 4 and the central area is 1.1313; the sum of the aspect ratio corresponding to the number 5 and the central area is 1.2469; the sum of the aspect ratio corresponding to the number 6 and the central area is 1.4258; the sum of the aspect ratio corresponding to the number 7 and the central area is 1.3469; the sum of the aspect ratio corresponding to the number 8 and the central area is 1.0821; the digital characters are The sum of the aspect ratio corresponding to 9 and the central area is 1.4197.

本发明的目的之二通过以下技术方案实现。The second object of the present invention is achieved through the following technical solutions.

提供面向企业用户的基于机器视觉的产品防伪查询服务系统包括具备机器视觉的智能设备和防伪查询终端服务器,所述具备机器视觉的智能设备内置有防伪码自动识别软件,所述防伪查询终端服务器的数据库包括有上述技术方案所述的将密码锁密码、防伪码和条形码对应的数字字符串形成具有一一对应关系的文档。The product anti-counterfeiting query service system based on machine vision for enterprise users includes a smart device with machine vision and an anti-counterfeiting query terminal server. The smart device with machine vision has built-in anti-counterfeiting code automatic identification software. The database includes documents with a one-to-one correspondence between the password lock password, the anti-counterfeiting code and the digital character strings corresponding to the barcode described in the above technical solution.

本发明的有益效果如下:The beneficial effects of the present invention are as follows:

本发明的面向企业用户的基于机器视觉的产品防伪查询方法是在生产线安装三个摄像头;三个摄像头分别对产品的密码锁标签、防伪码标签、条形码标签拍照,以分别获取密码锁标签、防伪码标签、条形码标签的数字字符图像;通过计算得到查询表;利用算法并结合查询表处理,得到密码锁密码、防伪码和条形码对应的数字字符串;将该对应的数字字符串形成具有一一对应关系的文档上传至数据库,提供给用户端查询,这种模式在生产上可很好的提高效率,面向企业用户的基于机器视觉的产品防伪查询系统包括具备机器视觉的智能设备和防伪查询终端服务器,智能设备内置防伪码自动识别软件,让用户可做到随时随地进行产品防伪查询,适用性高,可代替传统的人工防伪查询,与现有技术需要将防伪码逐个输入查询终端相比,可提高防伪查询的效率,防伪查询的准确率高。The product anti-counterfeiting query method based on machine vision for enterprise users of the present invention is to install three cameras on the production line; the three cameras take pictures of the combination lock label, anti-counterfeiting code label and barcode label of the product respectively to obtain the combination lock label and anti-counterfeiting label respectively The digital character image of the code label and barcode label; the lookup table is obtained through calculation; the digital string corresponding to the combination lock password, anti-counterfeiting code and barcode is obtained by using the algorithm and combined with the lookup table; the corresponding digital string is formed into a one-to-one The documents of the corresponding relationship are uploaded to the database and provided to the user for query. This mode can improve the efficiency of production. The product anti-counterfeiting query system based on machine vision for enterprise users includes smart devices with machine vision and anti-counterfeiting query terminals. Servers and smart devices have built-in anti-counterfeiting code automatic identification software, allowing users to conduct product anti-counterfeiting inquiries anytime and anywhere. It has high applicability and can replace traditional manual anti-counterfeiting inquiries. The efficiency of the anti-counterfeiting query can be improved, and the accuracy of the anti-counterfeiting query is high.

附图说明Description of drawings

图1是本发明面向企业用户的基于机器视觉的产品防伪查询方法的流程图。Fig. 1 is a flow chart of the product anti-counterfeiting query method based on machine vision for enterprise users in the present invention.

图2是本发明面向企业用户的基于机器视觉的产品防伪查询方法的步骤4)中的算法处理流程图。Fig. 2 is a flow chart of algorithm processing in step 4) of the product anti-counterfeiting query method based on machine vision for enterprise users of the present invention.

具体实施方式detailed description

结合以下实施例对本发明作进一步说明。The present invention will be further described in conjunction with the following examples.

实施例1。Example 1.

本实施例的面向企业用户的基于机器视觉的产品防伪查询方法,如图1和图2所示,包括如下步骤:The product anti-counterfeiting query method based on machine vision for enterprise users of this embodiment, as shown in Figure 1 and Figure 2, includes the following steps:

1)在生产线对应着产品的密码锁标签、防伪码标签、条形码标签的位置安装三个摄像头;三个摄像头分别对产品的密码锁标签、防伪码标签、条形码标签拍照,以分别获取密码锁标签、防伪码标签、条形码标签的数字字符图像;1) Three cameras are installed on the production line corresponding to the combination lock label, anti-counterfeiting code label and barcode label of the product; the three cameras take pictures of the combination lock label, anti-counterfeiting code label and barcode label of the product respectively to obtain the combination lock label , anti-counterfeiting code labels, digital character images of barcode labels;

2)将获取的密码锁标签、防伪码标签、条形码标签的数字字符图像通过计算得到查询表;2) Obtain the lookup table by calculating the digital character images of the acquired combination lock label, anti-counterfeiting code label and barcode label;

3)利用算法并结合步骤2)的查询表处理,得到密码锁密码、防伪码和条形码对应的数字字符串;3) Using the algorithm and combining with the query table processing in step 2), obtain the digital string corresponding to the combination lock password, anti-counterfeiting code and barcode;

4)将密码锁密码、防伪码和条形码对应的数字字符串形成具有一一对应关系的文档;4) Form a document with one-to-one correspondence with the digital strings corresponding to the combination lock password, anti-counterfeiting code and barcode;

5)将步骤4)所生成的文档上传至数据库,提供给用户端查询。5) Upload the document generated in step 4) to the database and provide it to the client for query.

具体的,步骤2)中的查询表获取步骤包括:Specifically, the query table acquisition steps in step 2) include:

2.1)通过MATLAB软件将密码锁标签、防伪码标签、条形码标签的数字字符图像进行预处理、去噪、灰度变换和二值化处理;2.1) Perform preprocessing, denoising, grayscale transformation and binarization on digital character images of combination lock labels, anti-counterfeiting code labels, and barcode labels through MATLAB software;

2.2)通过MATLAB软件给每个数字字符定位一个大小相同的的正方形框,框选数字字符图像中的每个数字字符;2.2) Use MATLAB software to locate a square frame of the same size for each digital character, and frame each digital character in the digital character image;

2.3)将正方形框分割为四个部分;2.3) Divide the square frame into four parts;

2.4)通过MATLAB软件计算出矩形方框框选的每个数字字符的左右比例、列集中度、行集中度、宽高比与中心区域的和、上下比例、中心区域和宽高比。2.4) Use MATLAB software to calculate the left-right ratio, column concentration, row concentration, sum of aspect ratio and central area, up-down ratio, central area, and aspect ratio of each digital character selected by a rectangular box.

具体的,步骤3)中的算法处理步骤包括:Specifically, the algorithm processing steps in step 3) include:

3.1)将数字字符3、4、5、9、2、7、6、0、1和8的左右比例与设定阈值A进行比较,大于设定的阈值A,识别出数字字符为3或者数字字符为4;3.1) Compare the left and right ratios of the numeric characters 3, 4, 5, 9, 2, 7, 6, 0, 1, and 8 with the set threshold A, and if it is greater than the set threshold A, the numeric character is recognized as 3 or a number char is 4;

3.1.1)将数字字符为3和数字字符为4的列集中度与设定阈值C比较,大于设定的阈值C,则识别出数字字符为3;小于设定的阈值C,则识别出数字字符为4;3.1.1) Compare the column concentration of the numeric character 3 and the numeric character 4 with the set threshold C, if it is greater than the set threshold C, the numeric character is recognized as 3; if it is less than the set threshold C, it is recognized The numeric character is 4;

3.2)将数字字符5、9、2、7、6、0、1和8的左右比例与设定阈值A和设定的阈值B进行比较,大于设定的阈值A且小于设定的阈值B,识别出数字字符为5或者数字字符为9或者数字字符为2或者数字字符为7;3.2) Compare the left and right ratios of the numeric characters 5, 9, 2, 7, 6, 0, 1 and 8 with the set threshold A and the set threshold B, which is greater than the set threshold A and less than the set threshold B , recognize that the numeric character is 5 or the numeric character is 9 or the numeric character is 2 or the numeric character is 7;

3.2.1)将数字字符5、数字字符9、数字字符2和数字字符7的行集中度与设定的阈值D比较,小于设定的阈值D,则识别出数字字符为5或者数字字符为9;3.2.1) Compare the line concentration of the numeric character 5, the numeric character 9, the numeric character 2 and the numeric character 7 with the set threshold D, if it is less than the set threshold D, then the numeric character is recognized as 5 or the numeric character is 9;

3.2.1.1)将数字字符5和数字字符9的宽高比与中心区域的和与设定的阈值E比较,大于设定的阈值E,则识别出数字字符为9;小于设定的阈值E,则识别出数字字符为5;3.2.1.1) Compare the aspect ratio of the numeric character 5 and the numeric character 9 with the sum of the central area and the set threshold E, if it is greater than the set threshold E, the numeric character is identified as 9; if it is smaller than the set threshold E , the number character is identified as 5;

3.2.2)将数字字符2和数字字符7的行集中度与设定的阈值D比较,大于设定的阈值D,则识别出数字字符为2或者7;3.2.2) Comparing the row concentration of the numeric character 2 and the numeric character 7 with the set threshold D, if it is greater than the set threshold D, then the numeric character is identified as 2 or 7;

3.2.2.1)将数字字符2和数字字符7的上下比例与设定的阈值F比较,大于设定的阈值F,则识别出数字字符为2;小于设定的阈值F,则识别出数字字符为7;3.2.2.1) Compare the upper and lower proportions of the numeric character 2 and the numeric character 7 with the set threshold F, if it is greater than the set threshold F, the numeric character is recognized as 2; if it is smaller than the set threshold F, the numeric character is recognized is 7;

3.3)将数字字符5、9、2、7、6、0、1和8的左右比例与设定阈值B进行比较,小于设定的阈值B,则识别出数字字符为6或者数字字符为0或者数字字符为1或者数字字符为8;3.3) Compare the left and right ratios of the numeric characters 5, 9, 2, 7, 6, 0, 1, and 8 with the set threshold B, if it is less than the set threshold B, then the numeric character is recognized as 6 or the numeric character is 0 Either the numeric character is 1 or the numeric character is 8;

3.3.1)将数字字符6、数字字符0、数字字符1和数字字符8的中心区域与设定的阈值G比较,大于设定的阈值G,则识别出数字字符为0或者数字字符为6;3.3.1) Compare the central area of the numeric character 6, the numeric character 0, the numeric character 1 and the numeric character 8 with the set threshold G, if it is greater than the set threshold G, then the numeric character is recognized as 0 or the numeric character is 6 ;

3.3.1.1)将数字字符0和数字字符6的列集中度与设定的阈值H比较,大于设定的阈值H,则识别出数字字符为6;3.3.1.1) Compare the column concentration of the numeric character 0 and the numeric character 6 with the set threshold H, if it is greater than the set threshold H, then the numeric character is identified as 6;

3.3.1.2)将数字字符0和数字字符6的列集中度与设定的阈值H比较,小于设定的阈值H,则识别出数字字符为0;3.3.1.2) Compare the column concentration of the numeric character 0 and the numeric character 6 with the set threshold H, if it is less than the set threshold H, then the numeric character is identified as 0;

3.3.2)将数字字符1和数字字符8的中心区域与设定的阈值G比较,小于设定的阈值G,则识别出数字字符为1或者数字字符为8;3.3.2) Compare the central area of the numeric character 1 and the numeric character 8 with the set threshold G, if it is smaller than the set threshold G, then the numeric character is recognized as 1 or the numeric character is 8;

3.3.2.1)将数字字符1和数字字符8的宽高比与设定的阈值I比较,大于设定的阈值I,则识别出数字字符为8;小于设定的阈值I,则识别出数字字符为1。3.3.2.1) Compare the aspect ratio of the numeric character 1 and the numeric character 8 with the set threshold I, if it is greater than the set threshold I, then the numeric character is recognized as 8; if it is smaller than the set threshold I, then the number is recognized character is 1.

具体的,阈值A设定为1.2955;阈值B设定为1.0617;阈值C设定为0.2122;阈值D设定为0.2467;阈值E设定为1.3333;阈值F设定为0.8803;阈值G设定为0.6706;阈值H设定为1.0850;阈值I设定为0.4621。Specifically, threshold A is set to 1.2955; threshold B is set to 1.0617; threshold C is set to 0.2122; threshold D is set to 0.2467; threshold E is set to 1.3333; threshold F is set to 0.8803; threshold G is set to 0.6706; threshold H is set to 1.0850; threshold I is set to 0.4621.

具体的,步骤2)的查询表的内容包括:数字0对应的左右比例是009918;数字1对应的左右比例是009866;数字2对应的左右比例是1.1943;数字3对应的左右比例是1.3929;数字4对应的左右比例是1.5071;数字5对应的左右比例是1.1980;数字6对应的左右比例是0.9035;数字7对应的左右比例是1.1722;数字8对应的左右比例是0.9954;数字字符为9对应的左右比例是1.1280。Specifically, the content of the lookup table in step 2) includes: the left-right ratio corresponding to the number 0 is 009918; the left-right ratio corresponding to the number 1 is 009866; the left-right ratio corresponding to the number 2 is 1.1943; The left-right ratio corresponding to 4 is 1.5071; the left-right ratio corresponding to number 5 is 1.1980; the left-right ratio corresponding to number 6 is 0.9035; the left-right ratio corresponding to number 7 is 1.1722; The left-right ratio is 1.1280.

具体的,步骤2)的查询表的内容包括:数字0对应的列集中度为0.2121;数字1对应的列集中度为0.0303;数字2对应的列集中度为0.5606;数字3对应的列集中度为0.409;数字4对应的列集中度为0.0152;数字5对应的列集中度为0.5758;数字6对应的列集中度为0.4394;数字7对应的列集中度为0.6364;数字8对应的列集中度为0.2576;数字字符为9对应的列集中度为0.4394。Specifically, the content of the query table in step 2) includes: the column concentration corresponding to the number 0 is 0.2121; the column concentration corresponding to the number 1 is 0.0303; the column concentration corresponding to the number 2 is 0.5606; the column concentration corresponding to the number 3 The column concentration corresponding to the number 4 is 0.0152; the column concentration corresponding to the number 5 is 0.5758; the column concentration corresponding to the number 6 is 0.4394; the column concentration corresponding to the number 7 is 0.6364; the column concentration corresponding to the number 8 is 0.2576; the column concentration corresponding to a number character of 9 is 0.4394.

具体的,步骤2)的查询表的内容包括:数字0对应的行集中度为0.5500;数字1对应的行集中度为0.4583;数字2对应的行集中度为0.1220;数字3对应的行集中度为0.3889;数字4对应的行集中度为0.0000;数字5对应的行集中度为0.3714;数字6对应的行集中度为0.4500;数字7对应的行集中度为0.1026;数字8对应的行集中度为0.4865;数字字符为9对应的行集中度为0.4500。Specifically, the content of the query table in step 2) includes: the row concentration ratio corresponding to the number 0 is 0.5500; the row concentration ratio corresponding to the number 1 is 0.4583; the row concentration ratio corresponding to the number 2 is 0.1220; the row concentration ratio corresponding to the number 3 is 0.3889; the row concentration corresponding to the number 4 is 0.0000; the row concentration corresponding to the number 5 is 0.3714; the row concentration corresponding to the number 6 is 0.4500; the row concentration corresponding to the number 7 is 0.1026; the row concentration corresponding to the number 8 is 0.4865; the number character is 9, and the row concentration corresponding to it is 0.4500.

具体的,步骤2)的查询表的内容包括:数字0对应的上下比例1.0059;数字1对应的上下比例1.0214;数字2对应的上下比例0.9840;数字3对应的上下比例1.0000;数字4对应的上下比例1.1693;数字5对应的上下比例0.8275;数字6对应的上下比例1.1640;数字7对应的上下比例0.7765;数字8对应的上下比例1.0360;数字字符为9对应的上下比例0.8378。Specifically, the content of the lookup table in step 2) includes: the up-down ratio corresponding to number 0 is 1.0059; the up-down ratio corresponding to number 1 is 1.0214; the up-down ratio corresponding to number 2 is 0.9840; the up-down ratio corresponding to number 3 is 1.0000; The ratio is 1.1693; the up-down ratio corresponding to the number 5 is 0.8275; the up-down ratio corresponding to the number 6 is 1.1640; the up-down ratio corresponding to the number 7 is 0.7765; the up-down ratio corresponding to the number 8 is 1.0360;

具体的,步骤2)的查询表的内容包括:数字0对应的中心区域为1.0000;数字1对应的中心区域为0.3333;数字2对应的中心区域为0.8745;数字3对应的中心区域为0.8266;数字4对应的中心区域为0.4949;数字5对应的中心区域为0.7166;数字6对应的中心区域为0.8197;数字7对应的中心区域为0.7560;数字8对应的中心区域为0.5215;数字字符为9对应的中心区域为0.8136。Specifically, the content of the lookup table in step 2) includes: the central area corresponding to the number 0 is 1.0000; the central area corresponding to the number 1 is 0.3333; the central area corresponding to the number 2 is 0.8745; the central area corresponding to the number 3 is 0.8266; The central area corresponding to 4 is 0.4949; the central area corresponding to the number 5 is 0.7166; the central area corresponding to the number 6 is 0.8197; the central area corresponding to the number 7 is 0.7560; the central area corresponding to the number 8 is 0.5215; The central zone is 0.8136.

具体的,步骤2)的查询表的内容包括:数字0对应的宽高比为0.6061;数字1对应的宽高比为0.3636;数字2对应的宽高比为0.6212;数字3对应的宽高比为0.5455;数字4对应的宽高比为0.6364;数字5对应的宽高比为0.5303;数字6对应的宽高比为0.6061;数字7对应的宽高比为0.5909;数字8对应的宽高比为0.5606;数字字符为9对应的宽高比为0.6061;Specifically, the content of the lookup table in step 2) includes: the aspect ratio corresponding to the number 0 is 0.6061; the aspect ratio corresponding to the number 1 is 0.3636; the aspect ratio corresponding to the number 2 is 0.6212; the aspect ratio corresponding to the number 3 The aspect ratio corresponding to the number 4 is 0.6364; the aspect ratio corresponding to the number 5 is 0.5303; the aspect ratio corresponding to the number 6 is 0.6061; the aspect ratio corresponding to the number 7 is 0.5909; the aspect ratio corresponding to the number 8 is 0.5606; the aspect ratio corresponding to a number character of 9 is 0.6061;

步骤2)的查询表的内容包括:数字0对应的宽高比与中心区域的和为1.6061;数字1对应的宽高比与中心区域的和为0.6969;数字2对应的宽高比与中心区域的和为1.4957;数字3对应的宽高比与中心区域的和为1.3721;数字4对应的宽高比与中心区域的和为1.1313;数字5对应的宽高比与中心区域的和为1.2469;数字6对应的宽高比与中心区域的和为1.4258;数字7对应的宽高比与中心区域的和为1.3469;数字8对应的宽高比与中心区域的和为1.0821;数字字符为9对应的宽高比与中心区域的和为1.4197。The content of the lookup table in step 2) includes: the sum of the aspect ratio corresponding to the number 0 and the central area is 1.6061; the sum of the aspect ratio corresponding to the number 1 and the central area is 0.6969; the aspect ratio corresponding to the number 2 and the central area The sum of the aspect ratio corresponding to the number 3 and the central area is 1.3721; the sum of the aspect ratio corresponding to the number 4 and the central area is 1.1313; the sum of the aspect ratio corresponding to the number 5 and the central area is 1.2469; The sum of the aspect ratio corresponding to the number 6 and the central area is 1.4258; the sum of the aspect ratio corresponding to the number 7 and the central area is 1.3469; the sum of the aspect ratio corresponding to the number 8 and the central area is 1.0821; the number character is 9 corresponding The sum of the aspect ratio and the central area is 1.4197.

本发明的有益效果如下:The beneficial effects of the present invention are as follows:

本发明可提高生产效率,使得防伪查询的准确率高。The invention can improve the production efficiency, so that the accuracy of the anti-counterfeiting query is high.

字符3的识别过程如下:The recognition process of character 3 is as follows:

通过字符左右比例的阈值排除1、2、5、6、7、8、9、0,通过查询查询表中的列集中度,排除4,识别了字符3。1, 2, 5, 6, 7, 8, 9, and 0 are excluded by the threshold of the left-right ratio of characters, and 4 is excluded by querying the column concentration in the query table, and character 3 is identified.

本发明的方法可分为三种模式。The method of the present invention can be divided into three modes.

第一种,密码锁生产商、防伪码生产商、条形码生产商分别将其开锁密码、防伪码、条形码提供给企业用户,企业用户可以选择设置开锁密码或者由密码锁生厂商设置开锁密码,利用机器视觉将防伪码、密码锁密码、条形码同时扫描形成三码一一对应关系,行成一个文档上传到数据库。第二种,密码锁生厂商购买防伪码,并将防伪码和密码锁密码利用机器视觉形成一一对应关系,并提供给企业用户,企业用户通过条形码扫描使三码建立唯一映射关系。The first type is that combination lock manufacturers, anti-counterfeiting code manufacturers, and barcode manufacturers provide their unlocking passwords, anti-counterfeiting codes, and barcodes to enterprise users respectively. Enterprise users can choose to set the unlocking password or the combination lock manufacturer sets the unlocking password. The machine vision scans the anti-counterfeiting code, combination lock password, and barcode at the same time to form a one-to-one correspondence between the three codes, and uploads it to the database as a document. The second type is that combination lock manufacturers purchase anti-counterfeiting codes, and use machine vision to form a one-to-one correspondence between anti-counterfeiting codes and combination lock passwords, and provide them to enterprise users. Enterprise users scan barcodes to establish a unique mapping relationship between the three codes.

第二种,密码锁生厂商购买防伪码,并将防伪码和密码锁密码利用机器视觉形成一一对应关系,并提供给企业用户,企业用户通过条形码扫描使三码建立唯一映射关系。The second type is that combination lock manufacturers purchase anti-counterfeiting codes, and use machine vision to form a one-to-one correspondence between anti-counterfeiting codes and combination lock passwords, and provide them to enterprise users. Enterprise users scan barcodes to establish a unique mapping relationship between the three codes.

第三种,密码锁生厂商自己生产防伪码,并将防伪码和密码锁密码利用机器视觉形成一一对应关系,并提供给企业用户,企业用户通过条形码扫描使三码建立唯一映射关系。The third is that combination lock manufacturers produce anti-counterfeiting codes themselves, and use machine vision to form a one-to-one correspondence between anti-counterfeiting codes and combination lock passwords, and provide them to enterprise users. Enterprise users scan barcodes to establish a unique mapping relationship between the three codes.

本发明的主要特点是通过机器视觉的方式获取密码锁密码、防伪码、条形码,并将三码形成一一对应的关系。将机器视觉应用于防伪查询系统,企业用户在得到厂商提供的密码锁、防伪码、条形码后,采用机器视觉将密码密码锁、防伪码标签、条形码标签形成一一对应关系。在生产线特定的位置安装三个摄像头,可以为CCD(Charge-coupledDevice,中文全称:电荷耦合元件,可以称为CCD图像传感器)摄像头,对应着密码锁、防伪码标签、条形码标签拍照,将拍得的图像通过算法处理,得到密码锁密码、防伪码、条形码,并将三码合一,形成具有一一对应关系的文档。这种模式在生产上可以很好的提高效率。The main feature of the present invention is to acquire combination lock code, anti-counterfeiting code and bar code through machine vision, and form a one-to-one correspondence relationship between the three codes. Apply machine vision to the anti-counterfeiting query system. After obtaining the combination lock, anti-counterfeiting code, and barcode provided by the manufacturer, the enterprise user uses machine vision to form a one-to-one correspondence between the combination lock, anti-counterfeiting code label, and barcode label. Install three cameras at specific positions on the production line, which can be used for CCD (Charge-coupled Device, Chinese full name: charge-coupled device, which can be called CCD image sensor) cameras, corresponding to password locks, anti-counterfeiting code labels, and barcode labels. The image is processed by an algorithm to obtain the code lock password, anti-counterfeiting code, and barcode, and combine the three codes into one to form a document with a one-to-one correspondence. This mode can greatly improve the efficiency in production.

实施例2。Example 2.

面向企业用户的基于机器视觉的产品防伪查询服务系统,包括具备机器视觉的智能设备和防伪查询终端服务器,具备机器视觉的智能设备内置有防伪码自动识别软件,防伪查询终端服务器的数据库包括有实施例1的将密码锁密码、防伪码和条形码对应的数字字符串形成具有一一对应关系的文档。Machine vision-based product anti-counterfeiting query service system for enterprise users, including smart devices with machine vision and anti-counterfeiting query terminal servers. Example 1 forms a document with a one-to-one correspondence between the password lock password, the anti-counterfeiting code and the digital character string corresponding to the barcode.

具备机器视觉的智能设备可以是智能手机。A smart device with machine vision could be a smartphone.

自动识别软件包括图像获取模块、图像处理模块、图像识别模块、微处理模块、图像显示模块和信息发送接收模块,图像获取器的输出端与图像处理器的输入端连接,图像处理模块的输出端与图像识别模块的输入端连接,图像识别模块的输出端与微处理模块的输入端连接,微处理模块的第一输出端与图像显示模块的输入端连接,微处理模块的第二输出端与信息发送接收模块的输入端连接。The automatic identification software includes an image acquisition module, an image processing module, an image recognition module, a microprocessing module, an image display module and an information sending and receiving module, the output end of the image acquisition device is connected with the input end of the image processor, and the output end of the image processing module It is connected with the input end of the image recognition module, the output end of the image recognition module is connected with the input end of the micro-processing module, the first output end of the micro-processing module is connected with the input end of the image display module, and the second output end of the micro-processing module is connected with the input end of the image display module. The input terminal of the information sending and receiving module is connected.

信息发送接收模块包括MSG子发送接收模块或者HTTP子发送接收模块或者同时包括MSG子发送接收模块和HTTP子发送接收模块。The information sending and receiving module includes a MSG sub-sending and receiving module or an HTTP sub-sending and receiving module, or simultaneously includes a MSG sub-sending and receiving module and an HTTP sub-sending and receiving module.

图像识别模块采用的算法如下:The algorithm used by the image recognition module is as follows:

1)选择具备机器视觉的智能设备,并安装防伪码标签处理软件;1) Choose a smart device with machine vision and install anti-counterfeiting code label processing software;

2)个人用户端通过智能设备的机器视觉对防伪码标签进行拍照,获取图像;2) The personal client takes a photo of the anti-counterfeiting code label through the machine vision of the smart device to obtain the image;

3)防伪码标签处理软件对拍照所获取的图像通过识别算法进行处理、并识别出防伪码字符串;3) The anti-counterfeiting code label processing software processes the image obtained by taking pictures through a recognition algorithm, and recognizes the anti-counterfeiting code string;

4)将防伪码字符串发送至防伪查询终端服务器;4) Send the anti-counterfeiting code string to the anti-counterfeiting query terminal server;

5)防伪查询终端服务器对该防伪码字符串进行真伪辨别;5) The anti-counterfeiting query terminal server conducts authenticity identification on the anti-counterfeiting code string;

6)将辨别结果反馈至具备机器视觉的智能设备。6) Feedback the identification result to the smart device with machine vision.

具体的,步骤3)中的防伪码标签处理软件的识别算法包括以下步骤:Specifically, the identification algorithm of the anti-counterfeiting code label processing software in step 3) includes the following steps:

3.1)获取防伪码标签的图像;3.1) Obtain the image of the anti-counterfeiting code label;

3.2)对该图像依次进行正规化、去除噪声、影像矫正、图文分析、文字行与字分离的文件前处理;3.2) Perform file pre-processing of normalization, noise removal, image correction, image-text analysis, and separation of text lines and words in sequence on the image;

3.3)提取防伪码特征;3.3) Extract the anti-counterfeiting code features;

3.4)结合防伪码字符特征库,进行防伪码匹配;3.4) Combining with the anti-counterfeiting code character feature library, the anti-counterfeiting code is matched;

3.5)检查防伪码是否匹配正确;3.5) Check whether the anti-counterfeiting code matches correctly;

3.51)若提取防伪码特征;3.51) If the anti-counterfeiting code feature is extracted;

3.52)若防伪码匹配错误,则重新匹配一次,如防伪码匹配正确,则输出防伪码字符串;3.52) If the anti-counterfeiting code is wrongly matched, it will be matched again, if the anti-counterfeiting code is matched correctly, then the anti-counterfeiting code string will be output;

3.53)若防伪码匹配错误两次,则返回步骤3.1)重新获取防伪码标签的图像。3.53) If the anti-counterfeiting code is incorrectly matched twice, return to step 3.1) to obtain the image of the anti-counterfeiting code label again.

个人用户可以通过防伪码处理软件驱动机器视觉设备完成对防伪码的获取,并通过即时短消息或者网络的方式传输到产品防伪查询服务系统进行防伪查询。Individual users can use the anti-counterfeiting code processing software to drive the machine vision equipment to complete the acquisition of the anti-counterfeiting code, and transmit it to the product anti-counterfeiting query service system through instant short messages or the Internet for anti-counterfeiting query.

MSG是Messenger的缩写,中文为即时消息。HTTP,即超文本传输协议,是HyperTextTransferProtocol的缩写。浏览网页时在浏览器地址栏中输入网址地址都是以"HTTP://"开始的。HTTP定义了信息如何被格式化、如何被传输,以及在各种命令下服务器和浏览器所采取的响应。MSG is the abbreviation of Messenger, which means instant message in Chinese. HTTP, Hypertext Transfer Protocol, is the abbreviation of HyperTextTransferProtocol. When browsing the web, the URL addresses entered in the browser address bar all start with "HTTP://". HTTP defines how information is formatted, how it is transmitted, and the responses taken by servers and browsers under various commands.

本发明的具备机器视觉的智能设备可以是智能手机,是移动式机器视觉设备,可做到随时随地对产品进行防伪查询。The intelligent device equipped with machine vision of the present invention can be a smart phone, which is a mobile machine vision device, and can perform anti-counterfeiting inquiries on products anytime and anywhere.

本发明针对查询方面提出了改进方式,对于消费者的恶意查询通过应用程序限制查询次数和收费模式来防止。数据库在消费者第一次查询的自动记录查询号码、查询次数或查询设备号,超过一定次数则采取收费模式,该产品被获取开锁密码后则清空该产品记录的查询号码记录表。The invention proposes an improved method for query, and prevents malicious query of consumers by limiting the number of queries and the charging mode of the application program. The database automatically records the query number, query times or query device number when the consumer queries for the first time. If the number exceeds a certain number, the charging mode will be adopted. After the product is obtained with the unlock password, the query number record table recorded by the product will be cleared.

本发明的防伪查询终端服务器的短信平台也可以对图像(彩信方式)、短消息进行处理解析出防伪码,查询系统通过得到防伪码,将数据进入数据库查询得到防伪查询,得到查询结果,返回给客户;同理针对需要开锁的产品也采取同样的方法对开锁码进行处理,通过系统返回的密码打开密码锁。该查询技术对某一个产品查询后,对同一个手机号码(智能手机)或者同一机器视觉设备号无法再进行下次查询,开锁码只可查询一次,防止包装盒重复使用造假以及恶意查询等现象,同现有技术对比,本发明适用性高、效率高、准确率高,防伪的效果好,可代替传统的人工防伪查询。The short message platform of the anti-counterfeiting query terminal server of the present invention can also process images (MMS mode) and short messages to analyze anti-counterfeiting codes, and the query system can obtain anti-counterfeiting codes by entering the data into the database query to obtain anti-counterfeiting queries, obtain query results, and return to Customers; similarly, the same method is used to process the unlock code for products that need to be unlocked, and the combination lock is opened through the password returned by the system. After the query technology queries a certain product, the same mobile phone number (smart phone) or the same machine vision device number cannot be queried next time, and the unlock code can only be queried once to prevent repeated use of packaging boxes, fraudulent and malicious queries, etc. Compared with the prior art, the present invention has high applicability, high efficiency, high accuracy rate and good anti-counterfeiting effect, and can replace traditional manual anti-counterfeiting inquiry.

最后应当说明的是,以上实施例仅用于说明本发明的技术方案而非对本发明保护范围的限制,尽管参照较佳实施例对本发明作了详细说明,本领域的普通技术人员应当理解,可以对本发明的技术方案进行修改或者等同替换,而不脱离本发明技术方案的实质和范围。Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than limit the protection scope of the present invention. Although the present invention has been described in detail with reference to the preferred embodiments, those of ordinary skill in the art should understand that Modifications or equivalent replacements are made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention.

Claims (8)

3. the product false proof querying method based on machine vision of To enterprises user according to claim 1, it is characterised in that: described step 2) the content of inquiry table include: the left and right ratio of digital 0 correspondence is 0.09918;The left and right ratio of numeral 1 correspondence is 0.09866;The left and right ratio of numeral 2 correspondences is 1.1943;The left and right ratio of numeral 3 correspondences is 1.3929;The left and right ratio of numeral 4 correspondences is 1.5071;The left and right ratio of numeral 5 correspondences is 1.1980;The left and right ratio of numeral 6 correspondences is 0.9035;The left and right ratio of numeral 7 correspondences is 1.1722;The left and right ratio of numeral 8 correspondences is 0.9954;The left and right ratio that numerical character is 9 correspondences is 1.1280;
4. the product false proof querying method based on machine vision of To enterprises user according to claim 1, it is characterised in that: described step 2) the content of inquiry table include: the row concentration degree of digital 0 correspondence is 0.5500;The row concentration degree of numeral 1 correspondence is 0.4583;The row concentration degree of numeral 2 correspondences is 0.1220;The row concentration degree of numeral 3 correspondences is 0.3889;The row concentration degree of numeral 4 correspondences is 0.0000;The row concentration degree of numeral 5 correspondences is 0.3714;The row concentration degree of numeral 6 correspondences is 0.4500;The row concentration degree of numeral 7 correspondences is 0.1026;The row concentration degree of numeral 8 correspondences is 0.4865;Numerical character is the row concentration degree of 9 correspondences is 0.4500.
7. the product false proof querying method based on machine vision of To enterprises user according to claim 1, it is characterised in that: described step 2) the content of inquiry table include: the ratio of width to height of digital 0 correspondence is 0.6061;The ratio of width to height of numeral 1 correspondence is 0.3636;The ratio of width to height of numeral 2 correspondences is 0.6212;The ratio of width to height of numeral 3 correspondences is 0.5455;The ratio of width to height of numeral 4 correspondences is 0.6364;The ratio of width to height of numeral 5 correspondences is 0.5303;The ratio of width to height of numeral 6 correspondences is 0.6061;The ratio of width to height of numeral 7 correspondences is 0.5909;The ratio of width to height of numeral 8 correspondences is 0.5606;Numerical character is the ratio of width to height of 9 correspondences is 0.6061;
Described step 2) the content of inquiry table include: the ratio of width to height of digital 0 correspondence and central area and be 1.6061;The ratio of width to height and the central area of numeral 1 correspondence and be 0.6969;The ratio of width to height and the central area of numeral 2 correspondences and be 1.4957;The ratio of width to height and the central area of numeral 3 correspondences and be 1.3721;The ratio of width to height and the central area of numeral 4 correspondences and be 1.1313;The ratio of width to height and the central area of numeral 5 correspondences and be 1.2469;The ratio of width to height and the central area of numeral 6 correspondences and be 1.4258;The ratio of width to height and the central area of numeral 7 correspondences and be 1.3469;The ratio of width to height and the central area of numeral 8 correspondences and be 1.0821;Numerical character be the ratio of width to height and the central area of 9 correspondences and be 1.4197.
CN201210174981.2A2012-05-312012-05-31The product false proof querying method based on machine vision of To enterprises user and systemExpired - Fee RelatedCN102750637B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN201210174981.2ACN102750637B (en)2012-05-312012-05-31The product false proof querying method based on machine vision of To enterprises user and system

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201210174981.2ACN102750637B (en)2012-05-312012-05-31The product false proof querying method based on machine vision of To enterprises user and system

Publications (2)

Publication NumberPublication Date
CN102750637A CN102750637A (en)2012-10-24
CN102750637Btrue CN102750637B (en)2016-06-29

Family

ID=47030791

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN201210174981.2AExpired - Fee RelatedCN102750637B (en)2012-05-312012-05-31The product false proof querying method based on machine vision of To enterprises user and system

Country Status (1)

CountryLink
CN (1)CN102750637B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN111652224A (en)*2019-12-312020-09-11重庆芯讯通无线科技有限公司Automatic module IMEI number checking device and checking method

Citations (2)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US6366696B1 (en)*1996-12-202002-04-02Ncr CorporationVisual bar code recognition method
CN101515299A (en)*2009-04-082009-08-26海南亚元防伪技术研究所False-proof/anti-channeling method for recording and examining position relation

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN102446273B (en)*2011-09-062013-10-02贵州卓霖防伪科技有限公司Method for producing pair code of code-locked anti-counterfeit bottle cap

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US6366696B1 (en)*1996-12-202002-04-02Ncr CorporationVisual bar code recognition method
CN101515299A (en)*2009-04-082009-08-26海南亚元防伪技术研究所False-proof/anti-channeling method for recording and examining position relation

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Edge Detection Methods for Gray-R Barcode Grade Rod;Gengbiao Chen等;《Proceedings of 2010 International Conference on Broadcast Technology and Multimedia Communication》;20101213;全文*
一种人民币纸币号码自动识别快速方法;娄元芳等;《微计算机信息》;20081225;第24卷(第12-3期);第210-212页*

Also Published As

Publication numberPublication date
CN102750637A (en)2012-10-24

Similar Documents

PublicationPublication DateTitle
US20240014820A1 (en)Detection of images in relation to targets based on colorspace transformation techniques and utilizing ultraviolet light
US9946865B2 (en)Document authentication based on expected wear
EP3065335B1 (en)System and method for real-time verification of clock synchronisation-based dynamic password anti-counterfeiting tag validity
CN106022805A (en)Anti-fake traceablility system and method based on label reading
US20220198473A1 (en)Method and apparatus for generating and querying traceability code of commodity
US20210142337A1 (en)Product Authenticity Verification Based on Environment
US20150341370A1 (en)Systems and methods relating to the authenticity and verification of photographic identity documents
CN106529976A (en)Checking system and checking method for commodity determination uniqueness
CN104424570B (en)A kind of vehicle parts anti-counterfeiting information reviews discrimination method
US20200151738A1 (en)Data Driven Product Authenticity Verification
US20200074130A1 (en)Item identification
CN102609543A (en)Multifunctional two-dimensional code product traceability system and traceability method
CN103136676A (en)Two-dimension code anti-counterfeiting system recognized by mobile phone automatically and usage method thereof
CN110020161B (en)Data processing method, log processing method and terminal
CN102693490B (en) Product anti-counterfeiting query method and system based on machine vision for individual users
CN102903072A (en)Blind digital watermark detection method and system
CN104243474A (en)Electronic device authenticity verification method and device
CN107078909A (en)Method and Verification System for registering random security feature
WO2016155159A1 (en)Anti-fake method for realizing all-barcode verification based on wechat id
CN107263924B (en)Smart packages mounted box is manufactured and application method
CN206431680U (en)A kind of rapid safety Claims Resolution system for identity code barcode scanning of being traced to the source based on product false proof
CN102750637B (en)The product false proof querying method based on machine vision of To enterprises user and system
US20210256235A1 (en)Object id-centered workflow
WuA qr code-based on-street parking fee payment mechanism
CN103426092A (en)Two-dimensional code verification method for food safety

Legal Events

DateCodeTitleDescription
C06Publication
PB01Publication
C10Entry into substantive examination
SE01Entry into force of request for substantive examination
C14Grant of patent or utility model
GR01Patent grant
CF01Termination of patent right due to non-payment of annual fee

Granted publication date:20160629

CF01Termination of patent right due to non-payment of annual fee

[8]ページ先頭

©2009-2025 Movatter.jp