Method for predicting SOH of battery based on MH-MoE model and EIS data

By using the multi-head hybrid expert model (MH-MoE) combined with CNN and LSTM in battery SOH prediction, the problems of insufficient generalization capabilities and low efficiency of traditional models are solved, and more efficient and accurate prediction of battery state health is achieved.

CN119247146APending Publication Date: 2025-01-03NANTONG LE CHUANGXIN ENERGY CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411280087.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-12
Publication Date
2025-01-03

AI Technical Summary

Technical Problem

Traditional machine learning models have limited generalization capabilities when predicting battery state health (SOH), which can easily lead to overfitting, and are not efficient when processing large-scale data, making it difficult to adapt to complex and variable battery operating conditions.

Method used

The multi-head hybrid expert model (MH-MoE) is used to combine CNN and LSTM to process input data in parallel through multiple gated networks, and the expert network is activated for feature extraction and timing processing, and the multi-head mechanism and sparse activation mechanism are used to improve computing efficiency and prediction accuracy.

Benefits of technology

It improves the accuracy and efficiency of battery SOH prediction, can efficiently process complex and variable battery data, significantly improves prediction accuracy and robustness, and adapts to different battery states and conditions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119247146A_ABST
    Figure CN119247146A_ABST
Patent Text Reader

Abstract

The invention discloses a method for predicting the SOH of a battery based on an MH-MoE model and EIS data. The method comprises the steps that S1, the EIS data and the SOH data of the battery are tested and collected; s2, constructing an MH-MoE model, wherein the MH-MoE model comprises three expert sub-models and three gating network models, and each sub-model is a CNN-LSTM model; the CNN model extracts spatial features of input data, and the LSTM model extracts time sequence features of battery EIS data; s3, training and verifying the MH-MoE model; and S4, predicting the SOH of the battery. The method is based on the MH-MoE model and uses the battery impedance to predict SOH, has the advantages of diversified feature extraction brought by a multi-head mechanism, sparse activation to improve calculation efficiency, capability of focusing on different modes by an expert network, and flexible adaptation to a multi-task environment, can predict the health state of the battery more efficiently and more accurately, and adapts to complex working conditions.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the field of electrochemical technology, and in particular to a method for predicting battery SOH based on an MH-MoE model and EIS data. Background Art

[0002] The health of the battery, or "State of Health" (SOH), is a key indicator for measuring battery performance degradation and remaining service life. The importance of SOH is mainly reflected in the following aspects: it reveals the degree of battery aging, provides a basis for determining when to replace the battery, and helps to evaluate the remaining capacity of the battery. In addition, SOH plays a vital role in optimizing battery management strategies, analyzing potential battery failures, evaluating battery safety, and predicting the remaining service life of the battery.

[0003] Predicting the state of health (SOH) of batteries is of great importance in practical applications.

[0004] Electrochemical impedance spectroscopy (EIS) is an effective method for analyzing the electrochemical reactions inside batteries. When the active substances in the battery decrease and the performance declines, the EIS curve will also change. Therefore, using EIS data to predict SOH is a feasible method.

[0005] Typically, we use EIS data to train machine learning algorithms, such as neural networks or support vector machines, to capture the changing patterns of battery SOH and make predictions.

[0006] Traditional machine learning models often use a single model to fit the entire data set, which is inadequate when faced with complex and highly heterogeneous data. Such models have limited generalization capabilities, are prone to overfitting problems, and are inefficient when processing large-scale data.

[0007] Multi-Head Mixture of Experts (MH-MoE) is a neural network architecture designed to improve the expressiveness and computational efficiency of the model.

[0008] The model structure of MH-MoE is roughly as follows: 1. Expert network: The expert network (Experts) contains multiple independent sub-networks, each of which processes the input data from different angles.

[0009] 2. Gated network: Each gated network of the gated network is a "head" that selects and activates the appropriate expert network based on the input data. Multiple gated networks (heads) can process input data in parallel.

