CN113312719B - Rotary machine fault diagnosis method based on class unbalance weight cross entropy - Google Patents

Rotary machine fault diagnosis method based on class unbalance weight cross entropy Download PDF

Info

Publication number
CN113312719B
CN113312719B CN202110584346.0A CN202110584346A CN113312719B CN 113312719 B CN113312719 B CN 113312719B CN 202110584346 A CN202110584346 A CN 202110584346A CN 113312719 B CN113312719 B CN 113312719B
Authority
CN
China
Prior art keywords
fault diagnosis
fault
rotary machine
encoder
sparse
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110584346.0A
Other languages
Chinese (zh)
Other versions
CN113312719A (en
Inventor
王奇斌
杨胜康
孔宪光
程涵
余粼钖
吉王辉
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xidian University
Original Assignee
Xidian University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xidian University filed Critical Xidian University
Priority to CN202110584346.0A priority Critical patent/CN113312719B/en
Publication of CN113312719A publication Critical patent/CN113312719A/en
Application granted granted Critical
Publication of CN113312719B publication Critical patent/CN113312719B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/10Geometric CAD
    • G06F30/17Mechanical parametric or variational design
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/10Complex mathematical operations
    • G06F17/14Fourier, Walsh or analogous domain transformations, e.g. Laplace, Hilbert, Karhunen-Loeve, transforms
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation
    • G06F30/27Design optimisation, verification or simulation using machine learning, e.g. artificial intelligence, neural networks, support vector machines [SVM] or training a model
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2119/00Details relating to the type or aim of the analysis or the optimisation
    • G06F2119/02Reliability analysis or reliability optimisation; Failure analysis, e.g. worst case scenario performance, failure mode and effects analysis [FMEA]

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Geometry (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • General Engineering & Computer Science (AREA)
  • Pure & Applied Mathematics (AREA)
  • Mathematical Physics (AREA)
  • Mathematical Optimization (AREA)
  • Mathematical Analysis (AREA)
  • Computational Mathematics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Artificial Intelligence (AREA)
  • Software Systems (AREA)
  • Computer Hardware Design (AREA)
  • Evolutionary Biology (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Algebra (AREA)
  • Databases & Information Systems (AREA)
  • Medical Informatics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Testing Of Devices, Machine Parts, Or Other Structures Thereof (AREA)

Abstract

The invention provides a rotary machine fault diagnosis method based on class unbalance weight cross entropy, which comprises the following steps: acquiring a training sample set and a testing sample set; (2) constructing a sparse self-encoder model; (3) carrying out iterative training on the sparse self-encoder model; (4) constructing a fault diagnosis model of the rotary machine; (5) Carrying out iterative training on the rotating machine fault diagnosis model; and (6) acquiring a fault diagnosis result of the rotary machine. The method takes the category unbalance weight cross entropy loss function as the classification loss function of the fault diagnosis model, eliminates the influence of the fault category unbalance on the precision of the fault diagnosis model through the category unbalance weight, improves the diagnosis precision of the fault diagnosis model, and realizes the fault diagnosis of the rotary machine.

Description

Rotary machine fault diagnosis method based on class unbalance weight cross entropy
Technical Field
The invention belongs to the technical field of machinery, relates to a rotary machine fault diagnosis method, and particularly relates to a rotary machine fault diagnosis method based on class imbalance weight cross entropy, which can be used for carrying out intelligent detection, state monitoring and equipment maintenance on rotary machines.
Background
The rotating machine is one of the most widely used mechanical devices in industrial equipment, including gears, cams, bearings and other machines capable of rotating, the stability and reliability of the rotating machine directly affect the industrial production activity, and the fault diagnosis of the rotating machine is very important. The fault diagnosis is a process of finding out a fault of a device or a system, in an actual production environment, a rotating machine normally operates for a long time, and a device fault does not occur frequently, so that a problem of serious data imbalance is often faced, and the fault diagnosis is difficult to be used under an actual production condition. The method for solving the data unbalance problem mainly comprises a traditional method and a learning-based method, wherein the traditional method changes data distribution from a data level and reduces the data unbalance degree. The learning-based method learns unbalanced data characteristics by using deep learning technologies of deep characteristic learning such as a deep confidence network, a deep self-encoder and a convolutional neural network, and performs fault diagnosis of class imbalance.
In recent years, learning-based methods have been widely used in the field of fault diagnosis. For example, the application publication number is CN 112364706A, the name is 'a small sample bearing fault diagnosis method based on class imbalance', and discloses a small sample bearing fault diagnosis method based on class imbalance, the method comprises the steps of firstly constructing a class imbalance data set, segmenting one-dimensional original vibration signals through a sliding window, and enhancing one sample into a plurality of small samples with similar characteristics; then, taking the plurality of enhanced samples as input, and extracting signal features by utilizing a deep convolutional neural network; and finally, fault classification is realized by combining an integrated learning classification algorithm. The method adopts a data enhancement processing method to enlarge the sample size, improve the utilization rate of sample points and improve the accuracy of fault diagnosis by adopting an integrated learning method, but has the defects that the sample is enhanced into a small sample with similar characteristics, so that the overfitting of a network is easily caused, more characteristics of the sample cannot be learned, the generalization capability of the network is reduced, and the fault diagnosis precision is lower.
Disclosure of Invention
The invention aims to overcome the defects in the prior art, and provides a rotary machine fault diagnosis method based on class unbalance weight cross entropy, which is used for solving the technical problem of low rotary machine fault diagnosis precision under unbalanced data in the prior art.
In order to achieve the purpose, the technical scheme adopted by the invention comprises the following steps:
(1) Acquiring a training sample set and a testing sample set:
(1a) Carrying out Fourier transform on I vibration signals of the rotating machinery under C fault categories acquired by an acceleration sensor to obtain a frequency domain vibration signal set S = { x = i |1≤i≤I},x i Representing the ith frequency domain vibration signal, wherein C is more than or equal to 2,I and more than or equal to 50000;
(1b) Performing one-hot coding on the fault types corresponding to more than half of the frequency domain vibration signals in the frequency domain vibration signal set S, and taking more than half of the frequency domain vibration signals and the fault type labels corresponding to each signal as a training sample set X 1 Taking the rest frequency domain vibration signals in the frequency domain vibration signal set S as a test sample set X 2 Wherein, training sample set X 1 And test sample set X 2 Each fault category contains an unbalanced number of samples, i.e.
Figure BDA0003086543550000021
N c A number of samples representing a class c fault category;
(2) Constructing a sparse self-encoder model H:
constructing K sparse autoencoders F = { F) including sequential connections 1 ,F 2 ,...,F k ,...,F K H, wherein each sparse self-encoder F k Comprises an encoder and a decoder which are connected in sequence; the encoder and the decoder both adopt a full connection layer with an activation function sigmoid, wherein K is more than or equal to 3,F k Denotes the kth network parameter as
Figure BDA0003086543550000022
The sparse self-encoder of (1);
(3) Performing iterative training on the sparse self-encoder model H:
(3a) Initializing the iteration number to be N, wherein the maximum iteration number is N, N is more than or equal to 200, and N =0;
(3b) Initializing the kth sparse autoencoder F k Is X k And let k =1,X k =X 1
(3c) Mixing X k As a sparse self-encoder modelInput of H, sparse autoencoder F k The encoder in (1) encodes each training sample to obtain a code set X' k ,F k Of the decoder to the encoder of coding set X' k Decoding to obtain a decoded set X ″) k
(3d) Calculate X ″) k And X k Loss of mean square error of
Figure BDA0003086543550000023
And using a counter-propagating method by
Figure BDA0003086543550000024
Compute sparse autoencoder F k Network parameter gradient of
Figure BDA0003086543550000031
Then using a gradient descent algorithm through F k Network parameter gradient of
Figure BDA0003086543550000032
To F k Network parameters of
Figure BDA0003086543550000033
Updating is carried out;
(3e) Judging whether N is more than or equal to N, if so, obtaining a trained sparse self-encoder F' k And executing the step (3 f), otherwise, executing the step (3 c);
(3f) Judging whether K = K is true, if so, obtaining a trained sparse self-coding model H ', otherwise, enabling K = K +1, and simultaneously enabling X' k Performing step (3 c) as an input to the (k + 1) th sparse self-encoder;
(4) Constructing a rotary machine fault diagnosis model O:
(4a) Constructing a structure of a rotary machine fault diagnosis model O:
constructing a rotary machine fault diagnosis model O comprising K encoders and a classifier which are sequentially connected, wherein the encoders adopt sparse self-encoders in a trained sparse self-encoder model H', and the classifier comprises a full connection layer and a softmax activation function output layer which are sequentially connected;
(4b) Defining a class imbalance weight cross entropy loss function J (theta) of a rotary machine fault diagnosis model O:
Figure BDA0003086543550000034
where Σ denotes a summation operation, 1[ ·]The function of the index is expressed,
Figure BDA0003086543550000035
Figure BDA0003086543550000036
and f i Respectively representing the predictive label and the characteristic vector of the ith training sample, log (-) represents the logarithm operation based on a natural constant e,
Figure BDA0003086543550000037
transpose of classifier parameter vector, α, at the time of representing the ith training sample c A class imbalance weight representing a class c fault;
(5) Performing iterative training on a rotating machine fault diagnosis model O:
(5a) The number of initialization iterations is M, the maximum number of iterations is M, M is more than or equal to 100, and the network parameters of the mth iteration classifier are
Figure BDA0003086543550000038
And let m =0;
(5b) Will train sample set X 1 The forward propagation is carried out as the input of a fault diagnosis model O of the rotating machinery to obtain X 1 Classification result of fault category
Figure BDA0003086543550000039
And a feature vector f, and using a class imbalance weight cross entropy loss function J (theta) by
Figure BDA0003086543550000041
And f calculating a loss value of the classifier
Figure BDA0003086543550000042
Then using a back propagation method and passing through the loss value
Figure BDA0003086543550000043
Calculating network parameter gradients for classifiers
Figure BDA0003086543550000044
Finally adopting gradient descent algorithm and passing
Figure BDA0003086543550000045
Network parameters to classifiers
Figure BDA0003086543550000046
Updating is carried out;
(5c) Judging whether M is greater than or equal to M, if so, obtaining a trained fault diagnosis model O' of the rotary machine, otherwise, enabling M = M +1, and executing the step (5 b);
(6) Acquiring a fault diagnosis result of the rotary machine:
(6a) Set X of test samples 2 The forward propagation is carried out as the input of a trained rotary machine fault diagnosis model O' to obtain X 2 Predictive labelset for failure categories
Figure BDA0003086543550000047
And look up in the index table
Figure BDA0003086543550000048
And the subscript corresponding to the medium maximum value corresponds to the fault category.
Compared with the prior art, the invention has the following advantages:
1. the method adopts the loss value of the classifier calculated by the class unbalanced weight cross entropy loss function, and updates the network parameters through the network parameter gradient calculated by the loss value, thereby avoiding the influence of class unbalanced data on the loss value of the classifier, further avoiding the influence of the class unbalanced data on the network parameters, and effectively improving the diagnosis precision of the rotary machine fault.
2. The sparse self-encoder model and the rotary machine fault diagnosis model constructed by the method both comprise a plurality of sparse self-encoders which are connected in sequence, and in the process of training the two models and acquiring the fault diagnosis result of the rotary machine, the sparse self-encoders can better improve the feature extraction capability of the rotary machine fault diagnosis model on the vibration signal, and further improve the fault diagnosis precision of the rotary machine.
Drawings
FIG. 1 is a flow chart of an implementation of the present invention;
fig. 2 is a comparison graph of the fault diagnosis precision of the rolling bearing of the present invention and the prior art.
Detailed Description
The invention is described in further detail below with reference to the figures and the specific embodiments.
Referring to fig. 1, the present invention includes the steps of:
step 1) obtaining a training sample set and a testing sample set:
step 1 a) performing Fourier transform on I vibration signals of the rotating machine under C fault categories acquired by an acceleration sensor to obtain a frequency domain vibration signal set S = { x = i |1≤i≤I},x i The ith frequency domain vibration signal is represented, wherein C is not less than 2,I not less than 50000, in the example, the rotating machinery adopts a rolling bearing, C =12, I =50000, and Fourier transform is adopted to obtain the frequency domain information of the vibration signal, so that the sparse self-encoder model can extract more useful features to a certain extent, and the Fourier transform formula is as follows:
Figure BDA0003086543550000051
where F (ω) represents a frequency domain vibration signal, [ integral ] represents an integral operation, [ infinity ] represents infinity, F (t) represents a time domain vibration signal, [ omega ] represents frequency, t represents time, e represents -jωt Represents the complex function, dt represents the derivative of t;
step 1 b) to the frequency domainPerforming one-hot coding on fault categories corresponding to three-quarter frequency domain vibration signals in the vibration signal set S, and taking the three-quarter frequency domain vibration signals in the S and fault category labels corresponding to each signal as a training sample set X 1 Taking the rest frequency domain vibration signals in the frequency domain vibration signal set S as a test sample set X 2 Wherein, training sample set X 1 And test sample set X 2 In which the number of samples per fault category is not equal, i.e. in which
Figure BDA0003086543550000052
N c The number of samples representing class c fault category, in this example, 6 unbalanced cases of category are set, as shown in table 1:
TABLE 1
Class of failure Case1 Case 2 Case 3 Case 4 Case 5 Case 6
C1 200 200 200 200 200 200
C2 200 180 170 160 150 180
C3 200 180 170 160 150 180
C4 200 180 170 160 150 180
C5 200 180 170 160 150 160
C6 200 180 170 160 150 160
C7 200 180 170 160 150 160
C8 200 180 170 160 150 150
C9 200 180 170 160 150 150
C10 200 180 170 160 150 150
C11 200 180 170 160 150 150
C12 200 180 170 160 150 150
Step 2), constructing a sparse autoencoder model H:
constructing K sparse autoencoders F = { F) including sequential connections 1 ,F 2 ,...,F k ,...,F K A sparse autoencoder model of each sparse autoencoder F k Comprises an encoder and a decoder which are connected in sequence; the encoder and the decoder both adopt a full connection layer with an activation function sigmoid, wherein K is more than or equal to 3,F k Denotes the kth network parameter as
Figure BDA0003086543550000061
In this example, K =3, the 3 sparse autoencoders connected in sequence can better extract the depth characteristics of the frequency domain vibration signal, and the hyper-parameters of the sparse autoencoder model H include the network node number, the learning rate, the penalty coefficient, and the like, which are set as shown in table 2:
TABLE 2
Figure BDA0003086543550000062
Step 3), carrying out iterative training on the sparse self-encoder model H:
step 3 a) initializing the iteration number to be N, wherein the maximum iteration number is N, N is more than or equal to 200, and N =0, in this example, N =200;
step 3 b) initializing the kth sparse autoencoder F k Is X k And let k =1,X k =X 1
Step 3 c) converting X k Sparse autoencoder F as input to sparse autoencoder model H k The encoder in (1) encodes each training sample to obtain a code set X' k ,F k Decoder of (2) encodes encoder set X' k Decoding to obtain a decoded set X ″) k
Step 3 d) calculating X ″ k And X k Loss of mean square error of
Figure BDA0003086543550000063
And using a counter-propagating method by
Figure BDA0003086543550000064
Compute sparse autoencoder F k Network parameter gradient of
Figure BDA0003086543550000065
Then using a gradient descent algorithm through F k Network parameter gradient of
Figure BDA0003086543550000066
To F k Network parameters of
Figure BDA0003086543550000067
Updating is performed, wherein X ″' is calculated k And X k Loss of mean square error of
Figure BDA0003086543550000068
Compute sparse autoencoder F k Network parameter gradient of
Figure BDA0003086543550000069
To F k Network parameters of
Figure BDA00030865435500000610
Updating, wherein the calculation formula and the updating formula are respectively as follows:
Figure BDA0003086543550000071
Figure BDA0003086543550000072
Figure BDA0003086543550000073
wherein p represents a training sample set X 1 The number of training samples in the training sequence,
Figure BDA0003086543550000074
in order to represent the derivation of the partial derivatives,
Figure BDA0003086543550000075
sparse autoencoder F at time n +1 of representation iteration k The network parameters of (a) are set,
Figure BDA0003086543550000076
sparse autoencoder F at time representing iteration nth k The network parameters of (a) are set,
Figure BDA0003086543550000077
for sparse self-encoders F k The learning rate of (c);
step 3 e) judging whether N is more than or equal to N, if so, obtaining a trained sparse self-encoder F' k And executing step 3 f), otherwise, executing step 3 c);
step 3 f) judging whether K = K is true, if so, obtaining a trained sparse self-coding model H ', otherwise, enabling K = K +1, and simultaneously enabling X' k Performing step 3 c) as an input to the (k + 1) th sparse self-encoder;
step 4), constructing a fault diagnosis model O of the rotating machinery:
step 4 a) constructing a structure of a fault diagnosis model O of the rotary machine:
the method comprises the following steps of constructing a rotary machine fault diagnosis model O comprising K encoders and a classifier which are connected in sequence, wherein the encoders adopt sparse self-encoders in trained sparse self-encoder models H', the classifier comprises a full-connection layer and a softmax activation function output layer which are connected in sequence, and in the example, the hyper-parameters of the rotary machine fault diagnosis model O comprise learning rate, the number of network nodes and the like, and are set as shown in a table 3:
TABLE 3
Number of network nodes 200-100-50-25-12
Learning rate 0.0005
Learning rate attenuation coefficient 0.99
Step 4 b), defining a category unbalance weight cross entropy loss function J (theta) of the rotary machine fault diagnosis model O:
Figure BDA0003086543550000081
where Σ represents the summation operation, 1[ ·]The function of the index is expressed,
Figure BDA0003086543550000082
Figure BDA0003086543550000083
and f i Respectively representing the prediction label and the feature vector of the ith training sample, log (-) represents a logarithm operation based on a natural constant e,
Figure BDA0003086543550000084
transpose of classifier parameter vector, α, at the time of representing the ith training sample c A class imbalance weight representing a class c fault;
step 5) iterative training is carried out on the rotary machine fault diagnosis model O:
step 5 a) initializing the iteration times to be M, the maximum iteration times to be M, M is more than or equal to 100, and the network parameters of the mth iteration classifier are
Figure BDA0003086543550000085
Let M =0, M =100 in this example;
step 5 b) training sample set X 1 The forward propagation is carried out as the input of a fault diagnosis model O of the rotating machinery to obtain X 1 Classification result of fault category
Figure BDA0003086543550000086
And a feature vector f, and using a class imbalance weight cross entropy loss function J (theta) by
Figure BDA0003086543550000087
And f calculating a loss value of the classifier
Figure BDA0003086543550000088
Then using a back propagation method and passing through the loss value
Figure BDA0003086543550000089
Calculating network parameter gradients for classifiers
Figure BDA00030865435500000810
Finally, the network parameters of the classifier are subjected to gradient pair by adopting a gradient descent algorithm through the network parameter gradient of the classifier
Figure BDA00030865435500000811
Performing an update in which a loss value of the classifier is calculated
Figure BDA00030865435500000812
Calculating network parameter gradients for classifiers
Figure BDA00030865435500000813
Network parameters of classifier
Figure BDA00030865435500000814
The update formulas of (a) and (b) are respectively:
Figure BDA00030865435500000815
α c =exp(-A c )
Figure BDA00030865435500000816
Figure BDA00030865435500000817
Figure BDA00030865435500000818
wherein A is c Representing the prediction accuracy rate of the rotary machine fault diagnosis model O on the class c fault category, n c The number of samples representing that the rotating machinery fault diagnosis model O correctly predicts that the training samples belong to the class c fault category, exp (-) represents exponential operation with e as base,
Figure BDA0003086543550000091
network parameter, l, representing the classifier at time m +1 of iteration C Representing the learning rate of the classifier.
In the above steps, the category imbalance weight cross entropy loss function is used as a classification loss function of the fault diagnosis model, and the influence of the fault category imbalance on the classifier loss is eliminated through the category imbalance weight;
step 5 c) judging whether M is larger than or equal to M, if so, obtaining a trained rotary machine fault diagnosis model O', otherwise, enabling M = M +1, and executing the step (5 b);
step 6) obtaining a fault diagnosis result of the rotary machine:
set X of test samples 2 The forward propagation is carried out as the input of a trained rotary machine fault diagnosis model O' to obtain X 2 Predictive labelset for failure categories
Figure BDA0003086543550000092
And look up in the index table
Figure BDA0003086543550000093
And the subscript corresponding to the medium maximum value corresponds to the fault category.
The technical effects of the invention are further explained by combining simulation experiments as follows:
1. simulation conditions and contents:
the hardware platform of the simulation experiment is as follows: the central processing unit is Intel (R) Core (TM) i5-7500 CPU, the main frequency is 3.40GHZ, and the memory is 16G.
The software platform of the simulation experiment is as follows: WINDOWS 7 operating system and Python 3.7.
The time domain vibration signals used in the simulation experiment are all from the bearing time domain vibration signals collected by the bearing accelerated life test bench PRONOSTIA. The platform consists of three parts: the device comprises a driving module, a load module and a data acquisition module. The main function of the test device is to provide signals of different fault types, the main components of the test device comprise a driving motor, a torque sensor and a dynamometer, the power of the driving motor is 1.2Kw, and the maximum rotating speed is 6000r/min. The bearing model is 6205-2RS JEM SKF, an acceleration sensor (DYTRAN 3035B) is arranged near the driving end, and the sampling frequency is 12kHz. The working conditions are as follows: rotation speed 1800rpm, load 4000N. The test bearing mainly comprises four fault states of a normal state, a roller defect (BD), an outer ring defect (OR) and an inner ring defect (IR). Using electric discharge machining to introduce a single point fault into the test bearings, with fault diameters of 0.007, 0.014, 0.021 and 0.028 inches, for four size types, a total of 12 fault categories of rolling bearing time domain vibration signals were obtained including different fault conditions, different fault diameter sizes and different fault orientations, as shown in table 4:
TABLE 4
Position of Diameter (inches) Direction Label (R)
Is normal 0 - 1
Roller 0.007 - 2
Roller 0.014 - 3
Roller 0.021 - 4
Inner ring 0.007 - 5
Inner ring 0.014 - 6
Inner ring 0.021 - 7
Outer ring 0.007 Vertical 3 o' clock direction 8
Outer ring 0.007 Center 6 o' clock direction 9
Outer ring 0.014 Center 6 o' clock direction 10
Outer ring 0.021 Vertical 3 o' clock direction 11
Outer ring 0.021 Center 6 o' clock direction 12
The rolling bearing fault diagnosis precision of the normalized CNN based on data imbalance of the invention and the prior art is compared and simulated, and the result is shown in FIG. 2.
2. And (3) simulation result analysis:
the simulation experiment of the invention is to classify 6 different cases listed in table 1 by respectively adopting the method of the invention and the prior art (based on the normalized CNN rolling bearing fault diagnosis of data imbalance) and compare the results.
The prior art normalized CNN rolling bearing fault diagnosis Based on data imbalance refers to a rolling bearing fault diagnosis method proposed in the paper published by Bo ZHao et al, "Intelligent fault diagnosis of rolling bearings Based on normalized CNN conditioning data and variable working conditions, knowledge-Based Systems, volume 199,8July 2020, 105971".
In order to evaluate the effect of the invention, the accuracy of the classification results of 6 cases in the simulation experiment of the invention is respectively calculated by using the following formula of evaluation indexes (classification accuracy Acc), and the calculation results are drawn as table 5, wherein the expression of Acc is as follows:
Figure BDA0003086543550000111
in the formula (I), the compound is shown in the specification,
Figure BDA0003086543550000112
Figure BDA0003086543550000113
a prediction tag, y, representing the jth test sample j The actual label representing the jth test sample, J representing the total number of samples in the test sample set.
TABLE 5
Method Case1 Case 2 Case 3 Case 4 Case 5 Case 6
The invention 0.9958 0.9892 0.9908 0.9742 0.9867 0.9850
Prior Art 0.9850 0.9793 0.9775 0.9741 0.9686 0.9680
Referring to fig. 2, the abscissa represents different cases, and the ordinate represents the accuracy, and it can be seen from fig. 2 that the accuracy of the classification result of the method of the present invention is higher than that of the prior art in 6 cases compared with the prior art, and is significantly improved in case 3, case 5 and case 6, which proves that the present invention can better perform fault diagnosis and simultaneously improve the fault diagnosis accuracy under the condition of unequal sample numbers of each fault category.
The above simulation experiments show that: the sparse self-encoder model and the rotary machine fault diagnosis model constructed by the method both comprise a plurality of sparse self-encoders which are connected in sequence, in the process of training the two models and acquiring the fault diagnosis result of the rotary machine, the sparse self-encoders can better improve the feature extraction capability of the rotary machine fault diagnosis model on vibration signals, a category unbalance weight cross entropy loss function is used as a classification loss function of the fault diagnosis model, the influence of fault category unbalance on classification loss is eliminated through the category unbalance weight, the diagnosis precision of the fault diagnosis model is improved, and the technical problem of low rotary machine fault diagnosis precision under unbalanced data in the prior art is solved.

