A method and system for intelligent identification and verification of QR code production labeling positions

By collecting product image data in real time, identifying product benchmark features and generating positioning frames, and combining compensation algorithms to correct QR code overlap, the problem of QR code labeling position detection that is difficult to adapt to diverse products in existing technologies is solved, and efficient and accurate automatic labeling position judgment is achieved.

CN120146076BActive Publication Date: 2025-09-19GUANGZHOU SHANGZHUN INSTR EQUIP CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510325075.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-03-19
Publication Date
2025-09-19
Estimated Expiration
2045-03-19

AI Technical Summary

Technical Problem

When faced with diverse products, existing technologies have difficulty adapting to the shapes, surface curvatures, and reflective properties of different products, resulting in limited accuracy in detecting the position of QR code labels.

Method used

By collecting the overall image data of the target product in real time, identifying the product's benchmark features and generating a dynamic positioning frame, extracting the QR code label outline and calculating its geometric center point, establishing a spatial mapping model to calculate the overlapping area ratio, combining scene features and product attribute parameters to perform compensation algorithm calculations, and correcting the initial overlap to determine the labeling position.

Benefits of technology

It achieves dynamic adaptation to the surface characteristics of different products, improves the accuracy of QR code labeling position detection and automated judgment capabilities, reduces manual intervention, and improves production efficiency and quality consistency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120146076B_ABST
    Figure CN120146076B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of labeling position detection, and in particular to an intelligent identification and verification method and system for two-dimensional code production labeling positions, which collects the overall image data of a target product in real time; identifies the product reference features in the overall image data based on the overall image data, and dynamically generates a positioning frame that matches the product; extracts the two-dimensional code label outline based on the overall image data, and calculates its geometric center point; establishes a spatial mapping model of the geometric center point and the positioning frame, and calculates the overlapping area ratio of the two-dimensional code label outline and the positioning frame in the overall image data through the spatial mapping model as an initial coincidence; obtains scene features of the labeling environment and product surface attribute parameters, and calculates the deviation value of the coincidence through a preset compensation algorithm; corrects the initial coincidence based on the deviation value, and determines whether the corrected deviation value is greater than a preset deviation threshold; if the corrected coincidence is greater than the preset deviation threshold, it is determined that the labeling position is correct.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of labeling position detection, and in particular to a method and system for intelligently identifying and verifying the labeling position of a QR code. Background Art

[0002] QR code production labeling position recognition refers to the use of image processing technology to detect and verify whether the QR code is accurately affixed to the product according to the predetermined position during the production process. It is usually used in automated production lines to ensure that the QR code attached to the product meets quality standards and can be successfully scanned and identified in subsequent logistics, sales and other links.

[0003] Existing QR code production labeling position detection technologies primarily rely on image recognition and geometric algorithms to verify the accuracy of QR code labels on products. Typically, these technologies are based on unified detection standards and analyze features such as the QR code's position, shape, and contrast in the image to determine whether the QR code is accurately affixed to the product's designated location. This method relies on high-precision image acquisition equipment and specific algorithmic models to achieve automatic detection and verification of labeling positions. However, existing technologies are often limited when faced with a wide variety of product types. Because different product types vary significantly in shape, surface curvature, and reflective properties, unified detection standards are difficult to adapt to all product types. For example, the physical contours of the QR code on curved products differ significantly from those on flat products, and variations in shooting angle and lighting conditions can also cause deviations in the QR code's appearance in the image. Consequently, unified detection standards cannot fully address the characteristics of different products, easily leading to errors in detection results.

[0004] Therefore, the existing technology has defects and needs to be improved. Summary of the Invention

[0005] In order to solve one or several problems in the prior art, the main purpose of this application is to provide an intelligent identification and verification method and system for the production and labeling position of a QR code.

[0006] In order to achieve the above-mentioned purpose of the invention, the present application proposes an intelligent identification and verification method for the production labeling position of a QR code, the method comprising:

[0007] Collect the overall image data of the target product in real time;

[0008] identifying product reference features in the overall image data based on the overall image data, and dynamically generating a positioning frame that matches the product;

[0009] Extract the outline of the QR code label according to the overall image data and calculate its geometric center point;

[0010] Establishing a spatial mapping model between the geometric center point and the positioning frame, and calculating the overlapping area ratio between the QR code label outline and the positioning frame in the overall image data using the spatial mapping model as an initial overlap ratio;

[0011] Obtain the scene characteristics of the labeling environment and the product surface attribute parameters, and calculate the deviation value of the overlap through the preset compensation algorithm;

[0012] Correcting the initial overlap based on the deviation value, and determining whether the corrected deviation value is greater than a preset deviation threshold;

[0013] If the corrected overlap is greater than the preset deviation threshold, the labeling position is determined to be correct.

[0014] The present application also provides an intelligent identification and verification system for the production and labeling position of a QR code, including:

[0015] Acquisition module, used to collect the overall image data of the target product in real time;

[0016] an identification module for identifying, based on the overall image data, product reference features in the overall image data and dynamically generating a positioning frame that matches the product;

[0017] An extraction module, configured to extract the outline of the QR code label and calculate its geometric center point based on the overall image data;

[0018] An establishment module is used to establish a spatial mapping model between the geometric center point and the positioning frame, and calculate the overlapping area ratio of the QR code label outline and the positioning frame in the overall image data through the spatial mapping model as an initial overlap;