[0010] 3. Multi-Head Mechanism: The Multi-Head Mechanism supports multiple gating networks working simultaneously. Each gating network generates its own weight distribution and selects and activates different expert networks.

[0011] The workflow of MH-MoE is roughly as follows: first, the input data passes through multiple gating networks (heads), each of which generates a set of weights based on the input data for selecting and activating the expert network.

[0012] Second, each gating network selects and activates a small number of expert networks, which process the input data.

[0013] Finally, the outputs of all activated expert networks are fused to generate the final output result.

[0014] In addition, in order to improve the prediction accuracy of the model, a variety of deep learning models can be used to build a multi-objective prediction model.

[0015] Common deep learning models and their functions are: Convolution neural network (CNN): CNN can be used to extract spatial features of current, voltage and temperature data.

[0016] Long Short-Term Memory (LSTM): LSTM can learn the time series changes of current, voltage and temperature.

[0017] In summary, the combination of CNN and LSTM can automatically map the complex mapping relationship between EIS and SOH. The combination of the above two models can be used to build the MH-MoE model and use the battery EIS data to predict the battery SOH. Summary of the invention

[0018] In order to solve the above problems and achieve the above objectives, the present invention proposes a battery SOH prediction method based on the MH-MoE model and EIS data, and uses the battery EIS data to predict the battery SOH.

[0019] The present invention solves the technical problem, and the technical solution adopted is: A method for predicting battery SOH based on MH-MoE model and EIS data, comprising the following steps: Step S1. Test and collect battery EIS and SOH data: Professional impedance spectroscopy test equipment is used to test and collect battery EIS data, covering a frequency range of 10 -2 HZ to 10 5HZ, select 5 to 60 frequency values ​​in the middle of the frequency range, preferably 60 as samples.

[0020] When collecting data, record the real and imaginary data of the impedance corresponding to each frequency, as well as the target value to be predicted, which is the corresponding battery SOH.

[0021] Step S2. Constructing the MH-MoE model: The MH-MoE model contains three expert sub-models and three gated network models, each of which is a CNN-LSTM model. The CNN model extracts the spatial features of the input data, and the LSTM model extracts the temporal features of the battery EIS data.

[0022] Furthermore, the CNN structure contains 1 convolution layer and a maximum pooling layer. The activation functions of the convolution layers are all relu functions, the number of filters is set to 32, and the kernel size is 1.

[0023] Furthermore, the LSTM model controls the flow of information entry, retention and output by opening and closing the input gate, forget gate and output gate, realizing the memory and processing of time series information. The number of neurons in the LSTM layer is 32, and the activation function is the relu function.

[0024] Furthermore, the gated network model adopts a multi-layer perceptron model, which is a 3-layer network structure. The input layer receives input data, the middle layer is a 32-dimensional vector, the activation function is the relu function, and the three gated network models independently calculate the weight of each expert sub-model. The output layer is a 3-dimensional vector, and the activation function is softmax, which corresponds to the weights of the three expert sub-models respectively. The weighted sum is performed, and the sum of the three weights is 1.

[0025] The SOH prediction values ​​of the three expert sub-models are weighted and summed with the expert weights output by the three gating networks to obtain the weighted sum values ​​of the three SOHs. The weighted sum values ​​of the three SOHs are subjected to linear regression prediction to obtain the final predicted value SOH.

[0026] Furthermore, the weighted summation process is as follows: The outputs of the three expert sub-models are SOH_1, SOH_2 and SOH_3. These three outputs are all continuous variables, representing the predicted values ​​of SOH for each sub-expert model.

[0027] The three gating network models independently calculate the weight of each expert sub-model. The output of each gating network is a three-dimensional vector, corresponding to the weights of the three expert sub-models, and the sum of the three weights is 1.

[0028] The SOH prediction values ​​of the three expert sub-models are weighted and summed with the expert weights output by the three gating networks to obtain the weighted sum values ​​of the three SOHs.

[0029] The weighted sum of the three SOHs is used for linear regression prediction to obtain the final predicted value SOH.

