Method for predicting water content of oil of lubricating system of mechanical equipment

Through the CNN-BiLSTM-Attention network model combined with isolated forest and wavelet transformation, the limitations of traditional models in predicting oil moisture content changes are solved, and the rapid and accurate prediction of oil moisture content changes are achieved, and equipment wear prediction is improved accuracy.

CN119128529AActive Publication Date: 2024-12-13SOUTHWEST JIAOTONG UNIV
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202411608810.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-12
Publication Date
2024-12-13
Estimated Expiration
2044-11-12

AI Technical Summary

Technical Problem

Traditional time series prediction models have limitations in predicting changes in oil moisture content, and cannot effectively handle complex nonlinear relationships and high-dimensional data, and are difficult to adapt to rapid changes in the environment. The machine learning and deep learning methods are at rate and accuracy. The degree is poor, and changes in the water content of lubricant and signs of increased equipment wear cannot be identified in time.

Method used

The CNN-BiLSTM-Attention network model is used to combine isolated forests, discrete wavelet transformation and principal component analysis to eliminate outliers and noise, reduce dimensionality and perform supervised learning, predict through lag, and dynamically calculate attention weights to improve prediction accuracy sex.

Benefits of technology

It realizes rapid and accurate prediction of changes in oil moisture content, has high practical application value, can effectively identify signs of intensified equipment wear, and improves the prediction accuracy of lubricant deterioration trend.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119128529A_ABST
    Figure CN119128529A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of oil liquid detection, and provides a mechanical equipment lubricating system oil liquid moisture content prediction method, which comprises the following steps: S1, acquiring a historical data set of oil liquid multi-dimensional characteristics, and sequentially arranging according to the oil liquid characteristics and time to make a data set 1; s2, abnormal values in the data set 1 are removed through an isolated forest, data noise is removed through discrete wavelet transform, and a data set 2 is made; s3, performing dimensionality reduction on the data set 2 by using principal component analysis, removing redundant features of multi-dimensional data, and making a data set 3; s4, converting the data set 3 into input and output sequences with supervised learning in a lagging manner, and then performing normalization processing to make a data set 4; and S5, inputting the data set 4 into a CNN-BiLSTM-Attention network model to predict the water content of the oil, and obtaining an optimal prediction result. The method can quickly and accurately predict the water content of the oil.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of oil detection, and in particular to a method for predicting the water content of oil in a lubrication system of mechanical equipment. Background Art

[0002] Friction and wear are one of the most common failure modes of mechanical equipment, causing huge losses to the society and economy, including energy waste, increased carbon dioxide emissions, and environmental pollution. As a key component of mechanical equipment, lubricating oil has multiple functions such as reducing friction, reducing wear, cooling and cleaning, preventing rust, and reducing noise. However, the performance of lubricating oil will gradually decline over time. If the quality does not meet the standards, it will lead to insufficient lubrication of the equipment, which will affect the stable operation of the entire system and even pose a safety hazard.

[0003] With the rapid development of modern industry, the failure rate in lubrication systems or hydraulic systems has increased significantly, of which about 70% are related to oil contamination. Water is one of the main contamination factors of lubricating oil, and its influence cannot be ignored. When water and oil are mixed, acidic substances will be formed, which will cause corrosion of metal parts and reduce the service life of equipment; water and oil will form emulsions, which will destroy the uniformity of the oil. Emulsions not only reduce the lubrication performance of the oil, but also affect the viscosity of the oil, making it unable to effectively form a lubricating film, thereby increasing friction and wear, leading to abnormal wear of equipment and accidents.

[0004] In order to effectively manage the quality of lubricating oil and equipment wear, it is particularly important to adopt advanced prediction technology. Traditional time series prediction models have some limitations in predicting changes in oil water content. The models established in previous studies usually only focus on the changes in water content over time, ignoring the influence of other oil indicators. At the same time, the output of the models established in previous studies only focuses on the changes in oil water content at the next moment, so it is impossible to predict the changes in oil water content over a longer time span. In addition, traditional time series prediction models have weak processing capabilities for complex nonlinear relationships and high-dimensional data, making it difficult to model long-term dependencies and not easy to adapt to rapid changes in the environment. In contrast, in order to address these limitations, many time series prediction methods based on machine learning and deep learning have been developed in recent years, such as recurrent neural networks (RNN), long short-term memory networks (LSTM), convolutional neural networks (CNN), etc. These methods can better handle complex time series patterns and nonlinear relationships, and improve the accuracy and robustness of predictions. Therefore, they have significant advantages in predicting lubricating oil deterioration trends and abnormal equipment wear.