[0019] The acquisition module is used to obtain the scene characteristics of the labeling environment and the surface attribute parameters of the product, and calculate the deviation value of the overlap through a preset compensation algorithm;

[0020] a judgment module, configured to correct the initial overlap based on the deviation value, and determine whether the corrected deviation value is greater than a preset deviation threshold;

[0021] The correction module is used to determine that the labeling position is correct if the corrected overlap degree is greater than a preset deviation threshold.

[0022] The present application also provides a computer device, comprising a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of any of the above methods when executing the computer program.

[0023] The present application also provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of any of the above-mentioned methods are implemented.

[0024] The intelligent identification and verification method and system for the production labeling position of a QR code in the embodiment of the present application can dynamically generate a positioning frame that matches the product by collecting the overall image data in real time and identifying the product reference features, providing reliable reference and positioning information for the accurate labeling of the QR code. By extracting the QR code labeling contour and calculating its geometric center point. When calculating the degree of overlap, the present application not only relies on the geometric information of the QR code itself, but also obtains the scene characteristics of the labeling environment and the product surface attribute parameters, and performs deviation correction in combination with a preset compensation algorithm. It can effectively cope with the effects of environmental changes and irregularities on the product surface, and further improve the accuracy of the system. By comparing the corrected degree of overlap with the preset deviation threshold, it is automatically determined whether the labeling position of the QR code is correct, which reduces manual intervention and improves production efficiency and quality consistency. BRIEF DESCRIPTION OF THE DRAWINGS

[0025] Figure 1 This is a flow chart of a method for intelligently identifying and verifying the labeling position of a QR code according to an embodiment of the present application;

[0026] Figure 2 This is a flow chart of a method for intelligently identifying and verifying the labeling position of a QR code according to an embodiment of the present application;

[0027] Figure 3 This is a schematic block diagram of the structure of an intelligent identification and verification system for QR code production labeling positions according to an embodiment of the present application;

[0028] Figure 4 This is a schematic block diagram of the structure of a computer device according to an embodiment of the present application.

[0029] The realization of the objectives, functional features and advantages of this application will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0030] In order to make the purpose, technical solutions and advantages of this application more clear, the following further describes this application in detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.

[0031] Reference Figure 1 In an embodiment of the present application, a method for intelligently identifying and verifying the position of a QR code production label is provided, the method comprising:

[0032] S1, real-time collection of the overall image data of the target product;

[0033] S2. Identifying product reference features in the overall image data based on the overall image data, and dynamically generating a positioning frame that matches the product;

[0034] S3. Extract the outline of the QR code label based on the overall image data and calculate its geometric center point;

[0035] S4. Establish a spatial mapping model between the geometric center point and the positioning frame, and calculate the overlapping area ratio between the QR code label outline and the positioning frame in the overall image data using the spatial mapping model as an initial overlap ratio;

[0036] S5. Obtain the scene characteristics of the labeling environment and the product surface attribute parameters, and calculate the deviation value of the overlap through a preset compensation algorithm;

[0037] S6. Correcting the initial overlap based on the deviation value, and determining whether the corrected deviation value is greater than a preset deviation threshold;

[0038] S7. If the corrected overlap is greater than the preset deviation threshold, it is determined that the labeling position is correct.

[0039] As described in steps S1-S3 above, the acquisition of overall image data helps the system fully understand the relative position and integrity of the QR code. Real-time image acquisition ensures the system dynamically monitors the QR code labeling position during the production process, identifying problems in real time and ensuring timely and accurate production. Product fiducial features are fixed, easily identifiable characteristic points on the product surface, such as corners, edges, specific patterns, or logos. These fiducial features serve as reference points for determining the position of the QR code. A positioning frame is a frame generated around the product or QR code after identifying these fiducial features. The positioning frame can be rectangular, square, or other shapes, and its purpose is to define the correct positioning area for the QR code. Dynamically generating the positioning frame ensures that the system generates an appropriate reference frame for different products or production environments. This feature ensures that the relative position of the QR code is within a controllable range, reducing the occurrence of errors. The QR code labeling contour refers to the outer boundary of the QR code and can be obtained through image processing techniques such as edge detection and contour extraction. The geometric center point is the center of mass of the QR code, obtained by solving the geometric center of the QR code labeling contour. This point is representative of the QR code's position, rotation angle, and other aspects. Extracting the outline of a QR code label and its geometric center point allows for more accurate positioning of the QR code, particularly when the code is tilted or offset, facilitating subsequent correction and comparison. The geometric center point can be used to determine the relative position of the QR code, reducing recognition errors caused by morphological deformation.