[0030] Step S3. Training and verifying the MH-MoE model: Implement the MH-MoE model code and train it on the Keras platform. The training data is divided into a training set and a test set in a ratio of 8:2. The model is trained on the training set and verified on the test set.

[0031] Furthermore, the number of training times is 100 and the number of batch samples is 32. The optimizer for model training is the adam algorithm, and the loss function is the mean square error.

[0032] Step S4. Predicting battery SOH: After the MH-MoE model is trained, the MH-MoE model is deployed if the model effect is good, and the MH-MoE is used to predict the battery SOH. The weighted sum of the three SOH values ​​is linearly regressed, and the predicted value obtained is the SOH prediction value.

[0033] Furthermore, the loss function of the model is mean square error; the optimizer is adam; and the evaluation indicator is mean absolute error, which is the sum of the absolute values ​​of the differences between the target value and the predicted value.

[0034] The beneficial effects of the present invention are The present invention uses battery impedance (EIS) to predict SOH based on the MH-MoE model, which has the advantages of diversified feature extraction brought by the multi-head mechanism, sparse activation to improve computational efficiency, the ability of the expert network to focus on different modes, and flexible adaptation to multi-task environments. The MH-MoE model can predict the health status of the battery more efficiently and accurately, and adapt to complex and changeable battery working conditions.

[0035] The details are as follows: 1. Multi-head mechanism improves feature extraction capabilities: 1.1 Diversified feature extraction: Multiple gating networks (heads) in the MH-MoE model can process input data in parallel, and each head can focus on extracting different features of the input data to capture the complex information in the battery impedance spectrum.

[0036] 1.2 Improve prediction accuracy: The multi-head mechanism can combine multiple feature representations to improve the model’s sensitivity to changes in battery health status, thereby improving the accuracy of SOH prediction.

[0037] 2. Sparse activation improves computational efficiency 2.1 Reduce the amount of computation: Each input data point only activates a few expert networks, which reduces the computational overhead and improves the computational efficiency of the model.

[0038] 2.2 Efficient processing of large-scale data: For application scenarios that require processing large amounts of battery impedance data, the sparse activation mechanism enables the MH-MoE model to efficiently process and predict.

[0039] 3. Expert networks focus on different patterns 3.1 Specialized processing: Each expert network can focus on different battery impedance patterns or characteristics to improve the modeling capabilities of different battery states.

[0040] 3.2 Handling complex data: Through the collaboration of different expert networks, the MH-MoE model can handle complex patterns and nonlinear relationships in battery impedance data and improve the robustness of SOH prediction.

[0041] 4. Flexible adaptation to multi-tasking environment 4.1 Adaptive Modeling: Through the flexible combination of multiple gating networks and expert networks, the model can adaptively select the most appropriate network structure and parameters to adapt to battery data of different types and states.

[0042] 5. Higher model performance 5.1 Improving prediction accuracy: Combining the advantages of multiple CNN-LSTM expert networks and gating networks, the MH-MoE model can significantly improve the accuracy of SOH prediction. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] Figure 1 It is a structural diagram of the battery SOH prediction model based on the MH-MoE model and EIS of the present invention.

[0044] Figure 2 It is the overall flow chart of battery SOH prediction based on MH-MoE model and EIS of the present invention.

[0045] Figure 3 It is a schematic diagram of convolution calculation.

[0046] Figure 4 It is a schematic diagram of pooling calculation.

[0047] Figure 5 This is the LSTM model structure diagram.

[0048] Figure 6 This is a diagram of the gated network model structure.

[0049] Figure 7 This is a sample diagram of the battery SOH prediction results based on the MH-MoE model and EIS of the present invention. DETAILED DESCRIPTION

[0050] refer to Figure 1 , the input data is the EIS data of the battery. EIS consists of a real part and an imaginary part. real_1 to real_m represent the real part data of EIS, imaginary_1 to imaginary_m represent the imaginary part data of EIS, and m represents the number of frequencies of EIS.