[0005] However, the current time series prediction methods based on machine learning and deep learning have poor speed and accuracy, and cannot timely and accurately identify changes in the water content of lubricating oil and signs of increased equipment wear. Therefore, a method for predicting the water content of the oil in the lubrication system of mechanical equipment is needed to solve the above problems. Summary of the invention

[0006] The present invention provides a method for predicting the water content of oil in a lubrication system of mechanical equipment, which can quickly and accurately predict the water content of oil.

[0007] According to a method for predicting the water content of oil in a mechanical equipment lubrication system of the present invention, the method comprises the following steps: S1, obtaining a historical data set of multi-dimensional characteristics of oil, arranging them in chronological order according to oil characteristics and time, and making a data set 1; S2, remove outliers in data set 1 by isolation forest and remove data noise by discrete wavelet transform to produce data set 2; S3, using principal component analysis to reduce the dimension of data set 2, eliminating redundant features of multidimensional data, and making data set 3; S4, converting data set 3 into the input and output sequence of supervised learning by lagging, and then normalizing it to produce data set 4; S5. Input data set 4 into the CNN-BiLSTM-Attention network model to predict the water content of oil and obtain the best prediction result.

[0008] Preferably, in S1, the oil historical data set comes from the online monitoring system of the ball mill gearbox, data is collected once a minute, and the average value is calculated every hour, with a total of 1,300 sets of samples; the oil characteristics include oil physical and chemical information, oil ferromagnetic abrasive particle information and oil non-ferromagnetic abrasive particle information; The physical and chemical information of the oil includes temperature, water content, dynamic viscosity, density and dielectric constant; The oil ferromagnetic wear particle information includes the first-level ferromagnetic particle number of 40μm~99μm, the second-level ferromagnetic particle number of 100μm~199μm, the third-level ferromagnetic particle number of 200μm~299μm, the fourth-level ferromagnetic particle number of 300μm~399μm, the fifth-level ferromagnetic particle number ≥400μm and the total number of ferromagnetic particles; The oil non-ferromagnetic wear particle information includes the first-level number of non-ferromagnetic particles 150μm~199μm, the second-level number of non-ferromagnetic particles 200μm~299μm, the third-level number of non-ferromagnetic particles 300μm~399μm, the fourth-level number of non-ferromagnetic particles 400μm~499μm, the fifth-level number of non-ferromagnetic particles ≥500μm and the total number of non-ferromagnetic particles; The data of the fourth-level number of ferromagnetic particles, the fifth-level number of ferromagnetic particles, the fourth-level number of non-ferromagnetic particles, and the fifth-level number of non-ferromagnetic particles are always 0 and are directly removed. The original oil data has a total of 13 dimensions. The data are arranged in chronological order according to the oil characteristics and the time of data collection to produce data set 1.

