Method and system for accurately positioning labeling paper based on machine vision

Through deep learning technology, multi-angle rotation analysis is performed on the labeling detection image, and rotation desensitization features are extracted. Combined with the feature differences of the labeling qualified reference image, the problem of labeling positioning detection being sensitive to rotation changes is solved and the detection accuracy is improved. and system performance.

CN118657836BActive Publication Date: 2024-10-29BEIJING EGGPLANT BEAN NETWORK TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411139561.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-20
Publication Date
2024-10-29
Estimated Expiration
2044-08-20

AI Technical Summary

Technical Problem

Existing labeling positioning detection methods based on machine vision are sensitive to changes in image rotation, which increases the difficulty of feature extraction and affects detection accuracy. The complex preprocessing steps increase computational complexity and have a negative impact on the real-time performance of the system.

Method used

Image processing technology based on deep learning is used to conduct multi-angle rotation analysis on the labeling detection images collected by industrial cameras. The rotation desensitization representation vector of the labeling image is extracted through the feature distribution reverse mask clustering analysis network, and combined with the labeling qualification Refer to the feature differences of the image to intelligently determine whether the labeling positioning is qualified.

Benefits of technology

The anti-rotation change ability of labeling positioning detection is improved, the accuracy of detection is enhanced, the computational complexity is reduced, and the real-time performance of the system is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118657836B_ABST
    Figure CN118657836B_ABST
Patent Text Reader

Abstract

The present application relates to the field of intelligent image processing, and specifically to a method and system for accurately positioning labeling paper based on machine vision. It uses deep learning-based image processing technology to perform multi-angle rotation analysis on labeling detection images collected by industrial cameras, and mines the invariant features of labeling detection images under multi-angle rotation conditions, and then intelligently judges whether the labeling positioning in the detection image is qualified based on the feature difference between the multi-angle rotation invariant features of the detection image and the features of the reference image with qualified labeling. The present application can improve the ability of labeling positioning detection to resist rotation changes and improve the accuracy of labeling positioning detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of intelligent image processing, and specifically to a method and system for accurately positioning labeling paper based on machine vision. Background Art

[0002] In recent years, with the development of machine vision technology, vision-based labeling paper positioning detection methods have been widely used. They accurately identify and correct labeling deviations through image processing and analysis, thereby improving the accuracy and stability of labeling. For example, the Chinese patent application number 202010198167.9 discloses a sticker processing method and device, wherein the method includes: acquiring an image and a sticker; determining a target reference line; wherein the target reference line is used to identify the adding position of the sticker in the image; in response to the user's moving operation on the sticker, detecting the position change of the sticker in the image; determining the final adsorption state of the preset reference line on the sticker and the target reference line according to the position change; if the final adsorption state is adsorption, the sticker is moved to the adding position. The invention can accurately locate the position of the sticker by determining the target reference line coordinates and determining the final adsorption state of the preset reference line and the target reference line of the sticker according to the position change of the sticker in the image. If the final adsorption state is adsorption, the sticker is moved to the adding position.

[0003] However, existing machine vision-based labeling and positioning detection methods are usually sensitive to image rotation changes. When the labeled object or camera angle changes, it will increase the difficulty of feature extraction and affect the detection accuracy. Existing solutions usually rely on complex preprocessing steps to correct the image angle, which not only increases the computational complexity, but also has a negative impact on the real-time performance of the system.

[0004] Therefore, an optimized machine vision-based labeling paper precise positioning method is expected to solve the above technical problems. Summary of the invention

[0005] This application is made in consideration of the above problems. One object of this application is to provide a method and system for accurately positioning labeling paper based on machine vision.

[0006] The embodiment of the present application provides a method for accurately positioning labeling paper based on machine vision, which includes:

[0007] Obtain labeling detection images collected by industrial cameras;

[0008] Rotating the labeling condition detection image at multiple angles to obtain an image set of multi-angle labeling condition detection images;

[0009] Performing labeling feature clustering analysis on the image set of the multi-angle labeling detection images to obtain a rotation-desensitized representation vector of the labeling image;

[0010] Extracting labeling qualified reference images from a database;

[0011] Whether the labeling positioning is qualified is determined based on the feature difference between the labeling feature of the qualified labeling reference image and the rotation desensitized representation vector of the labeled image.

[0012] For example, according to the machine vision-based labeling paper precise positioning method of an embodiment of the present application, a labeling feature clustering analysis is performed on the image set of the multi-angle labeling detection image to obtain a rotation-desensitized representation vector of the labeling image, including:

[0013] Respectively extracting labeling features of each multi-angle labeling situation detection image in the image set of the multi-angle labeling situation detection image to obtain a set of multi-angle labeling image feature vectors;

[0014] The set of the multi-angle labeled image feature vectors is input into a feature distribution inverse mask clustering analysis network to obtain the rotation desensitized representation vector of the labeled image.

[0015] For example, according to the machine vision-based labeling paper precise positioning method of an embodiment of the present application, the labeling features of each multi-angle labeling situation detection image in the image set of the multi-angle labeling situation detection image are respectively extracted to obtain a set of multi-angle labeling image feature vectors, including:

[0016] Each multi-angle labeling detection image in the image set of the multi-angle labeling detection image is respectively input into a labeling feature extractor based on the AlexNet model to obtain a set of multi-angle labeling image feature vectors.

