CN117009749A - Interpreted battery life prediction method (BLP-transducer) based on transducer coding layer - Google Patents

Interpreted battery life prediction method (BLP-transducer) based on transducer coding layer Download PDF

Info

Publication number
CN117009749A
CN117009749A CN202311028314.8A CN202311028314A CN117009749A CN 117009749 A CN117009749 A CN 117009749A CN 202311028314 A CN202311028314 A CN 202311028314A CN 117009749 A CN117009749 A CN 117009749A
Authority
CN
China
Prior art keywords
data
feature
model
sequence
battery
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311028314.8A
Other languages
Chinese (zh)
Inventor
武畅
刘思言
张颖
黄宇航
王宏
杜小琦
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
University of Electronic Science and Technology of China
Original Assignee
University of Electronic Science and Technology of China
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by University of Electronic Science and Technology of China filed Critical University of Electronic Science and Technology of China
Priority to CN202311028314.8A priority Critical patent/CN117009749A/en
Publication of CN117009749A publication Critical patent/CN117009749A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/10Pre-processing; Data cleansing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/211Selection of the most significant subset of features
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/213Feature extraction, e.g. by transforming the feature space; Summarisation; Mappings, e.g. subspace methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/25Fusion techniques
    • G06F18/253Fusion techniques of extracted features
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • G06N3/0455Auto-encoder networks; Encoder-decoder networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/048Activation functions
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/0499Feedforward networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Artificial Intelligence (AREA)
  • General Physics & Mathematics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • General Engineering & Computer Science (AREA)
  • Evolutionary Computation (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Computational Linguistics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Evolutionary Biology (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Tests Of Electric Status Of Batteries (AREA)

Abstract

The invention provides an interpretable battery life prediction method (BLP-converter) based on a converter coding layer, which comprises the following steps: s1: preprocessing data based on the battery related data; s2: inputting the data into a battery life prediction algorithm (BLP-transformer) structure with interpretability, and performing feature extraction on the input data set to generate a feature selection mask; s3: the model is based on the feature selection mask, and the model is combined with the position coding information of the data to learn and code so as to obtain a coded sequence; s4: performing linear transformation and decoding on the coded sequence to obtain a battery life prediction result; s5: and combining the prediction results, aggregating the multi-step feature selection masks, quantifying the feature importance, and obtaining the interpretability of the model. The invention provides a battery life prediction method with interpretability, by which the prediction result of the battery life and the interpretability of the result can be obtained, and the accuracy of a model can be improved.

Description

Interpreted battery life prediction method (BLP-transducer) based on transducer coding layer
Technical Field
The invention belongs to the field of deep learning, and particularly relates to an interpretable battery life prediction method (BLP-transducer) based on a transducer coding layer.
Background
The battery is a core component of the electric automobile, and directly influences the endurance mileage, the performance and the service life of the automobile. To assist owners and manufacturers in better battery management and maintenance, prediction of battery life is of paramount importance. Currently, machine learning algorithms have achieved a pleasing outcome in predicting battery life. However, because of the lack of interpretability of currently used machine learning models, it is difficult to provide reliable interpretation of the predicted results, which may prevent their widespread use in the automotive industry. The transducer model is a neural network proposed in 2017 that learns context and meaning by tracking relationships in sequence data. The transducer model is one of the most powerful models at present, and effectively promotes the progress of machine learning. The present invention therefore proposes an interpretable battery life prediction method (BLP-converter) based on a converter coding layer. The invention can accurately predict the service life of the battery and provide interpretability for the result. The interpretability of the model is beneficial to analyzing the performance of the model, obtaining the best performance of the model and clarifying the basic principle of the data processing task.
Disclosure of Invention
Aiming at the problem that the current machine learning prediction battery life lacks of interpretability, the invention provides a method for predicting the interpretable battery life (BLP-transducer) based on a transducer coding layer.
The technical scheme of the invention is as follows: an interpretable battery life prediction method (BLP-converter) based on a converter coding layer, comprising the steps of:
s1: preprocessing data based on the battery related data;
s2: inputting the data into a battery life prediction algorithm (BLP-transformer) structure with interpretability, performing feature extraction on the input data set, and generating a feature selection mask
S3: the model is based on the feature selection mask, and the model is combined with the position coding information of the data to learn and code so as to obtain a coded sequence;
s4: performing linear transformation and decoding on the coded sequence to obtain a battery life prediction result;
s5: and combining the prediction results, aggregating the multi-step feature selection masks, quantifying the feature importance, and obtaining the interpretability of the model.
Further, step S1 comprises the sub-steps of:
s11, expanding the existing battery data set. The primary battery data contains information of RUL, voltage, current, battery temperature, internal resistance and charging time of the battery. The skewness, kurtosis, and temperature integral of the battery capacity decay curve of the input data, and the slope and intercept of its linear fit, are calculated. Using the calculated data as the information of the extended data set to assist the model calculation;
and S12, filtering the extended data set by adopting a median filter to obtain an input data set.
Further, step S2 comprises the sub-steps of:
s21, normalizing the input data set to obtain a normalized sequence f 1 (a 1 )~f N (a N );
Wherein f i (a i ) Representing the input sequence a for the ith decision step i And the obtained normalization result i represents the ith decision step, and the value of i is 1-N.
S22、f i (a i ) And prior scale term (priority scale) information P i-1 Multiplying to obtain result P i-1 ·f i (a i )(1≤i≤N);
Wherein, the prior scale item (priority scale) information initialization value is P 0 =1 B×t×f
Wherein B represents the batch size, t represents the decision step number, and f represents the feature number in the input data. A decision step refers to a cycle that the entire method has undergone in order to obtain the final decision result.
The prior scale term (priority scale) information generation formula in the ith decision step is as follows:
wherein, gamma is a relaxation parameter, and the use amount of the characteristics in the prior test scale item is measured. When γ=1, one feature can be used in only one decision step, and as γ increases, the feature can be used more flexibly in a plurality of decision steps.
S23, softmax function based on generated P i-1 ·f i (a 1 ) Feature importance Mask is extracted to data pair feature selection Mask i The calculation formula is as follows:
Mask i =Softmax(P i-1 ·f i (a i ))
the specific formula of the Softmax function is as follows:
the feature selection mask is used for providing interpretable information of the model, and the importance of the global feature can be obtained by aggregating the feature selection mask, so that the interpretability of the model is obtained.
S24, carrying out normalization processing on the feature selection mask generated in each decision step to generate a normalized feature data sequence.
Further, step S3 comprises the sub-steps of:
s31, calculating relative position information of the characteristic data sequence generated in the S2 by using sine and cosine functions of different frequencies. The corresponding calculation formula is:
where pos denotes the position of the encoding time step, s denotes the dimension, d model Representing the network output dimension.
S32, combining the characteristic data sequence with the relative position information to obtain a sequence to be learned;
s33, inputting a sequence to be learned into the multi-layer feedforward neural network, completing the learning of the data set, and generating a data sequence after model learning;
the formula of the multilayer feedforward neural network is:
FFN(x)=max(0,xW 1 +b 1 )W 2 +b 2
wherein the matrixWherein d is ff Is the inner layer dimension value. b 1 、b 2 For parameters that need to be updated by learning, x is the sequence to be learned generated in S32.
S34, carrying out normalization processing on the data sequence generated in the step S33, and combining the data sequence with the sequence to be learned generated in the step S32 to form a data coding sequence.
Further, step S4 comprises the sub-steps of:
s41, performing linear conversion on the coded sequence based on the output of the step S3 to obtain a sequence to be activated;
s42, carrying out LeakyReLU operation on the sequence to be activated, and completing prediction of the degradation data of the battery to obtain predicted data of the battery. The corresponding formula is as follows:
d out =LeakyReLU(0,f x W 0 +b 0 )
wherein, the LeakyReLU function is a linear rectification function with leakage. The formula is as follows:
where a is a constant less than 1, a=0.01 is taken in the experiment.
Wherein d out For decision output, the degradation data of the input sequence x is predicted; w (W) 0 And b 0 Is a linear conversion constant, f x Is the sequence to be activated of step S41.
Further, step S5 comprises the sub-steps of:
s51, aggregating the feature selection mask in each decision step and the prediction data output in the step S4 to an aggregation module in the model. The aggregation module first analyzes the feature selection mask to determine the global overall contribution of all features in one decision step. The calculation formula is as follows:
η i =LeakyReLU(d out [i])
wherein d out [i]Representing the output characteristics of the decision in step i, eta i Indicating the global overall contribution of all features in the ith decision step.
η i The larger the value, the greater the contribution of this step of decision to the model.
S52, based on the overall contribution of all the features in a decision step to the global, the aggregation module further analyzes a certain feature of the step to determine the accumulated contribution of the certain feature in the global model. The corresponding calculation formula is as follows:
wherein,Mask i [j]the contribution degree of the jth feature quantity to the decision in the ith decision step is represented by the sample. Mask agg Representing the cumulative contribution of each feature in the global model.
S53, accumulating contribution values Mask of each feature in the global model agg And (3) carrying out normalization processing to obtain an importance index feature_importance of the global feature value, namely obtaining the interpretability 0 of the model. The calculation formula is as follows:
feature importance =Norm(Mask agg )
wherein, the Norm function is a transverse normalized function, and the formula is:
wherein μ and σ 2 Representing the mean and variance of the inputs, e is a very small constant used to prevent the denominator from being 0.
Drawings
FIG. 1 is a flow chart of the method of the present invention.
Fig. 2 is a graph comparing the predicted result and the perfect predicted result of the algorithm model in the test task.
FIG. 3 is a graph showing the comparison of the predicted discharge capacity results of test ID-3 in the preliminary test data set, according to the algorithm model and other prediction algorithm models proposed by the present invention.
FIG. 4 is a graph comparing the absolute error curves of the predicted discharge capacity of test ID-3 in the preliminary test data set with the absolute error curves of the observed values, according to the algorithm model and other prediction algorithm models of the present invention.
FIG. 5 is a graph showing the comparison of the predictive effect of the algorithm model according to the present invention and other predictive algorithm models on the testID-21 data with a charging strategy of 2C (10%) -6C and RUL 148 cycles.
Fig. 6 is a graph showing the comparison of the prediction effect of the algorithm model proposed by the present invention and other prediction algorithm models on the testID-6 data with a charging strategy of 6C (20%) -4.5C and a rul of 466 cycles.
Fig. 7 is a graph showing the comparison of the prediction effect of the algorithm model proposed by the present invention and other prediction algorithm models on the testID-6 data with charging strategy of 5.4C (40%) -3.6C and rul of 1054 cycle.
Fig. 8 is a graph comparing the quantization results of the feature importance of the algorithm model proposed by the present invention and other predictive algorithm models with quantization interpretability.
Detailed Description
Embodiments of the present invention are further described below with reference to the accompanying drawings.
Before describing particular embodiments of the present invention, in order to make the aspects of the present invention more apparent and complete, abbreviations and key term definitions appearing in the present invention will be described first:
RUL: the number of charge and discharge cycles that the battery discharge capacity has undergone when it has degraded to a defined threshold.
Defining a threshold: is defined as the ratio of battery capacity to nominal capacity, and if it is below a defined threshold, the battery is determined to be unhealthy and an alert is issued to the user.
Multilayer feedforward neural network: each layer of neurons are fully interconnected with the next layer of neurons, no same-layer links exist between the neurons, and no cross-layer link structure exists.
Interpretability: for a machine learning or deep learning model, a human can understand the internal operation mechanism, the formation process and decision basis of the prediction result, the weight and influence degree of the model on different characteristics and the like, so that the prediction result and the behavior of the model can be further understood and explained.
As shown in fig. 1, the present invention provides an interpretable battery life prediction method (BLP-converter) based on a converter coding layer, comprising the steps of:
s1: preprocessing data based on the battery related data;
s2: inputting data into a battery life prediction algorithm (BLP-
Transformer) structure, the input data set is subjected to feature extraction to generate feature selection
Selecting a mask;
s3: model learning based on feature selection mask in combination with position coding information of data
And coding to obtain a coded sequence;
s4: performing linear transformation and decoding on the coded sequence to obtain a battery life prediction result;
s5: and combining the prediction results, aggregating the multi-step feature selection masks, quantifying the feature importance, and obtaining the interpretability of the model.
In embodiments of the present invention, the features and variations of the data are not fully described due to the features in the dataset. Therefore, in order to analyze the service life of the battery and improve the accuracy of analysis, the invention calculates other characteristics according to the discharge voltage curve so as to capture the electrochemical evolution of the single battery in the cyclic process and expand the data set. According to the invention, more characteristics are added by expanding the data set, the generalization capability of the model is improved, the risk of overfitting is reduced, and meanwhile, the accuracy and the interpretation of the model are improved. Based on the above ideas, the following data set preprocessing method is proposed.
In the present example, step S1 comprises the sub-steps of:
s11, expanding the existing battery data set. The primary battery data contains information of RUL, voltage, current, battery temperature, internal resistance and charging time of the battery. The skewness, kurtosis, and temperature integral of the battery capacity decay curve of the input data, and the slope and intercept of its linear fit, are calculated. The calculation data is used as the expansion data set information to assist the model calculation.
And S12, filtering the extended data set by adopting a median filter to obtain an input data set.
In a typical machine learning model, feature extraction is typically performed at the back of the model. However, this may disrupt the correspondence between features and data, thereby affecting the interpretation of the model. In the embodiment of the invention, the feature extraction is put in the first step of the model, and then the features are polymerized, so that the interpretability of the model is improved. The invention not only can help the user to better understand the relationship between the data and the model, but also can improve the prediction accuracy and stability of the model.
Specifically, in the field of battery prediction, the present invention employs a special aggregation module that combines feature masks with decoded prediction information. In this way, the invention can improve the interpretability of the model and better explain and understand the behavior and decision basis of the model while maintaining the prediction capability of the model. Through optimizing the model, the method effectively solves the problem that the model lacks of interpretability in the field of battery prediction, and improves the application value and the credibility of the model. Based on the above ideas, the present invention proposes the following battery prediction method and the interpretability enhancement method, so that the prediction result of the model is more accurate and easy to interpret.
In the present example, step S2 comprises the sub-steps of:
s21, normalizing the input data set to obtain a normalized sequence f 1 (a 1 )~f N (a N )。
Wherein f i (a i ) Representing the input sequence a for the ith decision step i And the obtained normalization result i represents the ith decision step, and the value of i is 1-N.
S22、f i (a i ) And prior scale term (priority scale) information P i-1 Multiplying to obtain result P i-1 ·f i (a i )(1≤i≤N)。
Wherein, the prior scale item (priority scale) information initialization value is P 0 =1 B×t×f
Where B represents the batch size, t represents the number of decision steps, and f represents the number of features in the input data. A decision step refers to a cycle that the entire method has undergone in order to obtain the final decision result.
The prior scale term (priority scale) information generation formula in the ith decision step is as follows:
where γ is the relaxation parameter and measures the amount of use of the feature in the prior scale term. When γ=1, one feature can be used in only one decision step, and as γ increases, the feature can be used more flexibly in a plurality of decision steps.
S23, softmax function based on generated P i-1 ·f i (a 1 ) Feature importance Mask is extracted to data pair feature selection Mask i The calculation formula is as follows:
Mask i =Softmax(P i-1 ·f i (a i ))
the specific formula of the Softmax function is as follows:
s24, carrying out normalization processing on the feature selection mask generated in each decision step to generate a normalized feature data sequence.
In the present example, step S3 includes the sub-steps of:
s31, calculating relative position information of the characteristic data sequence generated in the S2 by using sine and cosine functions of different frequencies. The corresponding calculation formula is:
where pos denotes the position of the encoding time step, s denotes the dimension, d model Representing the network output dimension.
S32, combining the characteristic data sequence with the relative position information to obtain a sequence to be learned.
S33, inputting the sequence to be learned into the multi-layer feedforward neural network, completing the learning of the data set, and generating the data sequence after model learning.
The formula corresponding to the feedforward neural network is:
FFN(x)=max(0,xW 1 +b 1 )W 2 +b 2
wherein the matrixWherein d is ff Is the inner layer dimension value. b 1 、b 2 To the parameter that needs to be updated by learning update, x is the sequence to be learned generated in S32.
S34, carrying out normalization processing on the data sequence generated in the step S33, and combining the data sequence with the sequence to be learned generated in the step S32 to form a data coding sequence.
In the present example, step S4 comprises the sub-steps of:
s41, based on the coded sequence output in the step S3, performing linear conversion on the coded sequence to obtain a sequence to be activated.
S42, carrying out LeakyReLU operation on the sequence to be activated, and completing prediction of the degradation data of the battery to obtain predicted data of the battery. The corresponding formula is as follows:
d out =LeakyReLU(0,f x W 0 +b 0 )
wherein the LeakyReLU function is a linear rectifying function with leakage. The formula is as follows:
where a is a constant less than 1, a=0.01 was taken in the experiment.
Wherein d is out For decision output, the degradation data of the input sequence x is predicted; w (W) 0 And b 0 Is a linear conversion constant, f x Is the sequence to be activated of step S41.
In the present example, step S5 includes the sub-steps of:
s51, aggregating the feature selection mask in each decision step and the prediction data output in the step S4 to an aggregation module in the model. The aggregation module first analyzes the feature selection mask to determine the global overall contribution of all features in one decision step. The calculation formula is as follows:
η i =LeakyReLU(d out [i])
wherein d is out [i]Representing the output characteristics of the decision in step i, eta i Indicating the global overall contribution of all features in the ith decision step.
η i The larger the value, the greater the contribution of this step of decision to the model.
S52, based on the overall contribution of all the features in a decision step to the global, the aggregation module further analyzes a certain feature of the step to determine the accumulated contribution of the certain feature in the global model. The corresponding calculation formula is as follows:
wherein Mask i [j]The contribution degree of the jth feature quantity to the decision in the ith decision step is represented by the sample. Mask agg Representing the cumulative contribution of each feature in the global model.
S53, accumulating contribution values Mask of each feature in the global model agg And (5) carrying out normalization processing to obtain an importance index feature_importance of the global feature value, namely obtaining the interpretability of the model. The calculation formula is as follows:
feature importance =Norm(Mask agg )
wherein, the Norm function is a transverse normalized function, and the formula is:
wherein mu and sigma 2 Representing the mean and variance of the inputs, e is a very small constant used to prevent the denominator from being 0.
In the embodiment of the invention, the prediction and the interpretation analysis of the battery life are realized for the interpreted battery life prediction method (BLP-transducer) based on the transducer coding layer. The invention well realizes the prediction of the battery life by expanding the data set and improving the transducer model. In the implementation example, the method provided by the invention is verified to improve the accuracy of battery life prediction and provide good model interpretation by designing some experimental scenes and comparing with other deep learning prediction modes.
To verify the interpretability of the proposed model of the present invention, four quantifiable self-interpretability models (Random Forest, XGBoost, qrf+ais, and N-Beats) and three model-dependent interpretation-based deep learning models (SVM, RNN, and LSTM) were chosen in the practical examples to compare with the proposed algorithm model BLP-Transformer. And on the basis of the seven models, simulation of degradation data prediction is performed. To ensure fairness of comparison, all models use similar hierarchical structures with the same number of layers and hierarchical connections. I.e. SVM, RNN, LSTM and the algorithm model BLP-transducer proposed by the present invention both use a two-layer network structure with 128 neurons. Wherein, the retention probability of the hidden layer is 0.2, and the super parameters are optimized by an Adam optimizer.
The Random Forest, XGBoost and ARF+AIS all use 128 weak classifier numbers. N-Beats employ 2 stacked blocks, each using three smaller blocks. The parallel computation of the above scheme is all completed on the image processor unit. The experimental parameters are shown in table 1.
Table 1:
super parameter Numerical value
Learning rate 0.001
Optimizer Adam optimizer
Number of layers/number of blocks/number of decision steps 2 layers
Hidden layer size 128 hidden layer sizes
Number of trees in random forest 128 trees
Discarding rate Discard Rate of 0.2
Batch size 64 batch sizes
The present experiment uses the public dataset of Toyota institute as the experimental dataset. The data set used in this experiment contained a total of 124 commercial LFP/graphite cells of model APR18650M 1A. The nominal capacity of these cells was 1.1Ah and the nominal voltage was 3.3V. All cell data were obtained using a 48-channel ArbinLBT cell test cycle potentiostat test at a constant temperature of 30 ℃. The data set includes information such as RUL, voltage, current, battery temperature, internal resistance, and charge time. The data set is measured in a real physical environment, and can reflect the real data condition of the lithium ion battery.
The dataset was divided into one training set and two test sets according to different charging conditions and experimental batches. The test set is divided into a primary test data set and a secondary test data set.
The training set is used for training the model and selecting parameters. The training set contains 20 units from the "2017-05-12" lot and 21 units from the "2017-06-30" lot in the dataset.
The preliminary test dataset is the first batch of test data to verify the performance of the model and to verify the quality of the dataset. The preliminary test dataset contained 21 units from the "2017-05-12" lot and 22 units from the "2017-06-30" lot.
The secondary data test set is the second batch of test data that further verifies the model performance and verifies the quality of the data set. The secondary test dataset contained 40 units from the "2018-04-12" lot.
The experiment pre-processes the data set, calculates and collates the skewness, kurtosis and temperature integral of the battery capacity decay curve after each cycle, and the slope and intercept of its linear fit. The calculation data is used as the expansion data set information to assist the model calculation. Finally, an extended data set which aims at discharging capacity and RUL and comprises 10 characteristics such as temperature and the like as training characteristics is formed.
RUL is defined in the experiment as the number of charge and discharge cycles experienced when the battery discharge capacity has degraded to a defined threshold.
The defined threshold is specified to be 80% of the nominal capacity of the battery.
Specific feature names and meanings are shown in table 2:
table 2:
the experiment adopts three indexes of a determination coefficient R2, a root mean square error RMSE and an average absolute percentage error MAPE to evaluate the performance of the algorithm provided by the invention.
The decision coefficient R2 reflects the fitting degree of the model provided by the invention to the data prediction result compared with a true value. The closer the decision coefficient R2 is to 1, the more similar the prediction result is to the true value, and the better the fitting degree of the model is. The calculation formula for the decision coefficient R2 is as follows:
the root mean square error RMSE measures the accuracy of the prediction result. The smaller the root mean square error RMSE, the higher the accuracy of the algorithm model proposed by the present invention. In the prediction for the vehicle RUL, RMSE is in units of cycle. The root mean square error RMSE is calculated as follows:
the mean absolute percentage error MAPE is used to measure the accuracy of the prediction result of the algorithm proposed in the present invention. The smaller the average absolute percentage error MAPE, the smaller the predicted result error rate, the calculation formula of the average absolute percentage error MAPE is as follows:
in the calculation formulas for determining three indexes of the coefficient R2, the root mean square error RMSE and the average absolute percentage error MAPE, N is the total sample amount of the evaluation data,the predictive value, y, of each sample is calculated for the algorithm model provided by the invention i For the observations of the data corresponding to the predicted values, +.>Represents the average of the observed data in one test sample.
The comparison data of the algorithm model provided by the invention and the prediction conditions of the other 7 common prediction algorithm models on the RUL of the vehicle are shown in the table 3.
Table 3:
as can be seen from Table 3, the BLP-transducer predictions were 11.68 cycles and 18.57 cycles for RMSE, 1.079% and 1.569% for MAPE, respectively, and the BLP-transducer was significantly better than the other models. It is shown that BLP-transducer has better prediction results for RUL.
In the test task of the primary test data set and the secondary test data set, the deviation degree of the algorithm model relative to the perfect prediction result is shown in fig. 2. Perfect predictions are defined as: the predicted battery RUL is identical to the observed RUL. As can be seen from FIG. 2, the result of the algorithm model proposed by the present invention for predicting RUL of the vehicle battery can reach a fitting degree of 0.998, a prediction accuracy of 15.51cycles and a prediction error rate of 1.324%. The BLP-transducer algorithm provided by the invention has accurate prediction capability.
The prediction results of the discharge capacity of the algorithm proposed by the present invention and other 7-class prediction algorithms on test ID-3 in the preliminary test data set are shown in fig. 3, and the absolute error curves of the prediction results with respect to the observed values are shown in fig. 4. As can be seen from fig. 3 and 4, the algorithm model provided by the invention has a good prediction effect on the discharge capacity of the battery. Even in the middle and later period (200 cycle-1000 cycle) of the cycle life, the algorithm provided by the invention can still keep a good prediction effect under the condition that the discharge capacity of the vehicle battery suddenly drops. The predicted value deviates from the observed value by about 10mAh, which is less than the other 7 prediction algorithms.
Table 4 shows the comparison data of the proposed algorithm with the other 7 common prediction algorithms for the predicted conditions of the battery discharge capacity.
Table 4:
as can be seen from table 4, BLP-converter has a better prediction effect on capacity prediction than other models. It can achieve a fitness of 0.937 and 0.985, RMSE of 14.21cycles and 5.448cycles, 0.374% he 0.332% MAPE.
Fig. 5, 6 and 7 show the comparison of the prediction effect of the proposed algorithm with 7 other common prediction algorithms for the discharge capacity of the vehicle battery under different charging strategies. FIG. 5 shows the predictive effect on testID-21 data for a charge strategy of 2C (10%) -6C, with RUL 148 cycles. FIG. 6 shows the predictive effect on testID-6 data for a charge strategy of 6C (20%) -4.5C with RUL 466 cycles. FIG. 7 shows the predictive effect on testID-6 data for a charging strategy of 5.4C (40%) -3.6C with RUL 1054 cycle.
Where charging strategy XC (Y%) -ZC represents charging to Y of battery capacity at voltage X followed by constant current charging to full at voltage Z.
Fig. 5, 6 and 7 show that the BLP-converter model according to the present invention is more suitable for batteries under different charging strategies than other 7 common prediction models, and provides a prediction result with higher accuracy. This helps the user to exclude the effects of outliers and make more accurate decisions.
Fig. 8 shows the feature importance of the proposed algorithm model and the other 4 quantifiable-interpretable predictive algorithm models.
Table 5 shows the ranking of the feature importance from high to low for 8 predictive algorithms, including the algorithm model proposed by the present invention. Using Kendall's tau coefficient τ a The correlation between different models and the model proposed by the invention in the aspect of feature importance is shown. τ a The calculation formula is as follows:
where C represents the logarithm of the element of identity in the two sequences, D represents the logarithm of the element of non-identity, and N represents the total number of sequences.
Table 5:
from Table 5, it can be seen that the three features Intercept, tintegral and Slope all obtained an aggregate value of 0.15 or more in the algorithm model BLP-transducer proposed by the present invention. It is explained that these three features contribute most to the prediction of the model during the training process. Tmin and Tavg then contribute minimal to the model's prediction. The algorithm model provided by the invention successfully quantifies the data set characteristics and shows the interpretability of the model.
The working principle and the working process of the invention are as follows: in the invention, the training data set is preprocessed first, and the data set is expanded. The preprocessed training set is input into a model, and a feature selection mask is extracted first. Based on the feature selection mask, after normalization, the position coding information of the training set data is combined to complete the coding of the data and the learning of the model, and a data coding sequence is output. And performing linear transformation and decoding on the data coding sequence to obtain a life prediction result of the battery data. And finally, combining a prediction result by the aggregation module, aggregating the multi-step feature selection masks, quantifying the feature importance, and obtaining the interpretability of the model.
The beneficial effects of the invention are as follows: the interpretable battery life prediction method (BLP-converter) based on the converter coding layer provided by the invention realizes effective prediction of battery life data, and can timely send out warning information before the battery RUL drops to a threshold value. Meanwhile, the invention realizes the interpretability characteristic of the model, can help to confirm the rationality of the model expression, and quantitatively gives the contribution degree of the characteristic to the model.
Those of ordinary skill in the art will recognize that the embodiments described herein are for the purpose of aiding the reader in understanding the principles of the present invention and should be understood that the scope of the invention is not limited to such specific statements and embodiments. Those of ordinary skill in the art can make various other specific modifications and combinations from the teachings of the present disclosure without departing from the spirit thereof, and such modifications and combinations remain within the scope of the present disclosure.

Claims (6)

1. An interpretable battery life prediction method (BLP-converter) based on a converter coding layer, comprising the steps of:
s1: preprocessing data based on the battery related data;
s2: inputting the data into a battery life prediction algorithm (BLP-transformer) structure with interpretability, and performing feature extraction on the input data set to generate a feature selection mask;
s3: the model is based on the feature selection mask, and the model is combined with the position coding information of the data to learn and code so as to obtain a coded sequence;
s4: performing linear transformation and decoding on the coded sequence to obtain a battery life prediction result;
s5: and combining the prediction results, aggregating the multi-step feature selection masks, quantifying the feature importance, and obtaining the interpretability of the model.
2. The method of interpreted battery life prediction (BLP-converter) based on a converter coding layer according to claim 1, wherein said step S1 comprises the sub-steps of:
s11, expanding the existing battery data set. The primary battery data contains information of RUL, voltage, current, battery temperature, internal resistance and charging time of the battery. The skewness, kurtosis, and temperature integral of the battery capacity decay curve of the input data, and the slope and intercept of its linear fit, are calculated. Using the calculated data as the information of the extended data set to assist the model calculation;
and S12, filtering the extended data set by adopting a median filter to obtain an input data set.
3. The method of interpreted battery life prediction (BLP-converter) based on a converter coding layer according to claim 1, wherein said step S2 comprises the sub-steps of:
s21, normalizing the input data set to obtain a normalized sequence f 1 (a 1 )~f N (a N );
Wherein f i (a i ) Representing the input sequence a for the ith decision step i And the obtained normalization result i represents the ith decision step, and the value of i is 1-N.
S22、f i (a i ) And a priori scale item information P i-1 Multiplying to obtain result P i-1 ·f i (a 1 )(1≤i≤N);
Wherein the prior scale item information initialization value is P 0 =1 B×t×f
Wherein B represents the batch size, t represents the decision step number, and f represents the feature number in the input data. The prior scale term information generation formula in the ith decision step is as follows:
wherein, gamma is a relaxation parameter, and the use amount of the characteristics in the prior test scale item is measured. When γ=1, one feature can be used in only one decision step, and as γ increases, the feature can be used more flexibly in a plurality of decision steps.
S23, softmax function based on generated P i-1 ·f i (a 1 ) Feature importance Mask is extracted to data pair feature selection Mask i The calculation formula is as follows:
Mask i =Softmax(P i-1 ·f ii ))
s24, carrying out normalization processing on the feature selection mask generated in each decision step to generate a normalized feature data sequence.
4. The method of interpreted battery life prediction (BLP-converter) based on a converter coding layer according to claim 1, wherein said step S3 comprises the sub-steps of:
s31, calculating relative position information of the characteristic data sequence generated in the S2 by utilizing sine and cosine functions of different frequencies;
s32, combining the characteristic data sequence with the relative position information to obtain a sequence to be learned;
s33, inputting a sequence to be learned into the multi-layer feedforward neural network, completing the learning of the data set, and generating a data sequence after model learning;
s34, carrying out normalization processing on the data sequence generated in the step S33, and combining the data sequence with the sequence to be learned generated in the step S32 to form a data coding sequence.
5. The method of interpreted battery life prediction (BLP-converter) based on a converter coding layer according to claim 1, wherein said step S4 comprises the sub-steps of:
s41, performing linear conversion on the coded sequence based on the output of the step S3 to obtain a sequence to be activated;
s42, carrying out LeakyReLU operation on the sequence to be activated, and completing prediction of the degradation data of the battery to obtain predicted data of the battery. The corresponding formula is as follows:
d out =LeakyReLU(0,f x W 0 +b 0 )
wherein d is out For decision output, the degradation data of the input sequence x is predicted; w (W) 0 And b 0 Is a linear conversion constant, f x Is the sequence to be activated of step S41.
6. The method of interpreted battery life prediction (BLP-converter) based on a converter coding layer according to claim 1, wherein said step S5 comprises the sub-steps of:
s51, aggregating the feature selection mask in each decision step and the prediction data output in the step S4 to an aggregation module in the model. The aggregation module first analyzes the feature selection mask to determine the global overall contribution of all features in one decision step. The calculation formula is as follows:
η i =LeakyReLU(d out [i])
wherein d is out [i]Representing the output characteristics of the decision in step i, eta i Representing the global ensemble of all features in the ith decision stepContribution;
η i the larger the value, the larger the contribution of the step of decision to the model is;
s52, based on the overall contribution of all the features in a decision step to the global, the aggregation module further analyzes a certain feature of the step to determine the accumulated contribution of the certain feature in the global model. The corresponding calculation formula is as follows:
wherein Mask i [j]The contribution degree of the jth feature quantity to the decision in the ith decision step is represented by the sample. Mask agg Representing the cumulative contribution of each feature in the global model;
s53, accumulating contribution values Mask of each feature in the global model agg And (5) carrying out normalization processing to obtain an importance index feature_importance of the global feature value, namely obtaining the interpretability of the model. The calculation formula is as follows:
feature importance =Norm(Mask agg )
CN202311028314.8A 2023-08-15 2023-08-15 Interpreted battery life prediction method (BLP-transducer) based on transducer coding layer Pending CN117009749A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311028314.8A CN117009749A (en) 2023-08-15 2023-08-15 Interpreted battery life prediction method (BLP-transducer) based on transducer coding layer

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311028314.8A CN117009749A (en) 2023-08-15 2023-08-15 Interpreted battery life prediction method (BLP-transducer) based on transducer coding layer

Publications (1)

Publication Number Publication Date
CN117009749A true CN117009749A (en) 2023-11-07

Family

ID=88565341

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311028314.8A Pending CN117009749A (en) 2023-08-15 2023-08-15 Interpreted battery life prediction method (BLP-transducer) based on transducer coding layer

Country Status (1)

Country Link
CN (1) CN117009749A (en)

Similar Documents

Publication Publication Date Title
CN109754113B (en) Load prediction method based on dynamic time warping and long-and-short time memory
CN111539515B (en) Complex equipment maintenance decision method based on fault prediction
CN112990556A (en) User power consumption prediction method based on Prophet-LSTM model
CN108445752B (en) Random weight neural network integrated modeling method for self-adaptively selecting depth features
CN112258251B (en) Grey correlation-based integrated learning prediction method and system for electric vehicle battery replacement demand
CN109492748B (en) Method for establishing medium-and-long-term load prediction model of power system based on convolutional neural network
CN112834927A (en) Lithium battery residual life prediction method, system, device and medium
CN112288137A (en) LSTM short-term load prediction method and device considering electricity price and Attention mechanism
CN112232561A (en) Power load probability prediction method based on constrained parallel LSTM quantile regression
CN111144721A (en) Power grid project demand evaluation model construction method and device and computing equipment
CN115271253A (en) Water-wind power generation power prediction model construction method and device and storage medium
CN117148197A (en) Lithium ion battery life prediction method based on integrated transducer model
CN114578234A (en) Lithium ion battery degradation and capacity prediction model considering causality characteristics
CN117034762A (en) Composite model lithium battery life prediction method based on multi-algorithm weighted sum
CN113033898A (en) Electrical load prediction method and system based on K-means clustering and BI-LSTM neural network
CN117312835A (en) Fuel cell performance prediction method based on mixed probability data driving model
Zhang et al. Remaining useful life prediction of lithium-ion batteries based on TCN-DCN fusion model combined with IRRS filtering
CN113762591B (en) Short-term electric quantity prediction method and system based on GRU and multi-core SVM countermeasure learning
CN117009749A (en) Interpreted battery life prediction method (BLP-transducer) based on transducer coding layer
CN116610416A (en) Load prediction type elastic expansion system and method based on Kubernetes
CN116187506A (en) Short-term wind power combination probability prediction method and system considering meteorological classification
CN115511230A (en) Electric energy substitution potential analysis and prediction method
CN115545342A (en) Risk prediction method and system for enterprise electric charge recovery
CN113989066A (en) Galvanic pile energy consumption analysis based on big data
CN113112085A (en) New energy station power generation load prediction method based on BP neural network

Legal Events

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