[0009] Preferably, in S2, the outlier removal of the data set 1 by the isolation forest is divided into a training phase and an evaluation phase. The training phase is to construct an isolation tree by the sample data set, and the evaluation phase is to obtain the anomaly score of the instance. After the outliers of the data set 1 are removed, the data noise is removed by wavelet transform. The specific steps include: S2.1. In the training phase, n pieces of data are extracted from data set 1 to form a sub-data set. , All dimensions of are denoted as set M, and a dimension is randomly selected from set M , then in the selected dimension A split point t is randomly selected on the dimension Randomly select between the minimum and maximum values ​​on and the split point t will Divide into two parts, recursively repeat the above steps on each subset until the tree reaches the predetermined maximum depth d and the data can no longer be split, that is, the child node contains only one data, forming an isolated tree; repeat the above steps to generate k isolated trees, and k isolated trees form an isolated forest; the depth of the tree reflects the degree of isolation of the sample point in the feature space, and the path length of the sample in the tree is used to determine whether it is an outlier. Samples with short paths are abnormal; In the scoring stage, the k isolated trees obtained in the training stage are used to calculate the anomaly score of each sample point in the data set to evaluate the anomaly of the data; each isolated tree assigns a path length As anomaly score, the sample point is calculated using formula (1) Anomaly score : ; in, is the number of samples used to train each isolated tree; For data points Average path length in isolated forests; is the normalization factor used to normalize the recorded data points The path length; S2.2 After removing the outliers from data set 1, the oil data is subjected to discrete wavelet transform and decomposed into feature items and noise items containing different characteristics, so that the signal can be represented and processed in both the time domain and the frequency domain, and is calculated using formulas (2) and (3); the db4 wavelet is selected as the wavelet function, and the data after outliers are removed is decomposed into three layers; the first layer of wavelet decomposition decomposes the original sample signal into an approximate component cA1 and a detail component cD1, the second layer of wavelet decomposition decomposes the approximate component cA1 obtained in the first layer into an approximate component cA2 and a detail component cD2 in the second layer, and the third layer of wavelet decomposition decomposes the approximate component cA2 obtained in the second layer into an approximate component cA3 and a detail component cD3 in the third layer; then the obtained wavelet coefficients are subjected to soft threshold processing; the wavelet coefficients after threshold processing are resynthesized into a denoised signal, i.e., data set 2; ; in, is the original signal, is the scaling function, is the wavelet function, and Represent the low-frequency and high-frequency coefficients respectively.

[0010] As a preferred embodiment, in S3, principal component analysis is used to reduce the dimension of data set 2 to remove redundant features of multidimensional data; first, formula (4) is used to standardize data set 2 to construct a standardized matrix ; Then use formula (5) to calculate The correlation coefficient matrix , verifying that most parameters have strong correlation; using formula (6) to calculate The eigenvalues ​​and eigenvectors of are obtained; finally, the principal component contribution rate is calculated using formula (7) and the cumulative contribution rate is calculated using formula (8); the water content of the oil, the second-level number of ferromagnetic particles, the third-level number of ferromagnetic particles, the density and the dielectric constant are used as new features to form data set 3; ; in, is the original data value, indicating The sample in The original value of the feature; , is the number of samples, For the The mean of the features; , is the sample standard deviation; is the standardized data value, indicating the The sample in Standardized values ​​on features; ; in, is the standardized data matrix; Transpose of the normalized data matrix; R is the correlation coefficient matrix; ; in, For the i eigenvalues; ; in, is the contribution rate, is the cumulative contribution rate, For the k eigenvalues, m is the total number.

[0011] Preferably, in S4, data set 3 is converted into input and output sequences of supervised learning by means of lag, and data with a lag step length of 24h is grouped as input, and the subsequent output time series data with a length of 48h is used as output, thereby realizing the prediction of the water content of the oil in the next 48h; then, Min-Max normalization processing is performed, and the data is scaled to between [-1,1]; then 80% of the converted data set is used as a training set, and 20% as a test set, and finally a data set 4 is made.

[0012] Preferably, in S5, the CNN-BiLSTM-Attention network model structure is as follows: first, the preprocessed data is converted into 3D data with a shape of [number of samples, time steps, number of features] as input samples; then, a one-dimensional convolutional layer is used to extract local features of the time series data, and 128 filters are set, each with a kernel size of 3; in order to reduce the dimension of the output of the convolutional layer, a pooling layer with a window size of 2×2 is set, and its result is passed to the BiLSTM layer. The BiLSTM layer is designed to capture the long-term dependencies of the input sequence, where each unidirectional LSTM layer contains 32 units; the output of the BiLSTM layer is passed to the Attention layer, which dynamically calculates the attention weight of each time step to help the model learn the importance of data at different times to the predicted value; then, the output is passed to the Dropout layer to reduce the risk of overfitting; finally, the predicted result of the water content of the oil is output through the fully connected layer, the output layer contains one neuron, and uses ReLU as the activation function.

[0013] As a preferred method, in S5, the CNN-BiLSTM-Attention network model uses mean square error MSE as the loss function and is trained with the Adam optimizer. During the training process, the learning rate is automatically adjusted using the ReduceLROnPlateau function, and the early stopping mechanism is implemented through the EarlyStopping function to avoid overfitting of the model.