[0017] For example, according to the machine vision-based labeling paper precise positioning method of an embodiment of the present application, the set of the multi-angle labeling image feature vectors is input into the feature distribution inverse mask clustering analysis network to obtain the rotation desensitized representation vector of the labeling image, including:

[0018] Clustering the set of multi-angle labeled image feature vectors to obtain a multi-angle labeled image feature clustering center vector;

[0019] Calculating the semantic correlation coefficient between each multi-angle labeled image feature vector in the set of multi-angle labeled image feature vectors and the multi-angle labeled image feature cluster center vector to obtain a sequence of semantic correlation coefficients;

[0020] Taking the reciprocal of each semantic correlation coefficient in the sequence of semantic correlation coefficients to obtain a sequence of semantic anti-correlation coefficients;

[0021] Using a Sigmoid function to normalize the sequence of semantic anti-correlation coefficients to obtain a sequence of semantic anti-correlation weight coefficients;

[0022] Using each semantic anti-correlation weight coefficient in the sequence of semantic anti-correlation weight coefficients as a weight, weighting each multi-angle labeled image feature vector in the set of multi-angle labeled image feature vectors to obtain a set of suppressed multi-angle labeled image feature vectors;

[0023] Calculating the positional difference between the set of multi-angle labeled image feature vectors and the set of suppressed multi-angle labeled image feature vectors to obtain a set of optimized multi-angle labeled image feature vectors;

[0024] The position-based mean vector of the set of the optimized multi-angle labeled image feature vectors is calculated to obtain the rotation-desensitized representation vector of the labeled image.

[0025] For example, according to the machine vision-based labeling paper precise positioning method of an embodiment of the present application, clustering the set of multi-angle labeling image feature vectors to obtain the multi-angle labeling image feature clustering center vector includes:

[0026] The position-based mean vector of the set of the multi-angle labeled image feature vectors is calculated to obtain the multi-angle labeled image feature cluster center vector.

[0027] For example, according to the machine vision-based labeling paper precise positioning method of an embodiment of the present application, the semantic correlation coefficient between each multi-angle labeling image feature vector in the set of multi-angle labeling image feature vectors and the multi-angle labeling image feature clustering center vector is calculated to obtain a sequence of semantic correlation coefficients, including:

[0028] The cosine similarity between each multi-angle labeled image feature vector in the set of the multi-angle labeled image feature vectors and the multi-angle labeled image feature cluster center vector is calculated as the semantic correlation coefficient to obtain a sequence of the semantic correlation coefficients.

[0029] For example, according to the machine vision-based labeling paper precise positioning method of the embodiment of the present application, determining whether the labeling positioning is qualified based on the feature difference between the labeling feature of the qualified labeling reference image and the rotation desensitized representation vector of the labeling image includes:

[0030] Extracting labeling features from the qualified labeling reference image to obtain a qualified labeling reference representation vector;

[0031] Calculating a differential feature vector between the rotation-desensitized representation vector of the labeled image and the labeled qualified reference representation vector;

[0032] The differential feature vector is input into a positioning identifier based on a classifier to obtain a recognition result, and the recognition result is used to indicate whether the labeling positioning is qualified.

[0033] For example, according to the machine vision-based labeling paper precise positioning method of an embodiment of the present application, wherein the labeling feature extraction is performed on the qualified labeling reference image to obtain a qualified labeling reference representation vector, including:

[0034] The labeled qualified reference image is input into the labeling feature extractor based on the AlexNet model to obtain the labeled qualified reference representation vector.

[0035] The embodiment of the present application also provides a labeling paper precise positioning system based on machine vision, which includes:

[0036] A detection image acquisition module is used to obtain a labeling detection image acquired by an industrial camera;

[0037] An image rotation module, used for performing multi-angle rotation on the labeling condition detection image to obtain an image set of multi-angle labeling condition detection images;

[0038] A cluster analysis module, used for performing labeling feature cluster analysis on the image set of the multi-angle labeling detection image to obtain a rotation desensitized representation vector of the labeling image;

[0039] A reference image extraction module is used to extract a labeling qualified reference image from a database;

[0040] The positioning analysis module is used to determine whether the labeling positioning is qualified based on the feature difference between the labeling feature of the qualified labeling reference image and the rotation desensitized representation vector of the labeled image.

[0041] For example, according to the machine vision-based labeling paper precise positioning system of an embodiment of the present application, the cluster analysis module is used to:

[0042] Respectively extracting labeling features of each multi-angle labeling situation detection image in the image set of the multi-angle labeling situation detection image to obtain a set of multi-angle labeling image feature vectors;

[0043] The set of the multi-angle labeled image feature vectors is input into a feature distribution inverse mask clustering analysis network to obtain the rotation desensitized representation vector of the labeled image.

[0044] The present application has at least the following technical effects: Compared with the prior art, the machine vision-based labeling paper precise positioning method and system according to the embodiment of the present application uses deep learning-based image processing technology to perform multi-angle rotation analysis on the labeling detection image collected by the industrial camera, and mines the invariant features of the labeling detection image under multi-angle rotation, and then intelligently judges whether the labeling positioning in the detection image is qualified based on the feature difference between the multi-angle rotation invariant features of the detection image and the features of the qualified reference image. The present application can improve the anti-rotation change capability of labeling positioning detection and improve the accuracy of labeling positioning detection. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings of the embodiments of the present application are briefly introduced below. Obviously, the drawings described below only relate to some embodiments of the present application, and are not intended to limit the present application.

