Method and system for predicting residual service life of vehicle energy storage lithium battery
Through the combination of feature clustering and deep neural networks of attention mechanisms, the problem of lithium batteries decreasing prediction accuracy in different driving scenarios is solved, and high-precision and stability prediction in multiple scenarios is achieved.
Patent Information
- Application Number
- CN202510164975.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-14
- Publication Date
- 2025-06-06
- Estimated Expiration
- 2045-02-14
AI Technical Summary
The existing lithium battery residual service life prediction methods have decreased prediction accuracy in different driving scenarios, and lack a systematic information fusion strategy, making it difficult to achieve consistent and excellent prediction performance in multiple scenarios.
The battery capacity data is clustered by feature clustering, divided into multiple sub-databases, and a prediction model based on the attention mechanism deep neural network is constructed to generate a corresponding number of sub-prediction models, and a suitable sub-prediction model is selected through a similarity evaluation algorithm for prediction.
It improves the accuracy and stability of the residual service life prediction of lithium batteries, adapts to the data characteristics of different driving scenarios, and realizes high-precision prediction in multiple scenarios and multiple operating conditions.
Smart Images

Figure CN120103189A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a method and system for predicting the remaining service life of a lithium battery, and in particular to a method and system for predicting the remaining service life of a vehicle energy storage lithium battery, belonging to the technical field of situation awareness of energy storage lithium batteries. Background Art
[0002] With the rapid development of Internet of Vehicles technology, the accurate prediction of the operating status and remaining service life of energy storage lithium batteries in electric vehicles, as key components of vehicles, has gradually become a research hotspot. This prediction not only helps to improve the safety and reliability of electric vehicles, but also provides a scientific basis for vehicle operation and maintenance, thereby reducing operating costs and extending battery life. Through a large number of sensors and communication devices in the Internet of Vehicles system, battery operation data can be collected in real time, transmitted to the cloud and stored, laying a solid foundation for related research.
[0003] In the prior art, there is a solution from the document "Prediction of Remaining Service Life of Lithium Batteries Based on SDAE-Transformer-ECA Network". This solution combines the advantages of stacked denoising auto encoder (SDAE) and transformer, and proposes a lithium-ion battery RUL prediction network of SDAE-Transformer-ECA combined with efficient channel attention (ECA). First, in view of the noise pollution such as capacity regeneration phenomenon and data set acquisition error existing in the use of batteries, SDAE is used to reconstruct, denoise and extract features of the input data. Then, the sequence information of the reconstructed data is captured through the Transformer network. Finally, the captured information is integrated and interacted across channels in combination with the ECA network, so as to realize the prediction of the RUL of lithium-ion batteries. The scheme was first verified by experiments based on the battery capacity dataset provided by the Center for Advanced Life Cycle Engineering (CALCE) of the University of Maryland. The experiments proved that the errors of the model in this paper were low and had high accuracy. Compared with the suboptimal algorithm Bi-LSTM, the average RE was relatively reduced by 62.67%, the average MAE was relatively reduced by 40.68%, and the average RMSE was relatively reduced by 34.33%. The generalization was then verified using the B0007 battery capacity dataset provided by the National Aeronautics and Space Administration (NASA). The experimental results of RE, MAE and RMSE were 1.98%, 3.12% and 4.16% respectively. Compared with existing algorithms such as RNN, LSTM, GRU and Bi-LSTM, the model prediction accuracy of this scheme is higher, proving the generalization of the model.
[0004] The current data-driven remaining battery life prediction method shows good prediction accuracy under ideal conditions. However, when electric vehicles are driven for a long time in different driving scenarios such as cities, highways or suburbs, the battery capacity degradation law shows significant differences, and the prediction accuracy of the existing methods will drop significantly. In addition, when existing data-driven models model the capacity degradation law in multiple scenarios, they often lack systematic information fusion strategies, making it difficult to achieve consistently excellent prediction performance under different driving conditions. Summary of the invention
[0005] Purpose of the invention: The purpose of the present invention is to provide a method and system for predicting the remaining service life of a lithium-ion battery for automotive energy storage, which can improve the prediction accuracy.
[0006] Technical solution: The method for predicting the remaining service life of a lithium-ion battery for automotive energy storage according to the present invention comprises:
[0007] Step 1: Obtain the battery capacity data and historically known remaining battery life of the automotive energy storage lithium battery, and perform preprocessing to obtain a battery data pool. Use the feature clustering method to cluster the battery capacity data. According to the clustering results, divide the battery data pool into multiple sub-databases, and set the typical capacity degradation curve corresponding to each sub-database;
[0008] Step 2: Build a prediction model based on the attention mechanism deep neural network, and generate a corresponding number of prediction models according to the number of sub-databases;
[0009] Step 3: Match the sub-databases to the prediction models one by one, use the data of each sub-database to train the corresponding prediction model, and obtain the sub-prediction model corresponding to each sub-database;
[0010] Step 4: Obtain the battery operation data of the automotive energy storage lithium battery to be predicted, compare it with the data in all sub-databases through a similarity evaluation algorithm and calculate the data similarity, and select the sub-prediction model corresponding to the sub-database with the highest similarity as the current prediction model;
[0011] Step 5: Use the current prediction model to predict the remaining service life curve of the automotive energy storage lithium battery to be predicted.
[0012] Furthermore, the step 1 comprises:
[0013] Step 1.1: Obtain battery capacity data and historically known remaining battery life from the historical operation data and real-time operation data of the vehicle energy storage lithium battery in the Internet of Vehicles system, and form a battery data pool through preprocessing, wherein the preprocessing includes data cleaning and data standardization;
[0014] Step 1.2: Use the feature clustering method to perform cluster analysis on all capacity curves of the battery capacity data according to the morphological characteristics, and select the optimal number of clusters as the clustering result according to the clustering performance evaluation index;
[0015] Step 1.3: Divide the battery data pool into multiple sub-databases based on the clustering results, and use the cluster center curve corresponding to each sub-database as the corresponding typical capacity degradation curve; each sub-database represents the battery operation data characteristics of a specific scenario, and the specific scenarios include urban driving scenarios, suburban driving scenarios, highway driving scenarios, tourist attraction driving scenarios, industrial area driving scenarios, and airport driving scenarios.
[0016] Furthermore, the feature clustering method described in step 1.2 is a K-shape clustering algorithm, and the clustering performance indicator evaluation is S_dbw.
[0017] Furthermore, the feature clustering method described in step 1.2 is the K-means clustering algorithm, and the clustering performance indicator evaluation is S_dbw.
[0018] Furthermore, the prediction model described in step 2 is composed of a denoising autoencoder, an attention mechanism encoding layer and a fully connected layer, with battery operation data as input and the remaining service life prediction result of the automotive energy storage lithium battery as output.
[0019] Furthermore, the step 3 comprises:
[0020] Step 3.1: The sub-databases are mapped to each prediction model one by one. For a prediction model, all parameters in the prediction model are randomly initialized, and a training data set is constructed using the battery operation data of the sub-database corresponding to the prediction model. The historically known remaining battery life in the corresponding sub-database is used as the benchmark output;
[0021] Step 3.2: Based on the back propagation method, the loss of the training data set is calculated according to the loss function integrating the typical capacity degradation curve;
[0022] Step 3.3: When the loss of the training data set is not greater than the set threshold, the model training is terminated to obtain the trained sub-prediction model and the corresponding weight parameters.
[0023] Furthermore, the step 3.2 includes:
[0024] Based on the back propagation method, the loss of the training data set is calculated according to the loss function of the typical capacity degradation curve, which satisfies the following relationship:
[0025]
[0026] Among them, L() is the improved loss function, x is the real capacity curve, is the predicted capacity curve, N is the length of the unknown battery capacity data to be predicted, x i is the actual capacity of the charge and discharge cycle of the i-th data, is the predicted capacity of the charge and discharge cycle of the i-th data, f MSELoss is the MSELoss loss function, T is the typical capacity degradation curve, T i is the typical capacity degradation value of the charge and discharge cycle of the i-th data, and a and c are hyperparameters.
[0027] Based on the same inventive concept, the present invention also provides a system for predicting the remaining service life of a lithium energy storage battery for a vehicle, comprising:
[0028] A preprocessing module is used to obtain the battery capacity data and the historically known remaining service life of the vehicle energy storage lithium battery, and perform preprocessing to obtain a battery data pool;
[0029] A clustering module is used to cluster the battery capacity data using a feature clustering method, divide the battery data pool into multiple sub-databases according to the clustering results, and set a typical capacity degradation curve corresponding to each sub-database;
[0030] The model building module is used to build a prediction model based on the deep neural network of the attention mechanism, and generate a corresponding number of prediction models according to the number of sub-databases;
[0031] The model training module is used to match the sub-databases with the prediction models one by one, use the data of each sub-database to train the corresponding prediction model, and obtain the sub-prediction model corresponding to each sub-database;
[0032] The model screening module is used to obtain the battery operation data of the automotive energy storage lithium battery to be predicted, compare it with the data in all sub-databases through a similarity evaluation algorithm and calculate the data similarity, and select the sub-prediction model corresponding to the sub-database with the highest similarity as the current prediction model;
[0033] The prediction module is used to predict the remaining service life curve of the automotive energy storage lithium battery to be predicted using the current prediction model.
[0034] Based on the same inventive concept, the present invention also provides a computing device, comprising: one or more processors, one or more memories and one or more programs, wherein the programs are stored in the memories and configured to be executed by the processors, and when the programs are loaded into the processors, the steps of the method for predicting the remaining service life of a vehicle energy storage lithium battery according to any one of the above items are implemented.
[0035] Based on the same inventive concept, the present invention also provides a storage medium, which stores a computer program, and the computer program includes program instructions. When the program instructions are executed by a processor, the processor executes the steps of the method for predicting the remaining service life of a vehicle energy storage lithium battery according to any of the above items.
[0036] Beneficial effects: Compared with the prior art, the present invention combines the Internet of Vehicles information clustering technology with the deep learning model, proposes a lithium battery remaining service life prediction method based on multi-scenario data clustering, adopts a feature clustering algorithm to classify the battery operation data in the driving scenario, and constructs a sub-prediction model with strong scenario adaptability, which effectively improves the model's adaptability to data in different scenarios; the present invention uses a denoising autoencoder and a deep neural network based on the attention mechanism to perform denoising and long-distance dependent feature extraction on the lithium battery capacity degradation data. At the same time, the typical capacity degradation curve is introduced as prior knowledge in the model training, and the convergence and prediction accuracy of the model are optimized through an improved loss function; the present invention adopts dynamic time warping and cosine similarity algorithm to achieve efficient matching between the data to be tested and the optimal sub-prediction model, so that the prediction results show high accuracy and high stability under multiple scenarios and multiple working conditions. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] Figure 1 is a flow chart of a method according to an embodiment of the present invention;
[0038] Figure 2 It is a line chart of feature clustering performance evaluation indicators of an embodiment of the present invention;
[0039] Figure 3 A schematic diagram of the prediction model structure of an embodiment of the present invention;
[0040] Figure 4 A loss function weight factor change curve diagram of an embodiment of the present invention;
[0041] Figure 5 This is a prediction curve diagram of the remaining service life of an electric vehicle energy storage lithium battery according to an embodiment of the present invention. DETAILED DESCRIPTION
[0042] In order to enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. The embodiments described in this application are only embodiments of a part of the present invention, not all embodiments. Based on the spirit of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work belong to the protection scope of the present invention.
[0043] As attached Figure 1 As shown, the method for predicting the remaining service life of a vehicle energy storage lithium battery in this embodiment includes:
[0044] Step 1: Obtain the battery capacity data and historically known remaining battery life of the automotive energy storage lithium battery, and perform preprocessing to obtain a battery data pool. Use the feature clustering method to cluster the battery capacity data. According to the clustering results, divide the battery data pool into multiple sub-databases, and set the typical capacity degradation curve corresponding to each sub-database;
[0045] Step 2: Build a prediction model based on the attention mechanism deep neural network, and generate a corresponding number of prediction models according to the number of sub-databases;
[0046] Step 3: Match the sub-databases to the prediction models one by one, use the data of each sub-database to train the corresponding prediction model, and obtain the sub-prediction model corresponding to each sub-database;
[0047] Step 4: Obtain the battery operation data of the automotive energy storage lithium battery to be predicted, compare it with the data in all sub-databases through a similarity evaluation algorithm and calculate the data similarity, and select the sub-prediction model corresponding to the sub-database with the highest similarity as the current prediction model;
[0048] Step 5: Use the current prediction model to predict the remaining service life curve of the automotive energy storage lithium battery to be predicted.
[0049] Specifically, the step 1 includes:
[0050] Step 1.1: Obtain battery capacity data and historically known remaining battery life from the historical operation data and real-time operation data of the vehicle energy storage lithium battery in the Internet of Vehicles system, and form a battery data pool through preprocessing, wherein the preprocessing includes data cleaning and data standardization;
[0051] Step 1.2: Use the feature clustering method to perform cluster analysis on all capacity curves of the battery capacity data according to the morphological characteristics, and select the optimal number of clusters as the clustering result according to the clustering performance evaluation index;
[0052] Step 1.3: Divide the battery data pool into multiple sub-databases based on the clustering results, and use the cluster center curve corresponding to each sub-database as the corresponding typical capacity degradation curve; each sub-database represents the battery operation data characteristics of a specific scenario, and the specific scenarios include urban driving scenarios, suburban driving scenarios, highway driving scenarios, tourist attraction driving scenarios, industrial area driving scenarios, and airport driving scenarios.
[0053] Furthermore, the feature clustering described in step 1.2 uses the K-shape clustering algorithm or the K-means clustering algorithm as the feature clustering method. For the K-shape clustering algorithm, its core is to use the normalized Euclidean distance to calculate the morphological similarity between time series, and to ensure the alignment between curves through the dynamic time warping distance method. Its objective function is:
[0054]
[0055] Among them, C represents the cluster, x i Represents the capacity curve of the battery, μ k is the center curve of the kth cluster, d(x i ,μ k ) represents the morphological distance.
[0056] For the K-means clustering algorithm, Euclidean distance is used as the similarity metric, and the objective function is:
[0057]
[0058] Among them, ‖x i ,μ k ‖ 2 is the Euclidean distance from the sample to the cluster center.
[0059] In the embodiment, S_dbw (Separation Davies-Bouldin) is used as an indicator to evaluate clustering performance. The S_dbw indicator evaluates the clustering effect by quantifying the intra-class compactness and inter-cluster separation, and its formula is:
[0060]
[0061] Among them, V S_dbw is the value of the S_dbw indicator, σ(C i ) is the standard deviation of the data in the i-th cluster, ||C i ,C j || is the distance between the centroids of the i-th and j-th clusters. The smaller V S_dbw This indicates a better clustering result.
[0062] In the embodiment, Figure 2 As shown in the figure, all capacity curves in a battery capacity database are clustered using the K-shape clustering algorithm and the K-means clustering algorithm. The V S_dbw The K-shape and K-means methods have different clustering performances and show a trend. When the number of clusters is set to 2 to 6, the clustering performance of the K-shape method is higher than that of the K-means method, which proves that the K-shape method has a better clustering effect. In addition, before the clustering data reaches 4, the V S_Dbw The overall trend is downward, and then the trend becomes flat. As the number of clusters increases, the clustering effect does not change significantly. S_Dbw and clustering calculation burden, the number of clusters is set to 4 for the best. Therefore, by calculating the V of the feature clustering method results S_Dbw, the optimal clustering number K can be determined, and the battery capacity database can be divided into K sub-databases.
[0063] Furthermore, the prediction model described in step 2 is composed of a denoising autoencoder, an attention mechanism encoding layer and a fully connected layer, with battery operation data as input and the remaining service life prediction result of the automotive energy storage lithium battery as output.
[0064] According to the method proposed in the present invention, the prediction model is composed of a denoising autoencoder, an attention mechanism encoding layer and a fully connected layer. It takes the battery operation data in the sub-database as input and takes the remaining service life prediction results of the automotive energy storage lithium battery under different scenarios as output.
[0065] In the embodiment, Figure 3 As shown, first, it is necessary to construct the input data of the prediction model, that is, to slice the battery operation data into multiple groups of time series data segments X = {x t ,x t+1 ,…x t+n Since the battery operation data is highly correlated with the number of cycles, the number of cycles corresponding to the battery capacity can be added to the original capacity data segment to form a multidimensional array as the input data of the model.
[0066] Secondly, before the data is positionally encoded, a denoising autoencoder is set up to denoise the input lithium battery capacity degradation data to reduce the impact of data noise caused by sensor anomalies or communication fluctuations in the energy storage system. The denoising autoencoder learns the nonlinear representation of the time series data segment by constructing an encoding-decoding process, and then reconstructs the denoised data. Its encoding process can be expressed as:
[0067] z=e(X)=f sigmoid (W T X+b)
[0068] Among them, e(·) represents the encoding function, z is the nonlinear representation of the time series data X, and f sigmoid is the sigmoid activation function, W and b are the weight matrix and bias matrix respectively.
[0069] The corresponding decoding process can be expressed as:
[0070]
[0071] Where d(·) represents the decoding function, is the denoised time series data output by the denoising autoencoder, W' and b' are the weight matrix and bias matrix respectively.
[0072] The denoising autoencoder constructs nonlinear mappings e and d to learn the nonlinear representation of noise data, achieves data denoising, and obtains the battery capacity data after denoising. As subsequent input. The details are as follows:
[0073]
[0074] Thirdly, the denoised data is input into the attention mechanism encoding layer based on the attention mechanism to further explore the long-distance dependencies in the lithium battery capacity degradation data. Compared with the recurrent neural network, it has superior data parallel processing capabilities, but also loses the sequence order of the original input. Therefore, the battery capacity curve after denoising Before entering the encoding layer, the temporal features of the sequence need to be represented by position encoding. The position encoding formula is as follows:
[0075]
[0076] Among them, p os is the position index of the input vector, d m is the dimension of the input vector, i∈[0,d m / 2], which is the index of the input vector dimension.
[0077] The attention mechanism encoding layer can set N according to the complexity of the prediction model d The attention submodules are connected in series. Each attention submodule mainly consists of a multi-head attention layer and a feedforward layer, and residual connections and layer normalization are set between each layer. The multi-head attention layer is formed based on the self-attention mechanism and is used to mine the long-distance correlation features of time series data. The multi-head attention layer is first split into multiple attention heads. Secondly, in each branch, the input data vector After the attention mechanism, multiple subspaces are formed, and finally multiple attention heads are used to extract information from different subspaces and merge them into the final output features. The self-attention mechanism is as follows:
[0078]
[0079] Where V head is the output of the self-attention mechanism, Q = XW Q , K = XW K , V = XW V , W Q , W K , W V is the weight matrix, Q, K, V are set as query matrix, key value matrix and value matrix respectively, f softmax is the activation function, d k is the dimension of the input vector.
[0080] After obtaining h self-attention mechanism outputs, the multi-head attention layer combines and splices them, and then uses the weight matrix W O The long-distance correlation features are extracted by fusion to form the layer output:
[0081]
[0082] In order to further enhance the nonlinear expression ability of the attention mechanism encoding layer and improve the prediction accuracy, the encoder additionally introduces two linear transformations and an activation function f Relu The feed-forward layer:
[0083] f FFN (x) = w 2 ·f Relu (w 1 x+b 1 )+b 2
[0084] Among them, w 1 , w 2 , b 1 , b 2 are the weights and biases of two sets of linear transformations respectively.
[0085] In addition, in order to effectively alleviate the problem of gradient disappearance, residual connections and normalization layers are set after the multi-head attention layer and the feedforward layer to ensure that useful information is effectively retained when the model has a deep layer. The implementation process is as follows:
[0086] f layernorm (V m )=V m +f multihead (V m )
[0087] f layernorm (V f )=V f +f FFN (V f )
[0088] Among them, V m and V f are the input values of the multi-head attention layer and the feed-forward layer, respectively, multihead (V m ) and f FFN (V f ) are the output values of the multi-head attention layer and the feed-forward layer respectively.
[0089] Finally, a fully connected layer is used to map the features obtained by the attention mechanism encoding layer to the output to achieve the prediction of the remaining useful life.
[0090] Furthermore, the step 3 comprises:
[0091] Step 3.1: The sub-databases are mapped to each prediction model one by one. For a prediction model, all parameters in the prediction model are randomly initialized, and a training data set is constructed using the battery operation data of the sub-database corresponding to the prediction model. The historically known remaining battery life in the corresponding sub-database is used as the benchmark output;
[0092] Step 3.2: Based on the back propagation method, the loss of the training data set is calculated according to the loss function integrating the typical capacity degradation curve;
[0093] Step 3.3: When the loss of the training data set is not greater than the set threshold, the model training is terminated to obtain the trained sub-prediction model and the corresponding weight parameters; the threshold is set to 0.05.
[0094] Further, step 3.2 includes:
[0095] Based on the back propagation method, the loss of the training data set is calculated according to the loss function of the typical capacity degradation curve, which satisfies the following relationship:
[0096]
[0097] Among them, L() is the improved loss function, x is the real capacity curve, is the predicted capacity curve, N is the length of the unknown battery capacity data to be predicted, x i is the actual capacity of the charge and discharge cycle of the i-th data, is the predicted capacity of the charge and discharge cycle of the i-th data, f MSELoss is the MSELoss loss function, T is the typical capacity degradation curve, T i is the typical capacity degradation value of the charge and discharge cycle of the ith data, a and c are hyperparameters, which are set to 5 and 1 respectively.
[0098] Based on the same inventive concept, this embodiment also provides a system for predicting the remaining service life of a vehicle energy storage lithium battery, including:
[0099] A preprocessing module is used to obtain the battery capacity data and the historically known remaining service life of the vehicle energy storage lithium battery, and perform preprocessing to obtain a battery data pool;
[0100] A clustering module is used to cluster the battery capacity data using a feature clustering method, divide the battery data pool into multiple sub-databases according to the clustering results, and set a typical capacity degradation curve corresponding to each sub-database;
[0101] The model building module is used to build a prediction model based on the deep neural network of the attention mechanism, and generate a corresponding number of prediction models according to the number of sub-databases;
[0102] The model training module is used to match the sub-databases with the prediction models one by one, use the data of each sub-database to train the corresponding prediction model, and obtain the sub-prediction model corresponding to each sub-database;
[0103] The model screening module is used to obtain the battery operation data of the automotive energy storage lithium battery to be predicted, compare it with the data in all sub-databases through a similarity evaluation algorithm and calculate the data similarity, and select the sub-prediction model corresponding to the sub-database with the highest similarity as the current prediction model;
[0104] The prediction module is used to predict the remaining service life curve of the automotive energy storage lithium battery to be predicted using the current prediction model.
[0105] Specifically, the preprocessing module obtains the operating data of the vehicle energy storage lithium battery and performs necessary preprocessing on the data to build a data pool;
[0106] Including: obtaining all historical and real-time operating data of the vehicle energy storage lithium battery in the Internet of Vehicles system through the preprocessing module in the electric vehicle, and forming a battery data pool after preprocessing, which includes battery capacity data;
[0107] According to the method proposed in the present invention, the key operating parameters of the vehicle energy storage lithium battery, including voltage, charging current, discharge current, temperature, state of charge, health status and other information, are monitored and obtained in real time through the preprocessing module installed on the electric vehicle, and the historical data and real-time data collected by the vehicle communication terminal using 4G / 5G, Wi-Fi, Bluetooth and other vehicle network wireless communication technologies ensure the real-time and integrity of data transmission. The data is preliminarily classified and indexed to form a battery data pool, in which the battery capacity data is stored separately and managed according to key attributes such as time, vehicle number, and battery model. Then, the raw data in the battery data pool is preprocessed as necessary, including data cleaning to remove redundancy, noise and abnormal data, data standardization to unify the data format of different times and vehicles, and alignment of time series data, and finally a high-quality battery data pool is constructed to provide basic support for subsequent feature clustering analysis and the construction of typical capacity degradation curves.
[0108] In the clustering module, the feature clustering method is used to perform cluster analysis on all capacity curves in the battery capacity data according to their morphological characteristics, and the optimal number of clusters is selected as the clustering result based on the clustering performance evaluation index.
[0109] According to the method proposed in the present invention, the clustering module first pre-processes all capacity curves in the battery capacity data. By standardizing the original data, the influence of differences in battery capacity and usage conditions is eliminated to ensure the comparability of the curve morphological characteristics. Then, a clustering method based on morphological characteristics is used to perform cluster analysis on the capacity curves.
[0110] In the embodiment, a K-shape clustering algorithm or a K-means clustering algorithm is used as a feature clustering method. For the K-shape clustering algorithm, its core is to use the normalized Euclidean distance to calculate the morphological similarity between time series, and to ensure the alignment between curves through the dynamic time warping distance method. Its objective function is:
[0111]
[0112] Among them, C represents the cluster, x i Represents the capacity curve of the battery, μ k is the center curve of the kth cluster, d(x i ,μ k ) represents the morphological distance.
[0113] For the K-means clustering algorithm, Euclidean distance is used as the similarity metric, and the objective function is:
[0114]
[0115] Among them, ‖x i ,μ k ‖ 2 is the Euclidean distance from the sample to the cluster center.
[0116] In the embodiment, S_dbw (Separation Davies-Bouldin) is used as an indicator to evaluate clustering performance. The S_dbw indicator evaluates the clustering effect by quantifying the intra-class compactness and inter-cluster separation, and its formula is:
[0117]
[0118] Among them, V S_dbw is the value of the S_dbw indicator, σ(C i ) is the standard deviation of the data in the i-th cluster, ||C i ,C j || is the distance between the centroids of the i-th and j-th clusters. The smaller V S_dbw This indicates a better clustering result.
[0119] In the embodiment, Figure 2As shown in the figure, all capacity curves in a battery capacity database are clustered using the K-shape clustering algorithm and the K-means clustering algorithm. The V S_dbw The K-shape and K-means methods have different clustering performances and show a trend. When the number of clusters is set to 2 to 6, the clustering performance of the K-shape method is higher than that of the K-means method, which proves that the K-shape method has a better clustering effect. In addition, before the clustering data reaches 4, the V S_Dbw The overall trend is downward, and then the trend becomes flat. As the number of clusters increases, the clustering effect does not change significantly. S_Dbw and clustering calculation burden, the number of clusters is set to 4 for the best. Therefore, by calculating the V of the feature clustering method results S_Dbw , the optimal clustering number K can be determined, and the battery capacity database can be divided into K sub-databases.
[0120] According to the clustering results, all battery data are divided into multiple sub-databases, and the cluster center curve μ is set as the typical capacity degradation curve T of the corresponding sub-database. Each sub-database represents the battery operation data characteristics of a specific scenario such as urban driving scenario, suburban driving scenario, high-speed driving scenario, tourist attraction driving scenario, industrial area driving scenario and airport driving scenario, and the corresponding typical capacity degradation curve contains the common change law of the performance of automotive energy storage lithium batteries under this characteristic.
[0121] In the model building module, a prediction model based on the attention mechanism deep neural network is constructed, and a corresponding number of prediction models are generated according to the number of sub-databases.
[0122] According to the method proposed in the present invention, the prediction model is composed of a denoising autoencoder, an attention mechanism encoding layer and a fully connected layer. It takes the battery operation data in the sub-database as input and takes the remaining service life prediction results of the automotive energy storage lithium battery under different scenarios as output.
[0123] In the embodiment, as shown in FIG. 3 , it is first necessary to construct the input data of the prediction model, that is, to slice the battery operation data into multiple groups of time series data segments X={x t ,x t+1 ,…x t+n Since the battery operation data is highly correlated with the number of cycles, the number of cycles corresponding to the battery capacity can be added to the original capacity data segment to form a multidimensional array as the input data of the model.
[0124] Secondly, before the data is positionally encoded, a denoising autoencoder is set up to denoise the input lithium battery capacity degradation data to reduce the impact of data noise caused by sensor anomalies or communication fluctuations in the energy storage system. The denoising autoencoder learns the nonlinear representation of the time series data segment by constructing an encoding-decoding process, and then reconstructs the denoised data. Its encoding process can be expressed as:
[0125] z=e(X)=f sigmoid (W T X+b)
[0126] Among them, e(·) represents the encoding function, z is the nonlinear representation of the time series data X, and f sigmoid is the sigmoid activation function, W and b are the weight matrix and bias matrix respectively.
[0127] The corresponding decoding process can be expressed as:
[0128]
[0129] Where d(·) represents the decoding function, is the denoised time series data output by the denoising autoencoder, W' and b' are the weight matrix and bias matrix respectively.
[0130] The denoising autoencoder constructs nonlinear mappings e and d to learn the nonlinear representation of noise data, achieves data denoising, and obtains the battery capacity data after denoising. As subsequent input. The details are as follows:
[0131]
[0132] Thirdly, the denoised data is input into the attention mechanism encoding layer based on the attention mechanism to further explore the long-distance dependencies in the lithium battery capacity degradation data. Compared with the recurrent neural network, it has superior data parallel processing capabilities, but also loses the sequence order of the original input. Therefore, the battery capacity curve after denoising Before entering the encoding layer, the temporal features of the sequence need to be represented by position encoding. The position encoding formula is as follows:
[0133]
[0134] Among them, p os is the position index of the input vector, d m is the dimension of the input vector, i∈[0,d m / 2], which is the index of the input vector dimension.
[0135] The attention mechanism encoding layer can set N according to the complexity of the prediction model dThe attention submodules are connected in series. Each attention submodule mainly consists of a multi-head attention layer and a feedforward layer, and residual connections and layer normalization are set between each layer. The multi-head attention layer is formed based on the self-attention mechanism and is used to mine the long-distance correlation features of time series data. The multi-head attention layer is first split into multiple attention heads. Secondly, in each branch, the input data vector After the attention mechanism, multiple subspaces are formed, and finally multiple attention heads are used to extract information from different subspaces and merge them into the final output features. The self-attention mechanism is as follows:
[0136]
[0137] Where V head is the output of the self-attention mechanism, Q = XW Q , K = XW K , V = XW V , W Q , W K , W V is the weight matrix, Q, K, V are set as query matrix, key value matrix and value matrix respectively, f softmax is the activation function, d k is the dimension of the input vector.
[0138] After obtaining h self-attention mechanism outputs, the multi-head attention layer combines and splices them, and then uses the weight matrix W O The long-distance correlation features are extracted by fusion to form the layer output:
[0139]
[0140] In order to further enhance the nonlinear expression ability of the attention mechanism encoding layer and improve the prediction accuracy, the encoder additionally introduces two linear transformations and an activation function f Relu The feed-forward layer:
[0141] f FFN (x) = w 2 ·f Relu (w 1 x+b 1 )+b 2
[0142] Among them, w 1 , w 2 , b 1 , b 2 are the weights and biases of two sets of linear transformations respectively.
[0143] In addition, in order to effectively alleviate the problem of gradient disappearance, residual connections and normalization layers are set after the multi-head attention layer and the feedforward layer to ensure that useful information is effectively retained when the model has a deep layer. The implementation process is as follows:
[0144] f layernorm (V m )=V m +f multihead (V m )
[0145] f layernorm (V f )=V f +f FFN (V f )
[0146] Among them, V m and V f are the input values of the multi-head attention layer and the feed-forward layer, respectively, multihead (V m ) and f FFN (V f ) are the output values of the multi-head attention layer and the feed-forward layer respectively.
[0147] Finally, a fully connected layer is used to map the features obtained by the attention mechanism encoding layer to the output to achieve the prediction of the remaining useful life.
[0148] In the model training module, the sub-databases are mapped one by one to each prediction model, and the corresponding prediction models are trained using data from different sub-databases.
[0149] According to the method proposed by the present invention, the prediction model training process includes:
[0150] The sub-databases are matched one by one with each prediction model. For a prediction model, all parameters in the prediction model are randomly initialized, and a training data set is constructed with all battery operation data in the sub-database. All known remaining battery life in the corresponding sub-database is output as a benchmark.
[0151] Based on the back-propagation method, the loss of the training data set is calculated according to the loss function that integrates the typical capacity degradation curve.
[0152] In the embodiment, the typical capacity degradation curve T is used as the cluster center, which has the common characteristics of all capacity curves in this type of sub-database and can provide guidance for the capacity prediction process as prior knowledge. To this end, based on the commonly used MSELoss loss function, this application transforms the typical capacity degradation curve into prior knowledge through a Gaussian function to form the weight factor W of the loss function. l The improved loss function is as follows:
[0153]
[0154] Among them, L() is the improved loss function, x is the real capacity curve, is the predicted capacity curve, N is the length of the unknown battery capacity data to be predicted, x i is the actual capacity of the charge and discharge cycle of the i-th data, is the predicted capacity of the charge and discharge cycle of the i-th data, f MSELoss is the MSELoss loss function, T is the typical capacity degradation curve, T i is the typical capacity degradation value of the charge and discharge cycle of the ith data, a and c are hyperparameters set to 5 and 1 respectively.
[0155] In the embodiment, Figure 4 As shown, when predicting the battery capacity of the i-th cycle, the model's predicted value Whenever it approaches T i When the weight factor W in the loss function i l It will give a higher weight, further accelerate the model convergence based on the original MSELoss loss function, and increase the model's attention to the predicted values near the typical capacity degradation curve. Ultimately, the predicted capacity curve is closer to the typical capacity degradation curve, so that the common characteristics of this type of capacity curve are incorporated into the prediction process as prior knowledge, further improving the prediction accuracy.
[0156] When the loss of the training data set is not greater than the set threshold, the model training is terminated, and the sub-prediction model and the corresponding trained weight parameters are stored.
[0157] In the embodiment, the threshold is set to 0.05.
[0158] Model screening module. When the remaining service life of the energy storage lithium battery in the electric vehicle needs to be predicted, the battery operation data is first uploaded to the model screening module through the Internet of Vehicles. The similarity evaluation algorithm therein will compare the vehicle data to be tested with the data in all sub-databases and calculate the data similarity, and mark the sub-prediction model corresponding to the sub-database with the highest similarity as m.
[0159] In the embodiment, when the remaining service life of the energy storage lithium battery in the electric vehicle needs to be predicted, the real-time operation data of the battery is first uploaded to the model screening module through the Internet of Vehicles. The model screening module uses a similarity evaluation algorithm to compare the operating data of the battery to be tested with the data in all sub-databases one by one, calculate the similarity, and select the optimal sub-prediction model based on the similarity.
[0160] Specifically, the similarity evaluation algorithm can use dynamic time warping or cosine similarity method. In all sub-databases, the model screening module calculates the similarity between the battery data to be tested and the data of each sub-database in turn, and selects the sub-database with the highest average similarity. The sub-prediction model corresponding to the sub-database with the highest average similarity is marked as m, and the remaining service life of the battery to be tested is predicted based on the model.
[0161] In the prediction module, the sub-prediction model m is used to predict the remaining service life curve of the electric vehicle energy storage lithium battery to obtain the remaining service life prediction result of the energy storage lithium battery.
[0162] In the embodiment, the sub-prediction model m and its corresponding weight parameters are loaded into the prediction module as a whole, and the operation data of the predicted electric vehicle energy storage lithium battery is input into the sub-prediction model m to obtain Figure 5 The remaining battery life prediction curve is shown. The number of cycles when the capacity value of the prediction curve is lower than 80% of the rated capacity of the energy storage lithium battery is recorded as n end , the current cycle period and n end The difference between the two is the prediction result of the remaining service life of the energy storage lithium battery. The prediction result is then downloaded to the electric vehicle to be predicted to achieve the prediction of the life of the vehicle energy storage lithium battery.
[0163] Based on the same inventive concept, this embodiment also provides a computing device, including: one or more processors, one or more memories and one or more programs, wherein the programs are stored in the memories and configured to be executed by the processors, and when the programs are loaded into the processors, the steps of the method for predicting the remaining service life of a vehicle energy storage lithium battery according to any of the above items are implemented.
[0164] Based on the same inventive concept, this embodiment also provides a storage medium, which stores a computer program, and the computer program includes program instructions. When the program instructions are executed by a processor, the processor executes the steps of the method for predicting the remaining service life of a vehicle energy storage lithium battery according to any of the above items.
[0165] The present invention may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present disclosure.
[0166] A computer-readable storage medium may be a tangible device that can hold and store instructions used by an instruction execution device. A computer-readable storage medium may be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing. More specific examples of computer-readable storage media (a non-exhaustive list) include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, such as a punch card or a raised structure in a groove on which instructions are stored, and any suitable combination of the foregoing. As used herein, a computer-readable storage medium is not to be interpreted as a transient signal per se, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium (e.g., a light pulse through a fiber optic cable), or an electrical signal transmitted through a wire.
[0167] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.
[0168] The computer program instructions for performing the operation of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions may be executed completely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or completely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be customized by utilizing the state information of the computer-readable program instructions, and the electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present disclosure.
[0169] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the relevant field should understand that the specific implementation methods of the present invention can still be modified or replaced by equivalents, and any modifications or equivalent replacements that do not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.
Claims
1. A method for predicting the remaining service life of a lithium battery for automotive energy storage, characterized in that: include: Step 1: Obtain the battery capacity data and historically known remaining battery life of the automotive energy storage lithium battery, and perform preprocessing to obtain a battery data pool. Use the feature clustering method to cluster the battery capacity data. According to the clustering results, divide the battery data pool into multiple sub-databases, and set the typical capacity degradation curve corresponding to each sub-database; Step 2: Build a prediction model based on the attention mechanism deep neural network, and generate a corresponding number of prediction models according to the number of sub-databases; Step 3: Match the sub-databases to the prediction models one by one, use the data of each sub-database to train the corresponding prediction model, and obtain the sub-prediction model corresponding to each sub-database; Step 4: Obtain the battery operation data of the automotive energy storage lithium battery to be predicted, compare it with the data in all sub-databases through a similarity evaluation algorithm and calculate the data similarity, and select the sub-prediction model corresponding to the sub-database with the highest similarity as the current prediction model; Step 5: Use the current prediction model to predict the remaining service life curve of the automotive energy storage lithium battery to be predicted.
2. The method for predicting the remaining service life of a lithium battery for vehicle energy storage according to claim 1, characterized in that: The step 1 comprises: Step 1.1: Obtain battery capacity data and historically known remaining battery life from the historical operation data and real-time operation data of the vehicle energy storage lithium battery in the Internet of Vehicles system, and form a battery data pool through preprocessing, wherein the preprocessing includes data cleaning and data standardization; Step 1.2: Use the feature clustering method to perform cluster analysis on all capacity curves of the battery capacity data according to the morphological characteristics, and select the optimal number of clusters as the clustering result according to the clustering performance evaluation index; Step 1.3: Divide the battery data pool into multiple sub-databases based on the clustering results, and use the cluster center curve corresponding to each sub-database as the corresponding typical capacity degradation curve; each sub-database represents the battery operation data characteristics of a specific scenario, and the specific scenarios include urban driving scenarios, suburban driving scenarios, highway driving scenarios, tourist attraction driving scenarios, industrial area driving scenarios, and airport driving scenarios.
3. The method for predicting the remaining service life of a lithium battery for vehicle energy storage according to claim 2, characterized in that: The feature clustering method described in step 1.2 is the K-shape clustering algorithm, and the clustering performance indicator evaluation is S_dbw.
4. The method for predicting the remaining service life of a lithium battery for vehicle energy storage according to claim 2, characterized in that: The feature clustering method described in step 1.2 is the K-means clustering algorithm, and the clustering performance indicator evaluation is S_dbw.
5. The method for predicting the remaining service life of a lithium battery for vehicle energy storage according to claim 1, characterized in that: The prediction model described in step 2 is composed of a denoising autoencoder, an attention mechanism encoding layer and a fully connected layer, with battery operation data as input and the remaining service life prediction result of the automotive energy storage lithium battery as output.
6. The method for predicting the remaining service life of a lithium battery for vehicle energy storage according to claim 1, characterized in that: The step 3 comprises: Step 3.1: The sub-databases are mapped to each prediction model one by one. For a prediction model, all parameters in the prediction model are randomly initialized, and a training data set is constructed using the battery operation data of the sub-database corresponding to the prediction model. The historically known remaining battery life in the corresponding sub-database is used as the benchmark output; Step 3.2: Based on the back propagation method, the loss of the training data set is calculated according to the loss function integrating the typical capacity degradation curve; Step 3.3: When the loss of the training data set is not greater than the set threshold, the model training is terminated to obtain the trained sub-prediction model and the corresponding weight parameters.
7. The method for predicting the remaining service life of a lithium battery for vehicle energy storage according to claim 6, characterized in that: The step 3.2 comprises: Based on the back propagation method, the loss of the training data set is calculated according to the loss function of the typical capacity degradation curve, which satisfies the following relationship: Among them, L() is the improved loss function, x is the real capacity curve, is the predicted capacity curve, N is the length of the unknown battery capacity data to be predicted, x i is the actual capacity of the charge and discharge cycle of the i-th data, is the predicted capacity of the charge and discharge cycle of the i-th data, f MSELoss is the MSELoss loss function, T is the typical capacity degradation curve, T i is the typical capacity degradation value of the charge and discharge cycle of the i-th data, and a and c are hyperparameters.
8. A system for predicting the remaining service life of a lithium-ion battery for automotive energy storage, characterized in that: include: A preprocessing module is used to obtain the battery capacity data and the historically known remaining service life of the vehicle energy storage lithium battery, and perform preprocessing to obtain a battery data pool; A clustering module is used to cluster the battery capacity data using a feature clustering method, divide the battery data pool into multiple sub-databases according to the clustering results, and set a typical capacity degradation curve corresponding to each sub-database; The model building module is used to build a prediction model based on the deep neural network of the attention mechanism, and generate a corresponding number of prediction models according to the number of sub-databases; The model training module is used to match the sub-databases with the prediction models one by one, use the data of each sub-database to train the corresponding prediction model, and obtain the sub-prediction model corresponding to each sub-database; The model screening module is used to obtain the battery operation data of the automotive energy storage lithium battery to be predicted, compare it with the data in all sub-databases through a similarity evaluation algorithm and calculate the data similarity, and select the sub-prediction model corresponding to the sub-database with the highest similarity as the current prediction model; The prediction module is used to predict the remaining service life curve of the automotive energy storage lithium battery to be predicted using the current prediction model.
9. A computing device, characterized in that include: One or more processors, one or more memories and one or more programs, wherein the programs are stored in the memories and configured to be executed by the processors, and when the programs are loaded into the processors, the steps of the method for predicting the remaining service life of a vehicle energy storage lithium battery according to any one of claims 1 to 7 are implemented.
10. A storage medium, characterized in that: The storage medium stores a computer program, which includes program instructions. When the program instructions are executed by a processor, the processor executes the steps of the method for predicting the remaining service life of a vehicle energy storage lithium battery according to any one of claims 1 to 7.
Citation Information
Patent Citations
Health state and residual life prediction method of multi-type lithium ion battery pack management system
CN111707956A
Vehicle driving cost evaluation method based on data driving scene
CN113034210A
Method and system for identifying and predicting work of hydrogen fuel cell, and storage medium
CN113486698A
Lithium ion battery remaining service life prediction method based on digital-analog linkage
CN115047350A
Wind turbine flow field prediction method based on deep learning
CN116108749A
Cited By
Method and device for predicting service life of transformer
CN120596850A