[0014] The beneficial effects of the present invention are: The present invention provides a method for predicting the water content of oil based on CNN-BiLSTM-Attention, which uses the isolation forest technology to eliminate outliers in the data and effectively removes data noise through wavelet transform. The data is reduced in dimension using principal component analysis, and the linear trend of the data is eliminated using the first-order difference method. CNN extracts the local spatial features of the oil data, BiLSTM extracts the time dependency of the oil data, and the Attention layer dynamically calculates the attention weight of each time step based on the output of the BiLSTM layer, helping the model learn the importance of data at different times to the predicted value. Through the above raw data preprocessing and prediction model structure, the present invention can achieve rapid and accurate prediction of changes in the water content of oil at future times, and has practical application value. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] Figure 1 It is a flow chart of a method for predicting the water content of oil in a lubrication system of mechanical equipment in an embodiment; Figure 2 This is a schematic diagram of the isolation forest process in the embodiment; Figure 3 A schematic diagram of discrete wavelet change decomposition in an embodiment; Figure 4 It is the oil parameter correlation heat map in the embodiment; Figure 5 This is a schematic diagram of the principal component analysis process in the embodiment; Figure 6 This is a structural diagram of the CNN-BiLSTM-Attention model in the embodiment; Figure 7 This is a diagram showing the prediction results of the oil water content prediction model in the embodiment; Figure 8 Graph showing the evaluation index of the oil water content prediction model in the embodiment. DETAILED DESCRIPTION

[0016] In order to further understand the content of the present invention, the present invention is described in detail in conjunction with the accompanying drawings and embodiments. It should be understood that the embodiments are only for explaining the present invention and are not intended to limit it.

[0017] Example

[0018] like Figure 1 As shown, this embodiment provides a method for predicting the water content of oil in a lubrication system of mechanical equipment, which includes the following steps: S1, obtaining a historical data set of multi-dimensional characteristics of oil, arranging them in chronological order according to oil characteristics and time, and making a data set 1; The oil historical data set comes from the online monitoring system of the ball mill gearbox. The data is collected once a minute and the average value is calculated every hour, with a total of 1,300 sets of samples. The oil characteristics include the physical and chemical information of the oil, the ferromagnetic wear particle information of the oil, and the non-ferromagnetic wear particle information of the oil. The physical and chemical information of the oil includes temperature, water content, dynamic viscosity, density and dielectric constant; The oil ferromagnetic wear particle information includes the first-level ferromagnetic particle number of 40μm~99μm, the second-level ferromagnetic particle number of 100μm~199μm, the third-level ferromagnetic particle number of 200μm~299μm, the fourth-level ferromagnetic particle number of 300μm~399μm, the fifth-level ferromagnetic particle number ≥400μm and the total number of ferromagnetic particles; The oil non-ferromagnetic wear particle information includes the first-level number of non-ferromagnetic particles 150μm~199μm, the second-level number of non-ferromagnetic particles 200μm~299μm, the third-level number of non-ferromagnetic particles 300μm~399μm, the fourth-level number of non-ferromagnetic particles 400μm~499μm, the fifth-level number of non-ferromagnetic particles ≥500μm and the total number of non-ferromagnetic particles; The data of the fourth-level number of ferromagnetic particles, the fifth-level number of ferromagnetic particles, the fourth-level number of non-ferromagnetic particles, and the fifth-level number of non-ferromagnetic particles are always 0 and are directly removed. The original oil data has a total of 13 dimensions. The data are arranged in chronological order according to the oil characteristics and the time of data collection to produce data set 1.