[0046] Figure 1 A schematic diagram of the application architecture of the method for accurately positioning labeling paper based on machine vision in an embodiment of the present application is shown;

[0047] Figure 2 A flow chart of a method for accurately positioning labeling paper based on machine vision in an embodiment of the present application is shown;

[0048] Figure 3 A flowchart of sub-step S530 of the method for accurately positioning labeling paper based on machine vision in an embodiment of the present application is shown;

[0049] Figure 4 A flowchart of sub-step S550 of the method for accurately positioning labeling paper based on machine vision in an embodiment of the present application is shown;

[0050] Figure 5 The structure diagram of the labeling paper precise positioning system based on machine vision in the embodiment of the present application is shown;

[0051] Figure 6 The diagram shows an application scenario of the method for accurately positioning labeling paper based on machine vision in an embodiment of the present application. DETAILED DESCRIPTION

[0052] The technical solutions in the embodiments of the present application will be described clearly and completely below in conjunction with the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, not all embodiments. Based on the embodiments of the present application, all other embodiments obtained by ordinary technicians in this field without creative work also fall within the scope of protection of the present application.

[0053] The terms used in this specification are those common terms currently widely used in the art in consideration of the functions of the present application, but these terms may vary according to the intentions of those skilled in the art, precedents, or new technologies in the art. In addition, specific terms may be selected, and in this case, their detailed meanings will be described in the detailed description of the present application. Therefore, the terms used in the specification should not be understood as simple names, but rather as a general description based on the meaning of the terms and the present application.

[0054] Although the present application makes various references to certain modules in the system according to the embodiments of the present application, any number of different modules can be used and run on the user terminal and / or server. The modules are only illustrative, and different aspects of the system and method can use different modules.

[0055] Flowcharts are used in the present application to illustrate the operations performed by the system according to the embodiments of the present application. It should be understood that the preceding or following operations are not necessarily performed accurately in order. On the contrary, various steps may be processed in reverse order or simultaneously as required. At the same time, other operations may also be added to these processes, or a certain step or several steps of operations may be removed from these processes.

[0056] Figure 1 The schematic diagram of the application architecture of the method for accurately locating labeling paper based on machine vision in an embodiment of the present application is shown, including a server 100 and a terminal device 200.

[0057] The terminal device 200 and the server 100 can be connected via the Internet to achieve mutual communication. Optionally, the above-mentioned Internet uses standard communication technology and / or protocol. The Internet is usually the Internet, but it can also be any network, including but not limited to any combination of a local area network (LAN), a metropolitan area network (MAN), a wide area network (WAN), a mobile, wired or wireless network, a private network or a virtual private network. In some embodiments, the data exchanged through the network can be represented by technologies and / or formats including Hyper Text Markup Language (HTML), Extensible Markup Language (XML), etc. In addition, conventional encryption technologies such as Secure Socket Layer (SSL), Transport Layer Security (TLS), Virtual Private Network (VPN), Internet Protocol Security (IPsec), etc. can be used to encrypt all or some links. In other embodiments, customized and / or dedicated data communication technologies can also be used to replace or supplement the above-mentioned data communication technologies.

[0058] The server 100 can provide various network services for the terminal device 200, wherein the server 100 can be a single server, a server cluster consisting of several servers, or a cloud computing center. Specifically, the server 100 may include a processor 110 (Center Processing Unit, CPU), a memory 120, an input device 130, and an output device 140, etc. The input device 130 may include a keyboard, a mouse, a touch screen, etc., and the output device 140 may include a display device, such as a liquid crystal display (Liquid Crystal Display, LCD), a cathode ray tube (Cathode Ray Tube, CRT), etc.

[0059] The memory 120 may include a read-only memory (ROM) and a random access memory (RAM), and provides the processor 110 with program instructions and data stored in the memory 120. In the embodiment of the present application, the memory 120 may be used to store the program of the machine vision-based labeling paper precise positioning method in the embodiment of the present application.

[0060] The processor 110 calls the program instructions stored in the memory 120, and the processor 110 is used to execute the steps of any one of the machine vision-based labeling paper precise positioning methods in the embodiments of the present application according to the obtained program instructions.

[0061] In addition, the application architecture diagram in the embodiment of the present application is intended to more clearly illustrate the technical solution in the embodiment of the present application, and does not constitute a limitation on the technical solution provided in the embodiment of the present application. Of course, for other application architectures and business applications, the technical solution provided in the embodiment of the present application is also applicable to similar problems.

[0062] The following is a non-restrictive description of the machine vision-based labeling paper precise positioning method provided according to at least one embodiment of the present application through several examples or embodiments. As described below, different features in these specific examples or embodiments can be combined with each other without conflicting with each other to obtain new examples or embodiments, and these new examples or embodiments also fall within the scope of protection of the present application.