[0040] As described in steps S4-S7 above, the spatial mapping model associates the geometric center point of the QR code with the positioning frame, forming a mathematical model that describes the spatial relationship between the QR code's position and the positioning frame. The overlap area percentage refers to the ratio of the area of ​​the intersection of the QR code label outline and the positioning frame area to the total area of ​​the QR code, serving as a quantitative indicator of the initial overlap. Calculating the overlap area percentage using the spatial mapping model quantifies the degree of alignment between the QR code and the target location, providing data support for subsequent correction and judgment. The initial overlap helps determine whether the QR code has been affixed to the intended location and provides a basis for determining whether further correction is needed. Scene characteristics of the labeling environment refer to environmental factors such as lighting and camera angle, which may affect image acquisition. Product surface attribute parameters may include surface reflectivity, texture, shape, and other factors, which can affect QR code recognition. The compensation algorithm dynamically adjusts the calculated overlap based on changes in environmental and surface properties, resulting in more accurate correction. By using the compensation algorithm to correct for changes in environmental and surface properties, the system's adaptability and accuracy can be improved, avoiding errors caused by environmental or surface factors. The deviation value refers to the corrected value after the compensation algorithm, which reflects the difference between the initial overlap and the actual situation. The preset deviation threshold is an allowable range set by the system according to production requirements, which is used to determine whether the QR code has been affixed correctly. If the deviation value is greater than the threshold, it means that the QR code position error is large and needs to be adjusted. The corrected overlap can improve the system's judgment accuracy and ensure that the QR code labeling position is within a reasonable range. If the deviation value is greater than the preset threshold, the system can detect labeling errors in a timely manner, ensure product quality control, and prevent incorrect products from entering the market. After compensation and correction, if the actual position of the QR code still meets the preset error range, the system determines that the labeling position is correct.

[0041] Reference Figure 2 In one embodiment, the steps of obtaining scene features of the labeling environment and product surface attribute parameters and calculating the deviation value of the overlap using a preset compensation algorithm include:

[0042] S51. Collect scene features of the labeling environment, including the shooting angle of the image acquisition device and the reflectivity parameters of the product surface;

[0043] S52. Analyze the product surface attribute parameters and extract the curvature radius when the product surface has curvature features;

[0044] S53, using a geometric projection compensation algorithm to calculate the deformation offset parameters of the QR code label outline according to the curvature radius and the shooting inclination angle;

[0045] S54 , constructing a deviation value analysis model, inputting the reflectivity parameter and the deformation offset parameter into the deviation value analysis model, and outputting the deviation value through the deviation value analysis model.

[0046] As described in the previous steps, the angle of the image acquisition device has a direct impact on image quality and the shape and position of the QR code. The shooting angle (i.e., tilt) can cause distortion of the QR code in the image, affecting QR code recognition accuracy. Product surface reflectivity refers to the light-reflecting properties of the product surface. Different materials or surfaces can result in differences in reflectivity, which can affect image quality, such as overexposure or low light levels, impacting QR code recognition accuracy. Capturing the shooting angle and reflectivity parameters accounts for the impact of the actual environment on image quality. Shooting angle and reflectivity are important factors affecting QR code recognition accuracy, and collecting this data provides foundational information for subsequent image compensation and correction. By collecting environmental feature data, image acquisition settings can be adjusted in real time to optimize image quality, reduce deviations caused by the external environment, and improve QR code recognition accuracy. Product surface attribute parameters refer to surface characteristics such as geometry, texture, and smoothness, which may affect the position and shape of the QR code label. Curvature characteristics indicate whether the product surface has curves, convexities, or concavities, while the radius of curvature measures the degree of surface curvature. If a product's surface has curvature, it may deform, affecting the geometric structure of the QR code. This surface curvature can cause QR code deformation, especially when applied to uneven surfaces. This deformation can affect recognition and scanning accuracy. By extracting the radius of curvature, this factor can be accounted for in subsequent compensation steps, reducing errors caused by curvature. The core concept of this algorithm is the geometric projection compensation algorithm, which is based on geometric principles. It compensates for the deformation of the QR code on curved surfaces and at different shooting angles. By analyzing the curvature radius and the shooting angle, the possible geometric deformation of the QR code in the image can be estimated and corrected. The deformation offset parameter represents the displacement or deformation of the QR code caused by changes in curvature or tilt during the capture process. The compensation algorithm calculates this offset parameter and applies corresponding corrections. Both the shooting angle and surface curvature can cause deformation of the QR code outline. The geometric projection compensation algorithm uses mathematical models to model and compensate for the effects of these factors, ensuring that the shape and position of the QR code are corrected even on curved or tilted surfaces, avoiding errors during recognition. Deviation Analysis Model: This mathematical or statistical model is used to comprehensively analyze data that influences QR code accuracy (such as reflectivity and deformation offset parameters). The model calculates deviations in the QR code's position or shape by inputting different parameters and performs error analysis based on the model results. Reflectivity and deformation offset inputs: Reflectivity and deformation offset represent the effects of environmental factors and geometric deformation on the QR code, respectively. These two parameters are input into the deviation analysis model, which outputs a deviation value representing the difference between the QR code's ideal position or shape in the image.Environmental factors (such as reflectivity) and geometric factors (such as deformation offset) jointly affect the recognition accuracy of QR codes. Constructing a deviation analysis model can comprehensively consider these factors and quantify their impact on QR code accuracy, thus providing a basis for subsequent correction or calibration.

[0047] In one embodiment, after the step of obtaining scene characteristics of the labeling environment and product surface attribute parameters, and before the step of calculating the deviation value of the overlap using a preset compensation algorithm, the method further includes:

[0048] Based on the overall image data, obtaining the color RGB value of the target product and the color RGB value of the QR code label;

[0049] Calculate the color difference between the target product and the QR code label based on their RGB values.

[0050] Based on the calculation results, when the color difference between the two is lower than the preset visual distinction threshold, it is determined to be a scene with similar colors;

[0051] According to the scene with similar colors, switch to the multispectral image acquisition mode to obtain image data containing infrared or ultraviolet bands;