[0051] Next are the expert layer and the gated network layer. The present invention takes three CNN-LSTM expert sub-models and three gated networks based on multi-layer perceptrons (MLPs) as examples.

[0052] The input data are input into three expert sub-models and three gating network models respectively.

[0053] The three expert sub-models extract corresponding features from different angles, and the three gating network models independently calculate the weight of each expert sub-model.

[0054] The outputs of the three expert sub-models are SOH_1, SOH_2 and SOH_3. These three outputs are all continuous variables, representing the predicted values ​​of SOH by each sub-expert model.

[0055] The three gating network models independently calculate the weight of each expert sub-model. The output of each gating network is a three-dimensional vector, corresponding to the weights of the three expert sub-models, and the sum of the three weights is 1.

[0056] Then, the SOH prediction values ​​of the three expert sub-models are weighted and summed with the expert weights output by the three gating networks to obtain the weighted sum values ​​of the three SOHs.

[0057] Finally, the weighted sum of the three SOHs is used for linear regression prediction to obtain the final predicted value SOH.

[0058] refer to Figure 2 The specific implementation process of the present invention is as follows: Step S1. Test and collect battery EIS and SOH data: Testing and collecting battery EIS data requires professional impedance spectrum testing instruments and needs to cover a certain frequency range. The frequency range can be set to 10 -2 HZ to 10 5 HZ, multiple frequency values ​​are selected at a certain interval in the middle of the frequency range, and the frequency values ​​are generally selected from 5 to 60. The present invention selects 60 as a sample.

[0059] When collecting data, it is necessary to record the real and imaginary data of the impedance corresponding to each frequency, as well as the target value to be predicted, which is the corresponding battery SOH.

[0060] Step S2. Constructing MH-MoE model: MH-MoE model includes 3 expert sub-models and 3 gated network models. In the present invention, each sub-model is a CNN-LSTM model. The CNN model extracts the spatial features of the input data, and the LSTM model extracts the temporal features of the battery EIS data.

[0061] refer to Figure 3 The CNN structure of the present invention includes 1 convolution layer and a maximum pooling layer. The activation function of the convolution layer is the relu function. The number of filters is set to 32, and the kernel size is 1.

[0062] Figure 3 In the convolution layer, there is a 1×6×6 rectangle as input data, called the input feature map. It passes through a 3×3 filter (also called a convolution kernel) for convolution operation, that is, the tensor product is calculated starting from the 3×3 receiving field area in the upper left corner of the input, and moves to the right after each calculation with a stride of 1. After completing this calculation, a 1×4×4 output feature map, namely Result, is obtained.

[0063] refer to Figure 4 The pooling layer performs nonlinear downsampling on the input and takes the maximum value (Max Pooling) or the average value (Avg Pooling) in the local neighborhood as the output.

[0064] Among them, the size of the pooling input feature map is 4×4, the size of the maximum pooling and average pooling convolution kernels are both 2×2, and the size of the pooling output feature map is 2×2.

[0065] Each convolutional layer can extract high-level features of the input data, and the pooling layer implements downsampling to reduce the data dimension.

[0066] The present invention adopts the maximum pooling method.

[0067] refer to Figure 5 ,LSTM is a special RNN that can learn long-term dependencies and capture the dynamic changes of time series data.

[0068] The structure of the LSTM model consists of the following components: (1) Input gate: determines which parts of the current input information are allowed to enter the state unit.

[0069] (2) Forget gate: determines which information in the state unit needs to be forgotten or removed.

[0070] (3) Status unit: a core component used to store historical status information.

[0071] (4) Output gate: determines the information output to the next hidden layer.

[0072] (5) Activation function (Sigmoid, Tanh): used for nonlinear transformation.

[0073] (6) Output layer: LSTM output data corresponding to the input data.

[0074] LSTM controls the flow of information entry, retention and output by opening and closing the input gate, forget gate and output gate, and realizes the memory and processing of time series information. Compared with simple RNN, LSTM can better capture the long-term dependencies in time series data, process longer time series, and has more powerful modeling capabilities.