[0019] S2, remove outliers in data set 1 by isolation forest and remove data noise by discrete wavelet transform to produce data set 2; In S2, the outlier removal of dataset 1 by isolation forest is divided into a training phase and an evaluation phase. The training phase is to construct an isolation tree through the sample dataset, and the evaluation phase is to obtain the anomaly score of the instance. After the outliers of dataset 1 are removed, the data noise is removed by wavelet transform. The specific steps include: S2.1. In the training phase, n pieces of data are extracted from data set 1 to form a sub-data set. , All dimensions of are denoted as set M, and a dimension is randomly selected from set M , then in the selected dimension A split point t is randomly selected on the dimension Randomly select between the minimum and maximum values ​​on and the split point t will Divide into two parts, recursively repeat the above steps on each subset until the tree reaches the predetermined maximum depth d and the data can no longer be split, that is, the child node contains only one data (that is, the child node contains only one data), forming an isolated tree; repeat the above steps, that is, generate k isolated trees, and k isolated trees form an isolated forest; the depth of the tree reflects the degree of isolation of the sample point in the feature space, and the path length of the sample in the tree is used to determine whether it is an outlier. Samples with short paths are abnormal; In the scoring stage, the k isolated trees obtained in the training stage are used to calculate the anomaly score of each sample point in the data set to evaluate the anomaly of the data; each isolated tree assigns a path length As anomaly score, the sample point is calculated using formula (1) Anomaly score , to assess the anomalies in the data: ; in, is the number of samples used to train each isolated tree; For data points Average path length in isolated forests; is the normalization factor used to normalize the recorded data points Path length; Isolation forest process diagram, such as Figure 2 As shown; S2.2 After removing the outliers from data set 1, the oil data is subjected to discrete wavelet transform and decomposed into feature items and noise items containing different characteristics, so that the signal can be represented and processed in both the time domain and the frequency domain. Formulas (2) and (3) are used for calculation; db4 wavelet is selected as the wavelet function, and the data after outliers are removed is decomposed into three layers. The discrete wavelet change decomposition diagram is as follows: Figure 3 As shown; the first layer of wavelet decomposition decomposes the original sample signal into approximate wavelet coefficients cA1 and detail wavelet coefficients cD1; the second layer of wavelet decomposition decomposes the approximate wavelet coefficients cA1 obtained in the first layer into approximate wavelet coefficients cA2 and detail wavelet coefficients cD2 in the second layer; the third layer of wavelet decomposition decomposes the approximate wavelet coefficients cA2 obtained in the second layer into approximate wavelet coefficients cA3 and detail wavelet coefficients cD3 in the third layer; then the obtained wavelet coefficients are subjected to soft threshold processing; the wavelet coefficients subjected to threshold processing are resynthesized into the denoised signal, i.e., data set 2; ; in, is the original signal, is the scaling function, is the wavelet function, and Represent the low-frequency and high-frequency coefficients respectively.

[0020] S3, using principal component analysis to reduce the dimension of data set 2, eliminating redundant features of multidimensional data, and making data set 3; In S3, principal component analysis is used to reduce the dimension of data set 2 and remove the redundant features of multidimensional data. First, formula (4) is used to standardize data set 2 to construct a standardized matrix ; Then use formula (5) to calculate The correlation coefficient matrix , draw the oil parameter correlation heat map as shown Figure 4 As shown, most parameters have strong correlation. In order to simplify the complexity of the model, it is necessary to reduce the dimension of the data and remove redundant features. Use formula (6) to calculate The eigenvalues ​​and eigenvectors of are calculated; finally, the principal component contribution rate is calculated using formula (7) and the cumulative contribution rate is calculated using formula (8). The flowchart of the principal component analysis is as follows: Figure 5 As shown in the figure, the contribution rate of principal component 1 is 0.76, the contribution rate of principal component 2 is 0.1, and the cumulative contribution rate is The component matrix obtained by principal component analysis is shown in Table 1. The water content of the oil, the second-grade number of ferromagnetic particles, and the third-grade number of ferromagnetic particles have the greatest influence on principal component 1; while the density and dielectric constant of the oil have the greatest influence on principal component 2; therefore, the water content of the oil, the second-grade number of ferromagnetic particles, the third-grade number of ferromagnetic particles, the density, and the dielectric constant are the main influencing factors of this embodiment; as the input features of the prediction model of the water content of the oil; the water content of the oil, the second-grade number of ferromagnetic particles, the third-grade number of ferromagnetic particles, the density, and the dielectric constant are used as new features to form data set 3; ; in, is the original data value, indicating The sample in The original value of the feature; , is the number of samples, For the The mean of the features; , is the sample standard deviation; is the standardized data value, indicating the The sample in Standardized values ​​on features; ; in, is the standardized data matrix; Transpose of the normalized data matrix; R is the correlation coefficient matrix; ; in, For the i eigenvalues; ; in, is the contribution rate, is the cumulative contribution rate, For the k eigenvalues, m is the total number.

