Packaging printed matter printing quality detection method
Through multimodal data fusion and adaptive learning rate algorithm, the problems of singleness and inaccuracy of existing packaging and printed matter detection methods are solved, and comprehensive and efficient detection and quality assessment of packaging and printed matter are achieved.
Patent Information
- Application Number
- CN202510716437.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-30
- Publication Date
- 2025-09-12
AI Technical Summary
Existing packaging and printed material inspection methods rely on QR code scanning, which has a single level of detection and is easily affected, resulting in inaccurate and inconsistent results.
Using multimodal data fusion technology, combining image, spectral, audio and tactile data, through tensor decomposition and adaptive learning rate algorithm, it optimizes feature extraction and model training for different packaging types, and uses deep learning and generative adversarial networks to improve the accuracy of defect recognition and quality assessment.
It realizes comprehensive and efficient inspection of packaging and printed materials, can accurately identify various defects, provide quantitative quality assessment and real-time feedback, adapt to the inspection needs of different packaging types, and improve the accuracy and efficiency of inspection.
Smart Images

Figure CN120634994A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of packaging printing quality detection, and in particular to a packaging printed matter printing quality detection method. Background Art
[0002] Packaging plays the role of protecting products, preventing product counterfeiting, decorating and beautifying, and promoting products. A good product cannot be without packaging, and the packaging mainly includes elements such as trademarks or brands, shapes, colors, and patterns. These elements are all for promoting the packaged goods. Therefore, it is necessary to test the trademarks or brands, shapes, colors, and patterns printed on the packaging to avoid affecting product promotion.
[0003] Current testing methods, such as the printed matter quality testing and material collection method and system disclosed in Chinese Patent Publication No. CN112767306B, primarily rely on scanning the QR code on the packaging to test the quality of printed matter. This approach not only provides a relatively limited level of testing but is also susceptible to single-factor testing factors, resulting in inaccurate and inconsistent test results. Accordingly, the present invention proposes a method for testing the print quality of printed matter. Summary of the Invention
[0004] The purpose of the present invention is to solve the shortcomings of the prior art and to propose a method for detecting the printing quality of packaging printed matter.
[0005] In order to achieve the above object, the present invention adopts the following technical solutions:
[0006] A method for detecting the printing quality of packaging printed matter comprises the following steps:
[0007] S1. Image Acquisition: A customized high-resolution linear array camera is selected based on the cigarette packaging type. Using a high-precision sensor, the camera monitors the movement of the cigarette packaging in real time. The camera dynamically adjusts the exposure time and scanning frequency accordingly to ensure clear and stable images, and sets a reasonable overlap area for adjacent images.
[0008] S2. Image Preprocessing: Based on the characteristics of cigarette packaging types, we use bilateral filtering, non-local means filtering, a combination of Gaussian bilateral filtering and homomorphic filtering, and a combination of median filtering and histogram equalization to perform denoising and enhancement preprocessing on the collected images, improving image quality and providing a good foundation for subsequent analysis.
[0009] S3. Feature Extraction: Based on conventional edge, color, and texture feature extraction, local binary pattern features, shape context features, Fourier transform features, and wavelet transform features are introduced for different cigarette packaging types to enrich the description of image features, more accurately capture information related to printing quality, and optimize the fusion feature extraction process;
[0010] S4. Defect Identification and Classification: Analyze pre-processed and feature-extracted images for different cigarette packaging types to identify and classify various defects in printed materials, such as ink spots, misregistration, and abnormal anti-counterfeiting features.
[0011] S5. Quality Assessment and Report Generation: Generate detailed inspection reports based on different cigarette packaging types and corresponding inspection frequencies. The report content covers production batch, number of defects, type distribution, defect location, and quality assessment recommendation information.
[0012] Preferably, during the model training process, for irregular paper cigarette boxes, an adaptive learning rate adjustment strategy is adopted in conjunction with a multimodal model training algorithm based on a generative adversarial network. The adaptive learning rate adjustment algorithm dynamically adjusts the learning rate according to the performance of the model on the multimodal data of irregular cigarette boxes during the training process, so that the GAN-based multimodal model can converge faster and enhance its learning ability for the complex features of irregular packaging in the adversarial training of the generator and the discriminator, and more accurately learn the special defect-related features of the stretching deformation of the printed pattern on the irregular part, thereby improving the accuracy and generalization ability of the model in detecting defects in irregular paper cigarette boxes.
[0013] Preferably, in the feature extraction link, for laser film-wrapped cigarette boxes, the Fourier transform feature extraction algorithm is combined with the feature extraction algorithm based on convolutional neural network. The Fourier transform is first used to convert the image and spectral data of the laser film cigarette box from the spatial domain to the frequency domain, and the features in the frequency domain, such as the high-frequency component distribution characteristics of the laser pattern, are extracted. Then, these features are further convolutionally operated and feature learned through CNN to explore the intrinsic connection between the frequency domain features and the spatial domain features, thereby enhancing the accuracy of defect positioning of laser film-wrapped cigarette boxes and more accurately determining the specific locations of laser pattern defects and film material quality defects.
[0014] Preferably, in the defect identification stage, for soft-pack cigarette packaging, a support vector machine model is used in collaboration with a multimodal fusion detection model based on deep learning. First, the multimodal fusion detection model based on deep learning is used to perform a preliminary analysis of the multimodal data of the soft pack to extract potential defect features, and then these features are input into the SVM model. The SVM model, based on its unique classification hyperplane construction capability, classifies defects more accurately, such as more accurately distinguishing ink dot defects, overprinting defects and material-related defects in soft pack printing, thereby improving the reliability of defect identification and classification of soft-pack cigarette packaging.
[0015] Preferably, in the quality assessment stage, for conventional paper cigarette boxes, a quality assessment algorithm based on the analytic hierarchy process is combined with the multimodal fusion detection results, and the weights of image, spectrum, audio, and tactile multimodal data in the quality assessment of conventional paper cigarette boxes are determined through the AHP algorithm. Then, based on the defect information obtained by multimodal fusion detection and the characteristics of each modal data, the quality assessment score of the cigarette box is comprehensively calculated, and a quantitative quality assessment system is formulated to achieve a comprehensive and objective quality assessment of conventional paper cigarette boxes. Based on the assessment results, weekly fine-tuning and monthly in-depth maintenance of production equipment can be more reasonably performed.
[0016] Preferably, in terms of report generation, for irregular-shaped paper cigarette boxes, a data visualization algorithm and a multimodal inspection report generation algorithm are used to work together. The data visualization algorithm presents the multimodal inspection data of irregular-shaped cigarette boxes, such as spectral images, audio waveforms, and tactile pressure distribution diagrams, in an intuitive and easy-to-understand manner. The multimodal inspection report generation algorithm generates a detailed and visual inspection report based on these visual data and defect identification and quality assessment results. The report not only contains traditional information, but also highlights the defects and quality problems of irregular-shaped parts through visual charts, which makes it convenient for production personnel to quickly understand the product quality status. At the same time, a multimodal inspection report management system is established to realize efficient classification, storage, retrieval and comparative analysis of irregular-shaped paper cigarette box inspection reports.
[0017] Preferably, in the entire cigarette packaging printing quality detection system, a system optimization algorithm based on genetic algorithm is used to globally optimize the algorithm parameters of each link. For different types of cigarette packaging, the genetic algorithm takes detection accuracy, recall rate, and model training time as optimization goals, and iteratively optimizes the image acquisition parameter adjustment algorithm, multimodal fusion algorithm parameters, model training parameters, and feature extraction algorithm parameters to find the optimal algorithm parameter combination, so that the entire detection system can achieve the best performance in the printing quality detection of different cigarette packaging types, improve detection efficiency and quality, and provide strong support for the continuous improvement of cigarette packaging printing quality.
[0018] The present invention has the following beneficial effects:
[0019] 1. Breaking through the limitations of single detection, the system simultaneously collects multimodal data including spectrum, audio, touch, and image, and uses multimodal fusion algorithms for deep integration to optimize feature extraction for different packaging types, greatly improving the comprehensiveness and accuracy of detection. In terms of model construction, the system tailors structures and training strategies for conventional and special-shaped paper cigarette boxes, adopts adaptive learning rates and data enhancement to enhance the model's ability to generalize and learn complex features. In the defect identification link, the system optimizes the process. Through multimodal collaboration, it can not only accurately locate various defects, but also identify new and special defect types, enriching the defect classification dimension. During quality assessment, a quantitative system is formulated based on the multimodal detection results, and a real-time feedback mechanism is established to provide targeted improvement suggestions for different packaging types.
[0020] 2. This paper uses different tensor decomposition models, such as CANDECOMP / PARAFAC for conventional paper cigarette boxes, Tucker for special-shaped paper cigarette boxes, PARAFAC2 for laser film-wrapped cigarette boxes, and block decomposition for soft-pack cigarette packaging, to construct and decompose image, spectral, audio, and tactile data into multidimensional tensors. This decomposition reveals the complex and potential correlation features between the data. Combined with the attention mechanism, this method highlights features closely related to printing quality, achieving comprehensive and efficient data fusion and providing a richer and more accurate data foundation for subsequent analysis.
[0021] 3. The present invention adopts Adagrad, Adadelta, RMSProp and Adam adaptive learning rate algorithms for different cigarette box types. According to the training error, accuracy, adversarial training effect or performance of the model on the corresponding cigarette box multimodal data, the learning rate is dynamically adjusted to make the model converge faster, reduce training time, enhance the model's ability to learn the characteristics of different cigarette box data, improve the generalization and stability of the model, and more accurately adapt to the needs of various types of cigarette packaging printing quality inspection. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] Figure 1 This is a schematic diagram of the architecture of a multimodal detection system in a packaging printed matter printing quality detection method proposed by the present invention;
[0023] Figure 2 This is a schematic diagram of model comparison in a packaging printed matter printing quality detection method proposed by the present invention;
[0024] Figure 3 This is a schematic diagram of multi-framework comparative analysis in a packaging printed matter printing quality detection method proposed by the present invention;
[0025] Figure 4 This is a flow chart of intelligent quality inspection in a method for inspecting the printing quality of printed packaging proposed by the present invention;
[0026] Figure 5This is a partial code display diagram of the simulated image acquisition in the packaging printed matter printing quality detection method proposed by the present invention;
[0027] Figure 6 This is a partial code display diagram of image preprocessing in a packaging printed matter printing quality detection method proposed by the present invention;
[0028] Figure 7 This is a partial code display diagram for feature extraction in the packaging printed matter printing quality detection method proposed by the present invention. DETAILED DESCRIPTION
[0029] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments.
[0030] Example 1: Algorithm Collaborative Detection of Conventional Paper Cigarette Packs
[0031] Step 1: Multimodal data fusion: For conventional paper cigarette boxes, the collected image, spectrum, audio and tactile data are constructed into a multidimensional tensor Where I represents the image data dimension, S is the spectral data dimension, A is the audio data dimension, and H is the tactile data dimension. The CANDECOMP / PARAFAC (CP) tensor decomposition model is used to decompose the tensor T into the sum of multiple rank tensors, namely where λ k is the weight coefficient, are the feature vectors of image, spectrum, audio and tactile data on the kth component, Denotes the outer product operation. Through this decomposition, the potential correlation features between different modal data are obtained.
[0032] The multimodal feature fusion network based on the attention mechanism takes the decomposed features as input. For each feature vector v i (i represents the feature index after fusion of different modalities), calculate its attention weight α i , the formula is Where w is a learnable weight vector and N is the total number of feature vectors. By performing a weighted summation on the features, features closely related to printing quality are highlighted, achieving efficient multimodal data fusion.
[0033] Step 2: Model training;
[0034] In the training process of the convolutional neural network (CNN) model, the Adagrad adaptive learning rate algorithm is used. The learning rate η t Dynamically adjusted over time t, the formula is Where η0 is the initial learning rate, gi is the gradient of step i, and ∈ is a small constant to prevent the denominator from being zero. Based on the training error and accuracy of the model on the multimodal data of regular paper cigarette boxes, the learning rate is dynamically adjusted to make the model converge faster.
[0035] Step 3: Feature extraction;
[0036] In terms of image feature extraction, for conventional paper cigarette box images, LBP features are calculated. c As a benchmark, for the neighborhood pixel p n (n=0,1,…,P-1, P is the number of neighborhood pixels), if p n ≥p c If it is 1, it is recorded as 1, otherwise it is recorded as 0, and these binary values are combined into a binary number, that is, Where (x, y) is the center pixel coordinate, R is the neighborhood radius, and s(x) is the sign function. LBP feature extraction is used to describe the texture details of the image.
[0037] Step 4: Defect identification and quality assessment:
[0038] During the defect recognition phase, an attention mechanism module is added to the improved CNN model. For the input multimodal fusion feature map F, a convolutional layer is used to generate an attention map A, where A = σ(Conv(F)), where σ is the activation function and Conv represents the convolution operation. The attention map is then element-wise multiplied with the feature map, resulting in F′ = F⊙A. This highlights important feature areas and improves the recognition of ink spots and overprint misregistration defects.
[0039] In the quality assessment phase, a hierarchical analysis model is constructed. Image, spectrum, audio, and tactile data are used as the criterion layer, and ink dot defects and overprinting defects are used as the indicator layer. A judgment matrix is constructed through expert scoring, and the weight w of each criterion layer element relative to the target layer (quality assessment) is calculated. i (i=1,2,…,4, corresponding to image, spectrum, audio, and touch respectively). Calculate the quality assessment score based on the defect information obtained by multimodal fusion detection and the data features of each modality. where f i It is the score of each modal data in defect detection, thereby achieving a comprehensive and objective quality assessment of conventional paper cigarette boxes.
[0040] Example 2: Algorithm-assisted detection of irregular-shaped paper cigarette boxes
[0041] Step 1: Multimodal data fusion:
[0042] For the multimodal data of irregular paper cigarette boxes, a multidimensional tensor is also constructed. Using the Tucker tensor decomposition model, the tensor T is decomposed into a core tensor G and multiple modal factor matrices, namely
[0043] T≈G×1U (I) ×2U (S) ×3U (A) ×4U (H) , where × i represents the tensor multiplication along the i-th dimension, U (I) 、U (S) 、U (A) 、U (H) are the factor matrices of each mode respectively. Through this decomposition, the complex relationship between the different modal data of special-shaped cigarette boxes is mined.
[0044] Similar to regular paper cigarette boxes, the feature weights are calculated using the attention mechanism. i ,pass Attention weights are calculated to highlight features related to special defects of stretching deformation of printed patterns on irregular parts.
[0045] Step 2: Model training:
[0046] In the training of multimodal models based on generative adversarial networks (GANs), the Adadelta adaptive learning rate algorithm is used. For the parameter updates of the generator and discriminator, the learning rate Δθ is calculated as follows:
[0047]
[0048] Where ρ is the attenuation coefficient, E[g 2 ] t is the exponentially weighted average of the square of the gradient at step t, E[Δθ 2 ] t-1 is the exponentially weighted average of the squares of the parameter updates in the previous step, where ∈ is a small constant. Based on the model's adversarial training performance on multimodal data of irregular-shaped cigarette boxes, the learning rate is dynamically adjusted to accelerate model convergence.
[0049] Step 3: Feature extraction:
[0050] For the image of the irregular paper cigarette box, the shape context feature is extracted. For each point p on the shape S, its shape context feature is defined as a histogram h p (S), Where k(·) is a kernel function, such as the Gaussian kernel function d = ||pq|| is the Euclidean distance between points p and q, and σ is the bandwidth parameter. The uniqueness of the shape of the irregular cigarette box is described by the shape context feature.
[0051] Step 4: Defect identification and quality assessment:
[0052] During the defect recognition phase, models pre-trained on large-scale general-purpose image datasets, such as ResNet, are utilized. Fine-tuning is performed on multimodal data to address the unique characteristics of irregularly shaped paper cigarette packs. During fine-tuning, the parameters of some pre-trained layers are fixed, and only the parameters of the last few fully connected layers are updated. Backpropagation is used to calculate gradients and update parameters, enabling the model to learn the unique defect characteristics of irregularly shaped cigarette packs and improve defect recognition accuracy.
[0053] During the quality assessment phase, quality assessment criteria are developed based on defect identification results, shape contextual features, and expert experience. Stretch deformation of printed patterns on irregularly shaped parts is quantitatively assessed based on the degree of deformation compared to the standard shape. For report generation, a data visualization algorithm is used to intuitively present multimodal inspection data, such as spectral images of irregularly shaped parts and folded audio waveforms. The multimodal inspection report generation algorithm uses this visualized data, along with defect identification and quality assessment results, to generate detailed and visual inspection reports, making it easier for production personnel to understand product quality.
[0054] Example 3: Algorithm-based collaborative detection of laser film-wrapped cigarette boxes
[0055] Step 1: Multimodal data fusion:
[0056] For the multimodal data of laser film packaging cigarette boxes, construct a multidimensional tensor The PARAFAC2 tensor decomposition model was used. This model, based on CP decomposition, considers the correlation of different modal data across different dimensions. By decomposing the latent factors of different modal data, the complex relationships between the multimodal data of laser film cigarette boxes were explored.
[0057] Calculate the multimodal fusion feature vector v i The attention weight Highlight features related to laser pattern clarity and film material quality.
[0058] Step 2: Model training:
[0059] In the training process of the ensemble learning model that integrates multiple convolutional neural networks (CNNs) with different structures, the RMSProp adaptive learning rate algorithm is used. The learning rate η t The update formula is:
[0060]
[0061] Where γ is the attenuation coefficient, E[g 2 ] tis the exponentially weighted average of the squared gradient at step t, η0 is the initial learning rate, and ∈ is a small constant. Based on the model’s training performance on multimodal data from laser-filmed cigarette boxes, the learning rate is dynamically adjusted to improve model training efficiency.
[0062] Step 3: Feature extraction:
[0063] For the image and spectral data of the laser film cigarette box, perform Fourier transform. For the image f(x,y), its two-dimensional discrete Fourier transform is Where (u, v) is the frequency coordinate, (x, y) is the spatial coordinate, M and N are the image sizes. For the spectral data S(λ), its Fourier transform is Where ω is the frequency and λ is the wavelength. Fourier transform is used to extract features in the frequency domain, such as the high-frequency component distribution of the laser pattern.
[0064] The Fourier transformed features are used as input and further convolution operations and feature learning are performed through CNN. The convolution layer of CNN performs convolution operations with the input feature map F through the convolution kernel K and outputs the feature map O, and
[0065]
[0066] , where (x, y) are the coordinates of the output feature map, (m, n) are the coordinates of the convolution kernel, and M and N are the kernel sizes. This approach exploits the inherent connection between frequency and spatial domain features, enhancing the accuracy of defect location in laser film-wrapped cigarette boxes.
[0067] Step 4: Defect identification and quality assessment:
[0068] During the defect recognition phase, multiple CNNs with different structures, such as VGG and ResNet, are combined to extract features and classify multimodal fusion data. A voting mechanism determines the final defect classification result. For a sample, if two of the three CNNs identify a particular defect type, the sample is assigned that defect type. This ensemble learning approach improves defect recognition accuracy.
[0069] During the quality assessment phase, quantitative quality assessment indicators were developed based on the quality standards for laser film cigarette packaging and combined with multimodal inspection data. Pattern clarity was assessed by calculating the proportion of high-frequency energy in the laser pattern, and film quality was determined by analyzing characteristic peaks in the spectral data. Inspection reports were generated hourly, detailing defect locations, types, and quality assessment results. Based on these assessment results, production equipment was adjusted daily, and raw materials were randomly inspected weekly.
[0070] Example 4: Algorithm-based collaborative detection of soft-pack cigarette packaging
[0071] Step 1: Multimodal data fusion:
[0072] For multimodal data of soft pack cigarette packaging, construct a multidimensional tensor The Block Term Decomposition (BTD) tensor decomposition model, which is suitable for processing multimodal data with block structures, is used to decompose the data to obtain the potential features of different modal data under the block structure and to explore the associations between the multimodal data of soft-pack cigarette boxes.
[0073] Calculate the multimodal fusion feature vector v i The attention weight Highlight the features related to the printing quality and materials of the soft pack.
[0074] Step 2: Model training:
[0075] In the training process of the multimodal fusion detection model based on deep learning, the Adam adaptive learning rate algorithm is used. The learning rates β1 and β2 are the decay rates of the first-order moment estimate and the second-order moment estimate, respectively. The parameter update formula is:
[0076] m t =β1m t-1 +(1-β1)g t
[0077]
[0078]
[0079] where m t and v t are the estimates of the first and second order moments, respectively. and is the revised estimate, θ t is the parameter for step t, η is the learning rate, and ∈ is a small constant. Based on the model's training performance on multimodal data from soft-pack cigarette boxes, the learning rate is dynamically adjusted to accelerate model convergence.
[0080] Step 3: Feature extraction:
[0081] For the image and audio data of soft cigarette packaging, wavelet transform is performed. For the one-dimensional signal f(t), its continuous wavelet transform is Where a is the scale parameter, b is the translation parameter, and ψ(t) is the wavelet function. For a two-dimensional image f(x,y), a two-dimensional wavelet transform is used to decompose the image into subbands of different frequencies. The wavelet coefficients are extracted as features to detect printing defects and material texture on the surface of soft packaging.
[0082] Step 4: Defect identification and quality assessment:
[0083] In the defect identification stage, we first use the multimodal fusion detection model based on deep learning to perform a preliminary analysis of the multimodal data of the soft package to extract potential defect features. These features are then input into the SVM model, which constructs a classification hyperplane w T x + b = 0, where w is the weight vector, x is the input feature vector, and b is the bias. Defects are classified using the SVM's ability to construct classification hyperplanes. This allows for more accurate differentiation of ink dot defects, overprint errors, and material-related defects in soft packaging printing.
[0084] During the quality assessment stage, a quality assessment system is developed based on the quality standards of soft-pack cigarette packaging and combined with multimodal inspection data. For overprint deviation, an allowable deviation range is specified, and any deviation exceeding the range is considered a defect. An inspection report is generated for every 1,000 soft packs produced, and the report records the defect location, type and quality assessment recommendations in detail. Production equipment is inspected and maintained weekly, and the soft pack materials provided by suppliers are evaluated monthly.
[0085] Table 1. Comparison of specific test report data of each embodiment:
[0086]
[0087] From the comparison in the above table, it can be clearly seen that multiple embodiments of cigarette packaging printing quality inspection exhibit extremely outstanding characteristics. In terms of inspection accuracy, the camera's high pixel resolution is combined with precise defect detection capabilities. For example, the pixel configuration of 2500dpi for conventional paper cigarette boxes and 3000dpi for special-shaped paper cigarette boxes can clearly capture the surface details of the cigarette boxes, accurately identify 0.05mm ink dots and extremely small overprint deviations, and ensure high precision in pattern and text printing. In terms of production adaptability, each embodiment reasonably sets the data transmission speed and inspection frequency according to differences in production scale. Whether it is conventional paper cigarette boxes produced on a large scale or special-shaped paper cigarette boxes produced in small batches, the inspection work can be completed efficiently. At the same time, the accuracy rate of anti-counterfeiting feature recognition is extremely high, and all packaging types are maintained at above 98%, which effectively protects brand intellectual property rights.
[0088] Furthermore, the pixel resolution of the detection camera is generally high, with conventional paper cigarette boxes being 2500dpi and special-shaped paper cigarette boxes reaching 3000dpi, which makes it extremely accurate to capture the surface details of the cigarette boxes. In terms of ink dot detection, each embodiment can detect ink dots with a diameter of 0.05mm, effectively avoiding the impact of tiny ink dots on the packaging appearance. The overprint deviation detection accuracy is also very impressive, and the barcode area (conventional paper cigarette boxes) and fine line area (laser film packaging cigarette boxes) can reach 0.03mm, and the text area (special-shaped paper cigarette boxes, soft pack cigarette packaging) is 0.04mm, ensuring the accuracy of pattern and text printing and improving the overall quality and visual effect of cigarette packaging.
[0089] Furthermore, the data transmission speed and daily inspection quantity demonstrate good adaptability to different production scales. For large-scale production inspection of conventional paper cigarette boxes, the data transmission speed is 500 sheets per second. Assuming 500 cigarette boxes are produced per minute and the working time is 8 hours per day, approximately 240,000 cigarette boxes can be inspected, which can effectively meet the rapid inspection needs of large-scale production. For small-batch production inspection of special-shaped paper cigarette boxes, the data transmission speed is 100 sheets per second. Although relatively slow, a report is generated for every 50 cigarette boxes produced, which is suitable for detailed inspection of each cigarette box in small-batch production, and timely identification and resolution of problems. The inspection embodiments of laser film-wrapped cigarette boxes and soft pack cigarette packaging also reasonably set the data transmission speed and inspection frequency according to their own production speed and scale, ensuring that the inspection work is carried out efficiently and orderly.
[0090] Specifically, in each embodiment, key code examples and corresponding analysis are written in Python.
[0091] Furthermore, Figure 5-Figure 6 As shown in the figure, the code simulates the image acquisition process through the image_acquisition function. The camera parameters can be adjusted according to different cigarette packaging types (conventional paper cigarette boxes, special-shaped paper cigarette boxes, laser film packaging cigarette boxes, and soft pack cigarette boxes) (the code is only for illustration). Although images should be acquired from a real camera in actual applications, this function provides the image data foundation for subsequent processing and reflects the differentiated treatment of different packaging types in the acquisition process. The image_preprocessing function performs different preprocessing operations based on the packaging type. Conventional paper cigarette boxes use bilateral filtering, special-shaped paper cigarette boxes use non-local mean filtering, laser film packaging cigarette boxes combine Gaussian bilateral filtering and homomorphic filtering, and soft pack cigarette packaging uses median filtering and histogram equalization. These operations are designed to remove noise and enhance image quality for subsequent feature extraction. At the same time, they demonstrate optimized processing methods for different packaging materials and characteristics.
[0092] Furthermore, Figure 7 As shown in the figure, the feature_extraction function extracts unique features for each type of packaging. For regular paper cigarette packaging, local binary pattern (LBP) features are used to describe texture details; for irregular-shaped paper cigarette packaging, the number of contours is used to simply represent the shape context (actually more complex); for laser-film-wrapped cigarette packaging, frequency domain features are obtained through Fourier transform; and for soft-pack cigarette packaging, wavelet transform is used to obtain features of different frequency sub-bands. These feature extraction methods fully consider the characteristics of different packaging and help to more accurately capture information related to print quality.
[0093] The above description is only a preferred specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any technician familiar with the technical field can replace or change the technical solution and inventive concept of the present invention within the technical scope disclosed by the present invention, and the replacement or change should be covered by the scope of protection of the present invention.
Claims
1. A method for detecting the printing quality of packaging printed matter, characterized in that: The following steps are involved: S1. Image Acquisition: A customized high-resolution linear array camera is selected based on the cigarette packaging type. Using a high-precision sensor, the camera monitors the movement of the cigarette packaging in real time. The camera dynamically adjusts the exposure time and scanning frequency accordingly to ensure clear and stable images, and sets a reasonable overlap area for adjacent images. S2. Image Preprocessing: Based on the characteristics of cigarette packaging types, we use bilateral filtering, non-local means filtering, a combination of Gaussian bilateral filtering and homomorphic filtering, and a combination of median filtering and histogram equalization to perform denoising and enhancement preprocessing on the collected images, improving image quality and providing a good foundation for subsequent analysis. S3. Feature Extraction: Based on conventional edge, color, and texture feature extraction, local binary pattern features, shape context features, Fourier transform features, and wavelet transform features are introduced for different cigarette packaging types to enrich the description of image features, more accurately capture information related to printing quality, and optimize the fusion feature extraction process; S4. Defect Identification and Classification: Analyze pre-processed and feature-extracted images for different cigarette packaging types to identify and classify various defects in printed materials, such as ink spots, misregistration, and abnormal anti-counterfeiting features. S5. Quality Assessment and Report Generation: Generate detailed inspection reports based on different cigarette packaging types and corresponding inspection frequencies. The report content covers production batch, number of defects, type distribution, defect location, and quality assessment recommendation information.
2. A packaging printed matter printing quality detection method according to claim 1, characterized in that: During the model training process, for irregular-shaped paper cigarette boxes, an adaptive learning rate adjustment strategy is adopted in conjunction with the multimodal model training algorithm based on the generative adversarial network. The adaptive learning rate adjustment algorithm dynamically adjusts the learning rate according to the performance of the model on the multimodal data of irregular-shaped cigarette boxes during training. This enables the GAN-based multimodal model to converge faster and enhance its ability to learn the complex features of irregular-shaped packaging during the adversarial training of the generator and the discriminator. It can also more accurately learn the special defect-related features of the stretching deformation of the printed pattern on the irregular-shaped parts, thereby improving the accuracy and generalization ability of the model in detecting defects in irregular-shaped paper cigarette boxes.
3. The method for detecting printing quality of packaged printed matter according to claim 1, wherein: In the feature extraction stage, for laser film-wrapped cigarette boxes, the Fourier transform feature extraction algorithm is combined with the feature extraction algorithm based on convolutional neural network. The Fourier transform is first used to convert the image and spectral data of the laser film cigarette box from the spatial domain to the frequency domain, and the features in the frequency domain are extracted, such as the high-frequency component distribution characteristics of the laser pattern. Then, these features are further convolutionally operated and feature learned through CNN to explore the intrinsic connection between frequency domain features and spatial domain features, thereby enhancing the accuracy of defect positioning of laser film-wrapped cigarette boxes and more accurately determining the specific locations of laser pattern defects and film material quality defects.
4. The method for detecting printing quality of packaged printed matter according to claim 1, wherein: In the defect identification stage, for soft-pack cigarette packaging, a support vector machine model is used in collaboration with a multimodal fusion detection model based on deep learning. First, the multimodal fusion detection model based on deep learning is used to perform a preliminary analysis of the multimodal data of the soft pack to extract potential defect features. These features are then input into the SVM model. Based on its unique classification hyperplane construction capability, the SVM model can more accurately classify defects, such as more accurately distinguishing ink dot defects, overprinting defects, and material-related defects in soft pack printing, thereby improving the reliability of defect identification and classification of soft-pack cigarette packaging.
5. The method for detecting printing quality of packaging printed matter according to claim 1, wherein: During the quality assessment stage, for conventional paper cigarette boxes, a quality assessment algorithm based on the hierarchical analysis method is combined with the multimodal fusion detection results. The AHP algorithm is used to determine the weights of image, spectrum, audio, and tactile multimodal data in the quality assessment of conventional paper cigarette boxes. Then, based on the defect information obtained from multimodal fusion detection and the characteristics of each modal data, the quality assessment score of the cigarette box is comprehensively calculated, and a quantitative quality assessment system is formulated to achieve a comprehensive and objective quality assessment of conventional paper cigarette boxes. Based on the assessment results, weekly fine-tuning and monthly in-depth maintenance of production equipment can be more reasonably carried out.
6. The method for detecting printing quality of packaged printed matter according to claim 1, wherein: In terms of report generation, for irregular-shaped paper cigarette boxes, the data visualization algorithm and the multimodal inspection report generation algorithm are used to work together. The data visualization algorithm presents the multimodal inspection data of irregular-shaped cigarette boxes, such as spectral images, audio waveforms, and tactile pressure distribution diagrams, in an intuitive and easy-to-understand manner. The multimodal inspection report generation algorithm generates a detailed and visual inspection report based on these visual data as well as defect identification and quality assessment results. The report not only contains traditional information, but also highlights the defects and quality problems of irregular-shaped parts through visual charts, which makes it convenient for production personnel to quickly understand the product quality status. At the same time, a multimodal inspection report management system is established to realize the efficient classification, storage, retrieval and comparative analysis of irregular-shaped paper cigarette box inspection reports.
7. The method for detecting printing quality of packaged printed matter according to claim 1, wherein: In the entire cigarette packaging printing quality inspection system, a system optimization algorithm based on genetic algorithm is used to globally optimize the algorithm parameters of each link. For different types of cigarette packaging, the genetic algorithm takes detection accuracy, recall rate, and model training time as optimization goals, and iteratively optimizes the image acquisition parameter adjustment algorithm, multimodal fusion algorithm parameters, model training parameters, and feature extraction algorithm parameters to find the optimal algorithm parameter combination, so that the entire inspection system can achieve the best performance in the printing quality inspection of different cigarette packaging types, improve inspection efficiency and quality, and provide strong support for the continuous improvement of cigarette packaging printing quality.
Citation Information
Cited By
Printing and typesetting detection method and system based on image recognition
CN121304596A
Image recognition-based printing layout detection method and system
CN121304596B
Printed matter defect online detection method and system based on machine vision
CN121707914A