Real-time quality management method and system for PVC pipes
By combining multimodal datasets and deep learning models, multi-scale features of PVC pipes are extracted, solving the problems of insufficient real-time detection and efficiency in existing technologies. This enables efficient and accurate detection of surface defects in PVC pipes and optimizes the production process.
Patent Information
- Application Number
- CN202411834201.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-13
- Publication Date
- 2025-01-10
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing PVC pipe quality inspection technologies are insufficient to meet the requirements of high-speed production lines in terms of real-time performance and efficiency, resulting in delayed test results and affecting production and inspection efficiency.
By employing real-time acquisition of multimodal datasets and deep learning models, combined with depthwise separable convolution and asymmetric convolution to extract multi-scale features, and combining global mean pooling for feature dimensionality reduction, a real-time quality management system is constructed to achieve real-time detection of surface defects in PVC pipes.
It improves the accuracy and efficiency of surface defect detection for PVC pipes, adapts to the real-time detection needs of high-speed production lines, reduces false detections and missed detections, optimizes production processes, and improves production efficiency and product quality.
Smart Images

Figure CN119295470A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of quality management, and in particular to a real-time quality management method and system for PVC pipes. Background Art
[0002] PVC, the full name of polyvinyl chloride, is a common plastic material. PVC pipes have good weather resistance, corrosion resistance and mechanical properties, so PVC pipes are everywhere in daily life and are widely used in construction, medical, packaging, electronics and transportation. However, during the production process of PVC pipes, due to poor production technology, raw material quality problems, equipment failure and environmental factors, defects such as bubbles, cracks and scratches appear on the surface of PVC pipes. These defects not only affect the appearance of PVC pipes, but also reduce their pressure resistance and corrosion resistance. In severe cases, they may cause leakage, rupture and shortened life of PVC pipes during use, endangering project safety and user experience. Therefore, timely detection and control of surface defects as a quality issue is the key to ensuring product quality, extending service life and enhancing market competitiveness.
[0003] There are many PVC pipe quality inspection technologies, such as rotationally invariant feature vector calculation and curve compensation methods and wavelet transform and gradient analysis technology combined to inspect PVC pipes with complex texture defects. However, most of the existing PVC pipe quality inspection technologies focus on high precision and ignore real-time performance, which makes the processing speed of the inspection system unable to keep up with the production speed of the high-speed production line, resulting in delayed inspection results, affecting the efficiency of production and inspection, and making it difficult to meet the real-time requirements of the online quality inspection system, thus affecting the real-time management of PVC pipe quality.
[0004] Therefore, a real-time quality management method and system for PVC pipes are proposed. Summary of the invention
[0005] The object of the present invention is to provide a real-time quality management method and system for PVC pipes. The present invention first collects a multimodal data set of PVC pipes in real time and preprocesses it to obtain preprocessed data; secondly, a deep learning model is constructed, and multi-scale features of the preprocessed data are extracted by deep separable convolution and asymmetric convolution to reduce the parameters of the deep learning model; then, the extracted multi-scale features are fused by multimodal fusion, and feature dimension reduction is performed in combination with global mean pooling; then, the deep learning model is trained and its detection performance is evaluated; finally, surface defects of PVC pipes are detected and alarmed in real time, and the defect categories and locations are recorded to optimize the production process.
[0006] To achieve the above object, the present invention provides the following technical solutions: A real-time quality management method for PVC pipes, comprising: Real-time acquisition of multimodal data sets of PVC pipes, including image data and geometric data, and data annotation; The image data includes: normal samples and defective samples; the defects include: cracks, bubbles, scratches and color difference; the geometric information includes: outer diameter, wall thickness and density distribution of PVC pipes; The data annotation includes: annotating the image data using an annotation tool to mark the defect location and defect type; The collected multimodal dataset is divided into training set, validation set and test set.
[0007] Preferably, the image data and the geometric data are preprocessed to obtain preprocessed data; the preprocessing includes: image data preprocessing and geometric data preprocessing; The image data preprocessing includes: denoising and image enhancement to obtain a preprocessed image; wherein the denoising includes: removing the noise of the industrial environment during the acquisition process; The image enhancement includes: expanding the training data set through geometric transformation, color adjustment and noise addition; wherein the geometric transformation includes: simulating defects at different angles through random rotation and horizontal flipping; the color adjustment includes: simulating different lighting conditions through random adjustment of brightness, contrast and saturation; the noise addition includes: simulating sensor interference through random addition of salt and pepper noise and Gaussian noise; The geometric data preprocessing includes: projecting the geometric data into a depth map to obtain a preprocessed depth map; The preprocessed image data and the preprocessed depth map are temporally synchronized and spatially aligned.
[0008] Preferably, a deep learning model is constructed to extract multi-scale features of PVC pipes, and perform feature fusion and dimensionality reduction; the structure of the deep learning model includes: an input layer, a depth-separable asymmetric convolution layer, a multimodal fusion layer, a global mean pooling layer and an output layer; The input layer includes: inputting the preprocessed data and taking them as two independent input channels respectively; fusing the preprocessed image and the preprocessed depth map at the feature layer after they are processed by independent first several layers of convolution; the input data formula is: ; in, It is the input data of the deep learning model; is the preprocessed image; is the preprocessed depth map; The depth-wise separable asymmetric convolution layer combines depth-wise separable convolution and asymmetric convolution to extract multi-scale features. The specific process is: the parallel structure of 1×1 and 3×3 convolution kernels is introduced through the depth-wise separable convolution, and the 3×3 convolution kernel is decomposed into 1×3 and 3×1 convolutions through the asymmetric convolution. The formula of 1×3 convolution is: ; in, It is the feature in the horizontal direction; is the 1×3 convolution kernel weight; is the pixel horizontal coordinate; is the pixel ordinate; For input data in category Medium Pixels The value of is the total number of categories; The formula for 3×1 convolution is: ; in, It is a feature in the vertical direction; is the 3×1 convolution kernel weight; The formula for the asymmetric convolution is: ; in, is the output of the asymmetric convolution decomposition; is the sum operation of the corresponding positions; The multi-scale features of the PVC pipe are extracted by the depth-separable convolution; the multi-scale features include: surface image features and depth map features of the PVC pipe, and the specific extraction formula is: ; in, It is the multi-scale feature of PVC pipe, including the image feature of PVC pipe and depth map features ; is the 1×1 convolution output; where The formula is: ; in, is the 1×1 convolution kernel weight; The multi-scale features are fused through the multi-modal fusion layer to obtain the fused features; the multi-modal fusion layer includes: fusing the image features and the depth map features; the multi-modal fusion formula is: ; in, For fusion features; is the image feature; is the depth map feature; is the weight of the image feature; is the weight of the depth map feature; The fusion feature is reduced in dimension through the global mean pooling layer to reduce the number of parameters and obtain the reduced-dimensional feature; the specific formula of the global mean pooling is: ; in, is the feature after pooling; is the height of the input feature map; is the width of the input feature map; is the first OK The value of the column; The dimension reduction features are input into the output layer, and the confidence of each type of defect is output. The specific formula is: ; in, For Category Confidence level; For Category feature score.
[0009] Preferably, the deep learning model is trained and optimized, and the performance of the deep learning model for PVC pipe surface defect detection is evaluated; the specific training and optimization process includes: loading ImageNet pre-trained weights through transfer learning, retaining the early feature extraction layers, and only fine-tuning the latter layers to adapt to the PVC pipe surface defect classification task; Batch normalization and nonlinear activation functions are introduced to accelerate convergence; classification results are calculated through forward propagation, and the weighted cross entropy loss function is used to measure the prediction error; Then, the Adam optimizer is used for back propagation to update the parameters of the deep learning model and gradually optimize the network performance; At the end of each training cycle, the validation set is used to evaluate the model performance by calculating the accuracy and detection time; The model is continuously improved by fine-tuning parameters to ensure its generalization ability and high-precision performance in defect detection tasks.
[0010] Preferably, real-time detection and alarm are performed on the surface defects of PVC pipes. When the confidence level exceeds the set threshold, an alarm is triggered and the defect type and location are recorded, and the production process is automatically optimized in combination with production parameters.
[0011] A real-time quality management system for PVC pipes, comprising: a data acquisition module, a data preprocessing module, a deep learning model building module, a model training module, and a result evaluation and alarm module; The data acquisition module is used to collect multimodal data sets of PVC pipes in real time, including image data and geometric data, and perform data annotation; The image data includes: normal samples and defective samples; the defects include: cracks, bubbles, scratches and color difference; the geometric information includes: outer diameter, wall thickness and density distribution of PVC pipes; The data annotation includes: using an annotation tool to annotate the image data, marking defect locations and defect categories.
[0012] The collected multimodal dataset is divided into training set, validation set and test set.
[0013] Preferably, the data preprocessing module is used to preprocess the image data and the geometric data to obtain preprocessed data; the preprocessing includes: image data preprocessing and geometric data preprocessing; The image data preprocessing includes: denoising and image enhancement to obtain a preprocessed image; wherein the denoising includes: removing the noise of the industrial environment during the acquisition process; The image enhancement includes: expanding the training data set through geometric transformation, color adjustment and noise addition; wherein the geometric transformation includes: simulating defects at different angles through random rotation and horizontal flipping; the color adjustment includes: simulating different lighting conditions through random adjustment of brightness, contrast and saturation; the noise addition includes: simulating sensor interference through random addition of salt and pepper noise and Gaussian noise; The geometric data preprocessing includes: projecting the geometric data into a depth map to obtain a preprocessed depth map; The pre-processed image data and the pre-processed geometric data are temporally synchronized and spatially aligned.
[0014] Preferably, the deep learning model construction module is used to construct a deep learning model for extracting multi-scale features of PVC pipes, and performing feature fusion and dimensionality reduction; the structure of the deep learning model includes: an input layer, a depth-separable convolution layer, an asymmetric convolution layer, a multimodal fusion layer, a global mean pooling layer and an output layer; The input layer includes: inputting the preprocessed data and taking them as two independent input channels respectively; fusing the preprocessed image and the preprocessed depth map at the feature layer after they are processed by independent first several layers of convolution; the input data formula is: ; in, It is the input data of the deep learning model; is the preprocessed image; is the preprocessed depth map; The depth-wise separable asymmetric convolution layer combines depth-wise separable convolution and asymmetric convolution to extract multi-scale features. The specific process is: the parallel structure of 1×1 and 3×3 convolution kernels is introduced through the depth-wise separable convolution, and the 3×3 convolution kernel is decomposed into 1×3 and 3×1 convolutions through the asymmetric convolution. The formula of 1×3 convolution is: ; in, It is the feature in the horizontal direction; is the 1×3 convolution kernel weight; is the pixel horizontal coordinate; is the pixel ordinate; For input data in category Medium Pixels The value of is the total number of categories; The formula for 3×1 convolution is: ; in, It is a feature in the vertical direction; is the 3×1 convolution kernel weight; The formula for the asymmetric convolution is: ; in, is the output of asymmetric convolution; is the sum operation of the corresponding positions; The multi-scale features of the PVC pipe are extracted by the depth-separable convolution; the multi-scale features include: surface image features and depth map features of the PVC pipe, and the specific extraction formula is: ; in, It is the multi-scale feature of PVC pipe, including the image feature of PVC pipe and depth map features ; It is the 1×1 convolution output; in, The formula is: ; in, is the 1×1 convolution kernel weight; The multi-scale features are fused through the multi-modal fusion layer to obtain the fused features; the multi-modal fusion layer includes: fusing the image features and the depth map features; the multi-modal fusion formula is: ; in, For fusion features; is the image feature; is the depth map feature; is the weight of the image feature; is the weight of the depth map feature; The fusion feature is reduced in dimension through the global mean pooling layer to reduce the number of parameters and obtain the reduced-dimensional feature; the specific formula of the global mean pooling is: ; in, is the feature after pooling; is the height of the input feature map; is the width of the input feature map; is the first OK The value of the column; The dimension reduction features are input into the output layer, and the confidence of each type of defect is output. The specific formula is: ; in, For Category Confidence level; For Category feature score.
[0015] Preferably, the model training module and the evaluation module are used to train and optimize the deep learning model and evaluate the performance of the deep learning model for PVC pipe surface defect detection; the specific optimization and training steps include: loading the ImageNet pre-trained weights through transfer learning, retaining the early feature extraction layers, and only fine-tuning the latter layers to adapt to the PVC pipe surface defect classification task; Batch normalization and nonlinear activation functions are introduced to accelerate convergence; classification results are calculated through forward propagation, and the weighted cross entropy loss function is used to measure the prediction error; Then, the Adam optimizer is used for back propagation to update the parameters of the deep learning model and gradually optimize the network performance; At the end of each training cycle, the model performance is evaluated by calculating the accuracy and detection speed using the validation set; The model is continuously improved by fine-tuning parameters to ensure its generalization ability and high-precision performance in defect detection tasks.
[0016] Preferably, the alarm module is used to perform real-time detection and alarm on surface defects of PVC pipes. When the confidence level exceeds a set threshold, an alarm is triggered and the defect type and location are recorded, and the production process is automatically optimized in combination with production parameters.
[0017] Compared with the prior art, the present invention has the following beneficial effects: 1. The present invention uses image enhancement operations to expand the diversity of data sets, simulates the acquisition conditions at different angles and positions in real production through geometric transformation, and improves the adaptability of deep learning models to spatial transformation; simulates surface characteristics under different lighting conditions through color adjustment, so that the model has better fault tolerance to changes in ambient light. In addition, the model is also enhanced to be robust to interference signals that may exist in the acquisition process by adding random noise, providing a diverse data set for the subsequent real-time detection of surface defects of PVC pipes through the deep learning model, thereby laying a foundation for improving the detection accuracy and comprehensiveness of the deep learning model in actual industrial scenarios.
[0018] 2. The present invention proposes a deep learning model, which combines image data and geometric data through a deep separable convolution layer and multimodal data fusion technology, and can accurately extract multi-scale features of the surface of PVC pipes, and adapt to various defect types such as cracks, bubbles, scratches, etc.; the deep separable convolution module extracts features of different scales and complex textures on the surface of PVC pipes through 1×1 and 3×3 convolution kernels, and effectively copes with diverse defect types; the multimodal fusion combines image data and geometric data to make up for the possible deficiencies of a single data mode, especially for tiny cracks and hidden defects. It has better recognition ability, improves the accuracy of defect detection, and provides diversified features for deep learning models to detect surface defects of PVC pipes, so as to improve detection efficiency.
[0019] 3. The present invention reduces convolution parameters by combining asymmetric convolution and global mean pooling technology. The asymmetric convolution decomposes the standard 3×3 convolution into a combination of 1×3 and 3×1 operations, reducing the computational complexity and the number of parameters while maintaining the same receptive field, thereby improving the feature extraction capability. At the same time, the global mean pooling replaces the fully connected layer with an efficient global information compression method, removes a large number of parameters in the fully connected layer, and averages the values of the entire feature map, further reducing the number of parameters and reducing the risk of overfitting. The combination of asymmetric convolution and global mean pooling can maintain the lightweight of the deep learning model while achieving efficient extraction, thereby improving the detection speed of the model, thereby realizing real-time detection of surface defects and improving detection efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 A flow chart of a real-time quality management method for PVC pipes provided by an embodiment of the present invention; Figure 2 A structural diagram of a real-time quality management method for PVC pipes provided by an embodiment of the present invention; Figure 3 A deep learning model diagram provided by an embodiment of the present invention; Figure 4This is a graph showing the detection results of scratch defects on the surface of a PVC pipe provided by an embodiment of the present invention; Figure 5 A diagram showing the detection results of bubble defects on the surface of a PVC pipe provided by an embodiment of the present invention; Figure 6 A diagram showing the detection results of color difference defects on the surface of a PVC pipe provided by an embodiment of the present invention; Figure 7 This is a diagram showing the detection results of crack defects on the surface of a PVC pipe provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0021] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0022] PVC pipes are important materials widely used in the fields of construction, drainage and communications. Their quality directly affects the pressure resistance and corrosion resistance of PVC pipes. In severe cases, they may cause leakage, rupture and shortened life of the pipes during use, endangering project safety and user experience. By real-time monitoring of key indicators in the production process, potential problems can be discovered in a timely manner, unqualified products can be prevented from entering the market, and the cost of subsequent maintenance and replacement can be reduced. In addition, real-time management can also optimize production processes, reduce resource waste, and improve production efficiency, thereby enhancing corporate competitiveness and meeting the requirements of intelligent manufacturing and high-quality development.
[0023] The present invention proposes a real-time quality management method for PVC pipes, which realizes real-time monitoring of surface defects of PVC pipes. This method is applied to a real-time quality management system for PVC pipes. The flowchart of the specific method and system is shown in Figure 1 and Figure 2 In order to illustrate that the method and system of the present invention can play a role in real-time detection of surface defects of PVC pipes, the effectiveness of the present invention will be described in two embodiments below.
[0024] Embodiment 1 In the specific implementation process of this embodiment, the method of the present invention is implemented by a specific system module. Figure 1The specific steps of the method proposed in the present invention are described in detail; the specific steps include: S10. real-time acquisition of multimodal data sets of PVC pipes and data annotation; S20. preprocessing the acquired multimodal data sets to obtain preprocessed data; S30. building a deep learning model, extracting multi-scale features from the preprocessed data using deep separable convolution and asymmetric convolution, and reducing deep learning model parameters; S40. fusing the extracted multi-scale features using multimodal fusion, and combining with global mean pooling for feature dimensionality reduction; S50. training the deep learning model and evaluating its defect detection performance; S60. triggering an alarm operation and recording the defect category and location when it is detected that the confidence exceeds the set threshold.
[0025] The data of the present invention is provided by Figure 2 The data acquisition module in the system collects data by using a high-resolution industrial camera and a laser scanner, corresponding to the above step S10; the data includes image data and geometric data; Two high-resolution industrial cameras with a pixel size greater than 5 million are arranged at 45° and 90° above the production line to ensure that the entire surface area of the PVC pipe is covered for identifying dominant defects; the surface image of the PVC pipe is collected in real time, and the image data is obtained by continuous shooting at a rate of 30 frames per second; the image data includes: 1,000 defect samples and 1,000 normal samples; the defect samples include: 250 crack defect samples, 250 bubble defect samples, 250 scratch defect samples and 250 color difference defect samples; the quality of the collected images is checked, and blurred, out-of-focus and / or overexposed images are removed; A laser scanner is arranged behind the industrial camera perpendicular to the surface of the pipe to detect hidden defects such as geometric deformation and internal bubbles; the laser scanner is used to collect depth information on the surface of the PVC pipe to assist in analyzing structural defects and obtain the geometric data; the geometric data includes: the outer diameter, wall thickness and density distribution of the PVC pipe; Using a Labelling annotation tool to mark the category of the defect in the image data, and using a rectangular frame to mark the specific location of the defect; All collected data sets are divided into 70% as training sets for model training, including normal samples and defective samples; 20% as validation sets for adjusting the hyperparameters of the deep learning model; and 10% as test sets for evaluating the performance of the deep learning model for surface defect detection of PVC pipes.
[0026] The embodiment of the present application utilizes a data acquisition unit to collect a multimodal data set of the surface of a PVC pipe through a high-resolution industrial camera and a laser scanner, including tiny surface defects and precise geometric shapes of the PVC pipe; the image features and geometric features of the PVC pipe are complemented by multimodal data fusion, effectively improving the problem of missing depth information of the PVC pipe in a single image data, and avoiding false detection and missed detection caused by factors such as illumination changes and reflections; a surface defect detection model for PVC pipes is constructed and trained using a multimodal data set, which can not only enhance the model's ability to classify and detect complex defects and irregular surfaces on the surface of PVC pipes, but also accurately locate tiny defects, providing more reliable data support and technical guarantees for the intelligent management of PVC pipes.
[0027] Preferably, by Figure 2 The data preprocessing module in the system preprocesses the image data and the geometric data, corresponding to the above step S20, to obtain preprocessed data; the preprocessing includes: image data preprocessing and geometric data preprocessing; The image data preprocessing includes: denoising and image enhancement to obtain a preprocessed image; wherein the denoising includes: using Gaussian filtering and median filtering to remove noise interference in the industrial environment; The image enhancement includes: expanding the training data set through geometric transformation, color adjustment and noise addition; wherein the geometric transformation includes: simulating defects at different angles through random rotation and horizontal flipping; the color adjustment includes: simulating different lighting conditions through random adjustment of brightness, contrast and saturation; the noise addition includes: simulating sensor interference through random addition of salt and pepper noise and Gaussian noise; The geometric data preprocessing includes: projecting the geometric data into a depth map, adjusting the resolution of the depth map to be consistent with the resolution of the image data, and filling the sparse area using linear interpolation to obtain a preprocessed depth map; The preprocessed image and the preprocessed depth map are time-synchronized using a timestamp; based on a camera calibration matrix, the preprocessed image and the preprocessed depth map are mapped to the same coordinate system for spatial alignment.
[0028] The embodiment of the present application performs preprocessing operations on the collected multimodal data through a data preprocessing module to obtain preprocessed data; through denoising, image enhancement and multimodal data alignment, it is possible to remove invalid data and noise interfered by noise in the industrial environment during data collection, improve the quality of the multimodal data set, and solve the problem of false detection in complex industrial environments; these high-quality data sets provide an important foundation for the subsequent construction of a PVC pipe surface defect detection model, which helps to improve the defect detection capability and efficiency of the model in industrial scenes with insufficient light or significant curved surface features.
[0029] Preferably, by Figure 2 The deep learning model building module in the system builds a deep learning model for extracting multi-scale features of PVC pipes, and performs feature fusion and dimensionality reduction, corresponding to the above step S30; the structure of the deep learning model can be found in Figure 3 , including: input layer, depth-wise separable asymmetric convolution layer, multimodal fusion layer, global mean pooling layer and output layer; The input layer includes: inputting the preprocessed data and taking them as two independent input channels respectively; fusing the preprocessed image data and the preprocessed depth map at the feature layer after the preprocessed image data and the preprocessed depth map are processed by independent first several layers of convolution; the input data formula is: ; in, It is the input data of the deep learning model; is the preprocessed image; is the preprocessed depth map; The depth-wise separable asymmetric convolution layer combines depth-wise separable convolution and asymmetric convolution to extract multi-scale features. The specific process is: the parallel structure of 1×1 and 3×3 convolution kernels is introduced through the depth-wise separable convolution, and the 3×3 convolution kernel is decomposed into 1×3 and 3×1 convolutions through the asymmetric convolution. The formula of 1×3 convolution is: ; in, It is the feature in the horizontal direction; is the 1×3 convolution kernel weight; is the pixel horizontal coordinate; is the pixel ordinate; For input data in category Medium Pixels The value of is the total number of categories; The formula for 3×1 convolution is: ; in, It is a feature in the vertical direction; is the 3×1 convolution kernel weight; The formula for the asymmetric convolution is: ; in, is the output of the asymmetric convolution decomposition; is the sum operation of the corresponding positions; The multi-scale features of the PVC pipe are extracted by the depth-separable convolution; the multi-scale features include: surface image features and depth map features of the PVC pipe, and the specific extraction formula is: ; in, It is the multi-scale feature of PVC pipe, including the image feature of PVC pipe and depth map features ; It is the 1×1 convolution output; in, The formula is: ; in, is the 1×1 convolution kernel weight; The multi-scale features are fused through the multi-modal fusion layer to obtain the fused features; the multi-modal fusion layer includes: fusing the image features and the depth map features; the multi-modal fusion formula is: ; in, For fusion features; is the image feature; is the depth map feature; is the weight of the image feature; is the weight of the depth map feature; The fusion feature is reduced in dimension through the global mean pooling layer to reduce the number of parameters and obtain the reduced-dimensional feature; the specific formula of the global mean pooling is: ; in, is the feature after pooling; is the height of the input feature map; is the width of the input feature map; is the first OK The value of the column; The dimension reduction features are input into the output layer, and the confidence of each type of defect is output. The specific formula is: ; in, For Category Confidence level; For Category feature score.
[0030] The embodiment of the present application constructs a deep learning model, and for various surface defects such as cracks, bubbles, scratches and chromatic aberrations, multi-scale feature extraction, feature fusion and feature dimension reduction are performed on the multi-modal data of PVC pipes through a deep separable asymmetric convolution layer, a multi-modal fusion layer and a global mean pooling layer, thereby ensuring the ability to recognize subtle and complex defects on the surface of PVC pipes, while reducing the dimension of the features and retaining the effective global information of the multi-scale features of PVC pipes; using this model to detect surface defects of PVC pipes can speed up the detection speed of the model, making it more suitable for actual industrial scenarios of high-speed production, and also overcome the problem of missed detection that may be caused by single image data, thereby comprehensively improving the model's quality management efficiency for PVC pipes, please refer to Table 1.
[0031] Table 1 compares the performance of the deep learning model proposed in the present invention with other defect detection models for PVC pipes in terms of model size, real-time performance, complex defect handling capability, and applicable scenarios.
[0032] Table 1 Performance comparison of the model of the present invention and other models
[0033] From the comparison in Table 1, it can be seen that the model proposed in the present invention, under the joint action of the deep separable asymmetric convolution layer, the multimodal fusion layer and the global mean pooling layer, greatly reduces the model size, improves the automatic processing capability of complex defects, makes the calculation and detection of the model more efficient, and can meet the real-time detection requirements of high-speed production lines.
[0034] Preferably, by Figure 2 The model training and evaluation module in the system trains and optimizes the deep learning model, and evaluates the performance of the deep learning model for PVC pipe surface defect detection. Corresponding to the above step S50, the specific optimization and training steps include: loading the ImageNet pre-trained weights through transfer learning, retaining the early feature extraction layers, and only fine-tuning the latter layers to adapt to the PVC pipe surface defect classification task; Batch normalization and nonlinear activation functions are introduced to accelerate convergence; classification results are calculated through forward propagation, and the weighted cross entropy loss function is used to measure the prediction error; Then, the Adam optimizer is used for back propagation to update the parameters of the deep learning model and gradually optimize the network performance; At the end of each training cycle, the performance of the deep learning model is evaluated by calculating the accuracy and detection time using the validation set; the specific defect detection results are shown in Table 2; The model is continuously improved by fine-tuning parameters to ensure its generalization ability and high-precision performance in defect detection tasks.
[0035] For specific scratch defect detection results, please refer to Figure 4 ; For specific bubble defect detection results, please refer to Figure 5 ; For specific color difference defect detection results, please refer to Figure 6 ; For specific crack defect detection results, please refer to Figure 7 .
[0036] Table 2 PVC pipe surface defect detection results
[0037] It can be seen from Table 2 that the confidence level of most results exceeds 85%, indicating that the deep learning model has high detection accuracy. The test results show that cracks are mainly distributed in the center, which may be related to the extrusion process of PVC pipes. Bubbles are mainly distributed in the edge area, and scratches are mainly concentrated in the area affected by mechanical friction. At the same time, it can be seen from the results that the single-frame detection takes about 36-64ms, which meets the actual real-time detection requirements of industry.
[0038] In order to prove the real-time and accuracy of the deep learning model used in the present invention for detecting surface defects of PVC pipes, the PVC surface defect detection results of the deep learning model of the present invention are compared with other models with the same function, see Table 3.
[0039] Table 3 Performance comparison of different models for PVC pipe surface defect detection
[0040] It can be seen from Table 3 that the deep learning model proposed in the present invention is superior to other models for surface defect detection of PVC pipes in terms of accuracy and real-time performance of surface defect detection, especially in terms of real-time performance, and is suitable for high-precision and high-speed industrial quality management scenarios; at the same time, the deep learning model proposed in the present invention further enhances the robustness to complex surface textures and changes in lighting conditions by fusing multimodal data features.
[0041] The embodiment of the present application uses a weighted cross entropy loss function and a transfer learning strategy to significantly reduce the computational complexity and number of parameters while ensuring the detection accuracy of the model. It can achieve efficient real-time detection of surface defects of PVC pipes in resource-constrained industrial scenarios, provide a fast and reliable quality control tool for production lines, and enhance the robustness and generalization ability of the model to complex defects.
[0042] Preferably, by Figure 2 The alarm module in the system detects and alarms the surface defects of the PVC pipe, corresponding to the above-mentioned step S60; when the confidence level exceeds the set threshold, the alarm is triggered and the defect type and location are recorded, and the production process is automatically optimized in combination with the production parameters.
[0043] The embodiment of the present application performs real-time quality management of the surface defects of PVC pipes through the deep learning model proposed by the present invention. By combining the image data and geometric data of PVC pipes to form a multimodal data set, the problems of false detection and missed detection caused by the lack of depth information of PVC pipes in single image data are improved; by annotating the data of the multimodal data set, the type and location of the surface defects of PVC pipes are marked, which is used for the subsequent construction of a deep learning model to detect the type and location of surface defects of PVC pipes. This can not only enhance the model's classification and detection capabilities for surface defects of PVC pipes, but also accurately locate tiny defects, so that workers can quickly perform corresponding processing and optimization operations according to the type and location of defects during the production and use of PVC pipes; by preprocessing the collected multimodal data of PVC pipes, removing invalid data and noise interfered by noise in the industrial environment during data collection, and improving the quality of the multimodal data set, it can provide a high-quality data foundation for the subsequent construction and training of surface defect detection models for PVC pipes, and improve The model's defect detection capability and efficiency in complex industrial scenarios such as insufficient light or significant surface features; by constructing a deep learning model to extract multi-scale features (image features and depth map features) of PVC pipes and perform feature fusion and dimensionality reduction. The fusion and dimensionality reduction of these multi-scale features reduce the computational complexity of model feature extraction while ensuring the comprehensiveness of the model's recognition of surface defects of PVC pipes, thereby further accelerating the model's defect detection speed and improving the ability to recognize subtle and complex defects on the surface of PVC pipes, making it more suitable for actual industrial scenarios of high-speed production lines; finally, the alarm module monitors PVC surface defects in real time, and triggers an alarm when the confidence level of the detected defect exceeds the set threshold, so that workers can promptly discover and control the quality problem of surface defects, greatly reducing the possibility of leakage, rupture, and shortened life of PVC pipes during daily use, thereby ensuring engineering safety and user experience.
[0044] Embodiment 2 In Example 1, the method of the present invention is combined with the system to achieve real-time management of surface defects of PVC pipes. The method proposed by the present invention will be described again in the examples of this application.
[0045] In the embodiment of the present application, real-time detection of surface defects of PVC pipes in the multimodal dataset B is achieved, and the specific process includes: The multimodal data set of the present invention is collected by using a high-resolution industrial camera and a laser scanner, corresponding to the above-mentioned step S10; the data includes image data and geometric data; The surface image of the PVC pipe is collected in real time, and the image data is obtained by continuously shooting at a rate of 30 frames per second; the image data includes: 1000 defect samples and 1000 normal samples; the defect samples include: 250 crack defect samples, 250 bubble defect samples, 250 scratch defect samples and 250 color difference defect samples; the quality of the collected image is checked, and blurred, out-of-focus and / or overexposed images are removed; Using a laser scanner to collect depth information on the surface of the PVC pipe to assist in analyzing structural defects, and obtain the geometric data; the geometric data includes: the outer diameter, wall thickness and density distribution of the PVC pipe; Using a Labelling annotation tool to mark the category of the defect in the image data, and using a rectangular frame to mark the specific location of the defect; All collected data sets are divided into 70% as training sets for model training, including normal samples and defective samples; 20% as validation sets for adjusting the hyperparameters of deep learning models; and 10% as test sets for evaluating the performance of deep learning models.
[0046] Preferably, the image data and the geometric data are preprocessed, corresponding to the above step S20, to obtain preprocessed data; the preprocessing includes: image data preprocessing and geometric data preprocessing; The image data preprocessing includes: denoising and image enhancement to obtain a preprocessed image; wherein the denoising includes: using Gaussian filtering and median filtering to remove noise interference in the industrial environment; The image enhancement includes: expanding the training data set through geometric transformation, color adjustment and noise addition; wherein the geometric transformation includes: simulating defects at different angles through random rotation and horizontal flipping; the color adjustment includes: simulating different lighting conditions through random adjustment of brightness, contrast and saturation; the noise addition includes: simulating sensor interference through random addition of salt and pepper noise and Gaussian noise; The geometric data preprocessing includes: projecting the geometric data into a depth map, adjusting the resolution of the depth map to be consistent with the resolution of the image data, and filling the sparse area using linear interpolation to obtain a preprocessed depth map; The preprocessed image and the preprocessed depth map are time-synchronized using a timestamp; based on a camera calibration matrix, the preprocessed image and the preprocessed depth map are mapped to the same coordinate system for spatial alignment.
[0047] Preferably, a deep learning model is constructed to extract multi-scale features of PVC pipes, and feature fusion and dimensionality reduction are performed, corresponding to the above step S30; the structure of the deep learning model can be found in Figure 3, including: input layer, depth-wise separable asymmetric convolution layer, multimodal fusion layer, global mean pooling layer and output layer; The input layer includes: inputting the preprocessed data and taking them as two independent input channels respectively; fusing the preprocessed image data and the preprocessed depth map at the feature layer after the preprocessed image data and the preprocessed depth map are processed by independent first several layers of convolution; the input data formula is: ; in, It is the input data of the deep learning model; is the preprocessed image; is the preprocessed depth map; The depth-wise separable asymmetric convolution layer combines depth-wise separable convolution and asymmetric convolution to extract multi-scale features. The specific process is: the parallel structure of 1×1 and 3×3 convolution kernels is introduced through the depth-wise separable convolution, and the 3×3 convolution kernel is decomposed into 1×3 and 3×1 convolutions through the asymmetric convolution. The formula of 1×3 convolution is: ; in, It is the feature in the horizontal direction; is the 1×3 convolution kernel weight; is the pixel horizontal coordinate; is the pixel ordinate; For input data in category Medium Pixels The value of is the total number of categories; The formula for 3×1 convolution is: ; in, It is a feature in the vertical direction; is the 3×1 convolution kernel weight; The formula for the asymmetric convolution is: ; in, is the output of the asymmetric convolution decomposition; is the sum operation of the corresponding positions; The multi-scale features of the PVC pipe are extracted by the depth-separable convolution; the multi-scale features include: surface image features and depth map features of the PVC pipe, and the specific extraction formula is: ; in, It is the multi-scale feature of PVC pipe, including the image feature of PVC pipe and depth map features ; It is the 1×1 convolution output; in, The formula is: ; in, is the 1×1 convolution kernel weight; The multi-scale features are fused through the multi-modal fusion layer to obtain the fused features; the multi-modal fusion layer includes: fusing the image features and the depth map features; the multi-modal fusion formula is: ; in, For fusion features; is the image feature; is the depth map feature; is the weight of the image feature; is the weight of the depth map feature; The fusion feature is reduced in dimension through the global mean pooling layer to reduce the number of parameters and obtain the reduced-dimensional feature; the specific formula of the global mean pooling is: ; in, is the feature after pooling; is the height of the input feature map; is the width of the input feature map; is the first OK The value of the column; The dimension reduction features are input into the output layer, and the confidence of each type of defect is output. The specific formula is: ; in, For Category Confidence level; For Category feature score.
[0048] Preferably, the deep learning model is trained and optimized, and the performance of the deep learning model for PVC pipe surface defect detection is evaluated. Corresponding to the above step S50, the specific optimization and training steps include: loading the ImageNet pre-trained weights through transfer learning, retaining the early feature extraction layers, and only fine-tuning the latter layers to adapt to the PVC pipe surface defect classification task; Batch normalization and nonlinear activation functions are introduced to accelerate convergence; classification results are calculated through forward propagation, and the weighted cross entropy loss function is used to measure the prediction error; Then, the Adam optimizer is used for back propagation to update the parameters of the deep learning model and gradually optimize the network performance; At the end of each training cycle, the validation set is used to evaluate the model performance by calculating the accuracy and detection speed. The specific defect detection results for the multimodal dataset B are shown in Table 4. The model is continuously improved by fine-tuning parameters to ensure its generalization ability and high-precision performance in defect detection tasks.
[0049] Table 4 PVC pipe surface defect detection results
[0050] The confidence results of the multimodal dataset B of PVC pipes in Table 4 once again show that the deep learning model of the present invention has high detection accuracy; at the same time, the single-frame detection time is about 35-65ms, which meets the actual real-time detection requirements of industry.
[0051] In order to prove the real-time and accuracy of the deep learning model used in the present invention for detecting surface defects of PVC pipes, the PVC surface defect detection results of the deep learning model of the present invention are compared with other models with the same function, see Table 5.
[0052] Table 5 Performance comparison of different models for PVC pipe surface defect detection
[0053] It can be seen from Table 5 that the deep learning model proposed in the present invention is also superior to other models for surface defect detection of PVC pipes in terms of accuracy and real-time performance of surface defect detection for multimodal dataset B.
[0054] Preferably, by Figure 2 The alarm module in the system detects surface defects of PVC pipes and issues an alarm, corresponding to the above step S60; when the confidence level exceeds the set threshold, an alarm is triggered and the defect type and location are recorded, and the production process is automatically optimized in combination with production parameters.
[0055] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.
Claims
1. A real-time quality management method for PVC pipes, characterized in that: include: Real-time acquisition of multimodal data sets of PVC pipes, including image data and geometric data, and data annotation; Preprocessing the multimodal data set to obtain preprocessed data; A deep learning model is constructed to extract the multi-scale features of PVC pipes, and feature fusion and dimensionality reduction are performed. The multi-scale features of PVC pipes are extracted by combining the depth-separable asymmetric convolution layer with the depth-separable convolution and asymmetric convolution. The specific process is as follows: the parallel structure of 1×1 and 3×3 convolution kernels is introduced through the depth-separable convolution, and the 3×3 convolution kernel is decomposed into 1×3 and 3×1 convolutions through asymmetric convolution. The asymmetric convolution formula is: ; in, is the output of asymmetric convolution; is the sum operation of the corresponding positions; It is the feature in the horizontal direction; It is a feature in the vertical direction; The multi-scale features of the PVC pipe are extracted by the depth-separable convolution; the multi-scale features include: surface image features and depth map features of the PVC pipe, and the specific extraction formula is: ; in, It is the multi-scale characteristics of PVC pipe; It is the 1×1 convolution output; The multi-scale features are fused through a multimodal fusion layer to obtain fused features; the fused features are reduced in dimension through a global mean pooling layer to obtain reduced-dimensional features; and the confidence of each type of defect is output through an output layer; Training and optimizing the deep learning model through a weighted cross entropy loss function and evaluating its defect detection performance; Real-time detection and alarm of surface defects of PVC pipes can be carried out to optimize the production process of PVC pipes.
2. A real-time quality management method for PVC pipes according to claim 1, characterized in that: The image data includes: normal samples and defective samples; the defects include: cracks, bubbles, scratches and color difference; the geometric data includes: outer diameter, wall thickness and density distribution of PVC pipes; The data annotation includes: using an annotation tool to annotate the image data to mark the defect location and defect type.
3. A real-time quality management method for PVC pipes according to claim 1, characterized in that: The preprocessing includes: image data preprocessing and geometric data preprocessing; wherein, the image data preprocessing includes: denoising and image enhancement to obtain a preprocessed image; wherein, the denoising includes: removing noise from the industrial environment during the acquisition process; The image enhancement includes: expanding the training data set by random geometric transformation, color adjustment and noise addition to obtain a preprocessed image; wherein the geometric transformation includes: simulating defects at different angles by random rotation and horizontal flipping; the color adjustment includes: simulating different lighting conditions by randomly adjusting brightness, contrast and saturation; the noise addition includes: simulating sensor interference by randomly adding salt and pepper noise and Gaussian noise; The geometric data preprocessing includes: projecting the geometric data into a depth map to obtain a preprocessed depth map; The preprocessed image and the preprocessed depth map are temporally synchronized and spatially aligned.
4. A real-time quality management method for PVC pipes according to claim 1, characterized in that: The deep learning model includes: an input layer, a depth-separable asymmetric convolution layer, a multimodal fusion layer, a global mean pooling layer and an output layer; the input layer is used to input the preprocessed data as two independent input channels respectively; The depth-wise separable asymmetric convolution layer combines depth-wise separable convolution and asymmetric convolution. The specific process is: using depth-wise separable convolution to introduce 1×1 and 3×3 convolution kernels, and decomposing the 3×3 convolution into 1×3 and 3×1 convolutions through asymmetric convolution; the decomposition formula of the asymmetric convolution is: ; in, is the output of asymmetric convolution; is the sum operation of the corresponding positions; It is the feature in the horizontal direction; It is a feature in the vertical direction; The multi-scale features of the PVC pipe are extracted by the depth-separable convolution; the multi-scale features include: surface image features and depth map features of the PVC pipe, and the specific extraction formula is: ; in, It is the multi-scale feature of PVC pipe, including the image feature of PVC pipe and depth map features ; It is the 1×1 convolution output; The multi-scale features are fused through the multi-modal fusion layer to obtain the fused features; the specific formula is: ; in, For fusion features; is the image feature; is the depth map feature; is the weight of the image feature; is the weight of the depth map feature; Performing feature dimensionality reduction on the fused features through the global mean pooling layer to obtain reduced dimensionality features; The dimension reduction features are input into the output layer, and the confidence of each type of defect is output.
5. A real-time quality management method for PVC pipes according to claim 1, characterized in that: The training and optimization of the deep learning model include: loading ImageNet pre-trained weights through transfer learning, retaining the early feature extraction layers, and only fine-tuning the latter layers to adapt to the PVC pipe surface defect classification task; introducing batch normalization and nonlinear activation functions to accelerate convergence; calculating the classification results through forward propagation, and using a weighted cross entropy loss function to measure the prediction error.
6. A real-time quality management system for PVC pipes, characterized in that: include: Data acquisition module, used to collect multimodal data sets of PVC pipes in real time, including image data and geometric data, and perform data annotation; A data preprocessing module, used to preprocess the multimodal data set to obtain preprocessed data; Deep learning model building module, used to build a deep learning model to extract multi-scale features of PVC pipes, and perform feature fusion and dimensionality reduction; The preprocessed data is input as two independent input channels through the input layer; the multi-scale feature extraction of PVC pipes is performed by combining the depth-separable asymmetric convolution layer with the depth-separable convolution and the asymmetric convolution. The specific process is: the parallel structure of 1×1 and 3×3 convolution kernels is introduced through the depth-separable convolution, and the 3×3 convolution kernel is decomposed into 1×3 and 3×1 convolution through asymmetric convolution; the asymmetric convolution formula is: ; in, is the output of asymmetric convolution; is the sum operation of the corresponding positions; It is the feature in the horizontal direction; It is a feature in the vertical direction; The multi-scale features of the PVC pipe are extracted by the depth-separable convolution; the multi-scale features include: surface image features and depth map features of the PVC pipe, and the specific extraction formula is: ; in, It is the multi-scale characteristics of PVC pipe; It is the 1×1 convolution output; The multi-scale features are fused through a multimodal fusion layer to obtain fused features; the fused features are reduced in dimension through a global mean pooling layer to obtain reduced-dimensional features; and the confidence of each type of defect is output through an output layer; A model training and evaluation module, for training and optimizing the deep learning model through a weighted cross entropy loss function, and evaluating its defect detection performance for PVC pipes; The alarm module is used to monitor and alarm the surface defects of PVC pipes in real time and optimize the production process of PVC pipes.
7. A real-time quality management system for PVC pipes according to claim 6, characterized in that: The image data includes: normal samples and defective samples; the geometric data includes: outer diameter, wall thickness and density distribution of PVC pipes; The data annotation includes: using an annotation tool to annotate the image data to mark the defect location and defect type.
8. A real-time quality management system for PVC pipes according to claim 6, characterized in that: The preprocessing includes: image data preprocessing and geometric data preprocessing to obtain a preprocessed image and a preprocessed depth map.
9. A real-time quality management system for PVC pipes according to claim 6, characterized in that: The deep learning model construction includes: an input layer, a depth-separable asymmetric convolution layer, a multimodal fusion layer, a global mean pooling layer and an output layer.
10. A real-time quality management system for PVC pipes according to claim 6, characterized in that: The training and optimization of the deep learning model include: loading ImageNet pre-trained weights through transfer learning, retaining the early feature extraction layers, and only fine-tuning the latter layers to adapt to the PVC pipe surface defect classification task; introducing batch normalization and nonlinear activation functions to accelerate convergence; calculating the classification results through forward propagation, and using a weighted cross entropy loss function to measure the prediction error.
Citation Information
Patent Citations
Steel rail tread defect recognition method based on combination of gray image and depth image
CN108921846A
Industrial product defect image classification method based on lightweight deep neural network
CN110660046A
Electric power metering box three-dimensional appearance defect detection method and device based on visible light image depth estimation
CN118096518A
Cited By
Wire harness crimping defect detection system and method based on machine vision
CN119880937A
A wire harness crimping defect detection system and method based on machine vision
CN119880937B
Intelligent PE pipe manufacturing whole process digital management system and method
CN120387741A
PVC sizing material defect detection method based on AI visual identification and intelligent sorting system
CN121661057A
PVC adhesive defect detection method based on AI visual recognition and intelligent sorting system
CN121661057B