[0021] Table 1 Component matrix obtained by principal component analysis

[0022] S4, converting data set 3 into the input and output sequence of supervised learning by lagging, and then normalizing it to produce data set 4; In S4, data set 3 is converted into the input and output sequence of supervised learning by means of lag. The data with a lag step length of 24h is grouped as input, and the subsequent output time series data with a length of 48h is used as output. Thus, the prediction of the water content of the oil in the next 48h is achieved. Then, Min-Max normalization processing is performed and the data is scaled to [-1,1]. Then, 80% of the converted data set is used as a training set and 20% as a test set, and finally data set 4 is made.

[0023] S5. Input data set 4 into the CNN-BiLSTM-Attention network model to predict the water content of oil and obtain the best prediction result; In S5, the CNN-BiLSTM-Attention network model structure is as follows Figure 6 As shown in the figure; first, the preprocessed data is converted into 3D data with the shape of [number of samples, time steps, number of features] as the input sample; then, a one-dimensional convolution layer is used to extract the local features of the time series data, and 128 filters are set, and the kernel size of each filter is 3; in order to reduce the dimension of the output of the convolution layer, a pooling layer with a window size of 2×2 is set, and its result is passed to the BiLSTM layer. The BiLSTM layer is designed to capture the long-term dependencies of the input sequence, where each unidirectional LSTM layer contains 32 units; the output of the BiLSTM layer is passed to the Attention layer, which dynamically calculates the attention weight of each time step to help the model learn the importance of data at different times to the predicted value; then, the output is passed to the Dropout layer to reduce the risk of overfitting; finally, the prediction result of the water content of the oil is output through the fully connected layer. The output layer contains one neuron and uses ReLU as the activation function.

[0024] In S5, the CNN-BiLSTM-Attention network model uses mean square error (MSE) as the loss function and is trained with the Adam optimizer. During the training process, the ReduceLROnPlateau function is used to automatically adjust the learning rate, and the EarlyStopping function is used to implement the early stopping mechanism to avoid overfitting of the model.

[0025] The test set oil data is input into the trained oil water content prediction model for prediction, and the obtained oil water content prediction value is compared with the true value in the test set. Figure 7 The figure shows a comparison between the model prediction value (Prediction) and the true value (Original). It can be seen from the figure that the gap between the predicted value and the true value is small, indicating that the constructed oil water content prediction model has a good prediction effect on the future water content value in the oil.

[0026] This example selects the root mean square error (RMSE), mean absolute error (MAE), mean absolute percentage error (MAPE), and R 2 To evaluate the performance and prediction effect of the model. RMSE is an evaluation indicator used to measure the degree of error dispersion between the true value and the predicted value; MAE is used to measure the average absolute deviation between the predicted value and the true value; MAPE is used to measure the average percentage error between the predicted value and the true value; R 2 Statistical indicators used to measure the goodness of fit of regression models. The closer RMSE, MAE, and MAPE are to 0, the better the model effect is. 2 The closer the value is to 1, the better the model effect is.

[0027] Figure 8 This is the evaluation index diagram of the oil water content prediction model, where the RMSE is 0.02, the MAE is 0.012, and the MAPE is 0.008. Most of them are close to 0, while R 2 Reaching 93.47%. Therefore, from the above model evaluation index size, it can be concluded that the model has high prediction accuracy and good robustness, and can achieve rapid and accurate prediction of the changes in oil water content at future moments, providing reliable technical support for oil monitoring and control.

[0028] The present invention and its embodiments are described schematically above, and the description is not restrictive. The drawings show only one embodiment of the present invention, and the actual structure is not limited thereto. Therefore, if a person skilled in the art is inspired by it and designs a structural method and an embodiment similar to the technical solution without creativity without departing from the purpose of the invention, they shall all fall within the protection scope of the present invention.

Claims