Claims (3)

1. A rotary machine fault diagnosis method based on class imbalance weight cross entropy is characterized by comprising the following steps:
(1) Acquiring a training sample set and a testing sample set:
(1a) Fourier transformation is carried out on I vibration signals of the rotating machinery under C fault categories acquired through the acceleration sensor, and a frequency domain vibration signal set S = { x = (x) } is obtained i |1≤i≤I},x i Representing the ith frequency domain vibration signal, wherein C is more than or equal to 2,I and more than or equal to 50000;
(1b) Performing one-hot coding on fault categories corresponding to more than half of frequency domain vibration signals in the frequency domain vibration signal set S, and taking more than half of frequency domain vibration signals and fault category labels corresponding to each signal thereof as a training sample set X 1 Taking the rest frequency domain vibration signals in the frequency domain vibration signal set S as a test sample set X 2 Wherein, training sample set X 1 And a test specimenCollection X 2 Each fault class contains an unbalanced number of samples, i.e.
Figure FDA0003086543540000011
N c A number of samples representing a class c fault category;
(2) Constructing a sparse self-encoder model H:
constructing K sparse autoencoders F = { F) including sequential connections 1 ,F 2 ,...,F k ,...,F K H, wherein each sparse self-encoder F k Comprises an encoder and a decoder which are connected in sequence; the encoder and the decoder both adopt a full connection layer with an activation function sigmoid, wherein K is more than or equal to 3,F k Denotes the kth network parameter as
Figure FDA0003086543540000012
The sparse self-encoder of (1);
(3) Performing iterative training on the sparse self-encoder model H:
(3a) Initializing the iteration number to be N, wherein the maximum iteration number is N, N is more than or equal to 200, and N =0;
(3b) Initializing the kth sparse autoencoder F k Is X k And let k =1,X k =X 1
(3c) X is to be k Sparse autoencoder F as input to sparse autoencoder model H k The encoder in (1) encodes each training sample to obtain a code set X' k ,F k Of the decoder to the encoder of coding set X' k Decoding to obtain a decoded set X ″) k
(3d) Calculate X ″) k And X k Loss of mean square error of
Figure FDA0003086543540000021
And using a counter-propagating method by
Figure FDA0003086543540000022
Compute sparse autoencoder F k Network parameter gradient of
Figure FDA0003086543540000023
Then using a gradient descent algorithm through F k Network parameter gradient of
Figure FDA0003086543540000024
To F k Network parameters of
Figure FDA0003086543540000025
Updating is carried out;
(3e) Judging whether N is more than or equal to N, if so, obtaining a trained sparse self-encoder F' k And executing the step (3 f), otherwise, executing the step (3 c);
(3f) Judging whether K = K is true, if so, obtaining a trained sparse self-coding model H ', otherwise, enabling K = K +1, and simultaneously enabling X' k Performing step (3 c) as an input to the (k + 1) th sparse self-encoder;
(4) Constructing a rotary machine fault diagnosis model O:
(4a) Constructing a structure of a rotary machine fault diagnosis model O:
constructing a rotary machine fault diagnosis model O comprising K encoders and a classifier which are sequentially connected, wherein the encoders adopt sparse self-encoders in a trained sparse self-encoder model H', and the classifier comprises a full connection layer and a softmax activation function output layer which are sequentially connected;
(4b) Defining a class imbalance weight cross entropy loss function J (theta) of a rotary machine fault diagnosis model O:
Figure FDA0003086543540000026
where Σ denotes a summation operation, 1[ ·]The function of the index is expressed,
Figure FDA0003086543540000027
Figure FDA0003086543540000028
and f i Respectively representing the predictive label and the characteristic vector of the ith training sample, log (-) represents the logarithm operation based on a natural constant e,
Figure FDA0003086543540000029
transpose of classifier parameter vector, α, at the time of representing the ith training sample c A class imbalance weight representing a class c fault;
(5) Performing iterative training on a rotating machine fault diagnosis model O:
(5a) The number of initialization iterations is M, the maximum number of iterations is M, M is more than or equal to 100, and the network parameters of the mth iteration classifier are
Figure FDA00030865435400000210
And let m =0;
(5b) Will train sample set X 1 The forward propagation is carried out as the input of a fault diagnosis model O of the rotating machinery to obtain X 1 Classification result of fault category
Figure FDA0003086543540000031
And a feature vector f, and using a class imbalance weight cross entropy loss function J (theta) by
Figure FDA0003086543540000032
And f calculating a loss value of the classifier
Figure FDA0003086543540000033
Then using a back propagation method and passing through the loss value
Figure FDA0003086543540000034
Calculating network parameter gradients for classifiers
Figure FDA0003086543540000035
Finally, a gradient descent algorithm is adopted andby passing
Figure FDA0003086543540000036
Network parameters to classifiers
Figure FDA0003086543540000037
Updating is carried out;
(5c) Judging whether M is greater than or equal to M, if so, obtaining a trained fault diagnosis model O' of the rotary machine, otherwise, enabling M = M +1, and executing the step (5 b);
(6) Acquiring a fault diagnosis result of the rotary machine:
(6a) Set X of test samples 2 The forward propagation is carried out as the input of a trained rotary machine fault diagnosis model O' to obtain X 2 Predictive labelset for failure categories
Figure FDA0003086543540000038
And look up in the index table
Figure FDA0003086543540000039
And the subscript corresponding to the medium maximum value corresponds to the fault category.
2. The method for diagnosing faults of rotating machinery based on class imbalance weight cross entropy as claimed in claim 1, wherein the step (3 d) calculates X ″ " k And X k Loss of mean square error of
Figure FDA00030865435400000310
Compute sparse autoencoder F k Network parameter gradient of
Figure FDA00030865435400000311
To F k Network parameters of
Figure FDA00030865435400000312
Updating, wherein the calculation formula and the updating formula are respectively as follows:
Figure FDA00030865435400000313
Figure FDA00030865435400000314
Figure FDA00030865435400000315
wherein p represents a training sample set X 1 The number of training samples in the training sequence,
Figure FDA00030865435400000316
in order to represent the derivation of the partial derivatives,
Figure FDA00030865435400000317
sparse autoencoder F at time n +1 of representation iteration k The network parameters of (a) are set,
Figure FDA00030865435400000318
sparse autoencoder F at time representing iteration nth k The network parameters of (a) are set,
Figure FDA00030865435400000319
for sparse self-encoders F k The learning rate of (2).
3. The method for diagnosing faults of rotating machinery based on class-C imbalance weight cross entropy as claimed in claim 1, wherein the class-C imbalance weight α of the fault in step (4 b) c The calculation formula is as follows:
α c =exp(-A c )
Figure FDA0003086543540000041
where exp (. Cndot.) denotes the exponential operation with e as base, A c Representing the prediction accuracy rate of the rotary machine fault diagnosis model O on the class c fault category, n c And the number of samples representing that the rotating machinery fault diagnosis model O correctly predicts that the training samples belong to the class c fault category.
CN202110584346.0A 2021-05-27 2021-05-27 Rotary machine fault diagnosis method based on class unbalance weight cross entropy Active CN113312719B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110584346.0A CN113312719B (en) 2021-05-27 2021-05-27 Rotary machine fault diagnosis method based on class unbalance weight cross entropy

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110584346.0A CN113312719B (en) 2021-05-27 2021-05-27 Rotary machine fault diagnosis method based on class unbalance weight cross entropy