[0075] The number of neurons in the LSTM layer of the present invention is 32, and the activation function is the relu function.

[0076] refer to Figure 6 The gated network model adopts a multi-layer perceptron model, which is a 3-layer network structure. The input layer receives input data, the middle layer is a 32-dimensional vector, the activation function is the relu function, and the 3 gated network models independently calculate the weight of each expert sub-model. The output layer is a 3-dimensional vector, and the activation function is softmax, which corresponds to the weights of the 3 expert sub-models respectively. The weighted sum is performed, and the sum of the 3 weights is 1.

[0077] The SOH prediction values ​​of the three expert sub-models are weighted and summed with the expert weights output by the three gating networks to obtain the weighted sum values ​​of the three SOHs. The weighted sum values ​​of the three SOHs are subjected to linear regression prediction to obtain the final predicted value SOH.

[0078] Furthermore, the weighted summation process is as follows: The outputs of the three expert sub-models are SOH_1, SOH_2 and SOH_3. These three outputs are all continuous variables, representing the predicted values ​​of SOH for each sub-expert model.

[0079] The three gating network models independently calculate the weight of each expert sub-model. The output of each gating network is a three-dimensional vector, corresponding to the weights of the three expert sub-models, and the sum of the three weights is 1.

[0080] The SOH prediction values ​​of the three expert sub-models are weighted and summed with the expert weights output by the three gating networks to obtain the weighted sum values ​​of the three SOHs.

[0081] The weighted sum of the three SOHs is used for linear regression prediction to obtain the final predicted value SOH.

[0082] Step S3. Training and verifying the MH-MoE model: The present invention implements the MH-MoE model code and trains it on the Keras platform. The training data is divided into a training set and a test set in a ratio of 8:2. The model is trained on the training set, and the model is verified on the test set.

[0083] Furthermore, the number of training epochs is 100, and the number of batch samples is batch_size=32. The optimizer for model training is the adam algorithm, and the loss function is mean square error (mse).

[0084] Step S4. Predicting battery SOH: After the MH-MoE model is trained, if the model effect is good, the MH-MoE model can be deployed and the battery SOH can be predicted using MH-MoE. The weighted sum of the three SOH values ​​is linearly regressed, and the predicted value is the SOH prediction value.

[0085] Furthermore, the loss function of the model is Mean Square Error (MSE); the optimizer is Adam; and the evaluation metric is Mean Absolute Error (MAE), which is the sum of the absolute values ​​of the differences between the target value and the predicted value. Example

[0086] 1. Prediction data display The present invention tests the effect on a public data set (https: / / github.com / YunweiZhang / ML-identify-battery-degradation) and uses the impedance data therein to predict the battery SOH. There are 1358 battery EIS and SOH data. Referring to Table 1, EIS has 120 features, and the feature numbers are 1 to 120. The first 60 features are the real part data of the impedance data corresponding to the frequency from high to low, and the last 60 features are the imaginary part data of the impedance data corresponding to the frequency from high to low.

[0087]

[0088] Among them, f1 to f120 represent the EIS frequency characteristics, and the Capacity here represents the maximum capacity of the battery, namely SOH.

[0089] 2.SOH prediction results display The mean of the test set of battery capacity is 30.6249, the standard deviation is 4.1309, and the mean of the prediction set is 30.5395, the standard deviation is 4.1411, which shows that the data distribution of the prediction results is basically consistent with the data distribution of the real data.

[0090] The root mean square error between the prediction set and the test set of battery SOH is only 0.2663, indicating that the prediction effect of the model is good.

[0091] The prediction results are shown in Table 2 below:

[0092] The prediction results are as follows: Figure 7 As shown, Figure 7 The solid line in the upper middle represents the true value, the dotted line represents the predicted value, and the solid square represents the error value. The numbers represent the true values. Figure 7 It can be seen that the prediction effect is good.

Claims