1. A method for predicting the water content of oil in the lubrication system of mechanical equipment, Features: The following steps are involved: S1, obtaining a historical data set of multi-dimensional characteristics of oil, arranging them in chronological order according to oil characteristics and time, and making a data set 1; S2, remove outliers in data set 1 by isolation forest and remove data noise by discrete wavelet transform to produce data set 2; S3, using principal component analysis to reduce the dimension of data set 2, eliminating redundant features of multidimensional data, and making data set 3; S4, converting data set 3 into the input and output sequence of supervised learning by lagging, and then normalizing it to produce data set 4; S5. Input data set 4 into the CNN-BiLSTM-Attention network model to predict the water content of oil and obtain the best prediction result.

2. A method for predicting the water content of oil in a mechanical equipment lubrication system according to claim 1, Features: In S1, the oil historical data set comes from the online monitoring system of the ball mill gearbox. Data is collected once a minute and the average value is calculated every hour, with a total of 1,300 sets of samples. The oil characteristics include the physical and chemical information of the oil, the ferromagnetic wear particle information of the oil, and the non-ferromagnetic wear particle information of the oil. The physical and chemical information of the oil includes temperature, water content, dynamic viscosity, density and dielectric constant; The oil ferromagnetic wear particle information includes the first-level ferromagnetic particle number of 40μm~99μm, the second-level ferromagnetic particle number of 100μm~199μm, the third-level ferromagnetic particle number of 200μm~299μm, the fourth-level ferromagnetic particle number of 300μm~399μm, the fifth-level ferromagnetic particle number ≥400μm and the total number of ferromagnetic particles; The oil non-ferromagnetic wear particle information includes the first-level number of non-ferromagnetic particles 150μm~199μm, the second-level number of non-ferromagnetic particles 200μm~299μm, the third-level number of non-ferromagnetic particles 300μm~399μm, the fourth-level number of non-ferromagnetic particles 400μm~499μm, the fifth-level number of non-ferromagnetic particles ≥500μm and the total number of non-ferromagnetic particles; The data of the fourth-level number of ferromagnetic particles, the fifth-level number of ferromagnetic particles, the fourth-level number of non-ferromagnetic particles, and the fifth-level number of non-ferromagnetic particles are always 0 and are directly removed. The original oil data has a total of 13 dimensions. The data are arranged in chronological order according to the oil characteristics and the time of data collection to produce data set 1.

3. A method for predicting the water content of oil in a mechanical equipment lubrication system according to claim 2, Features: In S2, the outlier removal of dataset 1 by isolation forest is divided into a training phase and an evaluation phase. The training phase is to construct an isolation tree through the sample dataset, and the evaluation phase is to obtain the anomaly score of the instance; After removing the outliers in data set 1, the data noise is removed by wavelet transform. The specific steps include: S2.

1. In the training phase, n pieces of data are extracted from data set 1 to form a sub-data set. , All dimensions of are denoted as set M, and a dimension is randomly selected from set M , then in the selected dimension A split point t is randomly selected on the dimension Randomly select between the minimum and maximum values ​​on and the split point t will Divide into two parts, recursively repeat the above steps on each subset until the tree reaches the predetermined maximum depth d and the data can no longer be split, that is, the child node contains only one data, forming an isolated tree; repeat the above steps to generate k isolated trees, and k isolated trees form an isolated forest; the depth of the tree reflects the degree of isolation of the sample point in the feature space, and the path length of the sample in the tree is used to determine whether it is an outlier. Samples with short paths are abnormal; In the scoring stage, the k isolated trees obtained in the training stage are used to calculate the anomaly score of each sample point in the data set to evaluate the anomaly of the data; each isolated tree assigns a path length As anomaly score, the sample point is calculated using formula (1) Anomaly score : ; in, is the number of samples used to train each isolated tree; For data points Average path length in isolated forests; is the normalization factor used to normalize the recorded data points The path length; S2.2 After removing the outliers from data set 1, the oil data is subjected to discrete wavelet transform and decomposed into feature items and noise items containing different characteristics, so that the signal can be represented and processed in both the time domain and the frequency domain, and is calculated using formulas (2) and (3); the db4 wavelet is selected as the wavelet function, and the data after outliers are removed is decomposed into three layers; the first layer of wavelet decomposition decomposes the original sample signal into an approximate component cA1 and a detail component cD1, the second layer of wavelet decomposition decomposes the approximate component cA1 obtained in the first layer into an approximate component cA2 and a detail component cD2 in the second layer, and the third layer of wavelet decomposition decomposes the approximate component cA2 obtained in the second layer into an approximate component cA3 and a detail component cD3 in the third layer; then the obtained wavelet coefficients are subjected to soft threshold processing; the wavelet coefficients after threshold processing are resynthesized into a denoised signal, i.e., data set 2; ; in, is the original signal, is the scaling function, is the wavelet function, and Represent the low-frequency and high-frequency coefficients respectively.