Publications (2)

Publication Number Publication Date
CN113312719A CN113312719A (en) 2021-08-27
CN113312719B true CN113312719B (en) 2023-02-10

Family

ID=77375545

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110584346.0A Active CN113312719B (en) 2021-05-27 2021-05-27 Rotary machine fault diagnosis method based on class unbalance weight cross entropy

Country Status (1)

Country Link
CN (1) CN113312719B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118298600B (en) * 2024-06-06 2024-08-13 山东斯诺电子有限公司 Gas pipeline valve fault monitoring and alarming method, system and storage medium
CN118378167B (en) * 2024-06-24 2024-09-13 湖南科技大学 Transmission chain fault diagnosis method based on zero sequence current correlation entropy reinforcement sparse learning

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20190339688A1 (en) * 2016-05-09 2019-11-07 Strong Force Iot Portfolio 2016, Llc Methods and systems for data collection, learning, and streaming of machine signals for analytics and maintenance using the industrial internet of things
CN109102032A (en) * 2018-09-03 2018-12-28 中国水利水电科学研究院 A kind of pumping plant unit diagnostic method based on depth forest and oneself coding
CN110286279B (en) * 2019-06-05 2021-03-16 武汉大学 Power electronic circuit fault diagnosis method based on extreme tree and stack type sparse self-coding algorithm
CN110334764B (en) * 2019-07-04 2022-03-04 西安电子科技大学 Rotary machine intelligent fault diagnosis method based on integrated depth self-encoder
CN112115922A (en) * 2020-09-27 2020-12-22 天津工业大学 Rotary machine fault diagnosis method for enhancing deep feature learning