[0063] In response to the above technical problems, the technical concept of this application is to use deep learning-based image processing technology to perform multi-angle rotation analysis on the labeling detection image collected by the industrial camera, and to mine the invariant features of the labeling detection image under multi-angle rotation. Then, based on the feature difference between the multi-angle rotation invariant features of the detection image and the features of the reference image with qualified labeling, it is intelligently determined whether the labeling positioning in the detection image is qualified. This application can improve the anti-rotation change capability of labeling positioning detection and improve the accuracy of labeling positioning detection.

[0064] Based on this, Figure 2 The flowchart of the method for accurately locating label paper based on machine vision in the embodiment of the present application is shown. For example, the method for accurately locating label paper based on machine vision can be executed by a server, which can be Figure 1 The server 100 shown in FIG. Figure 2 As shown, according to the machine vision-based precise positioning method of labeling paper according to the embodiment of the present application, the steps include: S510, acquiring a labeling condition detection image collected by an industrial camera; S520, performing multi-angle rotation on the labeling condition detection image to obtain an image set of multi-angle labeling condition detection images; S530, performing labeling feature clustering analysis on the image set of multi-angle labeling condition detection images to obtain a labeling image rotation desensitized representation vector; S540, extracting a labeling qualified reference image from a database; S550, determining whether the labeling positioning is qualified based on the feature difference between the labeling feature of the labeling qualified reference image and the labeling image rotation desensitized representation vector.

[0065] Specifically, in the technical solution of the present application, first, a labeling condition detection image collected by an industrial camera is obtained. Then, considering that the labeling image will present different visual features at different angles, which will affect the accuracy of labeling feature extraction and positioning recognition. Therefore, in order to overcome the rotation sensitivity of labeling positioning feature extraction, in the technical solution of the present application, the labeling condition detection image is rotated at multiple angles to simulate various rotation changes that may be encountered in the actual production process, thereby constructing an image set of multi-angle labeling condition detection images, which not only enriches the sample diversity used for feature extraction, but also enhances the system's robustness to rotation changes.

[0066] Next, a labeling feature extractor based on the AlexNet model is used to perform feature extraction on each multi-angle labeling detection image in the image set of the multi-angle labeling detection image, so as to utilize the powerful ability of the AlexNet model in image feature extraction, and perform sliding convolution operations on each multi-angle labeling detection image to effectively capture the labeling features in each image, thereby obtaining a set of multi-angle labeling image feature vectors.

[0067] Furthermore, considering that during the multi-angle rotation of the labeling detection image, some features in the labeling detection image may change with the change of the rotation angle, which interferes with the accurate judgment of the labeling positioning. In order to effectively remove the rotation-sensitive features in the image and extract the core features of the labeled image that remain stable under multi-angle rotation, in the technical solution of the present application, a feature distribution reverse mask clustering analysis network is introduced to perform labeling feature clustering analysis on the set of multi-angle labeled image feature vectors, and key features that are insensitive to rotation changes are extracted from them to obtain a rotation-desensitized representation vector of the labeled image. Specifically, the feature distribution reverse mask clustering analysis network calculates the mean vector of the set of multi-angle labeled image feature vectors as the cluster center to extract the common information of the image and reveal the stability characteristics of the labeled image during the rotation process. At the same time, using the reverse masking technology, according to the semantic similarity between each multi-angle labeled image feature vector in the set and the cluster center, the reverse mask weighting is performed to enhance the feature representation (i.e., rotation-sensitive features) that deviate from the cluster center. Then, the weighted explicit rotation sensitivity features are removed from the set of multi-angle labeled image feature vectors through differential operation to highlight common information, thereby achieving purification optimization and selective attention of labeling features. Finally, global feature aggregation is achieved through position average calculation to obtain the rotation desensitized representation vector of the labeled image, thereby providing a more stable and accurate feature representation for labeling positioning detection.

[0068] Accordingly, in step S530, if Figure 3As shown, a labeling feature clustering analysis is performed on the image set of the multi-angle labeling situation detection image to obtain a labeling image rotation desensitized representation vector, including: S531, respectively extracting the labeling features of each multi-angle labeling situation detection image in the image set of the multi-angle labeling situation detection image to obtain a set of multi-angle labeling image feature vectors; S532, inputting the set of multi-angle labeling image feature vectors into a feature distribution inverse mask clustering analysis network to obtain the labeling image rotation desensitized representation vector.

[0069] Among them, in step S531, the labeling features of each multi-angle labeling situation detection image in the image set of the multi-angle labeling situation detection image are extracted respectively to obtain a set of multi-angle labeling image feature vectors, including: inputting each multi-angle labeling situation detection image in the image set of the multi-angle labeling situation detection image into a labeling feature extractor based on the AlexNet model respectively to obtain the set of multi-angle labeling image feature vectors.

