Mechanical equipment fault diagnosis method, device and storage medium
By using a convolutional neural network model of multi-channel input and multi-task branch in gearbox fault diagnosis, the problem of inability to effectively identify composite faults and multi-task diagnosis in the prior art is solved, and the fault diagnosis effect with high accuracy and low parameter scale is achieved.
Patent Information
- Application Number
- CN202210492062.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-07
- Publication Date
- 2025-04-08
- Estimated Expiration
- 2042-05-07
AI Technical Summary
The existing gearbox fault diagnosis methods are mainly suitable for fault type identification of a single component, and cannot effectively identify composite faults and multi-task diagnosis, resulting in low diagnostic accuracy and huge model parameters.
A convolutional neural network model with multi-channel input and multi-task branches is adopted. By collecting vibration signals at different positions of the gearbox, pre-processing and data enhancement, data samples are generated, and shared and unique features are extracted through the shared network and multi-task branches, and the composite loss function is used for training.
It realizes high accuracy of gearbox multi-tasking fault diagnosis, reduces the scale of model parameters, and improves the accuracy and generalization capabilities of diagnosis.
Smart Images

Figure CN114925724B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of mechanical equipment fault diagnosis, and in particular relates to a mechanical equipment fault diagnosis method, device and storage medium. Background Art
[0002] Gearboxes are key components used to connect and transmit power in rotating machinery, and have a significant impact on the stability of mechanical equipment operation. Gearboxes often work for a long time in high-speed, heavy-load environments, and their main components, such as gears and bearings, are prone to failure due to fatigue and wear. Once a gearbox fails, it will seriously affect the normal operation of the entire mechanical equipment, and thus threaten industrial production safety.
[0003] Existing intelligent fault diagnosis methods can achieve good diagnostic results, but most of these methods are only applicable to the fault type identification of a single component or other single-task fault diagnosis. However, in industrial sites, mechanical equipment is usually not shut down for maintenance immediately after a single fault occurs. Instead, the fault is tracked and evaluated, and repairs or replacements are performed only after the fault reaches a certain level. Fault level identification is the basis for situation-based maintenance, and it is necessary to identify the fault level while determining the fault type. In addition, when a gear or bearing fails, it usually causes failures in other components that contact it, which then develops into a compound fault.
[0004] In summary, there is a need to simultaneously identify the type and degree of gearbox faults or multiple types of faults in industrial production. If the existing single-task fault diagnosis method is used, not only can it not effectively extract features for multiple diagnostic tasks, but it will also cause the scale of diagnostic model parameters to be very large, making it difficult to perform effective diagnosis. Therefore, the research on multi-task diagnosis methods for gearbox faults is meaningful for realizing condition-based maintenance of mechanical equipment, reducing production costs, and ensuring industrial production safety. Summary of the invention
[0005] Purpose of the invention: The purpose of the present invention is to address the problem that most existing gearbox fault diagnosis methods can only perform single-task diagnosis, and to propose a mechanical equipment fault diagnosis method, device and storage medium, which solves the problem of multi-task diagnosis of gearbox faults and improves the diagnosis accuracy.
[0006] The method of the present invention specifically comprises the following steps:
[0007] Step 1: Collect vibration signals in various directions at different positions of the gearbox, analyze the collected vibration signals and then select vibration sensitive positions, and collect n groups of vibration signals at sensitive positions of the gearbox under different working conditions;
[0008] Step 2: Preprocess the n groups of vibration signals collected in step 1, expand the data dimension to meet the input requirements of subsequent models, add fault labels, and generate data samples;
[0009] Step 3: Build a convolutional neural network model with multi-channel input and multi-task branches;
[0010] Step 4: Input the data samples generated in step 2 into the convolutional neural network model built in step 3 to train the model;
[0011] Step 5: Input the gearbox vibration signal used for testing into the convolutional neural network model trained in step 4 to identify the fault state, and obtain the gearbox fault diagnosis result based on the fault label output by the model.
[0012] In step 1, the vibration signals of different measuring points are analyzed based on the core idea of minimizing residuals and classification optimization, and appropriate vibration-sensitive measuring points are selected to maximize the reflection of the vibration characteristics of the gearbox and reduce the collinear interference between the measuring points.
[0013] Step 2 includes: using sliding segmentation to perform data enhancement, setting the total number of data points to N and the number of single sample data points to N s , the number of overlapping data points is N o , then the calculation formula of the data volume n obtained after enhancement is as follows:
[0014]
[0015] By setting the appropriate number of overlapping data points N o , the data samples can be well expanded.
[0016] In step 2, the fault label is added by One-Hot encoding, which solves the problem that the classifier is not good at handling attribute labels. The representation of the fault label is a vector. Different numbers of fault categories correspond to label vectors of different lengths. In the fault label vector corresponding to each sample, only one bit is in state 1, and the rest are in state 0. State 1 means "yes", and state 0 means "no". Only one bit is valid at any time.
[0017] In step 2, the sliding segmentation method is used to enhance the data of the one-dimensional vibration signal, and different sliding step sizes are set for data in different states according to different data amounts to avoid the problem of sample imbalance.
[0018] In step 3, the convolutional neural network model includes multi-channel input, a shared network, M task branches and a composite loss function; M is an integer and M≥2;
[0019] Multiple groups of vibration signals collected at sensitive locations under different working conditions are simultaneously imported into the convolutional neural network model using multi-channel input; the shared network can preliminarily extract shared features between tasks from the vibration signals; M task branches further extract the unique features of each diagnostic task, and the number of branches is adjusted according to the number of tasks; the composite loss function is used to balance the loss scale between different tasks.
[0020] The convolutional neural network model completes the model feature extraction process and related calculations by executing the following steps:
[0021] Step 301: The n groups of vibration signals preprocessed in step 2 are simultaneously input through n channels into the convolutional neural network model built in step 3 for training. The convolution result of the multi-channel input is the superposition of the operation results of each channel, as shown below:
[0022]
[0023] In the formula, y i,j is the convolution result of multi-channel input, c is the sequence number of the feature sequence, W represents the size of the convolution kernel, is the j'th weight in the i-th convolution kernel, is the j'th convolved local area, Represents the bias of the i-th convolution kernel;
[0024] Step 302: After the n groups of vibration signals in step 301 are input into the convolutional neural network model, they are first passed through the backbone network to learn the shared features of multiple tasks (the backbone network refers to the network for extracting features, and its function is to extract information from the data for use by the subsequent network); the backbone network includes more than two convolutional pooling modules, each of which includes a convolutional layer, a batch normalization layer, a ReLU activation function and a pooling layer, and the pooling layer in each convolutional pooling module adopts maximum pooling;
[0025] Step 303: Input the shared features learned and extracted in step 302 into M task branches to learn and extract the unique features of each task. Each task branch includes more than two convolutional pooling modules, where the last pooling layer adopts global average pooling, and the remaining pooling layers adopt maximum pooling. The calculation formula of global average pooling is:
[0026]
[0027] in, represents the output value of the global average pooling of the ith channel of the lth layer, V represents the size of the pooling area, represents the tth eigenvalue of the ith channel;
[0028] Add the Softmax activation function in the fully connected layer of the M task branches (the general convolutional neural network consists of a convolutional layer, a pooling layer, a fully connected layer, and a Softmax layer. These four constitute a common convolutional neural network. After multiple rounds of convolutional and pooling layer processing, the convolutional neural network is generally connected to 1 to 2 layers of fully connected layers to give the final classification results) to estimate the probability distribution of different categories, as shown below:
[0029]
[0030] Among them, Z is the output value of the fully connected layer, h j (Z) is the probability value of Z belonging to the jth category, Z j is the jth element of Z, C is a constant; exp is an operation symbol;
[0031] Since the Softmax function involves exponential operations, if Z j The value of is very large and may overflow. Therefore, the Softmax function is improved by multiplying the numerator and denominator by the constant C, and the result remains unchanged. The formula is as follows:
[0032]
[0033] By selecting a suitable constant C, the Softmax function can be optimized.
[0034] Step 304: The multi-task convolutional neural network needs to set more than two cross entropy loss functions L f , f = A, B, ... (A, B, ... represent task branch A, task branch B, ...), as follows:
[0035]
[0036] In the formula, y f is the expected output of the task branch, The actual output of the task branch.
[0037] Introducing the weight coefficient λ into the composite loss function f , f=A,B,…, to control the weights of the M task branches in step 303 during the training process. The composite loss function L is expressed as follows:
[0038]
[0039] Where f represents the diagnostic task, L f Represents the cross entropy loss function corresponding to the diagnosis task.
[0040] The fault diagnosis model uses multi-channel input, which can simultaneously input multiple groups of vibration signals collected by sensors under different working conditions. Compared with single-channel input, the network can learn more comprehensive fault characteristics, improve the classification effect of the model, and have better noise resistance.
[0041] The fault diagnosis model contains M task branches. The number of task branches is adjusted according to the actual diagnosis situation. Each task branch completes the corresponding independent fault diagnosis task, thereby realizing multi-task fault diagnosis. Compared with the single-task network structure, taking J types of gear faults and H types of bearing faults as an example, the output category of the output layer changes from O = J × H to O' = J + H. The network parameter scale is reduced while the training difficulty is reduced.
[0042] The fault diagnosis model includes a shared network and M task branches. The task branches are connected through a shared network and all neurons in the shared hidden layer. During the back propagation process, the network parameters of multiple tasks can be optimized simultaneously, thereby realizing information sharing between different tasks and improving the accuracy of fault diagnosis and the generalization ability of the model.
[0043] Hyperparameters are introduced into the composite cross entropy loss function to add different weight coefficients for different task branches, which is conducive to balancing the loss scale of multiple loss functions and avoiding the situation where one task dominates the entire training process. The weight coefficients of different branches are determined by testing the classification accuracy of the network on sample data under different hyperparameters.
[0044] The wide convolution kernel is applied to the network construction, which has a similar function to the short-time Fourier transform. The first convolution layer uses a wide convolution kernel. The wide convolution kernel of the first layer is equivalent to the sine function in the short-time Fourier transform, which helps to fully obtain the low-frequency features in the vibration signal, resist the interference of high-frequency noise in the environment to a certain extent, and maintain the network at an appropriate depth. By setting convolution kernels of different sizes, M task branches containing information of different scales can be obtained.
[0045] Furthermore, the multi-channel input in step 301 can simultaneously input vibration signals of different working conditions collected by the sensor, thereby ensuring the integrity of different fault space characteristics.
[0046] Furthermore, each task branch in step 303 can complete a corresponding fault diagnosis task, thereby realizing multi-task fault diagnosis of the gearbox, and the number of task branches can be adjusted according to actual diagnosis conditions.
[0047] Furthermore, the M task branches in step 303 can connect all neurons in the hidden layer of the shared network in step 302, so as to realize information sharing between different tasks and improve the accuracy of fault diagnosis and the generalization ability of the model.
[0048] Furthermore, adding different weight coefficients for multiple tasks in the composite loss function in step 304 is conducive to balancing the loss scales of multiple loss functions and avoiding the situation where one task dominates the training process.
[0049] The present invention also provides a mechanical equipment fault diagnosis device, comprising:
[0050] The data acquisition module is used to collect vibration signals in various directions at different positions of the gearbox, perform spectrum analysis on the collected vibration signals, and then select vibration-sensitive positions, and collect n groups of vibration signals at sensitive positions of the gearbox under different working conditions;
[0051] The data processing module is used to pre-process the n groups of vibration signals collected, add fault labels, and generate data samples;
[0052] Convolutional neural network model building module, used to build a convolutional neural network model with multi-channel input and multi-task branches;
[0053] The training module is used to input data samples into the convolutional neural network model to train the model;
[0054] The fault mode recognition module is used to input the vibration signal of the gearbox used for testing into the trained convolutional neural network model, perform fault mode recognition based on the fault label output by the model, and obtain the fault diagnosis result of the gearbox.
[0055] The present invention also provides a storage medium storing a computer program or instruction, and when the computer program or instruction is executed, the method described is implemented.
[0056] The beneficial effects of the present invention are:
[0057] 1. The present invention realizes end-to-end fault feature extraction and classification, and can realize gearbox multi-task fault diagnosis without manual feature extraction and rich expert knowledge.
[0058] 2. The present invention simultaneously inputs multiple groups of vibration signals of the gearbox under different working conditions to perform fault diagnosis, thereby ensuring the integrity of the fault characteristics to the greatest extent and improving the diagnostic accuracy.
[0059] 3. The fault diagnosis model of the present invention includes M task branches, and multiple fault diagnosis tasks can be performed simultaneously, and the number of task branches can be adjusted according to the actual diagnosis situation.
[0060] 4. The present invention realizes information sharing among multiple diagnostic tasks through a shared network, thereby improving the fault diagnosis accuracy and the generalization ability of the model. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] The present invention will be further described in detail below in conjunction with the accompanying drawings and specific embodiments, and the above and / or other advantages of the present invention will become more clear.
[0062] Figure 1 The figure is an overall flow chart of the method of the present invention.
[0063] Figure 2 Schematic diagram of data augmentation processing.
[0064] Figure 3 The structure diagram of the convolutional neural network model with multi-channel input and multi-task branches. DETAILED DESCRIPTION
[0065] This implementation case takes the gearbox compound fault diagnosis including both gear fault and bearing fault as an example. Figure 1 As shown in the figure, it is the overall flow chart of gearbox compound fault diagnosis based on the convolutional neural network model with multi-channel input and multi-task branches. The specific process is as follows:
[0066] Step 1: Collect fault vibration signals of the gearbox under different working conditions based on the signal acquisition device and the acceleration sensor;
[0067] Step 2: Perform preprocessing operations such as data enhancement, segmentation, and dimension expansion on the three groups of vibration signals collected in step 1. The length of each sample is set to 2048, and the step length of sliding segmentation is set to 1000. One-Hot encoding is used to add fault labels to generate data samples;
[0068] Step 3: Build a convolutional neural network model with multi-channel input and multi-task branches; the model mainly consists of four parts: multi-channel input, shared network, M task branches and composite loss function. The shared network and M task branches can be combined Figure 3 The M task branches are the branch network structures behind the backbone network. The network part before the M task branches and shared by each task branch is called the shared network, which realizes information sharing between the M task branches during the back propagation of deep learning.
[0069] The sensor collects multiple sets of vibration signals under different working conditions at sensitive locations and imports them into the model simultaneously using multi-channel input; the shared network can initially extract shared features between tasks from the vibration signal, and M task branches further extract unique features of each diagnostic task. The number of branches can be adjusted according to the number of tasks; the composite loss function is used to balance the loss scale between different tasks. The model feature extraction process and calculation method are as follows:
[0070] Step 301: Input the three groups of vibration signal data preprocessed in step 2 into the network through three channels for training. For multi-channel input, the result of convolution is the superposition of the operation results of each channel, as follows:
[0071]
[0072] In the formula, y i,j is the convolution result of multi-channel input, c is the sequence number of the feature sequence, W represents the size of the convolution kernel, is the j′th weight in the i-th convolution kernel, is the j′th convolved local area, Represents the bias of the i-th convolution kernel.
[0073] Step 302: After the three groups of vibration signals in step 301 are input into the network, they are first passed through the backbone network to learn the shared features of multiple tasks. The backbone network includes four convolutional pooling modules, each of which consists of a convolutional layer, a batch normalization layer, a ReLU activation function, and a pooling layer. The model is built using a wide convolution kernel. The convolution kernel size of the first convolution layer is set to 32×1, and the convolution kernel size of each subsequent layer is set to 3×1. The pooling layer in each module uses maximum pooling, and the number of downsampling is 2.
[0074] Step 303: Input the shared features extracted in step 302 into the two task branches to extract the unique features of each task. The two task branches correspond to gear fault diagnosis and bearing fault diagnosis respectively. Each task branch includes two convolution pooling modules. The convolution kernel size of each layer is set to 3×1. The last pooling layer uses global average pooling. The calculation formula is:
[0075]
[0076] In the formula, represents the output value of the global average pooling of the ith channel of the lth layer, V represents the size of the pooling area, represents the t-th eigenvalue of the ith channel.
[0077] The Softmax activation function is added to the fully connected layer of the two task branches to estimate the probability distribution of belonging to different categories, which is expressed as follows:
[0078]
[0079] In the formula, Z is the output value of the fully connected layer, h j (Z) is the probability value of Z belonging to the jth category, Z j is the j-th element of Z, and C is a constant.
[0080] Step 304: Introduce weight coefficient λ into the loss function G and λ B To control the weights of the two task branches of gear fault diagnosis and bearing fault diagnosis in step 303 during the training process, the composite loss function of the model is expressed as follows:
[0081] L=λ G L G +λ B L B (4)
[0082] Where L represents the cross entropy loss function.
[0083] Step 4: Input the data samples generated in step 2 into the convolutional neural network model built in step 3 to train the model.
[0084] The experimental platform is configured as follows: the operating system is 64-bit Windows 10, the CPU is AMD R5 3600, the GPU is NVIDIA GTX 2060, the programming environment is Python 3.7, and the deep learning framework is PyTorch.
[0085] During the training process, the initial learning rate was set to 0.001 and the batch size was set to 512. The Dropout strategy was used to suppress overfitting that may occur during the training process, and the dropout probability was set to 0.1.
[0086] Step 5: Input the gearbox vibration signal used for testing into the model trained in step 4 to identify the fault state, and obtain the gearbox fault diagnosis result based on the fault label output by the model. In order to reduce the error caused by randomly selecting the initial value, 10 repeated training and testing were performed, and the obtained diagnostic accuracy is shown in the following table, where "joint diagnosis" means that both the gear fault and the bearing fault are diagnosed correctly.
[0087] Table 1
[0088]
[0089]
[0090] In summary, the present invention can be effectively used for gearbox compound fault diagnosis, and has strong generalization ability while achieving high diagnostic accuracy.
[0091] This embodiment also provides a mechanical equipment fault diagnosis device, including:
[0092] The data acquisition module is used to collect vibration signals in various directions at different positions of the gearbox, perform spectrum analysis on the collected vibration signals, and then select vibration-sensitive positions, and collect n groups of vibration signals at sensitive positions of the gearbox under different working conditions;
[0093] The data processing module is used to pre-process the n groups of vibration signals collected, add fault labels, and generate data samples;
[0094] Convolutional neural network model building module, used to build a convolutional neural network model with multi-channel input and multi-task branches;
[0095] The training module is used to input data samples into the convolutional neural network model to train the model;
[0096] The fault mode recognition module is used to input the vibration signal of the gearbox used for testing into the trained convolutional neural network model, perform fault mode recognition based on the fault label output by the model, and obtain the fault diagnosis result of the gearbox.
[0097] The present invention also provides a storage medium storing a computer program or instruction, and when the computer program or instruction is executed, the method described is implemented.
[0098] The present invention provides a mechanical equipment fault diagnosis method, device and storage medium. There are many methods and ways to implement the technical solution. The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications should also be regarded as the protection scope of the present invention. All components not specified in this embodiment can be implemented by existing technologies.
Claims
1. A mechanical equipment fault diagnosis method, characterized in that: The following steps are involved: Step 1: Collect vibration signals in various directions at different positions of the gearbox, perform spectrum analysis on the collected vibration signals, and then select vibration-sensitive positions, and collect n groups of vibration signals at the sensitive positions of the gearbox under different working conditions; Step 2: Preprocess the n groups of vibration signals collected in step 1, add fault labels, and generate data samples; Step 3: Build a convolutional neural network model with multi-channel input and multi-task branches; Step 4: Input the data samples generated in step 2 into the convolutional neural network model built in step 3 to train the model; Step 5: Input the gearbox vibration signal used for testing into the convolutional neural network model trained in step 4, perform fault mode recognition based on the fault label output by the model, and obtain the fault diagnosis result of the gearbox; In step 3, the convolutional neural network model includes multi-channel input, a shared network, M task branches and a composite loss function; Multiple sets of vibration signals collected under different working conditions at sensitive locations are simultaneously imported into the convolutional neural network model using a multi-channel input method; the shared network can preliminarily extract shared features between various tasks from the vibration signals; M task branches further extract unique features of each diagnostic task; the composite loss function is used to balance the loss scale between different tasks; The convolutional neural network model completes the model feature extraction process and related calculations by executing the following steps: Step 301: The n groups of vibration signals preprocessed in step 2 are simultaneously input through n channels into the convolutional neural network model built in step 3 for training. The convolution result of the multi-channel input is the superposition of the operation results of each channel, as shown below: In the formula, y i,j is the convolution result of multi-channel input, c is the sequence number of the feature sequence, W represents the size of the convolution kernel, is the j'th weight in the i-th convolution kernel, is the j'th convolved local area, Represents the bias of the i-th convolution kernel; Step 302: After the n groups of vibration signals in step 301 are input into the convolutional neural network model, they are first passed through the backbone network to learn the shared features of multiple tasks; the backbone network includes more than two convolutional pooling modules, each of which includes a convolutional layer, a batch normalization layer, a ReLU activation function and a pooling layer, and the pooling layer in each convolutional pooling module adopts maximum pooling; Step 303: Input the shared features learned and extracted in step 302 into M task branches to learn and extract the unique features of each task. Each task branch includes more than two convolutional pooling modules, where the last pooling layer adopts global average pooling, and the remaining pooling layers adopt maximum pooling. The calculation formula of global average pooling is: in, represents the output value of the global average pooling of the ith channel of the lth layer, V represents the size of the pooling area, represents the tth eigenvalue of the ith channel; A Softmax activation function is added to the fully connected layer of the M task branches to estimate the probability distribution of different categories, as shown below: (4) Among them, Z is the output value of the fully connected layer, h j (Z) is the probability value that Z belongs to the jth category, Z j is the jth element of Z, and C is a constant; Step 304: Set more than two cross entropy loss functions L f .
2. The method according to claim 1, characterized in that Step 2 includes: using sliding segmentation to perform data enhancement, setting the total number of data points to N and the number of single sample data points to N s , the number of overlapping data points is N o , then the calculation formula of the data volume n obtained after enhancement is as follows:
3. The method according to claim 2, characterized in that In step 2, one-hot encoding is used to add fault labels. The representation of fault labels is a vector. Different numbers of fault categories correspond to label vectors of different lengths. In the fault label vector corresponding to each sample, only one bit is in state 1, and the rest are in state 0. State 1 means yes, and state 0 means no. Only one bit is valid at any time.
4. The method according to claim 3, characterized in that In step 304, the cross entropy loss function L f as follows: In the formula, y f is the expected output of the task branch, The actual output of the task branch.
5. The method according to claim 4, characterized in that In step 304, the weight coefficient λ is introduced into the composite loss function f , to control the weights of the M task branches in step 303 during the training process, the composite loss function L is expressed as follows: Where, L f Represents the cross entropy loss function corresponding to the diagnosis task.
6. A mechanical equipment fault diagnosis device implemented by the method according to claim 1, characterized in that: include: The data acquisition module is used to collect vibration signals in various directions at different positions of the gearbox, perform spectrum analysis on the collected vibration signals, and then select vibration-sensitive positions, and collect n groups of vibration signals at sensitive positions of the gearbox under different working conditions; The data processing module is used to pre-process the n groups of vibration signals collected, add fault labels, and generate data samples; Convolutional neural network model building module, used to build a convolutional neural network model with multi-channel input and multi-task branches; The training module is used to input data samples into the convolutional neural network model to train the model; The fault mode recognition module is used to input the vibration signal of the gearbox used for testing into the trained convolutional neural network model, perform fault mode recognition based on the fault label output by the model, and obtain the fault diagnosis result of the gearbox.
7. A storage medium, characterized in that: A computer program or instruction is stored, and when the computer program or instruction is executed, the method according to any one of claims 1 to 5 is implemented.