Also Published As

Publication number Publication date
CN113312719A (en) 2021-08-27

Similar Documents

Publication Publication Date Title
CN112418013B (en) Complex working condition bearing fault diagnosis method based on meta-learning under small sample
CN109918752B (en) Mechanical fault diagnosis method, equipment and medium based on migration convolution neural network
CN110210381B (en) Domain separation self-adaptive one-dimensional convolutional neural network intelligent fault diagnosis method
CN110110768B (en) Rolling bearing fault diagnosis method based on parallel feature learning and multiple classifiers
CN112257530B (en) Rolling bearing fault diagnosis method based on blind signal separation and support vector machine
CN113312719B (en) Rotary machine fault diagnosis method based on class unbalance weight cross entropy
CN112347898B (en) Rolling bearing health index construction method based on DCAE neural network
CN116793682A (en) Bearing fault diagnosis method based on iCORAL-MMD and anti-migration learning
CN112364706A (en) Small sample bearing fault diagnosis method based on class imbalance
CN110188822A (en) A kind of domain is to the one-dimensional convolutional neural networks intelligent failure diagnosis method of anti-adaptive
CN114755017B (en) Variable-speed bearing fault diagnosis method of cross-domain data driving unsupervised field shared network
CN114492642A (en) Mechanical fault online diagnosis method for multi-scale element depth residual shrinkage network
CN114462446A (en) Rolling bearing fault diagnosis method based on vibration signal and electronic equipment
CN114048787B (en) Method and system for intelligently diagnosing bearing fault in real time based on Attention CNN model
CN114491828A (en) Compound fault diagnosis method based on multi-gating hybrid expert multi-task learning
CN116186641A (en) Cross-equipment rolling bearing small sample fault diagnosis method based on feature fusion
CN113758709A (en) Rolling bearing fault diagnosis method and system combining edge calculation and deep learning
CN113269221A (en) Rolling bearing fault diagnosis method based on multi-scale convolution neural network
CN113409213A (en) Plunger pump fault signal time-frequency graph noise reduction enhancement method and system
CN117037841A (en) Acoustic signal hierarchical cavitation intensity identification method based on hierarchical transition network
CN114818811A (en) Aircraft engine rolling bearing fault diagnosis method based on twin network metric learning
CN114742098A (en) Fault diagnosis method of rolling bearing based on time-frequency diagram and multi-scale CNN
CN113505817A (en) Self-adaptive weighting training method for bearing fault diagnosis model samples under unbalanced data
CN113588266A (en) Rolling bearing composite fault diagnosis method with embedded fault semantic space
CN117407698B (en) Hybrid distance guiding field self-adaptive fault diagnosis method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant