Method for detecting abnormal state of welding process of welding machine based on convolution self-coding network
1. The method for detecting the abnormal state of the welding process of the welding machine based on the convolutional self-coding network is characterized by comprising the following steps of:
step 1: acquiring a welding process signal to be detected;
step 2: preprocessing the acquired welding process signal;
and step 3: building a convolution self-coding network for anomaly detection, wherein the convolution self-coding network comprises a coding network and a decoding network, and training the network by using a normal welding process signal;
and 4, step 4: inputting the welding process signal preprocessed in the step 2 into a trained convolutional self-coding network, and taking a network reconstruction error as an abnormal score of the process signal;
and 5: and comparing the obtained abnormal score with a set abnormal judgment threshold, if the abnormal score is larger than or equal to the threshold, judging that the welding process is abnormal, alarming to remind field operators to pay attention, and if the abnormal score is smaller than the threshold, judging that the welding process is normal.
2. The method for detecting abnormal states of welding process of welder based on convolution self-coding network as claimed in claim 1, wherein the welding process signal in step 1 includes: at least two signals of a welding temperature signal, a welding pressure deviation signal and a welding current signal generated in the welding process of the welding machine.
3. The method for detecting the abnormal state of the welding process of the welding machine based on the convolutional self-coding network as claimed in claim 2, wherein the preprocessing the process signal in the step 2 comprises the following steps:
step 2.1: carrying out stable region interception on the obtained welding process signal;
step 2.2: then down-sampling the intercepted welding process signal;
step 2.3: then, standardizing the welding process signals after the downsampling processing;
step 2.4: the normalized multiple welding process signals are stacked in a rectangular form.
4. The method for detecting abnormal state of welding process of welder based on convolution self-coding network as claimed in claim 3 is characterized in that in step 2.1 the stationary region is truncated to remove the abnormal bump signal of the beginning and ending stage of welding temperature, and only the remaining stationary welding process signal is analyzed.
5. The method for detecting the abnormal state of the welding process of the welding machine based on the convolutional self-coding network as claimed in claim 3, wherein the step 2.2 is specifically as follows: and (4) aligning the welding process signals with different lengths in equal length by adopting a downsampling processing method.
6. The method for detecting the abnormal state of the welding process of the welding machine based on the convolutional self-coding network as claimed in claim 3, wherein in the step 2.3, the welding process signal is normalized according to the following formula:
in the formula, xiThe ith sample value represents a weld process signal, μ is the mean of the weld process signal, and σ is the standard deviation of the weld process signal.
7. The method for detecting the abnormal state of the welding process of the welding machine based on the convolutional self-coding network as claimed in claim 3, wherein the step 2.4 is specifically as follows: each welding process signal is formed into a row vector, and a plurality of row vectors are stacked to form a data rectangle.
8. The method for detecting the abnormal state of the welding process of the welding machine based on the convolutional self-coding network as claimed in claim 1, wherein the objective function of the convolutional self-coding network trained in the step 4 is a reconstruction error:
in the formula, LDCAETo reconstruct the error, xiI-th sample value, x, representing a certain welding process signalrN is the total number of samples for the welding process signal reconstructed after the convolutional self-coding network.
9. The method for detecting abnormal states of welding process of welder based on convolution self-coding network as claimed in claim 1, wherein said abnormal judgment threshold in step 5 is determined by using 3 sigma principle to abnormal score of historical normal welding process data.
10. The method for detecting the abnormal state of the welding process of the welding machine based on the convolutional self-coding network as claimed in claim 1, wherein the upper and lower limits of the abnormal judgment threshold are determined according to the following formula:
upper limit of abnormality determination threshold: l isup=μ+3σ
Lower limit of abnormality determination threshold: l islow=μ-3σ
Where μ is the mean of the historical anomaly scores and σ is the standard deviation of the historical anomaly scores.
Background
The large-scale seam welding machine is a key device for realizing continuous operation of a production line of an iron and steel plant, and the reliable and stable operation of the machine is an important factor for ensuring the high-efficiency production of the iron and steel plant. Due to the complexity of a welding machine system, manual all-weather guard is still needed for monitoring the welding process of the welding machine in actual production, the welding process of the welding machine is concerned all the time, and time and labor are wasted. Therefore, in order to save labor force and improve the detection efficiency of the welding process state abnormity of the welding machine, the signal automatic monitoring of the welding process of the welding machine is necessary.
For example, the invention patent CN112200000A of the Shanghai university of transportation proposes a welding stability recognition model training method and a welding stability recognition method, in which firstly, a segmentation scale is optimally designed according to a welding signal, then, a plurality of groups of segmentation signals are obtained according to a segmentation strategy, and multi-scale feature vectors of the segmentation signals are extracted and used for training a machine learning model to obtain a welding stability recognition model.
For the existing detection technology of welding process signals, the following defects generally exist: 1. the method of applying machine learning needs to manually extract key features, which needs to deeply understand the working mechanism of a welding machine system, while a large-scale welding machine system is often relatively complex, and a large amount of experiments and simulation are needed for determining the key features. 2. The training data needs a lot of data of different categories to be trained, for a large-scale welding machine with higher control precision, most of the accumulated welding data are normal data, abnormal data are rare, the sample size of the abnormal data is not enough to support the diagnosis of the welding process, and the traditional classification identification cannot be applied.
Disclosure of Invention
The invention provides a method for detecting abnormal states of a welding machine in a welding process based on a convolution self-coding network, which aims to solve the problems that mathematical modeling, simulation and artificial feature extraction are needed to be carried out on a working mechanism of a welding machine system and the detection process is complex by adopting a modeling and machine learning method in the prior art.
The invention discloses a method for detecting an abnormal state in a welding process of a welding machine based on a convolution self-coding network, which comprises the following steps:
step 1: acquiring a welding process signal to be detected;
step 2: preprocessing the acquired welding process signal;
and step 3: building a convolution self-coding network for anomaly detection, wherein the convolution self-coding network comprises a coding network and a decoding network, and training the network by using a normal welding process signal;
and 4, step 4: inputting the welding process signal preprocessed in the step 2 into a trained convolutional self-coding network, and taking a network reconstruction error as an abnormal score of the process signal;
and 5: and comparing the obtained abnormal score with a set abnormal judgment threshold, if the abnormal score is larger than or equal to the threshold, judging that the welding process is abnormal, alarming to remind field operators to pay attention, and if the abnormal score is smaller than the threshold, judging that the welding process is normal.
In the method for detecting an abnormal state of a welding process of a welding machine based on a convolutional self-coding network, the welding process signal in the step 1 comprises: at least two signals of a welding temperature signal, a welding pressure deviation signal and a welding current signal generated in the welding process of the welding machine.
In the method for detecting the abnormal state of the welding process of the welding machine based on the convolution self-coding network, the preprocessing of the process signal in the step 2 comprises the following steps:
step 2.1: carrying out stable region interception on the obtained welding process signal;
step 2.2: then down-sampling the intercepted welding process signal;
step 2.3: then, standardizing the welding process signals after the downsampling processing;
step 2.4: the normalized multiple welding process signals are stacked in a rectangular form.
In the method for detecting the abnormal state of the welding process of the welding machine based on the convolution self-coding network, the stable region in the step 2.1 is intercepted, namely, the abnormal bump signals of the beginning and the ending stages of the welding temperature are intercepted, and only the residual stable welding process signals are analyzed.
In the method for detecting the abnormal state of the welding process of the welding machine based on the convolution self-coding network, the step 2.2 specifically comprises the following steps: and (4) aligning the welding process signals with different lengths in equal length by adopting a downsampling processing method.
In the method for detecting the abnormal state of the welding process of the welding machine based on the convolution self-coding network, in the step 2.3, signals of the welding process are standardized according to the following formula:
in the formula, xiThe ith sample value represents a weld process signal, μ is the mean of the weld process signal, and σ is the standard deviation of the weld process signal.
In the method for detecting the abnormal state of the welding process of the welding machine based on the convolution self-coding network, the step 2.4 is specifically as follows: each welding process signal is formed into a row vector, and a plurality of row vectors are stacked to form a data rectangle.
In the method for detecting the abnormal state of the welding process of the welding machine based on the convolutional self-coding network, the target function of the convolutional self-coding network trained in the step 4 is a reconstruction error:
in the formula, LDCAETo reconstruct the error, xiI-th sample value, x, representing a certain welding process signalrN is the total number of samples for the welding process signal reconstructed after the convolutional self-coding network.
In the method for detecting the abnormal state of the welding process of the welding machine based on the convolution self-coding network, the abnormal judgment threshold value in the step 5 is determined by utilizing a 3 sigma principle on the abnormal fraction of the historical normal welding process data.
In the method for detecting the abnormal state of the welding machine based on the convolution self-coding network in the welding process, the upper limit and the lower limit of an abnormal judgment threshold are determined according to the following formula:
upper limit of abnormality determination threshold: l isup=μ+3σ
Lower limit of abnormality determination threshold: l islow=μ-3σ
Where μ is the mean of the historical anomaly scores and σ is the standard deviation of the historical anomaly scores.
The method for detecting the abnormal state of the welding process of the welding machine based on the convolution self-coding network at least has the following beneficial effects:
(1) the detection method can automatically learn the general potential characteristics representing normal data according to the normal data generated in the welding process, and only needs the normal data in the training stage.
(2) The detection method does not need to manually extract the key characteristics of the signals in the model training stage, does not need expert knowledge, and is simple and effective to operate.
(3) The detection method provided by the invention adopts a signal stacking mode to carry out detection, and can realize the information fusion of a plurality of detection signals by utilizing the characteristic that the convolution operation can effectively extract local associated information.
(4) The detection method of the invention reduces the operation difficulty by using the convolution self-coding network to carry out the abnormity detection, has loose requirements on training data, and only needs normal data, thereby having wider application range.
Drawings
FIG. 1 is a flow chart of the method for detecting abnormal states in the welding process of a welding machine based on a convolution self-coding network according to the invention;
FIG. 2 is a schematic diagram of the position of an abnormal bump of a welding temperature signal according to the present invention;
FIG. 3 is a schematic diagram of a signal stacking scheme for a welding process according to the present invention;
fig. 4 is a graph of anomaly scores.
Detailed Description
The large-scale seam welding machine is a key device for realizing continuous operation of a production line of an iron and steel plant, and the reliable and stable operation of the machine is an important factor for ensuring the high-efficiency production of the iron and steel plant. The traditional detection means adopts modeling and machine learning methods, which need mathematical modeling, simulation and artificial feature extraction on the working mechanism of a welding machine system and are complex, while the currently emerging deep learning can directly start from data, autonomously mine data internal information and does not need excessive manual intervention, so that the method applies the anomaly detection method based on the convolutional self-coding network to the task of detecting the signal anomaly state in the welding process, and the specific detection process is as follows:
as shown in FIG. 1, the method for detecting the abnormal state of the welding process of the welding machine based on the convolution self-coding network comprises the following steps:
step 1: acquiring a welding process signal to be detected;
in specific implementation, the welding process signals include: the welding process of the welding machine generates at least two signals of other signals related to the welding process, such as a welding temperature signal, a welding pressure deviation signal, a welding current signal and the like. In this embodiment, a welding pressure signal is obtained from the PLC, and a welding temperature signal is obtained from the temperature sensor.
Step 2: preprocessing the acquired welding process signal, which specifically comprises the following steps:
step 2.1: carrying out stable region interception on the obtained welding process signal;
in specific implementation, taking the welding temperature as an example, the abnormal bump signals at the beginning and the end stages of the welding temperature are cut off, and only the remaining stable welding process signals are analyzed. The abnormal protrusion position is shown in fig. 2.
Step 2.2: and then, the intercepted welding process signals are subjected to down-sampling treatment, and the welding process signals with different lengths are aligned in equal length.
Step 2.3: then, standardizing the welding process signals after the downsampling processing;
in specific implementation, the welding process signal is standardized according to the following formula:
in the formula, xiRepresents the ith sample value in a certain welding process signal, mu is the mean value of the welding process signal, and sigma is the standard deviation of the welding process signal.
Step 2.4: the normalized multiple welding process signals are stacked into a rectangular form.
In particular, as shown in fig. 3, each welding process signal is formed into a row vector, and a plurality of row vectors are stacked to form a data rectangle.
And step 3: and constructing a convolution self-coding network for anomaly detection, wherein the convolution self-coding network comprises a coding network and a decoding network, and training the network by using a normal welding process signal.
The parameter settings of the convolutional self-coding network structure are shown in table 1 and table 2:
TABLE 1 convolutional self-coding network architecture parameter set
TABLE 2 convolutional self-encoding network decoding network architecture parameter set
From the above table, it can be known that the constructed convolutional self-coding network DCAE of the present application is composed of 2 sub-networks, which are respectively a coding network and a decoding network. The coding network consists of 3 convolutional layer modules, wherein a convolutional layer 1 adopts a 1 multiplied by 3 convolutional core, a batch normalization layer BN is used, and an activation function adopts Leaky ReLU; the convolution layer 2 adopts a 1 multiplied by 2 convolution kernel, uses a batch normalization layer BN, and the activation function adopts Leaky ReLU to carry out maximum pooling (Maxpool) processing on the output of the activation function; convolutional layer 3 uses 1 × 3 convolutional kernel, using batch normalization layer BN, the activation function uses leakage ReLU, and the output of the activation function is maximally pooled.
The decoder network consists of 6 modules, including 4 convolutional layer modules and 2 deconvolution modules, wherein convolutional layer 1 adopts 1 × 3 convolutional core, batch normalization layer BN is used, and the activation function adopts Leaky ReLU; the deconvolution layer 1 adopts a 1 × 2 convolution kernel, a batch normalization layer BN is used, and an activation function adopts Leaky ReLU; the convolution layer 2 adopts a 1 × 3 convolution kernel, a batch normalization layer BN is used, and an activation function adopts Leaky ReLU; the convolution layer 3 adopts a 3 multiplied by 3 convolution kernel, a batch normalization layer BN is used, and an activation function adopts Leaky ReLU; deconvolution layer 2 uses a 1 × 2 convolution kernel without an activation function, and convolutional layer 4 uses a 1 × 3 convolution kernel without an activation function.
And 4, step 4: inputting the welding process signal preprocessed in the step 2 into a trained convolutional self-coding network, and taking a network reconstruction error as an abnormal score of the process signal;
in specific implementation, the target function of the trained convolutional self-coding network is a reconstruction error:
in the formula, LDCAETo reconstruct the error, xiI-th sample value, x, representing a certain welding process signalrN is the total number of samples for the welding process signal reconstructed after the convolutional self-coding network.
And 5: and comparing the obtained abnormal score with a set abnormal judgment threshold, if the abnormal score is larger than or equal to the threshold, judging that the welding process is abnormal, alarming to remind field operators to pay attention, and if the abnormal score is smaller than the threshold, judging that the welding process is normal.
In specific implementation, the abnormal judgment threshold is determined by utilizing the 3 sigma principle on the abnormal fraction of the historical normal welding process data. Provided that the detection model is trained.
Firstly, preprocessing the historical normal welding process signal data, and inputting the preprocessed historical normal welding process signal data into a detection model to obtain respective historical abnormal scores.
And then, determining the upper limit and the lower limit of the abnormal judgment threshold by using a 3 sigma principle. The specific formula is as follows:
upper limit of abnormality determination threshold: l isup=μ+3σ
Lower limit of abnormality determination threshold: l islow=μ-3σ
Where μ is the mean of the historical anomaly scores and σ is the standard deviation of the historical anomaly scores.
The effectiveness of the detection method for the abnormal state of the welding process of the welding machine based on the convolutional self-coding network is verified by actual welding data of a factory during 12-16-2021-1-4 days in 2020. Firstly, preprocessing the welding process signals in the time period according to the steps 2.1-2.4, and then sending the signals into a trained convolutional self-coding network for anomaly detection to obtain respective anomaly scores, as shown in fig. 4. The curve in the graph is an abnormal score curve, the circle marks the abnormal score of abnormal welding data in actual production, other abnormal scores of normal welding data are marked, the upper horizontal line and the lower horizontal line represent that the upper limit and the lower limit are obtained by analyzing historical data by using a 3 Xige method, and when the abnormal score exceeds the upper limit and the lower limit, the abnormal score can be judged to be abnormal by a convolution self-coding network. It can be seen from the figure that the abnormal score of the abnormal welding process signal is obviously greater than that of the normal welding process signal and exceeds the defined upper limit, and the judgment is carried out according to the step 5 to judge that the abnormal welding process signal is abnormal, so that the accuracy of 100 percent is reached, and the abnormal state detection method of the welding machine based on the convolution self-coding network in the welding process can effectively detect the abnormal state of the welding data.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the scope of the present invention, which is defined by the appended claims.
- 上一篇:石墨接头机器人自动装卡簧、装栓机
- 下一篇:画面展示方法、装置、终端及存储介质