A method and system for online detection of copper wire quality
By constructing a thermal map of copper wire surface reflection and adjusting light source parameters, combined with a copper wire defect detection model, the detection error problem caused by high surface reflection of copper wire was solved, and high-precision copper wire quality detection was achieved.
Patent Information
- Application Number
- CN202510543068.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-28
- Publication Date
- 2025-10-28
- Estimated Expiration
- 2045-04-28
AI Technical Summary
Traditional copper wire quality inspection methods suffer from high false alarm rates and low accuracy when identifying defects in images due to the high reflectivity of the copper wire surface, making it difficult to achieve real-time, high-precision defect identification.
By constructing a reflection thermal map using point cloud data of the copper wire surface and light source feature sequence data, adjusting the light source parameters, and combining this with a copper wire defect detection model, the impact of high reflection is reduced, thereby improving detection accuracy.
This effectively reduces the impact of high surface reflectivity of copper wire on image recognition, improving the accuracy and efficiency of copper wire quality inspection.
Smart Images

Figure CN120369742B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of online inspection technology, specifically to an online inspection method and system for copper wire quality. Background Technology
[0002] Copper wire, a crucial material in the electronics, power, and communications industries, directly impacts product performance and reliability. Therefore, online inspection technology plays a vital role in modern manufacturing. Traditional copper wire quality inspection methods primarily rely on machine vision systems, identifying surface defects such as scratches, cracks, or unevenness through image acquisition and processing. However, the highly reflective nature of copper wire surfaces causes strong specular reflection and scattering of light, significantly affecting defect recognition. Specifically, high reflectivity introduces glare, shadows, and reflection noise into images, interfering with the accuracy of feature extraction algorithms. For example, edge detection and texture analysis algorithms struggle to distinguish between real defects and reflection effects, increasing false alarm rates and reducing defect detection precision. Furthermore, reflection interference can lead to image distortion or information loss, especially in dynamic production line environments where changing light sources amplify these problems, resulting in low inspection efficiency and increased risk of misjudgment. Existing technologies, such as vision systems based on a single light source or simple filtering algorithms, while partially mitigating reflection issues, still cannot achieve real-time, high-precision defect identification, ultimately hindering overall production line efficiency and product quality control. Summary of the Invention
[0003] This invention collects point cloud data of the copper wire surface entering the detection area, as well as light intensity and angle data of the light source, to construct a light source feature sequence. Then, a copper wire reflection intensity prediction model is used to process the copper wire surface point cloud data and the light source feature sequence data to construct a copper wire surface reflection heat map. This predicts the reflection intensity distribution on the copper wire surface and adjusts the light source parameters based on the copper wire surface reflection heat map to reduce the impact of high copper wire surface reflection on image recognition. Furthermore, based on the copper wire surface reflection heat map and a copper wire defect detection model, image recognition is performed on the copper wire surface image to detect the copper wire quality. The copper wire surface reflection heat map can serve as prior knowledge to provide a reference for subsequent copper wire image recognition, improving the accuracy of copper wire quality detection.
[0004] This invention provides an online method for detecting the quality of copper wire, comprising:
[0005] Acquire point cloud data of the copper wire surface, acquire light intensity data and light angle data of the light source at the light source, and combine the light source feature data corresponding to the current timestamp with the light source feature data corresponding to the previous N-1 timestamps to form light source feature sequence data;
[0006] The point cloud data of the copper wire surface and the light source feature sequence data are fed into the copper wire reflection intensity prediction model for processing, and the reflection thermal map of the copper wire surface is output.
[0007] A scheme for adjusting the light source parameters is constructed based on the thermal reflection map of the copper wire surface, and the light source is adjusted based on the scheme.
[0008] After adjusting the light source through the light source parameter adjustment scheme, the surface of the copper wire is imaged to obtain the surface image of the copper wire. Then, the surface image of the copper wire and the thermal reflection map of the copper wire surface are sent into the copper wire defect detection model for processing to obtain the copper wire defect information.
[0009] The copper wire reflection intensity prediction model includes a spatial feature extraction layer, a light source temporal feature extraction layer, a feature stitching layer, and a reflection prediction layer. The spatial feature extraction layer processes the copper wire surface point cloud data to construct copper wire surface feature data; the light source temporal feature extraction layer performs temporal analysis on the light source feature sequence data to construct light source temporal feature data; the feature stitching layer stitches the copper wire surface feature data and the light source temporal feature data together to construct a copper wire reflection intensity analysis vector; and the reflection prediction layer performs deconvolution on the copper wire reflection intensity analysis vector to construct a copper wire surface reflection heatmap.
[0010] As a preferred aspect, the copper wire surface image and the copper wire surface reflection thermal map are fed into the copper wire defect detection model for processing to obtain copper wire defect information, specifically including the following:
[0011] The copper wire defect detection model includes a defect enhancement layer and a defect detection layer. The defect enhancement layer is used to perform a self-attention mechanism operation on the copper wire surface image based on the copper wire surface reflection thermal map to construct an enhanced copper wire surface image. The defect detection layer is built based on the YOLOv5 model and is used to process the enhanced copper wire surface image to output copper wire defect information.
[0012] The enhancement layer performs a self-attention mechanism operation on the copper wire surface image based on the copper wire surface reflection heatmap to construct an enhanced copper wire surface image. Specifically, this includes: performing matrix multiplication operations on the copper wire surface image with the value weight matrix and the bond weight matrix respectively to construct the corresponding copper wire image value vector V and copper wire surface bond vector K; performing matrix multiplication operations on the copper wire surface reflection heatmap with the query weight matrix to construct the copper wire surface query vector Q; and implementing the self-attention mechanism operation using the following formula: G = softmax(QK). T / D 0.5 )V, where G is the copper wire surface enhancement image, T is the matrix transpose operation, and D is the dimension of the copper wire surface bond vector K.
[0013] As a preferred approach, a scheme for adjusting light source parameters is constructed based on the thermal reflection map of the copper wire surface, specifically including the following steps:
[0014] The thermal map of reflection on the copper wire surface is fed into the light source parameter adjustment network for processing, and the light source parameter adjustment scheme is output. The light source parameter adjustment network includes a feature extraction layer and a light source parameter adjustment scheme output layer. The feature extraction layer is used to extract features from the thermal map of reflection on the copper wire surface and construct the reflection distribution characteristics of the copper wire surface. The light source parameter adjustment network is used to analyze the reflection distribution characteristics of the copper wire surface and construct the corresponding light source parameter adjustment scheme.
[0015] As a preferred approach, training a copper wire reflection intensity prediction model involves the following steps:
[0016] Training samples for predicting the reflection intensity of copper wire are obtained. These samples include point cloud data of the copper wire surface and light source feature sequence data. The training samples are labeled using a thermal map of the copper wire surface reflection. All labeled training samples are combined into a training set for predicting the reflection intensity of copper wire. The model for predicting the reflection intensity of copper wire is then trained using this training set. The training target is the labeled thermal map of the copper wire surface reflection.
[0017] As a preferred approach, training the copper wire defect detection model involves the following steps:
[0018] Training samples for copper wire defect detection are obtained, including images of the copper wire surface and thermal reflection maps of the copper wire surface. The training samples are labeled with copper wire defect information. All labeled training samples are combined into a copper wire defect detection training set. The copper wire defect detection model is trained using the copper wire defect detection training set, with the labeled copper wire defect information as the training target.
[0019] As a preferred approach, training the network for adjusting light source parameters includes the following steps:
[0020] Obtain training samples for adjusting light source parameters, including thermal maps of copper wire surface reflection. Label the training samples according to the light source parameter adjustment scheme. Combine all labeled training samples into a training set for adjusting light source parameters. Train the light source parameter adjustment network using the training set. The training objective is the labeled light source parameter adjustment scheme.
[0021] The present invention also provides an online copper wire quality inspection system, comprising:
[0022] The data acquisition module is used to acquire point cloud data of the copper wire surface, acquire light intensity data and light angle data of the light source at the light source, and combine the light source feature data corresponding to the current timestamp with the light source feature data corresponding to the previous N-1 timestamps to form light source feature sequence data.
[0023] The copper wire reflection intensity prediction module is used to input the copper wire surface point cloud data and light source feature sequence data into the copper wire reflection intensity prediction model for processing, and output the copper wire surface reflection thermal map.
[0024] The light source parameter adjustment module is used to construct a light source parameter adjustment scheme based on the thermal reflection map of the copper wire surface, and to adjust the light source based on the light source parameter adjustment scheme;
[0025] The copper wire defect detection module is used to acquire images of the copper wire surface after adjusting the light source through the light source parameter adjustment scheme, obtain copper wire surface images, and then send the copper wire surface images and copper wire surface reflection thermal maps into the copper wire defect detection model for processing to obtain copper wire defect information.
[0026] The copper wire reflection intensity prediction model includes a spatial feature extraction layer, a light source temporal feature extraction layer, a feature stitching layer, and a reflection prediction layer. The spatial feature extraction layer processes the copper wire surface point cloud data to construct copper wire surface feature data; the light source temporal feature extraction layer performs temporal analysis on the light source feature sequence data to construct light source temporal feature data; the feature stitching layer stitches the copper wire surface feature data and the light source temporal feature data together to construct a copper wire reflection intensity analysis vector; and the reflection prediction layer performs deconvolution on the copper wire reflection intensity analysis vector to construct a copper wire surface reflection heatmap.
[0027] The present invention has the following advantages:
[0028] This invention collects point cloud data of the copper wire surface entering the detection area, as well as light intensity and angle data of the light source, to construct a light source feature sequence. Then, a copper wire reflection intensity prediction model is used to process the copper wire surface point cloud data and the light source feature sequence data to construct a copper wire surface reflection heat map. This predicts the reflection intensity distribution on the copper wire surface and adjusts the light source parameters based on the copper wire surface reflection heat map to reduce the impact of high copper wire surface reflection on image recognition. Furthermore, based on the copper wire surface reflection heat map and a copper wire defect detection model, image recognition is performed on the copper wire surface image to detect the copper wire quality. The copper wire surface reflection heat map can serve as prior knowledge to provide a reference for subsequent copper wire image recognition, improving the accuracy of copper wire quality detection. Attached Figure Description
[0029] Figure 1This is a schematic diagram of the online copper wire quality detection system used in an embodiment of the present invention. Detailed Implementation
[0030] In order to enable those skilled in the art to better understand the technical solutions in the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present invention.
[0031] Example 1: An online method for detecting the quality of copper wire, comprising:
[0032] During the copper wire quality inspection process, whenever the copper wire enters the inspection area, a ToF sensor positioned in the inspection area acquires point cloud data of the copper wire surface. This point cloud data includes the X, Y, and Z coordinates and light intensity information of several points, reflecting the characteristic information of the copper wire surface. Simultaneously, a light sensor positioned at the light source acquires the light intensity data of the light source, and an inertial measurement unit positioned at the light source acquires the corresponding light source angle data. It should be noted that the light source angle refers to the angle between the light source and the ground, including pitch, yaw, or roll angles. The light intensity data and light source angle data are also included. The data reflects the characteristic information of the light emitted by the light source. The light intensity data and the light angle data corresponding to the current timestamp are combined to form the light source characteristic data. The light sensor and the inertial measurement unit perform data acquisition tasks according to the set acquisition frequency. Therefore, the light source characteristic data corresponding to the current timestamp and the light source characteristic data corresponding to the previous N-1 timestamps are combined to form the light source characteristic sequence data. The light source characteristic sequence data reflects the temporal changes in the intensity of the light emitted by the light source (due to the influence of the internal voltage of the light source) and the temporal changes in the angle (due to the mechanical vibration of the production line). The temporal changes in the intensity and angle of the light affect the reflection of the copper wire surface.
[0033] Point cloud data of the copper wire surface and light source feature sequence data are fed into a copper wire reflection intensity prediction model for processing, outputting a copper wire surface reflection heatmap. This 2D image represents the predicted reflection intensity distribution on the copper wire surface. Since copper wire is a highly reflective material, primarily exhibiting specular reflection, images acquired from the copper wire may be clear if the light source is stable. However, fluctuations in the light source (such as internal voltage changes or mechanical vibrations in the production line) amplify these reflectivity changes due to the high reflectivity of the copper wire. In such cases, image acquisition of the copper wire becomes more challenging. In images of normal areas of a copper wire, stripes may appear, while areas corresponding to defects may show bright spots due to overexposure. This can significantly impact subsequent quality inspection of the copper wire using image recognition technology. By predicting the reflection intensity distribution on the copper wire surface, the reflectivity of the surface can be analyzed in advance, allowing for adjustments to the light source parameters to mitigate the impact of high reflectivity on image recognition. Furthermore, since areas with high reflectivity may be defective or naturally curved, the surface reflection thermogram can also serve as prior knowledge for subsequent image recognition of the copper wire.
[0034] A light source parameter adjustment scheme is constructed based on the thermal map of copper wire surface reflection, and the light source is adjusted based on the light source parameter adjustment scheme. Illuminating the copper wire with the adjusted light source can reduce the high reflectivity of the copper wire surface and improve the quality of subsequent image acquisition.
[0035] After adjusting the light source through the light source parameter adjustment scheme, the surface of the copper wire is captured by an industrial camera to obtain the surface image of the copper wire. Then, the surface image of the copper wire and the thermal reflection map of the copper wire surface are sent to the copper wire defect detection model for processing to obtain the copper wire defect information. The copper wire defect information here includes two categories. One category is that no copper wire defects were found, that is, the copper wire quality is qualified, and the copper wire defect information is represented by a defect-free label. The other category is that copper wire defects were found, and the copper wire quality is unqualified. In this case, the copper wire defect information is represented by the copper wire defect type and the copper wire defect label box (the location of the copper wire defect) to facilitate the operator to find the cause of the copper wire defect.
[0036] The copper wire reflection intensity prediction model comprises a spatial feature extraction layer, a light source temporal feature extraction layer, a feature stitching layer, and a reflection prediction layer. The spatial feature extraction layer processes the point cloud data of the copper wire surface to construct surface feature data. Specifically, it is based on the PointNet model, but with the last layer (classification or segmentation layer) removed. This extracted feature data reflects the path and intensity distribution of light reflection, improving the accuracy of reflection intensity distribution prediction. The light source temporal feature extraction layer performs temporal analysis on the light source feature sequence data to construct light source temporal feature data. This data reflects the fluctuations in the light source, affecting the reflection intensity distribution of the copper wire surface. The feature stitching layer concatenates the copper wire surface feature data and the light source temporal feature data to construct a copper wire reflection intensity analysis vector. The reflection prediction layer performs deconvolution on the copper wire reflection intensity analysis vector to construct a reflection heatmap of the copper wire surface. This layer is based on the decoder in the U-net model and includes several deconvolution operations.
[0037] This application collects point cloud data of the copper wire surface entering the detection area, as well as light intensity and angle data of the light source, to construct a light source feature sequence data. Then, it processes the copper wire surface point cloud data and light source feature sequence data using a copper wire reflection intensity prediction model to construct a copper wire surface reflection heat map. This predicts the reflection intensity distribution on the copper wire surface and adjusts the light source parameters based on the copper wire surface reflection heat map to reduce the impact of high copper wire surface reflection on image recognition. Furthermore, it performs image recognition on the copper wire surface image based on the copper wire surface reflection heat map and a copper wire defect detection model to detect the copper wire quality. The copper wire surface reflection heat map can serve as prior knowledge to provide a reference for subsequent copper wire image recognition, improving the accuracy of copper wire quality detection.
[0038] The surface image and thermal reflection map of the copper wire are fed into the copper wire defect detection model for processing to obtain copper wire defect information, which includes the following:
[0039] The copper wire defect detection model consists of a defect enhancement layer and a defect detection layer. The defect enhancement layer performs a self-attention mechanism operation on the copper wire surface image based on the surface reflection heatmap to construct an enhanced copper wire surface image. Since areas with high reflectivity may be defective areas of the copper wire, enhancing the features corresponding to the high reflectivity areas of the copper wire surface image can make the detection of copper wire surface images focus more on areas where defects may occur, thereby improving the accuracy of copper wire defect detection. The defect detection layer is built based on the YOLOv5 model and is used to process the enhanced copper wire surface image to output copper wire defect information. The YOLOv5 model is a commonly used neural network model for image recognition, which can output the bounding box where the defect is located, the confidence level, and the class probability based on the image.
[0040] The enhancement layer performs a self-attention mechanism operation on the copper wire surface image based on the copper wire surface reflection heatmap to construct an enhanced copper wire surface image. Specifically, this includes: performing matrix multiplication operations on the copper wire surface image with the value weight matrix and the bond weight matrix respectively to construct the corresponding copper wire image value vector V and copper wire surface bond vector K; performing matrix multiplication operations on the copper wire surface reflection heatmap with the query weight matrix to construct the copper wire surface query vector Q; and implementing the self-attention mechanism operation using the following formula: G = softmax(QK). T / D 0.5 V, where G is the enhanced image of the copper wire surface, T is the matrix transpose operation, and D is the dimension of the copper wire surface bond vector K; it should be noted that the self-attention mechanism operation here is implemented with reference to the Transformer model, where the value weight matrix, key weight matrix and query weight matrix are all adjustable parameters, and the parameters are adjusted as the copper wire defect detection model is trained end-to-end;
[0041] A scheme for adjusting light source parameters is constructed based on the thermal reflection map of the copper wire surface, which includes the following steps:
[0042] The thermal map of copper wire surface reflection is fed into a light source parameter adjustment network for processing, outputting a light source parameter adjustment scheme. The light source parameter adjustment network includes a feature extraction layer and a light source parameter adjustment scheme output layer. The feature extraction layer is built based on a convolutional neural network. In this embodiment, the VGG16 model is used. Specifically, the last fully connected layer of the VGG16 model is removed to extract features from the thermal map of copper wire surface reflection and construct the reflection distribution characteristics of the copper wire surface. The light source parameter adjustment network is built based on a backpropagation neural network and is used to analyze the reflection distribution characteristics of the copper wire surface and construct the corresponding light source parameter adjustment scheme.
[0043] The training of the copper wire reflection intensity prediction model includes the following steps:
[0044] Training samples for predicting copper wire reflection intensity are obtained. These samples include point cloud data of the copper wire surface and light source feature sequence data. It should be noted that the point cloud data and light source feature sequence data in the training samples can be obtained from the actual production line or through simulation software (such as Blender and Unity) to create a simulation environment. The training samples are labeled using a copper wire surface reflection heatmap. This heatmap is obtained by the operator based on the actual production line or calculated using simulation software. All labeled training samples are combined into a training set for predicting copper wire reflection intensity. The copper wire reflection intensity prediction model is trained using this training set, with the training objective being the labeled copper wire surface reflection heatmap. The training conditions are then checked to determine if the accuracy of the prediction model meets expectations. If the accuracy meets expectations, the trained copper wire reflection intensity prediction model is output; otherwise, the model continues to be trained using the training set.
[0045] Training the copper wire defect detection model involves the following steps:
[0046] Training samples for copper wire defect detection are obtained, including images of the copper wire surface and thermal maps of its reflection. It's important to note that these images and thermal maps are acquired at the same timestamp, either from actual production lines or through simulation software. The training samples are then labeled with copper wire defect information obtained by operators using labeling tools (such as LabelStudio or RectLabel). All labeled training samples are combined into a training set. The copper wire defect detection model is then trained using this training set, with the training objective being the labeled copper wire defect information. The training condition is then determined: the accuracy of the copper wire defect detection model must meet expectations. If the accuracy meets expectations, the trained copper wire defect detection model is output; otherwise, the model continues to be trained using a copper wire reflection intensity prediction training set.
[0047] Training the network to adjust the light source parameters involves the following steps:
[0048] Training samples for adjusting light source parameters are obtained, including thermal maps of copper wire surface reflection. These thermal maps are from the same source as those used during the training of the copper wire reflection intensity prediction model. The training samples are labeled using the light source parameter adjustment scheme. This labeling process involves operators obtaining the optimal light source adjustment scheme based on feedback from the adjusted light source. All labeled training samples are combined into a training set. The light source parameter adjustment network is then trained using this training set, with the training objective being the labeled light source parameter adjustment scheme. The training condition is then determined: the accuracy of the light source parameter adjustment network meets expectations. If the accuracy meets expectations, the trained light source parameter adjustment network is output; otherwise, the network continues to be trained using the copper wire reflection intensity prediction training set.
[0049] Example 2, an online copper wire quality inspection system, see [link to example]. Figure 1 ,include:
[0050] The data acquisition module is used during copper wire quality inspection. Whenever a copper wire enters the inspection area, a ToF sensor positioned in the inspection area acquires point cloud data of the copper wire surface. This point cloud data includes the X, Y, and Z coordinates and light intensity information of several points, reflecting the characteristic information of the copper wire surface. Simultaneously, a light sensor positioned at the light source acquires the light intensity data of the light source, and an inertial measurement unit positioned at the light source acquires the corresponding light source angle data. It should be noted that the light source angle refers to the angle between the light source and the ground, including pitch, yaw, or roll angles. The light intensity data and... The light source angle data together reflect the characteristic information of the light emitted by the light source. The light intensity data and the light source angle data corresponding to the current timestamp are combined to form the light source characteristic data. Since the light sensor and the inertial measurement unit perform data acquisition tasks according to the set acquisition frequency, the light source characteristic data corresponding to the current timestamp and the light source characteristic data corresponding to the previous N-1 timestamps are combined to form the light source characteristic sequence data. The light source characteristic sequence data reflects the temporal changes in the intensity of the light emitted by the light source (due to the influence of the internal voltage of the light source) and the temporal changes in the angle (due to the mechanical vibration of the production line). The temporal changes in the intensity and angle of the light affect the reflection of the copper wire surface.
[0051] The copper wire reflection intensity prediction module processes point cloud data of the copper wire surface and light source feature sequence data into the copper wire reflection intensity prediction model, outputting a 2D image of the copper wire surface reflection heatmap. This heatmap represents the predicted reflection intensity distribution on the copper wire surface. Because copper wire is a highly reflective material, primarily exhibiting specular reflection, images acquired from the copper wire may be clear if the light source is stable. However, fluctuations in the light source (such as internal voltage changes or mechanical vibrations in the production line) amplify these reflectivity changes due to the high reflectivity of the copper wire. In such cases, the image acquired from the copper wire may be less clear. When acquiring images of copper wire, the images corresponding to normal areas may show stripes, while areas corresponding to defective areas may appear as bright spots due to overexposure. This can significantly impact subsequent quality inspection of the copper wire using image recognition technology. By predicting the reflection intensity distribution on the copper wire surface, the reflectivity of the surface can be analyzed in advance, allowing for adjustments to the light source parameters to mitigate the impact of high reflectivity on image recognition. Furthermore, since areas with high reflectivity may be defective or naturally curved, the thermal map of the copper wire surface reflection can also serve as prior knowledge for subsequent image recognition.
[0052] The light source parameter adjustment module is used to construct a light source parameter adjustment scheme based on the thermal map of copper wire surface reflection, and adjust the light source based on the light source parameter adjustment scheme. Illuminating the copper wire with the adjusted light source can reduce the high reflectivity of the copper wire surface and improve the quality of subsequent image acquisition.
[0053] The copper wire defect detection module is used to acquire images of the copper wire surface using an industrial camera after adjusting the light source parameters. The copper wire surface image and its reflection thermal map are then fed into the copper wire defect detection model for processing to obtain copper wire defect information. This information is divided into two categories: one where no defects were found, indicating that the copper wire quality is acceptable, and this is represented by a "no defect" label; and the other where defects were found, indicating that the copper wire quality is unacceptable, and this is represented by the copper wire defect type and a defect label box (the location of the defect) to facilitate operators in identifying the cause of the defects.
[0054] The copper wire reflection intensity prediction model comprises a spatial feature extraction layer, a light source temporal feature extraction layer, a feature stitching layer, and a reflection prediction layer. The spatial feature extraction layer processes the point cloud data of the copper wire surface to construct surface feature data. Specifically, it is based on the PointNet model, but with the last layer (classification or segmentation layer) removed. This extracted feature data reflects the path and intensity distribution of light reflection, improving the accuracy of reflection intensity distribution prediction. The light source temporal feature extraction layer performs temporal analysis on the light source feature sequence data to construct light source temporal feature data. This data reflects the fluctuations in light source intensity, affecting the reflection intensity distribution of the copper wire surface. The feature stitching layer concatenates the copper wire surface feature data and the light source temporal feature data to construct a copper wire reflection intensity analysis vector. The reflection prediction layer performs deconvolution on the copper wire reflection intensity analysis vector to construct a reflection heatmap of the copper wire surface. This layer is based on the decoder in the U-net model and includes several deconvolution operations.
[0055] It should be understood that those skilled in the art can make improvements or modifications based on the above description, and all such improvements and modifications should fall within the protection scope of the appended claims. Parts not described in detail in this specification are prior art known to those skilled in the art.
Claims
1. A method for online detection of copper wire quality, characterized in that, include: Acquire point cloud data of the copper wire surface, acquire light intensity data and light angle data of the light source at the light source, and combine the light source feature data corresponding to the current timestamp with the light source feature data corresponding to the previous N-1 timestamps to form light source feature sequence data; The point cloud data of the copper wire surface and the light source feature sequence data are fed into the copper wire reflection intensity prediction model for processing, and the reflection thermal map of the copper wire surface is output. A light source parameter adjustment scheme is constructed based on the thermal reflection map of the copper wire surface, and the light source is adjusted based on the light source parameter adjustment scheme. After the light source is adjusted by the light source parameter adjustment scheme, the copper wire surface is image acquired to obtain the copper wire surface image. Then, the copper wire surface image and the copper wire surface thermal reflection map are sent to the copper wire defect detection model for processing to obtain the copper wire defect information. The copper wire reflection intensity prediction model includes a spatial feature extraction layer, a light source temporal feature extraction layer, a feature stitching layer, and a reflection prediction layer. The spatial feature extraction layer is used to process the point cloud data of the copper wire surface to construct the copper wire surface feature data; the light source temporal feature extraction layer is used to perform temporal analysis on the light source feature sequence data to construct the light source temporal feature data. The feature splicing layer is used to splice the copper wire surface feature data and the light source temporal feature data end to end to construct the copper wire reflection intensity analysis vector; the reflection prediction layer is used to perform deconvolution operation on the copper wire reflection intensity analysis vector to construct the copper wire surface reflection thermal map.
2. The online copper wire quality detection method according to claim 1, characterized in that, The copper wire surface image and the copper wire surface reflection thermal map are fed into the copper wire defect detection model for processing to obtain copper wire defect information. Specifically, the copper wire defect detection model includes a defect enhancement layer and a defect detection layer. The defect enhancement layer is used to perform a self-attention mechanism operation on the copper wire surface image based on the copper wire surface reflection thermal map to construct an enhanced copper wire surface image. The defect detection layer is built based on the YOLOv5 model and is used to process the enhanced copper wire surface image to output copper wire defect information. The enhancement layer performs a self-attention mechanism operation on the copper wire surface image based on the copper wire surface reflection heatmap to construct an enhanced copper wire surface image. Specifically, this includes: performing matrix multiplication operations on the copper wire surface image with the value weight matrix and the bond weight matrix respectively to construct the corresponding copper wire image value vector V and copper wire surface bond vector K; performing matrix multiplication operations on the copper wire surface reflection heatmap with the query weight matrix to construct the copper wire surface query vector Q; and implementing the self-attention mechanism operation using the following formula: G = softmax(QK). T / D 0.5 )V, where G is the copper wire surface enhancement image, T is the matrix transpose operation, and D is the dimension of the copper wire surface bond vector K.
3. The online copper wire quality detection method according to claim 2, characterized in that, A scheme for adjusting light source parameters is constructed based on the thermal reflection map of the copper wire surface, which includes the following steps: The thermal map of reflection on the copper wire surface is fed into the light source parameter adjustment network for processing, and the light source parameter adjustment scheme is output. The light source parameter adjustment network includes a feature extraction layer and a light source parameter adjustment scheme output layer. The feature extraction layer is used to extract features from the thermal map of reflection on the copper wire surface and construct the reflection distribution characteristics of the copper wire surface. The light source parameter adjustment network is used to analyze the reflection distribution characteristics of the copper wire surface and construct the corresponding light source parameter adjustment scheme.
4. The online copper wire quality detection method according to claim 3, characterized in that, The training of the copper wire reflection intensity prediction model includes the following steps: Training samples for predicting the reflection intensity of copper wire are obtained. These samples include point cloud data of the copper wire surface and light source feature sequence data. The training samples are labeled using a thermal map of the copper wire surface reflection. All labeled training samples are combined into a training set for predicting the reflection intensity of copper wire. The model for predicting the reflection intensity of copper wire is then trained using this training set. The training target is the labeled thermal map of the copper wire surface reflection.
5. The online copper wire quality detection method according to claim 4, characterized in that, Training the copper wire defect detection model involves the following steps: Training samples for copper wire defect detection are obtained, including images of the copper wire surface and thermal reflection maps of the copper wire surface. The training samples are labeled with copper wire defect information. All labeled training samples are combined into a copper wire defect detection training set. The copper wire defect detection model is trained using the copper wire defect detection training set, with the labeled copper wire defect information as the training target.
6. The online copper wire quality detection method according to claim 5, characterized in that, Training the network to adjust the light source parameters involves the following steps: Obtain training samples for adjusting light source parameters, including thermal maps of copper wire surface reflection. Label the training samples according to the light source parameter adjustment scheme. Combine all labeled training samples into a training set for adjusting light source parameters. Train the light source parameter adjustment network using the training set. The training objective is the labeled light source parameter adjustment scheme.
7. An online copper wire quality inspection system, characterized in that, The system employs an online copper wire quality detection method according to any one of claims 1-6, comprising: The data acquisition module is used to acquire point cloud data of the copper wire surface, acquire light intensity data and light angle data of the light source at the light source, and combine the light source feature data corresponding to the current timestamp with the light source feature data corresponding to the previous N-1 timestamps to form light source feature sequence data. The copper wire reflection intensity prediction module is used to input the copper wire surface point cloud data and light source feature sequence data into the copper wire reflection intensity prediction model for processing, and output the copper wire surface reflection thermal map. The light source parameter adjustment module is used to construct a light source parameter adjustment scheme based on the thermal reflection map of the copper wire surface, and to adjust the light source based on the light source parameter adjustment scheme; The copper wire defect detection module is used to acquire images of the copper wire surface after adjusting the light source through the light source parameter adjustment scheme, obtain copper wire surface images, and then send the copper wire surface images and copper wire surface reflection thermal maps into the copper wire defect detection model for processing to obtain copper wire defect information. The copper wire reflection intensity prediction model includes a spatial feature extraction layer, a light source temporal feature extraction layer, a feature stitching layer, and a reflection prediction layer. The spatial feature extraction layer processes the copper wire surface point cloud data to construct copper wire surface feature data; the light source temporal feature extraction layer performs temporal analysis on the light source feature sequence data to construct light source temporal feature data; the feature stitching layer stitches the copper wire surface feature data and the light source temporal feature data together to construct a copper wire reflection intensity analysis vector; and the reflection prediction layer performs deconvolution on the copper wire reflection intensity analysis vector to construct a copper wire surface reflection heatmap.
Citation Information
Patent Citations
Defect detection method, device and equipment for copper-plated welding wire and storage medium
CN110866920A
Engine support assembly assembling quality appearance detection method based on machine vision
CN119048442A