[0052] Reconstruct the QR code label outline based on multispectral data to replace the outline data in the original visible light image;

[0053] Update the initial overlap based on the overlapping area between the reconstructed QR code label outline and the positioning frame.

[0054] As mentioned above, obtaining the RGB values ​​of image data is a common step in image processing. RGB represents the color intensity of the three channels: red, green, and blue. By extracting information about these three colors from images of the target product and the QR code label, a comprehensive description of the image's color characteristics can be achieved. This is an important foundation for determining the color consistency between the product and the QR code label. Color difference is a measure of the visual difference between two colors. Color difference calculations in the RGB color space, such as the Euclidean distance or the CIEDE2000 algorithm, quantify the difference between two RGB color values. This calculation is typically used to quantify the difference between colors and determine whether they are within a visually distinguishable range. By calculating color difference, the system can quantitatively analyze the color similarity between the target product and the QR code label. This step helps determine whether the target product and the QR code label are within a visually acceptable color range. If the color difference is small, the colors are similar and can proceed to the next processing stage. If the difference is large, further analysis is required. The preset visual distinction threshold is set based on the human eye's color perception. If the color difference between the target product and the QR code label falls below this threshold, the two colors are similar, making it difficult for humans to distinguish them visually. This judgment allows the system to intelligently distinguish between scenes with similar colors and scenes with significant color differences. If the colors are similar, further complex processing can be skipped, and the system can proceed to the next step of data acquisition and processing based on multispectral images. This helps improve system processing efficiency and avoids unnecessary activation of complex image acquisition modes in scenarios. When the target product and the QR code label have similar colors, standard visible light images may not be clear or accurate enough, especially against complex backgrounds, making it difficult to identify the QR code. Multispectral image acquisition mode captures wavelengths beyond visible light, such as infrared or ultraviolet. These wavelengths are more sensitive to surface details and physical contours, providing more image information even with minimal color difference. By switching to multispectral image acquisition mode, the system can obtain more information. In particular, when standard visible light cannot effectively distinguish the QR code from the background, infrared and ultraviolet images can provide a clearer outline of the QR code label. This helps improve QR code recognition accuracy, especially in cases of similar colors, by avoiding the influence of image noise. In multispectral images, infrared or ultraviolet bands are more sensitive to the details, materials, and reflective properties of the object surface, which allows the physical outline of the QR code to be presented more accurately. By processing the multispectral image data, the system can extract the physical outline of the QR code. Replacing the outline data in the original visible light image can improve the accuracy of QR code recognition. In ordinary visible light images, similar colors or complex backgrounds may blur the boundaries of the QR code. By reconstructing the physical outline, the outline data of the QR code can be ensured to be more accurate, thereby improving the accuracy of subsequent processing (such as positioning, recognition, and coincidence calculation).Overlap is a metric used to assess the degree of match between a QR code and a positioning frame (or target area). By calculating the overlap between the physical outline of the QR code and the preset positioning frame, it is possible to accurately measure whether the QR code has been correctly placed within the target area.

[0055] In one embodiment, after the step of calculating the overlap area ratio between the outline of the QR code label and the positioning frame in the overall image data using the spatial mapping model as the initial overlap ratio, the method further includes:

[0056] Calculating the closure degree of the outline of the QR code label;

[0057] Based on the calculation results, the closure degree of the QR code label outline is analyzed;

[0058] If the degree of closure of the outline of the QR code label is lower than a preset integrity threshold, it is determined that the overall image data of the QR code label is blocked or contaminated;

[0059] Extract the key points of the unobstructed area and reconstruct the outline of the incomplete QR code label using a curve fitting algorithm;

[0060] Update the initial overlap based on the reconstructed QR code label outline;

[0061] If the improvement rate of the updated initial overlap compared to the original value is less than the preset repair threshold, a manual re-inspection signal is triggered;

[0062] Otherwise, continue to execute the steps of obtaining scene features and calculating deviation values.

[0063] As mentioned above, closure refers to the integrity of the QR code label's outline, specifically whether the outline forms a closed shape. Closure is calculated based on whether the outline's endpoints are close together or whether there are missing or open areas. Common calculation methods include curve detection and endpoint distance. A low degree of closure typically indicates damage, occlusion, or contamination. By calculating closure, the QR code label's outline can be assessed to determine whether it is complete or incomplete (such as occlusion or contamination). If the closure of the QR code label's outline is low, the system can detect potential issues, providing a basis for subsequent repairs and inspections. Closure analysis of the QR code label's outline is performed to determine the integrity of the QR code. If the closure falls below a set threshold, it indicates that the QR code is occluded or contaminated, which may result in QR code recognition failure. Analyzing the specific closure value provides further insight into the integrity of the QR code label's outline and helps determine whether remedial measures are necessary. A preset integrity threshold is set to quantify the degree of outline integrity. If the closure of the QR code falls below this threshold, it indicates that the QR code label's outline is defective, possibly due to occlusion or contamination. This judgment can help the system identify quality problems of the QR code from the appearance. When the QR code label outline is obscured or damaged, the system extracts the key points of the outline of the unobstructed part and uses a curve fitting algorithm (such as Bezier curves, spline curves, etc.) to reconstruct the missing part. This method uses known image data to infer the contour shape of the obscured area, thereby restoring the complete outline of the QR code. Reconstructing the QR code in the obscured area through a curve fitting algorithm can improve the recognition rate of the QR code, especially when part of the image is obscured or damaged, to avoid the entire QR code being unrecognizable due to damage. This step improves the system's fault tolerance and ensures the stability of image recognition. After the QR code label outline is reconstructed, the system recalculates the overlapping area between the QR code label outline and the positioning frame and updates the overlap. Through this operation, the system can evaluate whether the reconstructed QR code better matches the target position. This step usually includes updating the overlapping area calculation based on image features. A repair threshold is set to determine whether the repair effect is significant. If the degree of overlap between the reconstructed QR code and the original positioning frame is not significantly improved, it means that the repair effect is not ideal. The system will trigger a manual re-inspection signal, requiring manual intervention to further check the quality and positioning of the QR code. By setting the repair threshold, the system can automatically evaluate the effectiveness of the repair process and trigger manual re-inspection if the repair is insufficient. This ensures that when the automated process cannot perfectly repair the QR code, product quality and the usability of the QR code can still be ensured through manual intervention. If the degree of overlap between the reconstructed QR code label outline and the positioning frame is significantly improved, it means that the QR code repair is successful, and the system will continue to perform subsequent image processing and recognition steps, such as obtaining scene features and calculating deviation values.These steps help to further analyze the environmental factors and deviations of the QR code and ensure the accuracy during the QR code recognition process.

[0064] In one embodiment, before the step of inputting the reflectivity parameter and the deformation offset parameter into the deviation value analysis model, the method further includes:

[0065] Real-time collection of ambient light intensity;

[0066] When the light intensity is greater than or equal to a preset light intensity threshold, activating the polarization filter;

[0067] According to the light intensity and the state of the polarization filter, the calibrated reflectivity parameters are calculated and input into the deviation value analysis model.

[0068] As mentioned above, ambient light intensity refers to the intensity of light incident on a target object. In practical applications, light intensity has a significant impact on the reflective properties of an object's surface, particularly in optical measurement and image recognition. Changes in light intensity can cause fluctuations in reflectivity parameters, impacting the accuracy of subsequent analysis. Therefore, real-time acquisition of light intensity data facilitates dynamic adjustment of input parameters in deviation analysis models. Polarizing filters control the polarization state of light reflected from an object's surface, effectively filtering out stray light and unwanted reflections caused by varying illumination angles or irregularities in the reflective surface. Enabling a polarizing filter can eliminate these interferences, particularly in strong light environments, effectively improving the accuracy of reflectivity measurements. When light intensity reaches a certain threshold, the scattering of reflected light can increase, affecting measurement accuracy. Therefore, enabling a polarizing filter improves measurement accuracy. Calibrated reflectivity parameters are the reflectivity data obtained after adjusting for light intensity and the polarizing filter. Because the properties of reflected light vary under different light intensities, the reflectivity parameters need to be adjusted based on the light intensity and filter state. By dynamically calculating the calibrated reflectivity, errors caused by environmental fluctuations can be eliminated, ensuring data accuracy. Specifically, when light intensity is high, a polarizing filter can effectively reduce interference from strong light, helping the system obtain more accurate reflectivity values. The calibrated reflectivity parameters are fed into the deviation analysis model as input data for further analysis of the target object's deviation. By incorporating calibrated reflectivity data, the model can calculate deviation values ​​based on the actual object's reflective properties, thereby determining the magnitude of the deviation. The deviation analysis model's role here is to help the system assess deformation, damage, or irregularities of the target object based on changes in the reflectivity parameters. By inputting calibrated reflectivity parameters, the deviation analysis model can provide more accurate deviation detection results, especially under varying lighting conditions. Calibrated reflectivity data effectively improves the accuracy of deviation calculations, ensuring the reliability of the final results. This reduces deviation detection errors caused by varying lighting conditions, improving the robustness and accuracy of the system.

[0069] In one embodiment, before the step of inputting the reflectivity parameter and the deformation offset parameter into the deviation value analysis model, the method further includes:

[0070] Obtaining a curvature change rate of the product surface;

[0071] If the curvature change rate of the product surface is greater than a preset curvature change rate threshold, the product surface is divided into multiple grid areas;

[0072] The local deformation offset parameters are calculated independently for each mesh region, and the offset parameters of each mesh region are input into the deviation value analysis model.