[0070] Wherein, in step S532, the set of the multi-angle labeled image feature vectors is input into the feature distribution reverse mask clustering analysis network to obtain the rotation desensitized representation vector of the labeled image, including: clustering the set of the multi-angle labeled image feature vectors to obtain the multi-angle labeled image feature clustering center vector; calculating the semantic correlation coefficient between each multi-angle labeled image feature vector in the set of the multi-angle labeled image feature vectors and the multi-angle labeled image feature clustering center vector to obtain a sequence of semantic correlation coefficients; taking the reciprocal of each semantic correlation coefficient in the sequence of semantic correlation coefficients to obtain a sequence of semantic anti-correlation coefficients; using the Sigmoid function to The sequence of semantic anti-correlation coefficients is normalized to obtain a sequence of semantic anti-correlation weight coefficients; each semantic anti-correlation weight coefficient in the sequence of semantic anti-correlation weight coefficients is used as a weight to weight each multi-angle labeled image feature vector in the set of multi-angle labeled image feature vectors to obtain a set of suppressed multi-angle labeled image feature vectors; the positional difference between the set of multi-angle labeled image feature vectors and the set of suppressed multi-angle labeled image feature vectors is calculated to obtain a set of optimized multi-angle labeled image feature vectors; the positional mean vector of the set of optimized multi-angle labeled image feature vectors is calculated to obtain the labeled image rotation desensitized representation vector.

[0071] Specifically, clustering the set of multi-angle labeled image feature vectors to obtain a multi-angle labeled image feature clustering center vector includes: calculating a position-based mean vector of the set of multi-angle labeled image feature vectors to obtain the multi-angle labeled image feature clustering center vector.

[0072] Specifically, the semantic correlation coefficient between each multi-angle labeled image feature vector in the set of multi-angle labeled image feature vectors and the multi-angle labeled image feature cluster center vector is calculated to obtain a sequence of semantic correlation coefficients, including: calculating the cosine similarity between each multi-angle labeled image feature vector in the set of multi-angle labeled image feature vectors and the multi-angle labeled image feature cluster center vector as the semantic correlation coefficient to obtain a sequence of semantic correlation coefficients.

[0073] In a specific example, the set of multi-angle labeled image feature vectors is input into a feature distribution reverse mask clustering analysis network to obtain the labeled image rotation desensitized representation vector, including: processing the set of multi-angle labeled image feature vectors with the following reverse mask aggregation formula to obtain the labeled image rotation desensitized representation vector, wherein the reverse mask aggregation formula is:

[0074]

[0075]

[0076]

[0077]

[0078]

[0079]

[0080]

[0081]

[0082] in, is the set of feature vectors of the multi-angle labeled image, , , and are respectively the first, second, and third in the set of multi-angle labeled image feature vectors. and multi-angle labeled image feature vectors, The value of is the number of feature vectors in the set of feature vectors of the multi-angle labeled image, represents the transpose of the eigenvector, is the feature clustering center vector of multi-angle labeled image, represents the magnitude of a vector, Indicates the The semantic correlation coefficient between the multi-angle labeled image feature vector and the multi-angle labeled image feature cluster center vector, For the The semantic anti-correlation coefficient, For the semantic anti-correlation weight coefficients, represents an exponential function with a natural constant as base, is a set of feature vectors that suppress multi-angle labeling images, , , and are respectively the first, second, and third in the set of the suppressed multi-angle labeling image feature vectors. and The suppressed multi-angle labeled image feature vector, is a set of optimized multi-angle labeled image feature vectors, , , and are respectively the first, second, and third in the set of optimized multi-angle labeled image feature vectors. and Optimized multi-angle labeled image feature vectors, A desensitized representation vector is rotated for the labeled image.

[0083] Next, in order to provide a clear benchmark for the quality inspection of product labeling positioning, qualified labeling reference images are further extracted from the database. The qualified labeling reference images are strictly screened and verified, representing the standard state of labeling quality, that is, the labeling position is accurate, without skew, wrinkles and other defects.

[0084] Furthermore, in order to ensure the consistency and comparability of the qualified labeling reference image and the labeling condition detection image in the feature space, the labeling feature extractor based on the AlexNet model is also used to perform feature extraction on the qualified labeling reference image to reduce the error introduced by the inconsistency of the image feature extraction model, thereby obtaining a qualified labeling reference representation vector.

[0085] Secondly, by calculating the differential feature vector between the rotation-desensitized representation vector of the labeling image and the qualified labeling reference representation vector, the feature difference between the labeling positioning detection image and the qualified labeling reference image is quantified to reveal the position deviation or defects that may exist in the labeling process, such as skew, misalignment or wrinkles. It is worth mentioning that since the labeling positioning detection image has been subjected to rotation desensitization processing, the relevant feature changes caused by the change in rotation angle have been removed from the rotation-desensitized representation vector of the labeling image. Therefore, the differential feature vector reflects more of the key difference information such as the shape, texture, and position of the label itself, rather than the changes caused by rotation.

[0086] Next, the differential feature vector is input into a positioning identifier based on a classifier to obtain a recognition result, and the recognition result is used to indicate whether the labeling positioning is qualified. That is, the differential feature vector is classified using a pre-trained classifier to determine whether it belongs to a qualified category. Specifically, during the training process, the classifier can learn the feature differences and boundaries between qualified labeling and unqualified labeling through supervised learning, so that the input differential feature vector can be accurately classified as qualified or unqualified during the test phase, providing instant feedback for the quality control of the production line. Accordingly, if the differential feature vector is classified as a qualified category, it indicates that the labeling positioning currently detected is accurate, and the product can continue to enter the next process; conversely, if the differential feature vector is classified as an unqualified category, an alarm mechanism is triggered to prompt the operator to handle the problem product, such as re-labeling or removing it from the production line.

