Bearing fault diagnosis method and system based on improved SMOTE and improved bee colony algorithm
By improving the combination of SMOTE and swarm algorithm, the bearing fault diagnosis problem under the unbalanced fault data set is solved, achieving higher diagnostic accuracy and reliability.
Patent Information
- Application Number
- CN202410877109.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-02
- Publication Date
- 2025-05-09
- Estimated Expiration
- 2044-07-02
AI Technical Summary
The prior art is difficult to effectively identify and diagnose bearing failures when dealing with unbalanced fault data sets, especially when a few types of samples are insufficient.
The improved SMOTE algorithm and the improved swarm algorithm are used to balance data through a shared nearest neighbor clustering algorithm based on density ratio, and the random forest model is optimized using simulated binary cross-improved artificial swarm algorithm to improve the accuracy of fault diagnosis.
It effectively improves the bearing fault diagnosis capability under unbalanced sample conditions, and improves the accuracy and reliability of fault diagnosis.
Smart Images

Figure CN118857738B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of rolling bearing fault diagnosis, and in particular relates to a bearing fault diagnosis method and system based on an improved SMOTE and an improved bee colony algorithm. Background Art
[0002] In the context of Industry 4.0, with the development of society, mechanical equipment is gradually moving towards automation, complexity, intelligence and precision, and higher requirements are placed on equipment stability and reliability. Accurate identification and judgment of faults have become the focus of ensuring production safety and the safety of people's lives and property. However, in practice, there is a problem of uneven fault sample data. When the number of a certain type of fault sample is small, how to design a small sample fault diagnosis method becomes the key to solving the problem. The present invention proposes an unbalanced sample bearing fault diagnosis strategy based on improved SMOTE and bee colony algorithm. Summary of the invention
[0003] In view of the shortcomings of the prior art, the present invention proposes a bearing fault diagnosis method and system based on improved SMOTE and improved bee colony algorithm. The proposed fault diagnosis strategy effectively improves the bearing fault diagnosis capability under the condition of unbalanced sample data.
[0004] To achieve the above object, the present invention provides the following solutions:
[0005] The bearing fault diagnosis method based on improved SMOTE and improved bee colony algorithm includes the following steps:
[0006] S1: using a triaxial acceleration sensor to collect bearing fault signal data, and performing segmentation processing on the collected bearing fault signal data to obtain a sample set;
[0007] S2: Combine the shared nearest neighbor clustering algorithm based on density ratio into the synthetic minority oversampling technology SMOTE algorithm to balance the bearing fault signal data of the sample and obtain a balanced data set;
[0008] S3: performing degradation variational mode decomposition on the balanced data set to extract time-frequency domain features of the bearing fault signal data;
[0009] S4: using the Relief-F algorithm to weight the time-frequency domain features and select bearing fault features that meet preset requirements;
[0010] S5: Construct a random forest fault diagnosis model based on improved bee colony algorithm;
[0011] S6: Classify and identify the bearing fault features using the random forest fault diagnosis model.
[0012] Preferably, in S2, the shared nearest neighbor clustering algorithm based on density ratio is combined with the synthetic minority class oversampling technology SMOTE algorithm, and the method for balancing the bearing fault signal data of the sample includes:
[0013] The synthetic minority oversampling technology SMOTE is introduced to balance the samples and obtain primary samples;
[0014] Based on the shared nearest neighbor similarity of the primary samples, the k nearest neighbors of the sample are generated, and the generated nearest neighbors are screened in combination with the average density ratio and the density ratio threshold to obtain a balanced data set.
[0015] Preferably, sample x i The ratio of the average density of the k nearest neighbors is calculated as:
[0016]
[0017] Among them, x is the generated sample, k is the number of newly generated samples, SN k (x i ) is x i According to the k nearest neighbors obtained by similarity, dr(x i ) is the ratio of the density of the newly generated sample to the average density of its nearest neighbors, de(x i ) is the newly generated sample x i density;
[0018] Among them, de(x i ) is obtained by:
[0019]
[0020] Among them, SNN represents the sample x generated by SMOTE i and the original sample x j The shared nearest neighbor similarity between ;
[0021] Among them, the method of obtaining SNN is:
[0022] SNN(x i ,x j )=|N k (x i )∩N k (x j )|,
[0023] Among them, N k (x i ) and N k (x j ) represents x i and x j The nearest neighbor of .
[0024] Preferably, in S5, the method for constructing a random forest fault diagnosis model based on an improved bee colony algorithm includes:
[0025] The artificial bee colony algorithm improved by simulating binary crossover is used to optimize the number of decision trees in the original random forest classification model and the number of features required to build the decision tree, and the optimized random forest model is obtained;
[0026] Based on the optimized random forest model, a random forest fault diagnosis model is obtained.
[0027] The present invention also provides a bearing fault diagnosis system based on improved SMOTE and improved bee colony algorithm, comprising the following steps: an acquisition module, a data balancing module, a feature extraction module, a feature selection module, a classification strategy module and a feature recognition module;
[0028] The acquisition module is used to acquire bearing fault signal data using a triaxial acceleration sensor, and to perform segmented processing on the acquired bearing fault signal data to obtain a sample set;
[0029] The data balancing module is used to combine the shared nearest neighbor clustering algorithm based on density ratio into the synthetic minority class oversampling technology SMOTE algorithm to balance the bearing fault signal data of the sample to obtain a balanced data set;
[0030] The feature extraction module is used to perform degradation variational mode decomposition on the balanced data set to extract the time-frequency domain features of the bearing fault signal data;
[0031] The feature selection module is used to weight the time-frequency domain features using the Relief-F algorithm to select bearing fault features that meet preset requirements;
[0032] The classification strategy module is used to construct a random forest fault diagnosis model based on an improved bee colony algorithm;
[0033] The feature recognition module is used to classify and identify the bearing fault features using the random forest fault diagnosis model.
[0034] Preferably, the data balancing module comprises: a primary data balancing unit and a deep data balancing unit;
[0035] The primary data balancing unit is used to introduce the synthetic minority oversampling technology SMOTE to balance the data of the samples to obtain primary samples;
[0036] The deep data balancing unit is used to generate k nearest neighbors of the sample based on the shared nearest neighbor similarity of the primary samples, and screen the generated nearest neighbors in combination with the average density ratio and the density ratio threshold to obtain a balanced data set.
[0037] Preferably, sample x i The ratio of the average density of the k nearest neighbors is calculated as:
[0038]
[0039] Among them, x is the generated sample, k is the number of newly generated samples, SN k (x i ) is x i According to the k nearest neighbors obtained by similarity, dr(x i ) is the ratio of the density of the newly generated sample to the average density of its nearest neighbors, de(x i ) is the newly generated sample x i density;
[0040] Among them, de(x i ) is obtained by:
[0041]
[0042] Among them, SNN represents the sample x generated by SMOTE i and the original sample x j The shared nearest neighbor similarity between ;
[0043] Among them, the process of SNN acquisition is:
[0044] SNN(x i ,x j )=|N k (x i )∩N k (x j )|,
[0045] Among them, N k (x i ) and N k (x j ) represents x i and x j The nearest neighbor of .
[0046] Preferably, the classification strategy module includes: an optimization unit and a classifier unit;
[0047] The optimization unit is used to optimize the number of decision trees in the original random forest classification model and the number of features required to construct the decision trees by using an artificial bee colony algorithm improved by simulating binary crossover, so as to obtain an optimized random forest model;
[0048] The classifier unit is used to obtain a random forest fault diagnosis model based on the optimized random forest model.
[0049] Compared with the prior art, the present invention has the following beneficial effects:
[0050] The unbalanced sample bearing fault diagnosis strategy based on improved SMOTE and bee colony algorithm proposed in this invention introduces a shared nearest neighbor clustering algorithm based on density ratio when processing the classification of unbalanced fault data sets. On the basis of primary samples generated by SMOTE, the k nearest neighbors of a few samples are found to enhance the sample quantity and quality. At the same time, in order to improve the classification performance of random forest, an improved artificial bee colony algorithm based on simulated binary crossover is proposed to optimize the key parameters of random forest, thereby effectively improving the accuracy of fault diagnosis. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] In order to more clearly illustrate the technical solution of the present invention, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0052] Figure 1 This is a flow chart of a bearing fault diagnosis method based on an improved SMOTE and an improved bee colony algorithm according to an embodiment of the present invention;
[0053] Figure 2 A schematic diagram of a random forest algorithm according to an embodiment of the present invention;
[0054] Figure 3 A schematic diagram of a crossover operation according to an embodiment of the present invention;
[0055] Figure 4 A schematic diagram of a simulated binary crossover improved bee colony algorithm according to an embodiment of the present invention;
[0056] Figure 5 Schematic diagram of the classification results of the public data set according to an embodiment of the present invention. DETAILED DESCRIPTION
[0057] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0058] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.
[0059] Embodiment 1
[0060] like Figure 1 As shown, an embodiment of the present invention provides a bearing fault diagnosis method based on improved SMOTE and improved bee colony algorithm, including the following steps: S1: using a three-axis acceleration sensor to collect bearing fault signal data, and performing segmentation processing on the collected bearing fault signal data to obtain a sample set; S2: combining a shared nearest neighbor clustering algorithm based on density ratio into a synthetic minority class oversampling technology SMOTE algorithm, balancing the bearing fault signal data of the sample, and obtaining a balanced data set; S3: performing degradation variational mode decomposition on the balanced data set to extract the time-frequency domain features of the bearing fault signal data; S4: using the Relief-F algorithm to weight-sort the time-frequency domain features, and selecting bearing fault features that meet preset requirements; S5: constructing a random forest fault diagnosis model based on an improved bee colony algorithm; S6: using the random forest fault diagnosis model to classify and identify the bearing fault features.
[0061] The specific implementation steps of this embodiment are as follows:
[0062] Step 1: Use a dynamic sliding window to segment the collected vibration signal and construct a sample set.
[0063] Step 2: In order to overcome the overfitting and deviation caused by the small amount of individual bearing fault data, the synthetic minority oversampling technology (SMOTE) is introduced for data balancing. In order to further improve the accuracy of sample generation by the algorithm, the shared nearest neighbor clustering algorithm based on density ratio is combined with the SMOTE algorithm. Based on the primary samples generated by SMOTE, the k nearest neighbors of the minority samples are generated according to their shared nearest neighbor similarity, and the generated nearest neighbors are screened in combination with the average density ratio and the density ratio threshold drT to obtain more samples.
[0064] Step 3: Perform degradation variational mode decomposition on the vibration data to obtain decomposition signals in 7 dimensions and extract time-frequency domain features for each decomposition signal to obtain 29 features such as peak index, pulse index, and center of gravity frequency, ensuring that 203 features are extracted from the original signal; in order to reduce the impact of the dimension of the training set on the computational complexity, the Relief-F algorithm is used to weight the features, which is used as a reference for the number of features of the training set in the subsequent input model matrix;
[0065] Step 4: Use the random forest strategy to classify and identify fault features. Considering that traditional manual parameter selection cannot guarantee the optimal recognition effect, the present invention uses the artificial bee colony algorithm to optimize the selection of features required for building decision trees, and optimizes the number of decision trees in the random forest to improve the classification accuracy of the random forest; in order to improve the local optimization ability of the bee colony algorithm, a simulated binary crossover strategy is introduced in the observation bee stage. By adjusting the genetic information between the two parent individuals, the offspring individuals can change on the basis of the parent generation, thereby enhancing the information exchange between each generation of honey sources, and improving the ability of the bee colony algorithm to jump out of the local optimal solution.
[0066] Step 5: Input the data into the constructed fault diagnosis model, compare the obtained diagnosis results and fine-tune the parameters of the classifier and optimization strategy to obtain the best diagnosis effect;
[0067] In this embodiment, a three-axis acceleration sensor is used to collect bearing data, and the collected bearing data is processed in sections, and a small number of sample bearing data are further balanced.
[0068] The SMOTE algorithm used for data balancing in the present invention is an oversampling method, which obtains new samples similar to the minority samples by performing calculations between the minority samples. The algorithm implementation steps are as follows:
[0069] Step 1: Set the sample with fewer fault types to be X = {x1, x2,…, x i}, data sampling rate N, sample neighbor number K;
[0070] Step 2: Perform K-nearest neighbor processing on all minority class samples, and find l neighboring samples x for each minority class sample. m ;
[0071] Step 3: Generate a random number δ between [0,1];
[0072] Step 4: Generate new sample xnew using formula (1);
[0073] x new =x i +(x m -x i )δ (1)
[0075] Where: x i Represents the parent, x m represents the reference sample, x new represents a newly synthesized sample; δ represents a random number between [0,1].
[0076] Step 5: All generated x new Add to set S.
[0077] After the above five operations, new samples are generated, providing a more robust and reliable foundation for subsequent model training. Furthermore, in order to improve the accuracy of samples generated by the SMOTE strategy, a shared nearest neighbor clustering algorithm based on density ratio is introduced into SMOTE. The primary samples generated by SMOTE are brought into it. According to the primary similarity, the k nearest neighbors of a few samples are found, and the average density ratio calculated by equations (2), (3), and (4) is further compared with the density ratio threshold drT (generally set to 1) to determine whether to retain it.
[0078] The sample x generated by SMOTE i and the original sample x j The calculation of the shared nearest neighbor similarity (SNN) between can be completed by formula (2):
[0079] SNN(x i ,x j )=|N k (x i )∩N k (x j )| (2)
[0080] Calculate the newly generated sample x i Density:
[0081]
[0082] Calculate the ratio of the density of a newly generated sample to the average density of its nearest neighbors:
[0083]
[0084] Among them, x is the generated sample, k is the number of newly generated samples, SN k (x i ) is x i The k nearest neighbors obtained based on similarity.
[0085] In this embodiment, feature extraction and feature selection are performed on the balanced data set to achieve data optimization. The implementation process is as follows.
[0086] RVMD is a data-driven reduced-order variational mode decomposition method that is more advantageous in dealing with nonlinearities and is not inferior to non-stationary signals.
[0087] RVMD decomposes a low-frequency mode of the original signal into two modes through the variational mode decomposition (VMD) operation until the two modes separated by VMD are close enough in center frequency. The stopping criterion is defined as
[0088] f d =(f h -f l ) / f l (5)
[0089] where f l Corresponding to the low-frequency center frequency, f h is the high frequency center frequency. If f d If it is greater than the threshold, it stops, that is, the original signal Ui(t)=Ul(t)+Uh(t). Since the vibration signal has a second-order cyclostationarity, we can get:
[0090]
[0091] Where X is the envelope of each mode, τ = q / fs represents the delay factor, and q = 0, 1, ... N-1. RVMD is used to obtain multiple sub-signals of different frequency bands, and the time-frequency domain features are extracted for each sub-signal.
[0092] In order to reduce the impact of generated features on computing speed and accuracy, the present invention uses the Relief-F algorithm to perform feature selection. It updates the weight of each feature by considering the average close distance samples between each category, so that it can effectively process multi-category data sets.
[0093] Assume that the total sample set S = {s1, s2, ..., s m}, each sample includes p features, s i ={s i1 ,s i2 ,…,s ip}, l(l>2) classes, the sample set is C={c1,c2,…,c l}. The Relief-F algorithm selects d s from each class of samples i The nearest neighbor sample is put into the set H and recorded as i The same sample set will then be compared with s i Different types of samples are put into the set M(c) according to their categories. Then s i The distance between samples of the same type is expressed as (12). Analyzing the above formula, we can get that the Relief-F algorithm converts s i The distance s from class c (c≠class(si)) iAverage the differences of the d samples of the nearest neighbors on feature t, and then multiply by the proportion of class c samples in all samples related to s i to obtain the distance between feature t in s i and class c. Finally, repeat this operation for all classes different from s i and take the average of all results to obtain the distance between feature t among different types of samples.
[0094]
[0095] s i The distance between s and samples of different types from it is expressed as
[0096]
[0097] In the formula:
[0098]
[0099] Combining the above formula, the update formula for the weight is
[0100] w t = w t -L(s i , x ∈ H) + L(s i , x ∈ M(c)) (10)
[0101] For each calculated weight w t , then sort all the w t of the features from largest to smallest, and also arrange the corresponding features. A new feature matrix can be obtained.
[0102] In this embodiment, based on the obtained feature vectors, a random forest model optimized by the artificial bee colony algorithm (random forest fault diagnosis model based on the improved bee colony algorithm) is used to diagnose the faults of the bearing.
[0103] The random forest algorithm is constructed using the idea such as Figure 2 :
[0104] (1) Let the original training set be D. Repeatedly draw k sample sets by the Bootstrap resampling method, and then construct classification trees based on the newly drawn sample sets;
[0105] (2) Each new sample set contains v dimensions, and then randomly select m (m < v) dimensions. Determine the threshold for attribute classification by checking each classification point, and then select the most suitable result among the m dimensions;
[0106] (3) The generation process of each decision tree is unconstrained, and the most appropriate result is obtained through the m dimensions in the sample set. When the decision tree is learned, it means that a unit of the random forest is completed. Each independent unit is carried out synchronously. When all decision trees are trained, it means that the random forest has completed training;
[0107] (4) When the sample D to be tested enters the random forest, the sample to be tested is used according to steps (1) and (2). If the final discrimination result can be likened to voting, the prediction category with the most votes is the final prediction result.
[0108] There are two key parameters in the random forest algorithm, namely the number of decision trees and the minimum number of sample leaf nodes. These two parameters have an important impact on the classification performance of the model. The number of decision trees determines the number of trees in the model. Increasing the number of decision trees can improve the classification accuracy and make the classification of samples richer, but it will also increase the running time and affect the efficiency of the algorithm. Therefore, choosing the right value is crucial to optimizing the model.
[0109] The present invention introduces an artificial bee colony algorithm to optimize two key parameters of the random forest to improve the accuracy of model classification.
[0110] When the artificial bee colony algorithm solves the problem of optimal solution, the information of the nectar source represents all possible solutions to the problem. The quality of the nectar source i (i = 1, 2, ..., NP) directly corresponds to the fitness value fit, and NP is the number of bees. The artificial bee colony algorithm divides the bee colony into three types: collecting bees, observation bees, and scout bees.
[0111] The initial individual of nectar source i According to formula (11), it is generated in the search space:
[0112]
[0113] in and Represent the upper and lower limits of the j-th dimension solution space respectively. In the bee-collecting stage, a new nectar source v im It is in the honey source x im Generated by surrounding search;
[0114]
[0115] Where: m is a randomly generated integer in [1,M], indicating that the bee randomly searches a dimension; j∈{1,2,…,NP}, j≠i, X j Indicates following a honey source not equal to i among NP honey sources; rand(0,1) is a random number between [0,1]. iThe fitness is better than X i When using the greedy algorithm to calculate V i Instead of X i Otherwise keep X i After all the bees complete the calculation of the new nectar source, they share the nectar source information. The observation bees calculate the probability of following the bees according to the nectar source information left by the bees according to formula (13):
[0116]
[0117] The observation bee selects the bees through its internal algorithm, that is, using the roulette method to generate a random number Q in [0,1]. If P i If it is greater than Q, the observer bee will regenerate a new nectar source.
[0118] In the whole search process, if the honey source X i Keep updating and iterating, but when the number of iterations is equal to the threshold limit, no better nectar source is found. i will be discarded, and the corresponding observer bee will disappear, because the disappearance of the observer bee means that the best fitness did not appear in the previous nectar source. In order to continue working, the observer bee will then transform into a scout bee. The newly appeared scout bee will randomly generate a new nectar source in the search space to replace X. i , the above process is as follows:
[0119]
[0120] The fitness evaluation index P of the optimal solution will be calculated according to formula (15).
[0121]
[0122] In the formula, fit i is the fitness of the i-th feasible solution; N is the number of nectar sources.
[0123] The standard artificial bee colony algorithm is an optimization algorithm that imitates the behavior of a bee colony in searching for nectar sources, and searches for the optimal solution to the problem through continuous iteration. Because the artificial bee colony algorithm has the problem of weak local optimization ability, a simulated binary crossover algorithm is introduced to improve the artificial bee colony algorithm. The simulated binary crossover algorithm adjusts the genetic information between the two parent individuals so that the offspring individuals can change on the basis of the parent generation, but will not deviate too much from the parent generation. This mechanism helps to conduct better exploration in the local space and helps to search for local optimization. The present invention combines the simulated binary crossover algorithm with the artificial bee colony algorithm, so that the artificial bee colony algorithm has both good global optimization ability and local optimization ability, and improves the efficiency and quality of the artificial bee colony algorithm in finding the optimal solution.
[0124] The simulated binary crossover algorithm used in the present invention is the point crossover method. First, determine the parent of the crossover operation; specify two integers in the interval of the honey source as the crossover point, such as Figure 3 As shown, a1=4, a2=7, a1, a2 represent the parent generation, and x in formula 20 id and x jd Correspondingly, as shown in the cross operation diagram, a cross operation is performed on the data between the fourth dimensions.
[0125] In the observation bee stage, in order to increase the ability of the observation bees to find the local optimal solution, speed up the local optimization, and conduct a more detailed local search, the simulated binary crossover algorithm is used to optimize the nectar source. The formula of the simulated binary crossover algorithm is:
[0126]
[0127] Among them, β is a random number, x id and x jd They are the nectar sources from the previous round and the previous round respectively.
[0128]
[0129] Here, μ is a random number in (0,1), η is the crossover index, and β is close to 1.
[0130] The improved artificial bee colony algorithm is combined with the random forest. The number of random forest decision trees and the number of features required to build the decision tree are used as the honey source, and the classification accuracy is used as the optimization target for optimization. The flowchart of the improved artificial bee colony optimization algorithm is as follows: Figure 4 shown.
[0131] The detailed steps of the rolling bearing fault diagnosis process proposed by the present invention are as follows: Figure 1 The steps are as follows:
[0132] (1) Data preprocessing
[0133] For the signal data collected over a long period of time, the sample set is constructed by segmentation. The sample data is cut and a new data set is constructed based on the cut sample data.
[0134] (2) Signal decomposition and feature extraction using RVMD
[0135] The segmented original vibration data is subjected to degradation variational mode decomposition to obtain decomposed signals in multiple dimensions. Then, the time-frequency domain features are extracted for the signals in each dimension after decomposition. Through 29 features, there are decomposed signals in 7 dimensions after decomposition. A total of 203 features can be extracted from each original signal, and then a new feature matrix is obtained.
[0136] (3) Relief-F feature selection
[0137] Since the data after feature extraction is of high degree, in order to reduce the dimension of the training set, feature selection is performed on the feature matrix. The Relief-F algorithm is used to calculate and sort the weight of each feature, which serves as a reference for the number of features of the training set in the subsequent input model matrix.
[0138] (4) Improved bee colony algorithm to optimize random forest
[0139] The artificial bee colony algorithm is used to optimize the number of decision trees in the random forest and the number of features required to build the decision tree to improve the classification accuracy of the random forest, and the optimized model is obtained. In this process, in order to improve the local optimization ability of the bee colony algorithm, the simulated binary crossover improved artificial bee colony algorithm is mainly used here to improve the ability to find better nectar sources. The present invention has come up with a bold idea, that is, in each iteration, the initial nectar source and the new nectar source of the observation bee are used to generate a new nectar source, which enhances the information exchange between each generation of nectar sources and effectively improves the ability to jump out of the local optimal solution.
[0140] (5) Testing of rolling bearing fault diagnosis model based on improved bee colony optimization random forest
[0141] The test set is input into the created fault diagnosis model for diagnosis, the obtained diagnosis results are compared with the actual results, and the effectiveness of the method is verified by comparing with other methods. Figure 5 Classification results for public datasets.
[0142] Embodiment 2
[0143] The present invention also provides a bearing fault diagnosis system based on improved SMOTE and improved bee colony algorithm, comprising the following steps: an acquisition module, a data balancing module, a feature extraction module, a feature selection module, a classification strategy module and a feature recognition module;
[0144] The acquisition module is used to acquire bearing fault signal data using a three-axis acceleration sensor, and to perform segmented processing on the acquired bearing fault signal data to obtain a sample set;
[0145] The data balancing module is used to combine the shared nearest neighbor clustering algorithm based on density ratio into the synthetic minority class oversampling technology SMOTE algorithm to balance the bearing fault signal data of the sample and obtain a balanced data set;
[0146] The feature extraction module is used to perform degradation variational mode decomposition on the balanced data set and extract the time-frequency domain features of the bearing fault signal data;
[0147] The feature selection module is used to weight the time-frequency domain features using the Relief-F algorithm and select the bearing fault features that meet the preset requirements;
[0148] The classification strategy module is used to build a random forest fault diagnosis model based on the improved bee colony algorithm;
[0149] The feature recognition module is used to classify and identify the bearing fault features using a random forest fault diagnosis model.
[0150] In this embodiment, the data balancing module includes: a primary data balancing unit and a deep data balancing unit;
[0151] The primary data balancing unit is used to introduce the synthetic minority oversampling technology SMOTE to balance the data of the samples and obtain primary samples;
[0152] The deep data balancing unit is used to generate k nearest neighbors of the sample based on the shared nearest neighbor similarity of the primary samples, and screen the generated nearest neighbors in combination with the average density ratio and the density ratio threshold to obtain a balanced data set.
[0153] In this embodiment, the sample x i The ratio of the average density of the k nearest neighbors is calculated as:
[0154]
[0155] Among them, x is the generated sample, k is the number of newly generated samples, SN k (x i ) is x i According to the k nearest neighbors obtained by similarity, dr(x i ) is the ratio of the density of the newly generated sample to the average density of its nearest neighbors, de(x i ) is the newly generated sample x i density;
[0156] Among them, de(x i ) is obtained by:
[0157]
[0158] Among them, SNN represents the sample x generated by SMOTE i and the original sample x j The shared nearest neighbor similarity between ;
[0159] Among them, the process of SNN acquisition is:
[0160] SNN(x i ,x j )=|N k (xi )∩N k (x j )|,
[0161] Among them, N k (x i ) and N k (x j ) represents x i and x j The nearest neighbor of .
[0162] In this embodiment, the classification strategy module includes: an optimization unit and a classifier unit;
[0163] The optimization unit is used to optimize the number of decision trees in the original random forest classification model and the number of features required to construct the decision trees by using an artificial bee colony algorithm improved by simulating binary crossover, so as to obtain an optimized random forest model;
[0164] The classifier unit is used to obtain a random forest fault diagnosis model based on the optimized random forest model.
[0165] The embodiments described above are only descriptions of the preferred embodiments of the present invention and are not intended to limit the scope of the present invention. Without departing from the design spirit of the present invention, various modifications and improvements made to the technical solutions of the present invention by ordinary technicians in this field should all fall within the protection scope determined by the claims of the present invention.
Claims
1. The bearing fault diagnosis method based on improved SMOTE and improved bee colony algorithm is characterized by: The following steps are involved: S1: using a triaxial acceleration sensor to collect bearing fault signal data, and performing segmentation processing on the collected bearing fault signal data to obtain a sample set; S2: Combine the shared nearest neighbor clustering algorithm based on density ratio into the synthetic minority oversampling technology SMOTE algorithm to balance the bearing fault signal data of the sample and obtain a balanced data set; S3: performing degradation variational mode decomposition on the balanced data set to extract time-frequency domain features of the bearing fault signal data; S4: using the Relief-F algorithm to weight the time-frequency domain features and select bearing fault features that meet preset requirements; S5: Construct a random forest fault diagnosis model based on improved bee colony algorithm; S6: using the random forest fault diagnosis model to classify and identify the bearing fault characteristics; Sample x i The ratio of the average density of the k nearest neighbors is calculated as: Among them, x is the generated sample, k is the number of newly generated samples, SN k (x i ) is x i According to the k nearest neighbors obtained by similarity, dr(x i ) is the ratio of the density of the newly generated sample to the average density of its nearest neighbors, de(x i ) is the density of the newly generated sample xi; Among them, de(x i ) is obtained by: Among them, SNN represents the sample x generated by SMOTE i and the original sample x j The shared nearest neighbor similarity between ; Among them, the method of obtaining SNN is: Among them, N k (x i ) and N k (x j ) represents x i and x j The nearest neighbor of The method of constructing a random forest fault diagnosis model based on an improved bee colony algorithm includes: The artificial bee colony algorithm improved by simulating binary crossover is used to optimize the number of decision trees in the original random forest classification model and the number of features required to build the decision tree, and the optimized random forest model is obtained; Based on the optimized random forest model, a random forest fault diagnosis model is obtained.
2. The bearing fault diagnosis method based on improved SMOTE and improved bee colony algorithm according to claim 1 is characterized in that: In S2, the shared nearest neighbor clustering algorithm based on density ratio is combined with the synthetic minority class oversampling technology SMOTE algorithm, and the method for balancing the bearing fault signal data of the sample includes: The synthetic minority oversampling technology SMOTE is introduced to balance the data of samples and obtain primary samples; Based on the shared nearest neighbor similarity of the primary samples, the k nearest neighbors of the sample are generated, and the generated nearest neighbors are screened in combination with the average density ratio and the density ratio threshold to obtain a balanced data set.
3. The bearing fault diagnosis system based on improved SMOTE and improved bee colony algorithm is characterized by: The following steps are involved: Acquisition module, data balancing module, feature extraction module, feature selection module, classification strategy module and feature recognition module; The acquisition module is used to acquire bearing fault signal data using a three-axis acceleration sensor, and to perform segmented processing on the acquired bearing fault signal data to obtain a sample set; The data balancing module is used to combine the shared nearest neighbor clustering algorithm based on density ratio into the synthetic minority class oversampling technology SMOTE algorithm to balance the bearing fault signal data of the sample to obtain a balanced data set; The feature extraction module is used to perform degradation variational mode decomposition on the balanced data set to extract the time-frequency domain features of the bearing fault signal data; The feature selection module is used to weight the time-frequency domain features using the Relief-F algorithm to select bearing fault features that meet preset requirements; The classification strategy module is used to construct a random forest fault diagnosis model based on an improved bee colony algorithm; The feature recognition module is used to classify and identify the bearing fault features using the random forest fault diagnosis model; Sample x i The ratio of the average density of the k nearest neighbors is calculated as: Among them, x is the generated sample, k is the number of newly generated samples, SN k (x i ) is x i According to the k nearest neighbors obtained by similarity, dr(x i ) is the ratio of the density of the newly generated sample to the average density of its nearest neighbors, de(x i ) is the density of the newly generated sample xi; Among them, de(x i ) is obtained by: Among them, SNN represents the sample x generated by SMOTE i and the original sample x j The shared nearest neighbor similarity between ; Among them, the process of SNN acquisition is: Among them, N k (x i ) and N k (x j ) represents x i and x j The nearest neighbor of The classification strategy module includes: an optimization unit and a classifier unit; The optimization unit is used to optimize the number of decision trees in the original random forest classification model and the number of features required to construct the decision trees by using an artificial bee colony algorithm improved by simulating binary crossover, so as to obtain an optimized random forest model; The classifier unit is used to obtain a random forest fault diagnosis model based on the optimized random forest model.
4. The bearing fault diagnosis system based on improved SMOTE and improved bee colony algorithm according to claim 3 is characterized in that: The data balancing module includes: a primary data balancing unit and a deep data balancing unit; The primary data balancing unit is used to introduce the synthetic minority oversampling technology SMOTE to balance the data of the samples to obtain primary samples; The deep data balancing unit is used to generate k nearest neighbors of the sample based on the shared nearest neighbor similarity of the primary samples, and screen the generated nearest neighbors in combination with the average density ratio and the density ratio threshold to obtain a balanced data set.