[0073] As mentioned above, curvature refers to the degree of curvature of a surface or curve and can typically be calculated using the derivative of the curve. For product surfaces, the curvature rate of change can reflect the curvature variation of the QR code surface or curve. This parameter is crucial for determining surface deformation, as surface deformation can affect QR code reading accuracy and reflectivity measurements. Obtaining the curvature rate of change can help determine whether the product surface has undergone irregular curvature or deformation. By obtaining the curvature rate of change of the product surface, the degree of surface deformation can be accurately detected. A significant curvature variation indicates significant deformation of the QR code surface, which may affect QR code scanning or reflectivity measurement. As a preprocessing step, the curvature rate of change provides a basis for subsequent meshing and calculation of local offset parameters, ensuring accurate calculation of the deformation offset parameters. If the curvature rate of change exceeds a preset threshold, it indicates significant surface deformation or non-uniform curvature, which cannot be addressed using a simple global model. Therefore, dividing the product surface into multiple mesh regions allows for localized processing, allowing each mesh region to be processed independently, thereby better capturing local deformation. Meshing can reduce the impact of large-scale deformation on the entire product surface, ensuring that offset parameters within localized areas more accurately reflect the true deformation of the QR code. After meshing, the deformation of each small area can be calculated and analyzed independently, avoiding errors introduced by global calculations. This approach enables more detailed and precise calculation of deformation offset parameters, helping to improve the accuracy of reflectivity measurement and deviation detection under complex deformation conditions. Different processing strategies can be employed for areas with varying degrees of deformation, enhancing the flexibility and reliability of deviation analysis. The deformation offset parameter for each mesh area represents the degree of deformation experienced by the QR code surface within that area. Independently calculating local deformation offset parameters helps accurately capture deformation in different areas. For curved or irregular QR code surfaces, only some areas may experience significant deformation, while others may experience relatively small deformation. Independently calculating local deformation offset parameters allows these differences to be accounted for, ensuring that deformation in each local area is accurately reflected. Independently calculating deformation offset parameters for each mesh area allows for more accurate analysis of the product surface, avoiding measurement errors caused by global assumptions or oversimplification. This localized processing not only improves the accuracy of the deformation parameters, but also provides more detailed feedback, which is more helpful for subsequent deviation value analysis. Different deformation areas can be treated differently, optimizing the accuracy of reflectivity calculation and deviation value evaluation. The offset parameters of each grid area are calculated based on the deformation of that area. When these offset parameters are input into the deviation value analysis model, they can help the model evaluate the deviation of the entire product surface. The deviation value analysis model comprehensively considers the local and overall deformation based on the offset of each local area to derive the deviation value of the entire product surface.By inputting local offset parameters into the deviation analysis model, the system's accuracy and robustness in complex deformation environments can be improved. Local offset parameters help accurately reflect the deformation of each region, and the model synthesizes these inputs to derive overall deviation detection results, providing accurate data support for calculating the QR code's reflectivity parameters. This step effectively improves the accuracy of the deviation analysis, ensuring that the final reflectivity parameters and deformation detection results remain reliable in dynamic environments.

[0074] In one embodiment, before the step of inputting the reflectivity parameter and the deformation offset parameter into the deviation value analysis model, the method further includes:

[0075] Obtaining the curvature radius of the product surface;

[0076] When the curvature radius of the product surface is detected to be less than or equal to the preset minimum curvature radius threshold, the high curvature compensation mode is activated;

[0077] Reconstruct the three-dimensional contour of the product surface through multi-view image fusion algorithm;

[0078] The deformation offset parameters are corrected based on the reconstructed three-dimensional contour, and the corrected deformation offset parameters are input into the deviation value analysis model.

[0079] As mentioned above, the radius of curvature is the inverse of the curvature of a surface or curve at a specific point and is used to describe the degree of curvature of the surface or curve. The smaller the radius of curvature, the greater the curvature of the surface or curve. By obtaining the radius of curvature of the product surface, it is possible to directly determine whether the product surface is in an area of ​​high curvature, that is, whether it has significant bending deformation. The reason for obtaining the radius of curvature is that the degree of deformation of the product surface is closely related to the surface curvature. If the product surface curvature is too large, the QR code may be deformed more severely, so special compensation is required in these areas. Obtaining the radius of curvature of the product surface can help the system determine whether the surface is in an area of ​​less curvature. If the radius of curvature is less than a preset threshold, the area can be identified as highly curved. This allows preemptive compensation to prevent QR code deformation in these areas from affecting subsequent scanning and reflectivity measurements. When the radius of curvature of the product surface is less than or equal to a preset minimum curvature radius threshold, the product surface is highly curved, and the QR code may be significantly deformed, making it difficult to scan or read accurately. To compensate for this deformation, the system needs to activate "High Curvature Compensation Mode." By activating this mode, the system uses special algorithms or compensation techniques to correct for surface deformation, ensuring that the QR code remains highly readable even in curved areas. This compensation mode effectively addresses deformation issues in areas of high curvature. By activating high curvature compensation mode, the system automatically identifies and corrects for surface deformation, ensuring accurate reflectivity and deformation analysis of the QR code even on curved surfaces, thereby improving QR code readability and scanning accuracy. The multi-view image fusion algorithm uses images captured from different angles to reconstruct the 3D shape of the product surface. This method typically combines image data from multiple viewpoints to address information loss and errors associated with a single viewpoint, resulting in a more accurate 3D contour reconstruction. Because the surface on which the QR code appears may be curved, traditional 2D images lack sufficient information. Using multiple viewpoints and fusing this information can more accurately capture the deformation of the QR code surface in 3D space, thereby improving correction accuracy. The multi-view image fusion algorithm enables more accurate 3D reconstruction of the QR code's area, particularly in highly curved areas. This allows the deformation of the QR code to be comprehensively evaluated in three-dimensional space, thereby providing more reliable data support for subsequent deformation correction and reflectivity measurement. After obtaining the three-dimensional profile of the product surface, the deformation of the QR code can be corrected based on the profile. The three-dimensional profile provides more realistic shape data of the QR code surface, which can be used to calculate the specific parameters of the deformation (such as offset, angle, curvature, etc.) and correct the offset parameters. The reason for correcting the deformation offset parameters is that the offset parameters of the product surface may be affected by irregular deformation in high curvature areas. By correcting the three-dimensional profile, the accuracy of the deformation parameters can be improved, making the subsequent deviation value analysis more accurate.Corrected deformation offset parameters are derived through 3D reconstruction and compensation algorithms. These parameters more accurately reflect the actual deformation of the product surface. Inputting these corrected parameters into the deviation value analysis model helps accurately assess the relationship between product surface deformation and reflectivity. Because the original deformation parameters may contain errors, especially in complex areas with high curvature, the corrected deformation offset parameters enable more precise deviation value analysis, thereby improving the accuracy of QR code reflectivity and scanning precision.

