A corrugated box production quality detection method and system based on intelligent analysis
By acquiring corrugated carton image data through intelligent analysis methods and utilizing LBP feature description and linear regression fitting, the problems of low efficiency and poor accuracy of traditional detection methods are solved. This enables precise detection of corrugated carton quality and optimization of equipment parameters, thereby improving production efficiency and product quality.
Patent Information
- Application Number
- CN202510724340.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-03
- Publication Date
- 2026-01-27
- Estimated Expiration
- 2045-06-03
AI Technical Summary
Traditional corrugated box production quality inspection relies on manual visual inspection and simple physical measurement, which is inefficient and easily affected by human factors, making it difficult to guarantee the accuracy and consistency of the test results. In particular, it lacks precise testing methods in the analysis of key indicators such as texture features, material consistency and thickness distribution.
By employing an intelligent analysis-based approach, high-definition camera image data of cardboard boxes is acquired. Texture features are extracted using LBP feature description and converted into feature vectors. Material consistency index and thickness uniformity index are calculated, and a thickness distribution map is generated by combining linear regression fitting. This enables accurate assessment of cardboard box quality and optimization of equipment parameters.
It enables precise detection and processing optimization of corrugated cardboard box production quality, improves detection efficiency and accuracy of results, reduces manpower and material consumption, and enhances the level of automated production.
Smart Images

Figure CN120495277B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of corrugated box production analysis, and more specifically, to a method and system for quality inspection of corrugated box production based on intelligent analysis. Background Technology
[0002] As a crucial component of the packaging industry, corrugated cardboard boxes directly impact product protection, transportation safety, and consumer experience. Traditional quality inspection in corrugated cardboard box production relies primarily on manual visual inspection and simple physical measurements. This method is not only inefficient but also susceptible to human error, making it difficult to guarantee the accuracy and consistency of results. Furthermore, there is a lack of corresponding technical means for precise detection of key quality indicators such as texture characteristics, material consistency, material uniformity, and thickness distribution. However, with the development of intelligent quality inspection based on image analysis, utilizing advanced information and intelligent technologies to achieve intelligent inspection of corrugated cardboard box production quality has become an inevitable trend in the industry. Therefore, there is an urgent need for a quality inspection method for corrugated cardboard box production based on intelligent analysis. Summary of the Invention
[0003] This invention overcomes the shortcomings of existing technologies and proposes a method and system for quality inspection of corrugated cardboard box production based on intelligent analysis.
[0004] The first aspect of this invention provides a method for quality inspection in corrugated cardboard box production based on intelligent analysis, comprising:
[0005] Obtain the front and side image data of the target cardboard box;
[0006] Based on the LBP feature description form, regional texture features are extracted and feature vectors are transformed from frontal and side image data to obtain multiple LBP feature vectors. Data variance is calculated based on multiple LBP feature vectors, and material consistency index is generated based on the variance value.
[0007] Obtain the cardboard box image area and divide the cardboard box image area into N image areas. The center point of each image area is used as a preset point. Obtain the thickness value of the preset point and map the thickness value to a preset grayscale range to obtain N grayscale values. The N grayscale values are the grayscale values of the center pixels of the N image areas.
[0008] Linear regression fitting is performed based on N gray values to generate a linear equation. The transition gray value between every two gray values is obtained through the linear equation. The transition gray value is filled into N image regions to obtain a thickness distribution map based on gray value representation.
[0009] Calculate the mean gray value of all pixels in each image region to obtain N mean gray values. Compare the N mean gray values with the standard value to evaluate the thickness uniformity and generate a thickness uniformity index.
[0010] Quality assessment was conducted using material consistency index and thickness uniformity index, and parameters of production equipment were optimized.
[0011] In this solution, obtaining the front and side image data of the target cardboard box specifically involves:
[0012] High-definition camera equipment is used to acquire front and side image data of the target carton after it has been flattened during the corrugated carton production process.
[0013] Image enhancement, noise reduction, and standardization preprocessing are performed on the frontal and side image data.
[0014] In this scheme, based on the LBP feature description format, regional texture feature extraction and feature vector transformation are performed on the frontal and side image data to obtain multiple LBP feature vectors. The data variance is calculated based on these multiple LBP feature vectors, and a material consistency index is generated based on the variance value. Specifically:
[0015] The frontal and side image data are converted to grayscale to generate a first grayscale image and a second grayscale image.
[0016] In the first grayscale image, a 3×3 matrix neighborhood is set for each pixel. Taking the selected pixel as the center point, it is determined whether the grayscale value of the pixel in the matrix neighborhood is greater than or equal to the grayscale value of the center point. If it is, it is marked as 1; otherwise, it is marked as 0.
[0017] After the matrix neighborhood is determined, the gray values of the pixels in the neighborhood are sequentially obtained to obtain the binarized values. The binarized values are then converted into decimal numbers to obtain the LBP code of the matrix neighborhood.
[0018] Calculate the LBP code for each pixel and statistically form an LBP histogram. Use the LBP histogram as a texture feature and generate multiple LBP feature vectors from the LBP histogram.
[0019] Variance is calculated for multiple LBP feature vectors. The difference between feature vectors is calculated using the Manhattan distance value, and the first variance is obtained.
[0020] Calculate the second variance based on the second grayscale image;
[0021] Material consistency is assessed based on the mean of the first variance and the second variance, resulting in a material consistency index.
[0022] In this solution, the process of acquiring a cardboard box image area and dividing it into N image areas, with the center point of each image area serving as a preset point, and obtaining the thickness value of the preset point, maps the thickness value onto a preset grayscale range to obtain N grayscale values. These N grayscale values are the grayscale values of the center pixels of the N image areas. Specifically:
[0023] For the front image data, obtain the cardboard image area of the target cardboard box. Divide the cardboard image area into N image areas from left to right and set N preset points, with the interval between adjacent preset points being consistent. Each preset point corresponds to the center point of an image area.
[0024] Measure and obtain the thickness values of N preset points, establish the mapping relationship between the thickness value range and the gray value range, and map the thickness values to the preset gray value range to obtain N gray values.
[0025] In this scheme, the linear regression fitting based on N gray values generates a linear equation. The transition gray value between every two gray values is obtained through the linear equation, and the transition gray value is filled into N image regions to obtain a thickness distribution map based on gray value representation. Specifically:
[0026] By pre-setting a linear equation, using N grayscale values as dependent variables and the pixel positions corresponding to the grayscale values as independent variables, a linear regression fit is performed, and a linear equation is generated.
[0027] The transition gray values between each gray value are calculated using linear equations, and then filled into N image regions based on these transition gray values.
[0028] In the cardboard box image area, the transition grayscale value is calculated based on a linear equation, and the grayscale value of the pixels in the entire cardboard box image area is filled with grayscale values so that the pixel grayscale values in the cardboard box image area from left to right conform to the numerical change of the linear equation, thus obtaining a thickness distribution map based on grayscale representation.
[0029] In this scheme, the grayscale mean of all pixels in each image region is calculated to obtain N grayscale mean values. These N grayscale mean values are then compared with a standard value to evaluate thickness uniformity and generate a thickness uniformity index. Specifically:
[0030] Calculate the mean gray value of all pixels in each image region to obtain N mean gray values;
[0031] The difference between the mean of N gray levels and the standard value is calculated, and the average difference is generated. The thickness uniformity index is then generated based on the average difference.
[0032] In this solution, the quality assessment using material consistency index and thickness uniformity index, and the parameter optimization of production equipment, specifically involve:
[0033] Obtain the processing data corresponding to the material association step and the thickness processing step;
[0034] The processing quality of the material correlation step and the thickness processing step is detected and evaluated based on the material consistency index and the thickness uniformity index, respectively. The parameters of the processing equipment are optimized based on the processing data, and the equipment production is dynamically adjusted.
[0035] A second aspect of the present invention also provides a corrugated cardboard box production quality inspection system based on intelligent analysis. The system includes a memory and a processor. The memory includes a corrugated cardboard box production quality inspection program based on intelligent analysis. When executed by the processor, the corrugated cardboard box production quality inspection program based on intelligent analysis performs the following steps:
[0036] Obtain the front and side image data of the target cardboard box;
[0037] Based on the LBP feature description form, regional texture features are extracted and feature vectors are transformed from frontal and side image data to obtain multiple LBP feature vectors. Data variance is calculated based on multiple LBP feature vectors, and material consistency index is generated based on the variance value.
[0038] Obtain the cardboard box image area and divide the cardboard box image area into N image areas. The center point of each image area is used as a preset point. Obtain the thickness value of the preset point and map the thickness value to a preset grayscale range to obtain N grayscale values. The N grayscale values are the grayscale values of the center pixels of the N image areas.
[0039] Linear regression fitting is performed based on N gray values to generate a linear equation. The transition gray value between every two gray values is obtained through the linear equation. The transition gray value is filled into N image regions to obtain a thickness distribution map based on gray value representation.
[0040] Calculate the mean gray value of all pixels in each image region to obtain N mean gray values. Compare the N mean gray values with the standard value to evaluate the thickness uniformity and generate a thickness uniformity index.
[0041] Quality assessment was conducted using material consistency index and thickness uniformity index, and parameters of production equipment were optimized.
[0042] A third aspect of the present invention also provides a computer-readable storage medium comprising a corrugated carton production quality inspection program based on intelligent analysis, wherein when the corrugated carton production quality inspection program based on intelligent analysis is executed by a processor, it implements the steps of the corrugated carton production quality inspection method based on intelligent analysis as described in any of the preceding claims.
[0043] This invention discloses a method and system for quality inspection in corrugated cardboard box production based on intelligent analysis. First, image data of the front and side of the cardboard box are acquired. Texture features are extracted using LBP feature description and converted into feature vectors. The variance of the vector data is calculated to determine material consistency. Simultaneously, preset points are set in the cardboard box image area, and the thickness values at these preset points are acquired and mapped to grayscale values. A linear equation is generated by fitting the grayscale values using linear regression. Based on the fitted equation, transition grayscale values are obtained and filled into the image area to obtain a thickness distribution map based on grayscale representation. The mean grayscale value of each image area is calculated and compared with a standard value to evaluate thickness uniformity, generating a thickness uniformity index. Finally, a comprehensive quality assessment is performed by combining material consistency and thickness uniformity, and the parameters of the corrugated cardboard box production equipment are optimized to achieve precise inspection and optimized control of cardboard box quality. Attached Figure Description
[0044] Figure 1 A flowchart of a method for quality inspection in corrugated cardboard box production based on intelligent analysis according to the present invention is shown;
[0045] Figure 2 A block diagram of a corrugated cardboard box production quality inspection system based on intelligent analysis according to the present invention is shown. Detailed Implementation
[0046] To better understand the above-mentioned objectives, features, and advantages of the present invention, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that, unless otherwise specified, the embodiments and features described in these embodiments can be combined with each other.
[0047] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and therefore the scope of protection of the invention is not limited to the specific embodiments disclosed below.
[0048] Figure 1 The flowchart of a method for quality inspection in corrugated cardboard box production based on intelligent analysis according to the present invention is shown.
[0049] like Figure 1 As shown, the first aspect of the present invention provides a method for quality inspection of corrugated cardboard box production based on intelligent analysis, comprising:
[0050] S102, acquire the front and side image data of the target carton;
[0051] S104, based on the LBP feature description form, performs regional texture feature extraction and feature vector transformation on the frontal image data and side image data to obtain multiple LBP feature vectors, calculates the data variance based on the multiple LBP feature vectors, and generates the material consistency index based on the variance value.
[0052] S106, obtain the cardboard box image area, and divide the cardboard box image area into N image areas. The center point of each image area is used as a preset point. Obtain the thickness value of the preset point, map the thickness value to a preset grayscale range, and obtain N grayscale values. The N grayscale values are the grayscale values of the center pixels of the N image areas.
[0053] S108: Perform linear regression fitting based on N gray values and generate a linear equation. Obtain the transition gray value between every two gray values through the linear equation. Fill the N image regions with the transition gray value to obtain a thickness distribution map based on gray value representation.
[0054] S110: Calculate the average gray value of all pixels in each image region to obtain N average gray values. Compare the N average gray values with the standard value to evaluate the thickness uniformity and generate a thickness uniformity index.
[0055] S112 uses material consistency index and thickness uniformity index to conduct quality assessment and optimize production equipment parameters.
[0056] According to an embodiment of the present invention, the acquisition of front image data and side image data of the target carton specifically includes:
[0057] High-definition camera equipment is used to acquire front and side image data of the target carton after it has been flattened during the corrugated carton production process.
[0058] Image enhancement, noise reduction, and standardization preprocessing are performed on the frontal and side image data.
[0059] It should be noted that the front image data refers to the image of the corrugated cardboard box when it is unfolded, generally including both the front and back sides. This is referred to as the front image data and is stored therein. This means that the acquired image data can be from non-finished cardboard boxes, i.e., from corrugated cardboard products in the production process, allowing for quality inspection. If abnormalities are found, early production intervention can be implemented. The side image data specifically refers to the cross-sectional image of the cardboard box, which can be used to analyze the texture and thickness information of the corrugated cardboard cross-section.
[0060] According to an embodiment of the present invention, the step of extracting regional texture features and transforming feature vectors from frontal and side image data based on LBP feature description to obtain multiple LBP feature vectors, calculating data variance based on multiple LBP feature vectors, and generating a material consistency index based on the variance value, specifically involves:
[0061] The frontal and side image data are converted to grayscale to generate a first grayscale image and a second grayscale image.
[0062] In the first grayscale image, a 3×3 matrix neighborhood is set for each pixel. Taking the selected pixel as the center point, it is determined whether the grayscale value of the pixel in the matrix neighborhood is greater than or equal to the grayscale value of the center point. If it is, it is marked as 1; otherwise, it is marked as 0.
[0063] After the matrix neighborhood is determined, the gray values of the pixels in the neighborhood are sequentially obtained to obtain the binarized values. The binarized values are then converted into decimal numbers to obtain the LBP code of the matrix neighborhood.
[0064] Calculate the LBP code for each pixel and statistically form an LBP histogram. Use the LBP histogram as a texture feature and generate multiple LBP feature vectors from the LBP histogram.
[0065] Variance is calculated for multiple LBP feature vectors. The difference between feature vectors is calculated using the Manhattan distance value, and the first variance is obtained.
[0066] Calculate the second variance based on the second grayscale image;
[0067] Material consistency is assessed based on the mean of the first variance and the second variance, resulting in a material consistency index.
[0068] It should be noted that texture features can reflect the distribution and uniformity of material texture. The uniformity and standardization of the material significantly affect the production quality and finished product pass rate of corrugated cardboard boxes. The sequential acquisition of binary values (excluding the center point, which are the eight values obtained sequentially) allows the top-left corner value of a 3×3 neighborhood to be used as the first value, resulting in an 8-bit binary number. For each pixel, a feature vector extraction process is performed, enabling regional texture feature extraction. The LBP feature vector reflects the material texture characteristics in vector form. The second variance is calculated in the same way as the first method.
[0069] Variance calculation is performed on multiple LBP feature vectors, that is, each LBP feature vector is treated as a data point and its variance is calculated. The difference between data points is calculated using Manhattan distance.
[0070] The larger the variance, the greater the dispersion between texture features and texture contours, and the lower the material consistency. Furthermore, the LBP method for calculating texture features is applicable to surface and cross-sectional images of corrugated paper (corresponding to front and side image data).
[0071] The specific material consistency index is as follows:
[0072]
[0073] Where P is the material consistency index, and S1 and S2 are the first and second variances, respectively. Specifically, the material consistency index is equal to the reciprocal of the mean of the first and second variances, and it is inversely proportional to the mean of the first and second variances.
[0074] Manhattan distance is calculated as follows:
[0075] ;
[0076] d represents the distance, and A and B are two feature vectors. Let A be the value of the k-th dimension of vector A. Let n be the value of the k-th dimension of vector B, where n is the total number of dimensions of the vector.
[0077] According to an embodiment of the present invention, the step of acquiring a cardboard box image area and dividing the cardboard box image area into N image areas, with the center point of each image area as a preset point, acquiring the thickness value of the preset point, mapping the thickness value to a preset grayscale range, and obtaining N grayscale values, wherein the N grayscale values are the grayscale values of the center pixels of the N image areas, specifically:
[0078] For the front image data, obtain the cardboard image area of the target cardboard box. Divide the cardboard image area into N image areas from left to right and set N preset points, with the interval between adjacent preset points being consistent. Each preset point corresponds to the center point of an image area.
[0079] Measure and obtain the thickness values of N preset points, establish the mapping relationship between the thickness value range and the gray value range, and map the thickness values to the preset gray value range to obtain N gray values.
[0080] It should be noted that the establishment of the mapping relationship between the thickness value range and the gray value range specifically involves mapping [min, max] to [0, 255], where min and max are the minimum and maximum thickness values, and the mapping method is consistent with the data normalization form.
[0081] It is worth mentioning that traditional techniques struggle to analyze the material uniformity and thickness distribution differences of cardboard boxes. Performing multi-point inspections or relying on manual experience to analyze texture and material quality issues would be extremely resource-intensive and impractical. Therefore, this invention uses the LBP operator to extract texture features from cardboard box material images and calculates corresponding features based on feature vectors. The LBP operator can analyze the texture and contour features of each pixel in a matrix-like manner, and generates feature data by statistically analyzing LBP histograms. The consistency of the material is determined based on the variance of the data. This method is suitable for analyzing the material distribution of cardboard boxes. Regarding thickness distribution, this invention acquires thickness values at multiple preset points and maps them to grayscale values in an image, using grayscale values to represent the thickness distribution. It can be understood that the thickness distribution of corrugated cardboard boxes generally conforms to a regional linear variation. Based on this, this invention linearly fits the grayscale values of preset points within a cardboard box image area, using grayscale values to infer the grayscale values of other pixel positions. By filling in transitional grayscale values, a thickness distribution map is formed, enabling a holistic analysis of the thickness distribution and allowing for more intuitive and efficient detection of the thickness distribution.
[0082] In addition, in the cardboard box image area of this invention, the area is specifically divided in the horizontal direction, and linear equation fitting is performed to achieve gray value filling of each area from left to right. Based on the distribution accuracy and quality requirements of the cardboard box, horizontal and vertical areas can be divided. For example, 6×6 image areas can be divided in a grid form, and the gray value of the center point of each image area can be obtained (calculated by measuring the thickness value). Multiple consecutive image areas can be set for linear gray value fitting. For example, the gray values corresponding to 6 vertically connected areas can be set for linear fitting, and transition gray value calculation and filling can be performed.
[0083] According to an embodiment of the present invention, the step of performing linear regression fitting based on N gray values and generating a linear equation, obtaining the transition gray value between every two gray values through the linear equation, and filling the transition gray value into N image regions to obtain a thickness distribution map based on gray value representation is specifically as follows:
[0084] By pre-setting a linear equation, using N grayscale values as dependent variables and the pixel positions corresponding to the grayscale values as independent variables, a linear regression fit is performed, and a linear equation is generated.
[0085] The transition gray values between each gray value are calculated using linear equations, and then filled into N image regions based on these transition gray values.
[0086] In the cardboard box image area, the transition grayscale value is calculated based on a linear equation, and the grayscale value of the pixels in the entire cardboard box image area is filled with grayscale values so that the pixel grayscale values in the cardboard box image area from left to right conform to the numerical change of the linear equation, thus obtaining a thickness distribution map based on grayscale representation.
[0087] It should be noted that the transition gray value is calculated using a linear equation. This linear equation determines the overall gray value trend of the carton, which in turn determines the thickness trend. This enables intelligent thickness distribution analysis, optimizes production steps, and improves the production process and quality inspection capabilities of corrugated paper.
[0088] The linear equations are as follows:
[0089]
[0090] Where β0 is the intercept, The slope For error terms, These are the independent and dependent variables, respectively. When using the pixel position corresponding to the grayscale value as the independent variable, the pixel's x (horizontal) coordinate can be used as the pixel position and the independent variable can be set accordingly.
[0091] According to an embodiment of the present invention, the step of calculating the average gray value of all pixels in each image region to obtain N average gray values, comparing the N average gray values with a standard value to evaluate the thickness uniformity, and generating a thickness uniformity index, specifically involves:
[0092] Calculate the mean gray value of all pixels in each image region to obtain N mean gray values;
[0093] The difference between the mean of N gray levels and the standard value is calculated, and the average difference is generated. The thickness uniformity index is then generated based on the average difference.
[0094] It should be noted that the standard value can be set to a value within 10, specifically determined by production quality requirements. The smaller the value, the higher the requirement for thickness uniformity in the production of corrugated paper. The thickness uniformity index is inversely proportional to the average difference; the larger the average difference, the lower the thickness uniformity.
[0095] According to an embodiment of the present invention, the quality assessment and parameter optimization of the production equipment using the material consistency index and thickness uniformity index specifically includes:
[0096] Obtain the processing data corresponding to the material association step and the thickness processing step;
[0097] The processing quality of the material correlation step and the thickness processing step is detected and evaluated based on the material consistency index and the thickness uniformity index, respectively. The parameters of the processing equipment are optimized based on the processing data, and the equipment production is dynamically adjusted.
[0098] It should be noted that the processing data includes parameter settings, processing time, and processing inspection information. Material-related steps include raw material selection, corrugated roll forming, and bonding forming—processing steps related to material texture. Thickness processing steps include flattening, die-cutting, drying, and printing; these steps have a significant impact on and correlation with the thickness distribution of the carton. By using the material consistency index and thickness uniformity index, processing quality can be precisely inspected and evaluated. Further parameter adjustments and processing optimizations can be made to the processing steps, achieving efficient quality inspection and intelligent processing optimization of corrugated paper, reducing manpower and material consumption, and improving the level of automated production.
[0099] According to an embodiment of the present invention, it further includes:
[0100] In the thickness distribution map, obtain grayscale images of N image regions;
[0101] Calculate the maximum gray value, minimum gray value, gray mean, and gray variance for each grayscale image, and set the grayscale vector based on these four values;
[0102] Generate N grayscale vectors based on N image regions;
[0103] Based on the DBSCAN clustering algorithm, a neighborhood radius and a minimum number of neighbors are set, and density clustering is performed on N gray vectors. The distance between gray vectors is calculated using Manhattan distance, and finally M clusters are formed.
[0104] The thickness consistency of the target carton is determined by dividing the value of N into Z numerical intervals on average, and then determining the numerical interval to which the cluster number M belongs.
[0105] It should be noted that, in this embodiment of the invention, in addition to comparing the mean of N grayscale values with the standard value to evaluate thickness uniformity, thickness uniformity can also be analyzed based on clustering. For the thickness distribution analysis of large cardboard boxes, it is often necessary to perform a refined analysis of the thickness uniformity of multiple regions. Therefore, this invention sets a grayscale vector based on the grayscale characteristics of the image region to reflect the thickness characteristics of the region. Through density clustering, the classification of N regions is determined, and the thickness consistency is determined based on the number of clusters. This process can perform thickness distribution feature analysis on multiple regions, realize efficient and intelligent cardboard box quality inspection, greatly reduce the involvement of human experience, and improve the level of automated cardboard box inspection.
[0106] The value of M is divided into Z intervals based on the size of N. For example, if N is 36 and Z is 6, then the intervals can be divided into 6 intervals: [1, 6], [7, 12], [13, 18], [19, 24], [25, 30], [31, 36]. The smaller M is, the earlier the interval is, which means the higher the thickness consistency.
[0107] It should be noted that the grayscale vector includes values in four dimensions, namely the maximum grayscale value, the minimum grayscale value, the grayscale mean, and the grayscale variance.
[0108] Figure 2 A block diagram of a corrugated cardboard box production quality inspection system based on intelligent analysis according to the present invention is shown.
[0109] A second aspect of the present invention also provides a corrugated cardboard box production quality inspection system 2 based on intelligent analysis. The system includes a memory 21 and a processor 22. The memory 21 includes a corrugated cardboard box production quality inspection program based on intelligent analysis. When the processor 22 executes the corrugated cardboard box production quality inspection program based on intelligent analysis, it performs the following steps:
[0110] Obtain the front and side image data of the target cardboard box;
[0111] Based on the LBP feature description form, regional texture features are extracted and feature vectors are transformed from frontal and side image data to obtain multiple LBP feature vectors. Data variance is calculated based on multiple LBP feature vectors, and material consistency index is generated based on the variance value.
[0112] Obtain the cardboard box image area and divide the cardboard box image area into N image areas. The center point of each image area is used as a preset point. Obtain the thickness value of the preset point and map the thickness value to a preset grayscale range to obtain N grayscale values. The N grayscale values are the grayscale values of the center pixels of the N image areas.
[0113] Linear regression fitting is performed based on N gray values to generate a linear equation. The transition gray value between every two gray values is obtained through the linear equation. The transition gray value is filled into N image regions to obtain a thickness distribution map based on gray value representation.
[0114] Calculate the mean gray value of all pixels in each image region to obtain N mean gray values. Compare the N mean gray values with the standard value to evaluate the thickness uniformity and generate a thickness uniformity index.
[0115] Quality assessment was conducted using material consistency index and thickness uniformity index, and parameters of production equipment were optimized.
[0116] According to an embodiment of the present invention, the acquisition of front image data and side image data of the target carton specifically includes:
[0117] High-definition camera equipment is used to acquire front and side image data of the target carton after it has been flattened during the corrugated carton production process.
[0118] Image enhancement, noise reduction, and standardization preprocessing are performed on the frontal and side image data.
[0119] It should be noted that the front image data refers to the image of the corrugated cardboard box when it is unfolded, generally including both the front and back sides. This is referred to as the front image data and is stored therein. This means that the acquired image data can be from non-finished cardboard boxes, i.e., from corrugated cardboard products in the production process, allowing for quality inspection. If abnormalities are found, early production intervention can be implemented. The side image data specifically refers to the cross-sectional image of the cardboard box, which can be used to analyze the texture and thickness information of the corrugated cardboard cross-section.
[0120] According to an embodiment of the present invention, the step of extracting regional texture features and transforming feature vectors from frontal and side image data based on LBP feature description to obtain multiple LBP feature vectors, calculating data variance based on multiple LBP feature vectors, and generating a material consistency index based on the variance value, specifically involves:
[0121] The frontal and side image data are converted to grayscale to generate a first grayscale image and a second grayscale image.
[0122] In the first grayscale image, a 3×3 matrix neighborhood is set for each pixel. Taking the selected pixel as the center point, it is determined whether the grayscale value of the pixel in the matrix neighborhood is greater than or equal to the grayscale value of the center point. If it is, it is marked as 1; otherwise, it is marked as 0.
[0123] After the matrix neighborhood is determined, the gray values of the pixels in the neighborhood are sequentially obtained to obtain the binarized values. The binarized values are then converted into decimal numbers to obtain the LBP code of the matrix neighborhood.
[0124] Calculate the LBP code for each pixel and statistically form an LBP histogram. Use the LBP histogram as a texture feature and generate multiple LBP feature vectors from the LBP histogram.
[0125] Variance is calculated for multiple LBP feature vectors. The difference between feature vectors is calculated using the Manhattan distance value, and the first variance is obtained.
[0126] Calculate the second variance based on the second grayscale image;
[0127] Material consistency is assessed based on the mean of the first variance and the second variance, resulting in a material consistency index.
[0128] It should be noted that texture features can reflect the distribution and uniformity of material texture. The uniformity and standardization of the material significantly affect the production quality and finished product pass rate of corrugated cardboard boxes. The sequential acquisition of binary values (excluding the center point, which are the eight values obtained sequentially) allows the top-left corner value of a 3×3 neighborhood to be used as the first value, resulting in an 8-bit binary number. For each pixel, a feature vector extraction process is performed, enabling regional texture feature extraction. The LBP feature vector reflects the material texture characteristics in vector form. The second variance is calculated in the same way as the first method.
[0129] Variance calculation is performed on multiple LBP feature vectors, that is, each LBP feature vector is treated as a data point and its variance is calculated. The difference between data points is calculated using Manhattan distance.
[0130] The larger the variance, the greater the dispersion between texture features and texture contours, and the lower the material consistency. Furthermore, the LBP method for calculating texture features is applicable to surface and cross-sectional images of corrugated paper (corresponding to front and side image data).
[0131] The specific material consistency index is as follows:
[0132]
[0133] Where P is the material consistency index, and S1 and S2 are the first and second variances, respectively. Specifically, the material consistency index is equal to the reciprocal of the mean of the first and second variances, and it is inversely proportional to the mean of the first and second variances.
[0134] Manhattan distance is calculated as follows:
[0135]
[0136] d represents the distance, and A and B are two feature vectors. Let A be the value of the k-th dimension of vector A. Let n be the value of the k-th dimension of vector B, where n is the total number of dimensions of the vector.
[0137] According to an embodiment of the present invention, the step of acquiring a cardboard box image area and dividing the cardboard box image area into N image areas, with the center point of each image area as a preset point, acquiring the thickness value of the preset point, mapping the thickness value to a preset grayscale range, and obtaining N grayscale values, wherein the N grayscale values are the grayscale values of the center pixels of the N image areas, specifically:
[0138] For the front image data, obtain the cardboard image area of the target cardboard box. Divide the cardboard image area into N image areas from left to right and set N preset points, with the interval between adjacent preset points being consistent. Each preset point corresponds to the center point of an image area.
[0139] Measure and obtain the thickness values of N preset points, establish the mapping relationship between the thickness value range and the gray value range, and map the thickness values to the preset gray value range to obtain N gray values.
[0140] It should be noted that the establishment of the mapping relationship between the thickness value range and the gray value range specifically involves mapping [min, max] to [0, 255], where min and max are the minimum and maximum thickness values, and the mapping method is consistent with the data normalization form.
[0141] It is worth mentioning that traditional techniques struggle to analyze the material uniformity and thickness distribution differences of cardboard boxes. Performing multi-point inspections or relying on manual experience to analyze texture and material quality issues would be extremely resource-intensive and impractical. Therefore, this invention uses the LBP operator to extract texture features from cardboard box material images and calculates corresponding features based on feature vectors. The LBP operator can analyze the texture and contour features of each pixel in a matrix-like manner, and generates feature data by statistically analyzing LBP histograms. The consistency of the material is determined based on the variance of the data. This method is suitable for analyzing the material distribution of cardboard boxes. Regarding thickness distribution, this invention acquires thickness values at multiple preset points and maps them to grayscale values in an image, using grayscale values to represent the thickness distribution. It can be understood that the thickness distribution of corrugated cardboard boxes generally conforms to a regional linear variation. Based on this, this invention linearly fits the grayscale values of preset points within a cardboard box image area, using grayscale values to infer the grayscale values of other pixel positions. By filling in transitional grayscale values, a thickness distribution map is formed, enabling a holistic analysis of the thickness distribution and allowing for more intuitive and efficient detection of the thickness distribution.
[0142] In addition, in the cardboard box image area of this invention, the area is specifically divided in the horizontal direction, and linear equation fitting is performed to achieve gray value filling of each area from left to right. Based on the distribution accuracy and quality requirements of the cardboard box, horizontal and vertical areas can be divided. For example, 6×6 image areas can be divided in a grid form, and the gray value of the center point of each image area can be obtained (calculated by measuring the thickness value). Multiple consecutive image areas can be set for linear gray value fitting. For example, the gray values corresponding to 6 vertically connected areas can be set for linear fitting, and transition gray value calculation and filling can be performed.
[0143] According to an embodiment of the present invention, the step of performing linear regression fitting based on N gray values and generating a linear equation, obtaining the transition gray value between every two gray values through the linear equation, and filling the transition gray value into N image regions to obtain a thickness distribution map based on gray value representation is specifically as follows:
[0144] By pre-setting a linear equation, using N grayscale values as dependent variables and the pixel positions corresponding to the grayscale values as independent variables, a linear regression fit is performed, and a linear equation is generated.
[0145] The transition gray values between each gray value are calculated using linear equations, and then filled into N image regions based on these transition gray values.
[0146] In the cardboard box image area, the transition grayscale value is calculated based on a linear equation, and the grayscale value of the pixels in the entire cardboard box image area is filled with grayscale values so that the pixel grayscale values in the cardboard box image area from left to right conform to the numerical change of the linear equation, thus obtaining a thickness distribution map based on grayscale representation.
[0147] It should be noted that the transition gray value is calculated using a linear equation. This linear equation determines the overall gray value trend of the carton, which in turn determines the thickness trend. This enables intelligent thickness distribution analysis, optimizes production steps, and improves the production process and quality inspection capabilities of corrugated paper.
[0148] The linear equations are as follows:
[0149]
[0150] Where β0 is the intercept, The slope For error terms, These are the independent and dependent variables, respectively. When using the pixel position corresponding to the grayscale value as the independent variable, the pixel's x (horizontal) coordinate can be used as the pixel position and the independent variable can be set accordingly.
[0151] According to an embodiment of the present invention, the step of calculating the average gray value of all pixels in each image region to obtain N average gray values, comparing the N average gray values with a standard value to evaluate the thickness uniformity, and generating a thickness uniformity index, specifically involves:
[0152] Calculate the mean gray value of all pixels in each image region to obtain N mean gray values;
[0153] The difference between the mean of N gray levels and the standard value is calculated, and the average difference is generated. The thickness uniformity index is then generated based on the average difference.
[0154] It should be noted that the standard value can be set to a value within 10, specifically determined by production quality requirements. The smaller the value, the higher the requirement for thickness uniformity in the production of corrugated paper. The thickness uniformity index is inversely proportional to the average difference; the larger the average difference, the lower the thickness uniformity.
[0155] According to an embodiment of the present invention, the quality assessment and parameter optimization of the production equipment using the material consistency index and thickness uniformity index specifically includes:
[0156] Obtain the processing data corresponding to the material association step and the thickness processing step;
[0157] The processing quality of the material correlation step and the thickness processing step is detected and evaluated based on the material consistency index and the thickness uniformity index, respectively. The parameters of the processing equipment are optimized based on the processing data, and the equipment production is dynamically adjusted.
[0158] It should be noted that the processing data includes parameter settings, processing time, and processing inspection information. Material-related steps include raw material selection, corrugated roll forming, and bonding forming—processing steps related to material texture. Thickness processing steps include flattening, die-cutting, drying, and printing; these steps have a significant impact on and correlation with the thickness distribution of the carton. By using the material consistency index and thickness uniformity index, processing quality can be precisely inspected and evaluated. Further parameter adjustments and processing optimizations can be made to the processing steps, achieving efficient quality inspection and intelligent processing optimization of corrugated paper, reducing manpower and material consumption, and improving the level of automated production.
[0159] A third aspect of the present invention also provides a computer-readable storage medium comprising a corrugated carton production quality inspection program based on intelligent analysis, wherein when the corrugated carton production quality inspection program based on intelligent analysis is executed by a processor, it implements the steps of the corrugated carton production quality inspection method based on intelligent analysis as described in any of the preceding claims.
[0160] This invention discloses a method and system for quality inspection in corrugated cardboard box production based on intelligent analysis. First, image data of the front and side of the cardboard box are acquired. Texture features are extracted using LBP feature description and converted into feature vectors. The variance of the vector data is calculated to determine material consistency. Simultaneously, preset points are set in the cardboard box image area, and the thickness values at these preset points are acquired and mapped to grayscale values. A linear equation is generated by fitting the grayscale values using linear regression. Based on the fitted equation, transition grayscale values are obtained and filled into the image area to obtain a thickness distribution map based on grayscale representation. The mean grayscale value of each image area is calculated and compared with a standard value to evaluate thickness uniformity, generating a thickness uniformity index. Finally, a comprehensive quality assessment is performed by combining material consistency and thickness uniformity, and the parameters of the corrugated cardboard box production equipment are optimized to achieve precise inspection and optimized control of cardboard box quality.
[0161] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods, such as: multiple units or components can be combined, or integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the various components shown or discussed can be through some interfaces, and the indirect coupling or communication connection between devices or units can be electrical, mechanical, or other forms.
[0162] The units described above as separate components may or may not be physically separate. The components shown as units may or may not be physical units. They may be located in one place or distributed across multiple network units. Some or all of the units may be selected to achieve the purpose of this embodiment according to actual needs.
[0163] In addition, in the various embodiments of the present invention, each functional unit can be integrated into one processing unit, or each unit can be a separate unit, or two or more units can be integrated into one unit; the integrated unit can be implemented in hardware or in the form of hardware plus software functional units.
[0164] Those skilled in the art will understand that all or part of the steps of the above method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it performs the steps of the above method embodiments. The aforementioned storage medium includes various media capable of storing program code, such as mobile storage devices, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0165] Alternatively, if the integrated units of this invention are implemented as software functional modules and sold or used as independent products, they can also be stored in a computer-readable storage medium. Based on this understanding, the technical solutions of the embodiments of this invention, or the parts that contribute to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the methods described in the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as mobile storage devices, ROM, RAM, magnetic disks, or optical disks.
[0166] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for quality inspection in corrugated cardboard box production based on intelligent analysis, characterized in that, include: Obtain the front and side image data of the target cardboard box; Based on the LBP feature description form, regional texture features are extracted and feature vectors are transformed from frontal and side image data to obtain multiple LBP feature vectors. Data variance is calculated based on multiple LBP feature vectors, and material consistency index is generated based on the variance value. Specifically, it includes: The frontal and side image data are converted to grayscale to generate a first grayscale image and a second grayscale image. In the first grayscale image, a 3×3 matrix neighborhood is set for each pixel. Taking the selected pixel as the center point, it is determined whether the grayscale value of the pixel in the matrix neighborhood is greater than or equal to the grayscale value of the center point. If it is, it is marked as 1; otherwise, it is marked as 0. After the matrix neighborhood is determined, the gray values of the pixels in the neighborhood are sequentially obtained to obtain the binarized values. The binarized values are then converted into decimal numbers to obtain the LBP code of the matrix neighborhood. Calculate the LBP code for each pixel and statistically form an LBP histogram. Use the LBP histogram as a texture feature and generate multiple LBP feature vectors from the LBP histogram. Variance is calculated for multiple LBP feature vectors. The difference between feature vectors is calculated using the Manhattan distance value, and the first variance is obtained. Calculate the second variance based on the second grayscale image; Material consistency is assessed based on the mean of the first variance and the second variance, resulting in a material consistency index. Obtain the cardboard box image area and divide the cardboard box image area into N image areas. The center point of each image area is used as a preset point. Obtain the thickness value of the preset point and map the thickness value to a preset grayscale range to obtain N grayscale values. The N grayscale values are the grayscale values of the center pixels of the N image areas. Linear regression fitting is performed based on N gray values to generate a linear equation. The transition gray value between every two gray values is obtained through the linear equation. The transition gray value is filled into N image regions to obtain a thickness distribution map based on gray value representation. Calculate the mean gray value of all pixels in each image region to obtain N mean gray values. Compare the N mean gray values with the standard value to evaluate the thickness uniformity and generate a thickness uniformity index. Quality assessment was conducted using material consistency index and thickness uniformity index, and parameters of production equipment were optimized.
2. The method for quality inspection of corrugated cardboard box production based on intelligent analysis according to claim 1, characterized in that, The acquisition of the front and side image data of the target carton specifically involves: High-definition camera equipment is used to acquire front and side image data of the target carton after it has been flattened during the corrugated carton production process. Image enhancement, noise reduction, and standardization preprocessing are performed on the frontal and side image data.
3. The method for quality inspection of corrugated cardboard box production based on intelligent analysis according to claim 1, characterized in that, The process involves acquiring a cardboard box image area, dividing the cardboard box image area into N image areas, using the center point of each image area as a preset point, obtaining the thickness value of the preset point, mapping the thickness value to a preset grayscale range, and obtaining N grayscale values. These N grayscale values are the grayscale values of the center pixels of the N image areas. Specifically: For the front image data, obtain the cardboard image area of the target cardboard box. Divide the cardboard image area into N image areas from left to right and set N preset points, with the interval between adjacent preset points being consistent. Each preset point corresponds to the center point of an image area. Measure and obtain the thickness values of N preset points, establish the mapping relationship between the thickness value range and the gray value range, and map the thickness values to the preset gray value range to obtain N gray values.
4. The method for quality inspection of corrugated cardboard box production based on intelligent analysis according to claim 1, characterized in that, The process involves performing linear regression fitting based on N grayscale values to generate a linear equation. The transition grayscale value between every two grayscale values is then obtained through this equation. This transition grayscale value is then filled into N image regions to obtain a thickness distribution map based on grayscale representation. By pre-setting a linear equation, using N grayscale values as dependent variables and the pixel positions corresponding to the grayscale values as independent variables, a linear regression fit is performed, and a linear equation is generated. The transition gray values between each gray value are calculated using linear equations, and then filled into N image regions based on these transition gray values. In the cardboard box image area, the transition grayscale value is calculated based on a linear equation, and the grayscale value of the pixels in the entire cardboard box image area is filled with grayscale values so that the pixel grayscale values in the cardboard box image area from left to right conform to the numerical change of the linear equation, thus obtaining a thickness distribution map based on grayscale representation.
5. The method for quality inspection of corrugated cardboard box production based on intelligent analysis according to claim 1, characterized in that, The process involves calculating the average grayscale value of all pixels in each image region to obtain N average grayscale values. These N average grayscale values are then compared with a standard value to evaluate thickness uniformity and generate a thickness uniformity index. Specifically: Calculate the mean gray value of all pixels in each image region to obtain N mean gray values; The difference between the mean of N gray levels and the standard value is calculated, and the average difference is generated. The thickness uniformity index is then generated based on the average difference.
6. The method for quality inspection of corrugated cardboard box production based on intelligent analysis according to claim 1, characterized in that, The quality assessment and production equipment parameter optimization using material consistency index and thickness uniformity index are specifically as follows: Obtain the processing data corresponding to the material association step and the thickness processing step; The processing quality of the material correlation step and the thickness processing step is detected and evaluated based on the material consistency index and the thickness uniformity index, respectively. The parameters of the processing equipment are optimized based on the processing data, and the equipment production is dynamically adjusted.
7. A quality inspection system for corrugated cardboard box production based on intelligent analysis, characterized in that, The system includes a memory and a processor. The memory includes a corrugated box production quality inspection program based on intelligent analysis. When the processor executes the corrugated box production quality inspection program based on intelligent analysis, it implements the steps of the corrugated box production quality inspection method based on intelligent analysis as described in claim 1.
8. The corrugated cardboard box production quality inspection system based on intelligent analysis according to claim 7, characterized in that, The acquisition of the front and side image data of the target carton specifically involves: High-definition camera equipment is used to acquire front and side image data of the target carton after it has been flattened during the corrugated carton production process. Image enhancement, noise reduction, and standardization preprocessing are performed on the frontal and side image data.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a corrugated carton production quality inspection program based on intelligent analysis. When the corrugated carton production quality inspection program based on intelligent analysis is executed by a processor, it implements the steps of the corrugated carton production quality inspection method based on intelligent analysis as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Corrugated paper production quality real-time detection method based on computer vision
CN116168024A
Corrugated board surface defect intelligent identification method based on analog image
CN117788469A