[0087] Accordingly, in step S550, if Figure 4 As shown, based on the feature difference between the labeling features of the qualified labeling reference image and the rotation desensitized representation vector of the labeling image, determining whether the labeling positioning is qualified includes: S551, extracting the labeling features of the qualified labeling reference image to obtain a qualified labeling reference representation vector; S552, calculating the differential feature vector between the rotation desensitized representation vector of the labeling image and the qualified labeling reference representation vector; S553, inputting the differential feature vector into a positioning identifier based on a classifier to obtain a recognition result, and the recognition result is used to indicate whether the labeling positioning is qualified.

[0088] Among them, in step S551, labeling features are extracted from the qualified labeling reference image to obtain a qualified labeling reference representation vector, including: inputting the qualified labeling reference image into the labeling feature extractor based on the AlexNet model to obtain the qualified labeling reference representation vector.

[0089] Preferably, the differential feature vector is input into a classifier-based positioning identifier to obtain a recognition result, including: calculating the first norm and second norm of the mean vector of the labeled image rotation desensitized representation vector and the labeled qualified reference representation vector; calculating the weighted sum of the inverse of the square root of the second norm and the first norm, and performing a dot multiplication with the differential feature vector to obtain a first differential feature correction subvector; performing a dot multiplication of the dot product vector of the labeled image rotation desensitized representation vector and the labeled qualified reference representation vector and the square root of the length of the differential feature vector to obtain a second differential feature correction subvector; calculating the weighted sum of the first differential feature correction subvector and the second differential feature correction subvector to obtain a differential feature correction vector; performing a dot multiplication of the differential feature correction vector and the differential feature vector to obtain a corrected differential feature vector; and inputting the corrected differential feature vector into the classifier-based positioning identifier to obtain the recognition result.

[0090] The calculation process of the differential feature correction vector is expressed as follows:

[0091]

[0092] in, and are respectively the rotation desensitized representation vector of the labeled image and the qualified reference representation vector of the labeled image, is the mean vector of the rotation-desensitized representation vector of the labeled image and the qualified reference representation vector of the labeled image, is the length of the differential eigenvector, represents the one-norm of the eigenvector, represents the bi-norm of the eigenvector, and and is the weighted sum weight as a hyperparameter, Indicates adding by position point. It means point multiplication by position. represents the differential feature correction vector.

[0093] Specifically, considering that the labeled image rotation desensitized representation vector and the labeled qualified reference representation vector represent the image semantic aggregation features of the image set of multi-angle labeling detection images and the image semantic features of the labeled qualified reference image, respectively. The positional difference between the labeled image rotation desensitized representation vector and the labeled qualified reference representation vector will also cause the difference feature vector to be offset relative to the semantic difference expression of the source image of the image set of multi-angle labeling detection images and the labeled qualified reference image due to the mismatch in the sample size of the image semantic feature distribution, thereby causing feature regression category shift. For this reason, the present application hopes to compensate for the category shift under the imbalance of the correspondence ratio of the image semantic fine-grained distribution by improving the differential representation of the labeled image rotation desensitized representation vector and the labeled qualified reference representation vector, thereby improving the accuracy of the classification results.

[0094] Therefore, based on the constrained representation of the structured foreground and background distinction of the supermanifold of the labeled image rotation desensitive representation vector and the labeled qualified reference representation vector based on the mean vector norm between the labeled image rotation desensitive representation vector and the labeled qualified reference representation vector, the feature-level key correspondence between the feature vectors of the labeled image rotation desensitive representation vector and the labeled qualified reference representation vector is modeled, and the global correlation relationship between the corresponding features is adjusted, so as to perform positive fine-grained correspondence suggestions by controlling the unbalanced ratio between the corresponding eigenvalues ​​of the labeled image rotation desensitive representation vector and the labeled qualified reference representation vector, so as to avoid extreme category imbalance between the feature vectors of the labeled image rotation desensitive representation vector and the labeled qualified reference representation vector by focusing on the focus.

[0095] By correcting the differential feature vector using the differential feature correction vector, the accuracy of the recognition result obtained by inputting the differential feature vector into a positioning identifier based on a classifier can be improved.

[0096] Specifically, the role of the classifier is to use the given categories and known training data to learn classification rules and classifiers, and then classify (or predict) unknown data. Logistic regression, SVM, etc. are often used to solve binary classification problems. For multi-class classification problems, logistic regression or SVM can also be used, but multiple binary classifications are required to form a multi-classification. However, this is prone to errors and is inefficient. Commonly used multi-classification methods include the Softmax classification function.

[0097] Based on the above embodiments, see Figure 5The figure is a structural schematic diagram of a labeling paper precise positioning system 800 based on machine vision in an embodiment of the present application. The labeling paper precise positioning system 800 based on machine vision includes: a detection image acquisition module 810, which is used to obtain a labeling condition detection image acquired by an industrial camera; an image rotation module 820, which is used to perform multi-angle rotation on the labeling condition detection image to obtain an image set of multi-angle labeling condition detection images; a cluster analysis module 830, which is used to perform labeling feature cluster analysis on the image set of multi-angle labeling condition detection images to obtain a labeling image rotation desensitization representation vector; a reference image extraction module 840, which is used to extract a labeling qualified reference image from a database; and a positioning analysis module 850, which is used to determine whether the labeling positioning is qualified based on the feature difference between the labeling feature of the labeling qualified reference image and the labeling image rotation desensitization representation vector.