1. A method for predicting battery SOH based on MH-MoE model and EIS data, characterized in that: The implementation steps include: Step S1. Test and collect battery EIS and SOH data: Professional impedance spectroscopy test equipment is used to test and collect battery EIS data, covering a frequency range of 10 -2 HZ to 10 5 HZ, select 5 to 60 frequency values ​​in the middle of the frequency range, preferably 60 as samples; When collecting data, record the real and imaginary data of the impedance corresponding to each frequency, as well as the target value to be predicted, which is the corresponding battery SOH; Step S2. Constructing the MH-MoE model: The MH-MoE model includes three expert sub-models and three gated network models, each of which is a CNN-LSTM model; the CNN model extracts the spatial features of the input data, and the LSTM model extracts the temporal features of the battery EIS data; Step S3. Training and verifying the MH-MoE model: Implement the MH-MoE model code and train it on the Keras platform. The training data is divided into a training set and a test set in a ratio of 8:

2. The model is trained on the training set and verified on the test set. Step S4. Predicting the battery SOH: After the MH-MoE model is trained, if the model effect is good, deploy the MH-MoE model, and use MH-MoE to predict the battery SOH. Perform linear regression on the weighted sum of the three SOHs, and the predicted value obtained is the SOH predicted value. According to a method for predicting battery SOH based on the MH-MoE model and EIS data according to claim 1, it is characterized in that in step S2, the CNN structure includes 1 convolution layer and one maximum pooling layer, the activation function of the convolution layer is the relu function, the number of filters is set to 32, and the kernel size is 1.

2. A method for predicting battery SOH based on MH-MoE model and EIS data according to claim 1, characterized in that: In step S2, the LSTM model controls the flow of information entry, retention and output by opening and closing the input gate, forget gate and output gate to realize the memory and processing of time series information; the number of neurons in the LSTM model is 32, and the activation function is the relu function.

3. The method for predicting battery SOH based on the MH-MoE model and EIS data according to claim 1, characterized in that: In step S2, the gated network model adopts a multi-layer perceptron model, which is a 3-layer network structure. The input layer receives input data, the middle layer is a 32-dimensional vector, the activation function is the relu function, and the 3 gated network models independently calculate the weight of each expert sub-model. The output layer is a 3-dimensional vector, the activation function is softmax, and the weights of the 3 expert sub-models are respectively corresponding to the weights, and the sum of the 3 weights is 1; The SOH prediction values ​​of the three expert sub-models are weighted and summed with the expert weights output by the three gating networks to obtain the weighted sum values ​​of the three SOHs; the weighted sum values ​​of the three SOHs are subjected to linear regression prediction to obtain the final predicted value SOH.

4. The method for predicting battery SOH based on the MH-MoE model and EIS data according to claim 1, characterized in that: The weighted summation process is as follows: The outputs of the three expert sub-models are SOH_1, SOH_2, and SOH_3. Each of these three outputs is a continuous variable, which represents the predicted value of SOH by each sub-expert model. Three gating network models independently calculate the weight of each expert sub-model. The output of each gating network is a 3D vector, corresponding to the weights of the three expert sub-models, and the sum of the three weights is 1. The SOH prediction values ​​of the three expert sub-models are weighted and summed with the expert weights output by the three gating networks to obtain the weighted sum values ​​of the three SOHs; The weighted sum of the three SOHs is used for linear regression prediction to obtain the final predicted value SOH.

5. The method for predicting battery SOH based on MH-MoE model and EIS data according to claim 1, characterized in that: In step S3, the number of training times is 100 and the number of batch samples is 32; the optimizer for model training is the Adam algorithm, and the loss function is the mean square error.

6. The method for predicting battery SOH based on MH-MoE model and EIS data according to claim 1, characterized in that: In step S4, the loss function of the model is mean square error; the optimizer is adam; and the evaluation indicator is mean absolute error, that is, the sum of the absolute values ​​of the differences between the target value and the predicted value.

Citation Information

Cited By

  • Battery health state detection method, equipment and medium

    CN120928230A