4. A method for predicting the water content of oil in a mechanical equipment lubrication system according to claim 3, Features: In S3, principal component analysis is used to reduce the dimension of data set 2 and remove the redundant features of multidimensional data. First, formula (4) is used to standardize data set 2 to construct a standardized matrix ; Then use formula (5) to calculate The correlation coefficient matrix , verify that most parameters have strong correlation; Use formula (6) to calculate The eigenvalues ​​and eigenvectors of are obtained; finally, the principal component contribution rate is calculated using formula (7) and the cumulative contribution rate is calculated using formula (8); the water content of the oil, the second-level number of ferromagnetic particles, the third-level number of ferromagnetic particles, the density and the dielectric constant are used as new features to form data set 3; ; in, is the original data value, indicating The sample in The original value of the feature; , is the number of samples, For the The mean of the features; , is the sample standard deviation; is the standardized data value, indicating the The sample in Standardized values ​​on features; ; in, is the standardized data matrix; Transpose of the normalized data matrix; R is the correlation coefficient matrix; ; in, For the i eigenvalues; ; in, is the contribution rate, is the cumulative contribution rate, For the k eigenvalues, m is the total number.

5. A method for predicting the water content of oil in a mechanical equipment lubrication system according to claim 4, Features: In S4, data set 3 is converted into the input and output sequence of supervised learning by means of lag. The data with a lag step length of 24h is grouped as input, and the subsequent output time series data with a length of 48h is used as output. Thus, the prediction of the water content of the oil in the next 48h is achieved. Then, Min-Max normalization processing is performed and the data is scaled to [-1,1]. Then, 80% of the converted data set is used as a training set and 20% as a test set, and finally data set 4 is made.

6. A method for predicting the water content of oil in a mechanical equipment lubrication system according to claim 5, Features: In S5, the CNN-BiLSTM-Attention network model structure is as follows: First, the preprocessed data is converted into 3D data with a shape of [number of samples, time steps, number of features] as the input sample; then, a one-dimensional convolution layer is used to extract the local features of the time series data, and 128 filters are set, and the kernel size of each filter is 3; in order to reduce the dimension of the output of the convolution layer, a pooling layer with a window size of 2×2 is set, and its result is passed to the BiLSTM layer. The BiLSTM layer is designed to capture the long-term dependencies of the input sequence, where each unidirectional LSTM layer contains 32 units; the output of the BiLSTM layer is passed to the Attention layer, which dynamically calculates the attention weight of each time step to help the model learn the importance of data at different times to the predicted value; then, the output is passed to the Dropout layer to reduce the risk of overfitting; finally, the prediction result of the water content of the oil is output through the fully connected layer. The output layer contains one neuron and uses ReLU as the activation function.

7. A method for predicting the water content of oil in a mechanical equipment lubrication system according to claim 6, Features: In S5, the CNN-BiLSTM-Attention network model uses mean square error (MSE) as the loss function and is trained with the Adam optimizer. During the training process, the ReduceLROnPlateau function is used to automatically adjust the learning rate, and the EarlyStopping function is used to implement the early stopping mechanism to avoid overfitting of the model.

Citation Information

Patent Citations

  • Combined denoising method and system based on improved complementary set mode decomposition

    CN114886378A

  • Mechanical fault diagnosis method based on adaptive noise transformation and stochastic resonance

    CN115655455A

  • Marginal factor weighted reconstruction method applied to conversion-static rub-impact fault identification

    CN116541677A

  • CNN-BiLSTM high-altitude multi-factor transmission line audible noise prediction method based on multi-head attention mechanism

    CN116796168A

  • Substation main equipment operation state anomaly detection method based on fusion terminal

    CN117110748A