[0080] Reference Figure 3 , the embodiment of the present application also provides an intelligent recognition and verification system for the production and labeling position of a QR code, comprising:

[0081] Acquisition module 1, used to collect the overall image data of the target product in real time;

[0082] Identification module 2, for identifying product reference features in the overall image data based on the overall image data, and dynamically generating a positioning frame that matches the product;

[0083] Extraction module 3, used to extract the outline of the QR code label according to the overall image data and calculate its geometric center point;

[0084] Establishing module 4, for establishing a spatial mapping model between the geometric center point and the positioning frame, and calculating the overlapping area ratio between the QR code label outline and the positioning frame in the overall image data through the spatial mapping model as the initial overlap;

[0085] Acquisition module 5, used to obtain scene characteristics of the labeling environment and product surface attribute parameters, and calculate the deviation value of the overlap through a preset compensation algorithm;

[0086] A judgment module 6 is used to correct the initial overlap based on the deviation value and determine whether the corrected deviation value is greater than a preset deviation threshold;

[0087] The correction module 7 is used to determine that the labeling position is correct if the corrected overlap degree is greater than a preset deviation threshold.

[0088] As described above, it can be understood that the various components of the intelligent identification and verification system for the production and labeling position of the QR code proposed in this application can realize the functions of any of the intelligent identification and verification methods for the production and labeling position of the QR code as described above, and the specific structure will not be repeated.

[0089] Reference Figure 4 In the embodiment of the present application, a computer device is also provided. The computer device may be a server, and its internal structure may be as follows: Figure 4As shown. The computer device includes a processor, a memory, a network interface and a database connected via a system bus. The processor of the computer design is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The memory provides an environment for the operation of the operating system and computer program in the non-volatile storage medium. The database of the computer device is used to store data such as monitoring data. The network interface of the computer device is used to communicate with an external terminal via a network connection. When the computer program is executed by the processor, it implements a method for intelligent identification and verification of the labeling position of a two-dimensional code production.

[0090] The above-mentioned processor executes the above-mentioned intelligent identification and verification method for the production labeling position of the QR code, including: real-time acquisition of the overall image data of the target product; based on the overall image data, identifying the product reference features in the overall image data, and dynamically generating a positioning frame that matches the product; based on the overall image data, extracting the QR code label outline and calculating its geometric center point; establishing a spatial mapping model of the geometric center point and the positioning frame, and calculating the overlapping area ratio of the QR code label outline and the positioning frame in the overall image data through the spatial mapping model as the initial coincidence; obtaining the scene characteristics of the labeling environment and the product surface attribute parameters, and calculating the deviation value of the coincidence through a preset compensation algorithm; correcting the initial coincidence based on the deviation value, and judging whether the corrected deviation value is greater than the preset deviation threshold; if the corrected coincidence is greater than the preset deviation threshold, it is determined that the labeling position is correct.

[0091] An embodiment of the present application also provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, an intelligent identification and verification method for the production labeling position of a QR code is implemented, comprising the following steps: real-time acquisition of overall image data of a target product; identification of product reference features in the overall image data based on the overall image data, and dynamic generation of a positioning frame matching the product; extraction of the QR code labeling contour and calculation of its geometric center point based on the overall image data; establishment of a spatial mapping model of the geometric center point and the positioning frame, and calculation of the overlapping area ratio between the QR code labeling contour and the positioning frame in the overall image data as an initial coincidence through the spatial mapping model; acquisition of scene features of the labeling environment and product surface attribute parameters, and calculation of a deviation value of the coincidence through a preset compensation algorithm; correction of the initial coincidence based on the deviation value, and determination of whether the corrected deviation value is greater than a preset deviation threshold; if the corrected coincidence is greater than the preset deviation threshold, determination that the labeling position is correct.

[0092] Those skilled in the art will understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media provided in this application and used in the embodiments may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (SSRSDRAM), enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct RAM bus dynamic RAM (DRDRAM), and RAM bus dynamic RAM (RDRAM), etc.

[0093] It should be noted that, in this document, the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, apparatus, article, or method comprising a series of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, apparatus, article, or method. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, apparatus, article, or method comprising the element.

[0094] The above description is only a preferred embodiment of the present application and does not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the present application specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present application.

Claims