[0098] In one example, in the above-mentioned machine vision-based labeling paper precise positioning system 800, the clustering analysis module 830 is used to: respectively extract the labeling features of each multi-angle labeling situation detection image in the image set of the multi-angle labeling situation detection image to obtain a set of multi-angle labeling image feature vectors; input the set of multi-angle labeling image feature vectors into the feature distribution inverse mask clustering analysis network to obtain the rotation desensitized representation vector of the labeling image.

[0099] Here, those skilled in the art can understand that the specific functions and operations of each module in the above-mentioned machine vision-based labeling paper precise positioning system 800 have been referred to above. Figures 2 to 4 The method for accurately positioning labeling paper based on machine vision has been described in detail, and therefore, its repeated description will be omitted.

[0100] Figure 6 FIG. 1 is an application scenario diagram of the method for accurately positioning labeling paper based on machine vision according to an embodiment of the present application. Figure 6 As shown, in this application scenario, first, a labeling detection image collected by an industrial camera is obtained (for example, Figure 6 D1 as shown in the figure) and extracting labeled qualified reference images from the database (e.g., Figure 6 Then, the labeling detection image and the qualified labeling reference image are input to a server (for example, Figure 6 In S) shown in , the server can use the machine vision-based labeling paper precise positioning algorithm to process the labeling condition detection image and the labeling qualified reference image to obtain a recognition result indicating whether the labeling positioning is qualified.

[0101] Based on the above embodiment, another exemplary embodiment of an electronic device is also provided in the embodiment of the present application. In some possible implementations, the electronic device in the embodiment of the present application may include a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor can implement the steps of the method for accurately positioning labeling paper based on machine vision in the above embodiment when executing the program.

[0102] For example, in the case of electronic equipment Figure 1 Taking the server 100 in the example as an example, the processor in the electronic device is the processor 110 in the server 100, and the memory in the electronic device is the memory 120 in the server 100.

[0103] The embodiment of the present application also provides a computer-readable storage medium, on which computer-executable instructions are stored. When the computer-executable instructions are executed by a processor, the method for accurately positioning labeling paper based on machine vision according to the embodiment of the present application described with reference to the above figures can be executed. The computer-readable storage medium includes, but is not limited to, for example, volatile memory and / or non-volatile memory. The volatile memory may, for example, include a random access memory (RAM) and / or a cache memory (cache), etc. The non-volatile memory may, for example, include a read-only memory (ROM), a hard disk, a flash memory, etc.

[0104] The embodiment of the present application also provides a computer program product or a computer program, which includes computer executable instructions, and the computer executable instructions are stored in a computer readable storage medium. The processor of the computer device reads the computer executable instructions from the computer readable storage medium, and the processor executes the computer executable instructions, so that the computer device executes the machine vision-based labeling paper precise positioning method according to the embodiment of the present application.

[0105] Those skilled in the art will appreciate that the contents disclosed in this application may be subject to various variations and improvements. For example, the various devices or components described above may be implemented by hardware, or by software, firmware, or a combination of some or all of the three.

[0106] In addition, although the present application makes various references to certain units in the system according to embodiments of the present application, any number of different units can be used and run on the client and / or server. The units are only illustrative, and different aspects of the system and method can use different units.

[0107] Those skilled in the art will appreciate that all or part of the steps in the above method can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable storage medium, such as a read-only memory, a disk or an optical disk. Optionally, all or part of the steps in the above embodiment can also be implemented using one or more integrated circuits. Accordingly, each module / unit in the above embodiment can be implemented in the form of hardware or in the form of software function modules. The present application is not limited to any particular form of combination of hardware and software.

[0108] Unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by those of ordinary skill in the art to which this application belongs. It should also be understood that terms such as those defined in common dictionaries should be interpreted as having a meaning consistent with their meaning in the context of the relevant technology, and should not be interpreted in an idealized or extremely formal sense, unless explicitly defined as such herein.

[0109] The above is an explanation of the present application and should not be considered as limiting thereof. Although several exemplary embodiments of the present application have been described, those skilled in the art will readily appreciate that many modifications may be made to the exemplary embodiments without departing from the novel teachings and advantages of the present application.

Claims

1. Precise positioning method of labeling paper based on machine vision, It is characterized in that include: Obtain labeling detection images collected by industrial cameras; Rotating the labeling condition detection image at multiple angles to obtain an image set of multi-angle labeling condition detection images; Performing labeling feature clustering analysis on the image set of the multi-angle labeling detection images to obtain a rotation-desensitized representation vector of the labeling image; Extracting labeling qualified reference images from a database; Determining whether the labeling positioning is qualified based on the feature difference between the labeling feature of the qualified labeling reference image and the rotation desensitized representation vector of the labeled image; The step of performing labeling feature clustering analysis on the image set of the multi-angle labeling detection image to obtain a rotation-desensitized representation vector of the labeling image includes: Respectively extracting labeling features of each multi-angle labeling situation detection image in the image set of the multi-angle labeling situation detection image to obtain a set of multi-angle labeling image feature vectors; Inputting the set of feature vectors of the multi-angle labeled image into a feature distribution inverse mask clustering analysis network to obtain a rotation desensitized representation vector of the labeled image; The method of inputting the set of the multi-angle labeled image feature vectors into a feature distribution inverse mask clustering analysis network to obtain the rotation desensitized representation vector of the labeled image comprises: Clustering the set of multi-angle labeled image feature vectors to obtain a multi-angle labeled image feature clustering center vector; Calculating the semantic correlation coefficient between each multi-angle labeled image feature vector in the set of multi-angle labeled image feature vectors and the multi-angle labeled image feature cluster center vector to obtain a sequence of semantic correlation coefficients; Taking the reciprocal of each semantic correlation coefficient in the sequence of semantic correlation coefficients to obtain a sequence of semantic anti-correlation coefficients; Using a Sigmoid function to normalize the sequence of semantic anti-correlation coefficients to obtain a sequence of semantic anti-correlation weight coefficients; Using each semantic anti-correlation weight coefficient in the sequence of semantic anti-correlation weight coefficients as a weight, weighting each multi-angle labeled image feature vector in the set of multi-angle labeled image feature vectors to obtain a set of suppressed multi-angle labeled image feature vectors; Calculating the positional difference between the set of multi-angle labeled image feature vectors and the set of suppressed multi-angle labeled image feature vectors to obtain a set of optimized multi-angle labeled image feature vectors; The position-based mean vector of the set of the optimized multi-angle labeled image feature vectors is calculated to obtain the rotation-desensitized representation vector of the labeled image.

2. According to the method for accurately positioning labeling paper based on machine vision according to claim 1, It is characterized in that Respectively extracting labeling features of each multi-angle labeling situation detection image in the image set of the multi-angle labeling situation detection image to obtain a set of multi-angle labeling image feature vectors, including: Each multi-angle labeling detection image in the image set of the multi-angle labeling detection image is respectively input into a labeling feature extractor based on the AlexNet model to obtain a set of multi-angle labeling image feature vectors.

3. According to the method for accurately positioning labeling paper based on machine vision according to claim 2, It is characterized in that Clustering the set of multi-angle labeled image feature vectors to obtain a multi-angle labeled image feature clustering center vector includes: The position-based mean vector of the set of the multi-angle labeled image feature vectors is calculated to obtain the multi-angle labeled image feature cluster center vector.

4. According to the method for accurately positioning labeling paper based on machine vision according to claim 3, It is characterized in that Calculating the semantic correlation coefficient between each multi-angle labeled image feature vector in the set of multi-angle labeled image feature vectors and the multi-angle labeled image feature cluster center vector to obtain a sequence of semantic correlation coefficients, including: The cosine similarity between each multi-angle labeled image feature vector in the set of the multi-angle labeled image feature vectors and the multi-angle labeled image feature cluster center vector is calculated as the semantic correlation coefficient to obtain a sequence of the semantic correlation coefficients.

5. According to the method for accurately positioning labeling paper based on machine vision according to claim 4, It is characterized in that Determining whether the labeling positioning is qualified based on the feature difference between the labeling feature of the qualified labeling reference image and the rotation desensitized representation vector of the labeled image includes: Extracting labeling features from the qualified labeling reference image to obtain a qualified labeling reference representation vector; Calculating a differential feature vector between the rotation-desensitized representation vector of the labeled image and the labeled qualified reference representation vector; The differential feature vector is input into a positioning identifier based on a classifier to obtain a recognition result, and the recognition result is used to indicate whether the labeling positioning is qualified.

6. According to the method for accurately positioning labeling paper based on machine vision according to claim 5, It is characterized in that Extracting labeling features from the qualified labeling reference image to obtain a qualified labeling reference representation vector includes: The labeled qualified reference image is input into the labeling feature extractor based on the AlexNet model to obtain the labeled qualified reference representation vector.

7. A label paper precise positioning system based on machine vision, wherein the label paper precise positioning system applies the label paper precise positioning method according to claim 6, It is characterized in that include: A detection image acquisition module is used to obtain a labeling detection image acquired by an industrial camera; An image rotation module, used for performing multi-angle rotation on the labeling condition detection image to obtain an image set of multi-angle labeling condition detection images; A cluster analysis module, used for performing labeling feature cluster analysis on the image set of the multi-angle labeling detection image to obtain a rotation desensitized representation vector of the labeling image; A reference image extraction module is used to extract a labeling qualified reference image from a database; The positioning analysis module is used to determine whether the labeling positioning is qualified based on the feature difference between the labeling feature of the qualified labeling reference image and the rotation desensitized representation vector of the labeled image.

8. According to the machine vision-based labeling paper precise positioning system of claim 7, It is characterized in that The cluster analysis module is used for: Respectively extracting labeling features of each multi-angle labeling situation detection image in the image set of the multi-angle labeling situation detection image to obtain a set of multi-angle labeling image feature vectors; The set of the multi-angle labeled image feature vectors is input into a feature distribution inverse mask clustering analysis network to obtain the rotation desensitized representation vector of the labeled image.

Citation Information

Patent Citations

  • Sticker processing method and device

    CN113496533A

  • Computer vision based automatic labelling positioning method

    CN109018591A

  • Automatic labeling positioning and deviation rectifying method based on computer vision

    CN114425776A