1. An intelligent identification and verification method for the production and labeling position of a QR code, characterized in that: The method comprises: Collect the overall image data of the target product in real time; identifying product reference features in the overall image data based on the overall image data, and dynamically generating a positioning frame that matches the product; Extract the outline of the QR code label according to the overall image data and calculate its geometric center point; Establishing a spatial mapping model between the geometric center point and the positioning frame, and calculating the overlapping area ratio between the QR code label outline and the positioning frame in the overall image data using the spatial mapping model as an initial overlap ratio; Obtain the scene characteristics of the labeling environment and the product surface attribute parameters, and calculate the deviation value of the overlap through the preset compensation algorithm; Correcting the initial overlap based on the deviation value, and determining whether the corrected deviation value is greater than a preset deviation threshold; If the corrected overlap is greater than the preset deviation threshold, the labeling position is determined to be correct; The steps of obtaining scene features of the labeling environment and product surface attribute parameters and calculating the deviation value of the overlap using a preset compensation algorithm include: Collect scene characteristics of the labeling environment, including the shooting angle of the image acquisition device and the reflectivity parameters of the product surface; Analyze product surface attribute parameters and extract the curvature radius when the product surface has curvature features; Using geometric projection compensation algorithm, the deformation offset parameters of the QR code label outline are calculated according to the curvature radius and shooting inclination angle; Constructing a deviation value analysis model, inputting the reflectivity parameter and the deformation offset parameter into the deviation value analysis model, and outputting a deviation value through the deviation value analysis model; After the step of obtaining the scene characteristics of the labeling environment and the product surface attribute parameters, and before the step of calculating the deviation value of the overlap using a preset compensation algorithm, the method further includes: Based on the overall image data, obtaining the color RGB value of the target product and the color RGB value of the QR code label; Calculate the color difference between the target product and the QR code label based on their RGB values. Based on the calculation results, when the color difference between the two is lower than the preset visual distinction threshold, it is determined to be a scene with similar colors; According to the scene with similar colors, switch to the multispectral image acquisition mode to obtain image data containing infrared or ultraviolet bands; Reconstruct the QR code label outline based on multispectral data to replace the outline data in the original visible light image; Update the initial overlap based on the overlapping area between the reconstructed QR code label outline and the positioning frame; Before the step of inputting the reflectivity parameter and the deformation offset parameter into the deviation value analysis model, the method further includes: Obtaining the curvature radius of the product surface; When the curvature radius of the product surface is detected to be less than or equal to the preset minimum curvature radius threshold, the high curvature compensation mode is activated; Reconstruct the three-dimensional contour of the product surface through multi-view image fusion algorithm; The deformation offset parameters are corrected based on the reconstructed three-dimensional contour, and the corrected deformation offset parameters are input into the deviation value analysis model.

2. The intelligent identification and verification method for the production and labeling position of a two-dimensional code according to claim 1, characterized in that: After the step of calculating the overlap area ratio of the QR code label outline and the positioning frame in the overall image data using the spatial mapping model as the initial overlap ratio, the method further includes: Calculating the closure degree of the outline of the QR code label; Based on the calculation results, the closure degree of the QR code label outline is analyzed; If the degree of closure of the outline of the QR code label is lower than a preset integrity threshold, it is determined that the overall image data of the QR code label is blocked or contaminated; Extract the key points of the unobstructed area and reconstruct the outline of the incomplete QR code label using a curve fitting algorithm; Update the initial overlap based on the reconstructed QR code label outline; If the improvement rate of the updated initial overlap compared to the original value is less than the preset repair threshold, a manual re-inspection signal is triggered; Otherwise, continue to execute the steps of obtaining the scene features of the labeling environment and calculating the deviation value.

3. The intelligent identification and verification method for the production and labeling position of a two-dimensional code according to claim 1, characterized in that: Before the step of inputting the reflectivity parameter and the deformation offset parameter into the deviation value analysis model, the method further includes: Real-time collection of ambient light intensity; When the light intensity is greater than or equal to a preset light intensity threshold, activating the polarization filter; According to the light intensity and the state of the polarization filter, the calibrated reflectivity parameters are calculated and input into the deviation value analysis model.

4. The intelligent identification and verification method for the production and labeling position of a two-dimensional code according to claim 1, characterized in that: Before the step of inputting the reflectivity parameter and the deformation offset parameter into the deviation value analysis model, the method further includes: Obtaining a curvature change rate of the product surface; If the curvature change rate of the product surface is greater than a preset curvature change rate threshold, the product surface is divided into multiple grid areas; The local deformation offset parameters are calculated independently for each mesh region, and the offset parameters of each mesh region are input into the deviation value analysis model.

5. An intelligent identification and verification system for the production and labeling position of a QR code, used in the method according to any one of claims 1 to 4, characterized in that: include: Acquisition module, used to collect the overall image data of the target product in real time; an identification module for identifying, based on the overall image data, product reference features in the overall image data and dynamically generating a positioning frame that matches the product; An extraction module, configured to extract the outline of the QR code label and calculate its geometric center point based on the overall image data; An establishment module is used to establish a spatial mapping model between the geometric center point and the positioning frame, and calculate the overlapping area ratio of the QR code label outline and the positioning frame in the overall image data through the spatial mapping model as an initial overlap; The acquisition module is used to obtain the scene characteristics of the labeling environment and the surface attribute parameters of the product, and calculate the deviation value of the overlap through a preset compensation algorithm; a judgment module, configured to correct the initial overlap based on the deviation value, and determine whether the corrected deviation value is greater than a preset deviation threshold; The correction module is used to determine that the labeling position is correct if the corrected overlap degree is greater than a preset deviation threshold.

6. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 4 are implemented.

7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 4 are implemented.

Citation Information

Patent Citations

  • High-speed article visual detection method based on artificial intelligence

    CN118134923A

  • Method for recognizing damaged quick-response code

    WO2025039767A1