A lithium-ion battery capacity prediction method based on TCN-UnetTSF model

The TCN-UnetTSF model addresses the limitations of traditional and data-driven methods by integrating TCN for time-dependent feature extraction with U-Net for multi-scale fusion, resulting in more accurate and robust lithium-ion battery capacity predictions.

CN118731716BActive Publication Date: 2024-12-31NANJING TECH UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411217268.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-09-02
Publication Date
2024-12-31
Estimated Expiration
2044-09-02

AI Technical Summary

Technical Problem

Traditional lithium-ion battery capacity prediction methods rely heavily on physical models and empirical formulas, requiring extensive experimental data and professional knowledge, and struggle to adapt to complex and changing environments, while data-driven methods like TCN struggle with capturing global features effectively.

Method used

A lithium-ion battery capacity prediction method utilizing a TCN-UnetTSF model that combines the temporal convolutional network (TCN) for capturing time-dependent features with the U-Net neural network structure to enhance multi-scale feature extraction and fusion, leveraging dilated convolution and causal convolution for long-term dependencies and incorporating a feature pyramid network (FPN) for improved feature retention and reuse.

Benefits of technology

The method significantly enhances the accuracy and robustness of battery capacity prediction by effectively capturing global features, improving the estimation of battery health state and providing a reliable basis for battery management systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118731716B_ABST
    Figure CN118731716B_ABST
Patent Text Reader

Abstract

The present invention relates to a lithium-ion battery capacity prediction method based on a TCN-UnetTSF model, which solves the technical problems of traditional methods in multi-scale feature extraction and fusion. The specific steps include: preprocessing lithium-ion battery capacity data; constructing a TCN module, using the preprocessed lithium-ion battery capacity data as initial input; constructing a UnetTSF module, using the output of the TCN module as initial input; training and testing based on the TCN module and the UnetTSF module to obtain lithium-ion battery capacity prediction results. The present invention can extract multi-scale features under time dependence through the TCN module, and use the UnetTSF module to make up for the global deficiencies of the TCN module, realize feature fusion and reshaping, thereby improving the accuracy and robustness of the overall prediction model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of lithium-ion battery capacity prediction, and in particular to a lithium-ion battery capacity prediction method based on a TCN-UnetTSF model. Background Art

[0002] With the development of new energy technologies, lithium-ion batteries have been widely used in electric vehicles, portable electronic devices and energy storage systems. The health status of lithium-ion batteries directly affects the operating efficiency and safety of the equipment, so it is of great significance to accurately evaluate the health status of the battery. Capacity is an important indicator of battery health. Traditional battery capacity prediction methods mainly rely on physical models and empirical formulas, but these methods usually require a large amount of experimental data and professional knowledge, and cannot adapt to the complex and changeable working environment of the battery.

[0003] In recent years, data-driven capacity prediction methods have gradually attracted attention. These methods use machine learning and deep learning techniques to automatically extract features from a large amount of battery operation data and establish a prediction model for battery health status. Among the many data-driven methods, the time series convolutional network (TCN) is widely used due to its superiority in processing time series data. TCN can effectively capture long-term dependencies through dilated convolution and causal convolution, and has good parallel computing capabilities. However, the TCN model still has certain limitations in capturing global features because its convolution operation is local in nature.

[0004] In order to make up for the shortcomings of TCN in capturing global features, the present invention introduces the UnetTSF (U-Net TimeSeries Forecasting) model, which aims to better capture global signs through the U-Net neural network structure, thereby realizing the fusion of multi-scale features. Summary of the invention

[0005] In view of the deficiencies in the prior art, the present invention provides a lithium-ion battery capacity prediction method based on the TCN-UnetTSF model, which solves the technical problems of traditional methods in multi-scale feature extraction and fusion, and can improve the accuracy and robustness of battery capacity prediction; in view of the problems existing in the above technical background, the UnetTSF model introduced in the present invention ensures that while performing feature extraction, the features of the early layers are retained and reused, so as to better capture the global features, and combines the advantage of the temporal convolutional network TCN that can effectively capture time-dependent features, thereby realizing the extraction and fusion of multi-scale features by the overall model, thereby improving the accuracy of the prediction of the battery health state, enhancing the robustness and generalization ability of the model, and providing a more reliable basis for health state assessment for the battery management system.

[0006] In order to solve the above technical problems, the present invention provides the following technical solutions: a lithium-ion battery capacity prediction method based on the TCN-UnetTSF model, specifically comprising the following steps:

[0007] S1. Preprocessing lithium-ion battery capacity data;

[0008] S2, constructing a TCN module, taking the pre-processed lithium-ion battery capacity data as initial input;

[0009] S3, build the UnetTSF module, taking the output of the TCN module as the initial input;

[0010] S4. Training and testing are performed based on the TCN module and the UnetTSF module to obtain the lithium-ion battery capacity prediction results.

[0011] Furthermore, step S1 specifically includes the following steps:

[0012] S11. Obtain the raw capacity data of lithium-ion batteries from the lithium-ion battery dataset provided by NASA X ;

[0013] S12, the original capacity data X Divide by the rated capacity to normalize to the range of 0 to 1, the formula is expressed as:

[0014] ;

[0015] in, X is the raw capacity data, is the rated capacity of the lithium-ion battery, is the normalized data;

[0016] S13, reshape the normalized data into the shape required by the TCN-UnetTSF model to obtain the initial input to the TCN module , the formula is:

[0017] ;

[0018] in, is the reshaped data, i.e. the initial input of the TCN module, represents the real tensor shape, express is a shape of A real tensor of , C represents the number of features, N Indicates the number of sequences, T represents the time step, Represents a reshape operation.

[0019] Furthermore, step S2 specifically includes the following steps:

[0020] S21,TCN module includes two expansion initial layers DIL, one of which has an output connected to a tanh activation function and the other connected to a sigmoid activation function;

[0021] S22, two expansion initial layers DIL initial input to TCN Perform the same process and get the output respectively and ;

[0022] S23, output , The final output of the TCN module is obtained by using the tanh activation function and the sigmoid activation function, and then performing dot product multiplication. , the formula is:

[0023] ;

[0024] in, express is a shape of A real tensor of , C represents the number of features, N Indicates the number of sequences, T represents the time step, represents the tanh activation function, represents the Sigmoid activation function, Represents dot product multiplication.

[0025] Furthermore, in step S22, the initial input of the expansion initial layer DIL to the TCN The specific processing is as follows:

[0026] S221, dilated convolution; initial input of TCN module The input is sent to an expansion initial layer DIL, which first passes through a set of convolution kernels with gradually increasing size. The one-dimensional causal expansion convolution layer extracts multi-scale features under time dependence. No padding operation is performed during the convolution process, and four multi-scale features are output. , the formula is:

[0027] ;

[0028] in, Through different convolution kernels The four multi-scale features after convolution, Indicates the size of The convolution operation is performed with a one-dimensional convolution kernel; the number of channels of each multi-scale feature mapping to the convolution kernel is , that is, the number of features C According to the number of convolutional layers, , the number of sequences N remains unchanged, and the time step becomes ;

[0029] S222, time dimension feature extraction; the time dimension is the minimum, that is, the time step T The shortest feature is used as the standard, and the four multi-scale features are intercepted to obtain four multi-scale features with the same time dimension. The largest, therefore The time dimension is the least, As the standard, the four multi-scale features after truncation are obtained , the formula is:

[0030] ;

[0031] in, Refers to indexing forward from the end of the array and uniformly intercepting the last The value of the time step;

[0032] S223, multi-scale feature concatenation; the four multi-scale feature values ​​after truncation are concatenated. In the channel dimension, that is, the number of features C Splice and restore to the original input of TCN The same number of features, get the concatenated feature tensor , the formula is:

[0033] ;

[0034] in, express Is a shape of A real tensor of , C represents the number of features, N Indicates the number of sequences, represents the time step, Indicates concatenating multiple features in the channel dimension;

[0035] S224, multi-layer perceptron MLP mapping; multi-layer perceptron MLP processes the concatenated feature tensor through two fully connected layers , two fully connected layers include linear layer Linear and ReLU activation function; the concatenated feature tensor First pass through a linear layer Linear, then through the ReLU activation function, and then through a linear layer Linear to restore the initial input of the TCN module Same time step T, Finally, we get the output of the first expansion initial layer DIL , the formula is:

[0036] ;

[0037] in, express is a shape of A real tensor of , Represents the mapping function of the multilayer perceptron;

[0038] S225, after the same process, the output of the second expansion initial layer DIL is obtained .

[0039] Furthermore, step S3 specifically includes the following steps:

[0040] S31, the final output of the TCN module As input, multi-scale features are extracted and fused based on the U-Net structure to obtain the fusion features of multi-scale features ;

[0041] S32, fusion features of multi-scale features Through a linear layer and reshape operation, the fusion features of the reshaped multi-scale features are obtained. , the formula is:

[0042] ;

[0043] in, represents the transformation matrix of the linear layer, and is a C×C The transformation matrix, Represents the fusion features of the reshaped multi-scale features is a shape of A real tensor of , C represents the number of features, N Indicates the number of sequences, T represents the time step, To reshape the operation;

[0044] S33. Finally, a linear layer is used to fuse the reshaped multi-scale features. Convert to point prediction results , which is the final output of the UnetTSF module, is expressed as:

[0045] ;

[0046] Among them, Linear represents linear transformation, Represents point prediction results is a scalar.

[0047] Furthermore, in step S31, a feature pyramid network FPN is introduced to realize the extraction and fusion of multi-scale features. The specific process includes the following steps:

[0048] S311, pooling layer; construct a four-layer pyramid structure, each layer uses a pooling layer to achieve feature extraction, and obtain , respectively, are the multi-scale temporal features extracted by the pooling operation of the 1st, 2nd, 3rd, and 4th layers, and the formula is expressed as:

[0049] ;

[0050] in, represents the average pooling operation, C represents the number of features, N Indicates the number of sequences, Represents the time step of each multi-scale temporal feature; the time step of the first layer Equal to the initial input of the TCN module Time step T The time steps of the remaining layers are based on the time step of the previous layer, calculated by the time step formula It turns out that the formula is:

[0051] ;

[0052] in, Indicates the padding size of the input data edge before the pooling operation. Indicates the size of the sliding window during the pooling operation, Indicates the number of steps the sliding window moves during the pooling operation;

[0053] S312, linear layer mapping; multi-scale temporal features Mapped into intermediate features through linear layers , the formula is:

[0054] ;

[0055] in, Represents a linear transformation, and extracts features through a fully connected layer;

[0056] S313, multi-scale feature fusion; based on a four-layer pyramid structure, intermediate features are fused from bottom to top The splicing in the time dimension is to first Layer and The intermediate features of the layer are concatenated, and the concatenated features are then passed through a linear layer to generate the first New intermediate features of the layer , repeat the operation until the new intermediate features of the first layer are output , the formula is:

[0057] ;

[0058] in, Represents the new intermediate features after the 1st, 2nd, and 3rd layers are concatenated and linearly transformed. represents a linear transformation, Represents a splicing operation;

[0059] Finally, the new intermediate features of layer 1 It is the fusion feature of multi-scale features .

[0060] Furthermore, step S4 specifically includes the following steps:

[0061] S41. The lithium-ion battery data is divided into a training set and a test set; the training set is divided into batch sizes After segmentation and preprocessing, the model is input into the TCN module and the UnetTSF module for training to obtain the trained TCN-UnetTSF model. ;

[0062] S42, then the test set is also divided into batch sizes Segmentation, after preprocessing to get the test input , input it into the trained TCN-UnetTSF model and get the test results , the formula is as follows:

[0063] ;

[0064] in, Refers to the test results is included A batch of point data scalars;

[0065] That is, the predicted result of the lithium-ion battery capacity is obtained.

[0066] By means of the above technical solution, the present invention proposes a lithium-ion battery capacity prediction method based on the TCN-UnetTSF model, which has at least the following beneficial effects:

[0067] Compared with traditional methods, the method proposed in this invention solves the technical problems in multi-scale feature extraction and fusion, and improves the accuracy and robustness of battery capacity prediction. The TCN module is superior in processing time series data. It can effectively capture multi-scale features under long-term dependencies through dilated convolution and causal convolution, and has good parallel computing capabilities; the UnetTSF module uses the U-net structure and feature pyramid network FPN to retain and reuse the features of the early layers while performing feature extraction, realizing the fusion and reshaping of multi-scale features, making up for the shortcomings of the TCN module in global feature capture.

[0068] The lithium-ion battery capacity prediction method proposed in the present invention organically combines the two models, which not only improves the estimation accuracy of the battery health state, but also enhances the robustness and generalization ability of the model, thereby providing a more reliable basis for health state assessment for the battery management system. BRIEF DESCRIPTION OF THE DRAWINGS

[0069] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0070] Figure 1 A diagram describing the lithium-ion battery dataset provided to NASA;

[0071] Figure 2 This is the overall flow chart of the TCN-UnetTSF model;

[0072] Figure 3 This is the TCN module structure diagram;

[0073] Figure 4 This is the UnetTSF module structure diagram;

[0074] Figure 5 Single-step and multi-step prediction diagrams for the capacity prediction of four batteries in the NASA dataset;

[0075] Figure 6 The figure is a comparison of the prediction effects of different models based on three evaluation indicators. DETAILED DESCRIPTION

[0076] In order to make the above-mentioned purposes, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific implementation methods, so that the implementation process of how the present application uses technical means to solve technical problems and achieve technical effects can be fully understood and implemented accordingly.

[0077] Those skilled in the art can understand that all or part of the steps in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a program, so the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.

[0078] Please refer to Figure 1-Figure 6 , showing a specific implementation of this embodiment, this embodiment effectively extracts multi-scale features under time dependence through dilated convolution and causal convolution through the TCN module, and retains and reuses early features through the U-net structure and feature pyramid network FPN in the UnetTSF module, and fuses and reshapes the extracted multi-scale features, making up for the shortcomings of the TCN module in global feature extraction; thereby, the overall model can obtain more accurate lithium-ion battery capacity prediction results, which is more accurate and robust than traditional prediction methods.

[0079] Please refer to Figure 2 This embodiment proposes a lithium-ion battery prediction method based on the TCN-UnetTSF model, which specifically includes the following steps:

[0080] S1. Preprocessing lithium-ion battery capacity data;

[0081] As a preferred implementation of step S1, the following steps are specifically included:

[0082] S11. Obtain the raw capacity data of lithium-ion batteries from the lithium-ion battery dataset provided by NASA X ;

[0083] S12, the original capacity data X Divide by the rated capacity to normalize to the range of 0 to 1, the formula is expressed as:

[0084] ;

[0085] in, X is the raw capacity data, is the rated capacity of the lithium-ion battery, is the normalized data;

[0086] S13, reshape the normalized data into the shape required by the TCN-UnetTSF model to obtain the initial input to the TCN module , the formula is:

[0087] ;

[0088] in, is the reshaped data, i.e. the initial input of the TCN module, represents the real tensor shape, express is a shape of A real tensor of , C represents the number of features, N Indicates the number of sequences, T represents the time step, Represents a reshape operation.

[0089] S2, constructing a TCN module, taking the pre-processed lithium-ion battery capacity data as initial input;

[0090] As a preferred implementation of step S2, Figure 3 As shown, the specific steps include:

[0091] S21,TCN module includes two expansion initial layers DIL, one of which has an output connected to a tanh activation function and the other connected to a sigmoid activation function;

[0092] S22, two expansion initial layers DIL initial input to TCN Perform the same process and get the output respectively and ;

[0093] More specifically, the expansion initial layer DIL processes the input including the following steps:

[0094] S221, dilated convolution; initial input of TCN module The input is sent to an expansion initial layer DIL, which first passes through a set of convolution kernels with gradually increasing size. The one-dimensional causal expansion convolution layer extracts multi-scale features under time dependence. No padding operation is performed during the convolution process, and four multi-scale features are output. , the formula is:

[0095] ;

[0096] in, Through different convolution kernels The four multi-scale features after convolution, Indicates the size used is The convolution operation is performed with a one-dimensional convolution kernel; the number of channels of each multi-scale feature mapping to the convolution kernel is , that is, the number of features CAccording to the number of convolutional layers, , the number of sequences N remains unchanged, and the time step becomes ;

[0097] S222, time dimension feature extraction; the time dimension is the minimum, that is, the time step T The shortest feature is used as the standard, and the four multi-scale features are intercepted to obtain four multi-scale features with the same time dimension. The largest, therefore The time dimension is the least, As the standard, the four multi-scale features after truncation are obtained , the formula is:

[0098] ;

[0099] in, Refers to indexing forward from the end of the array and uniformly intercepting the last The value of the time step is used to ensure that the outputs of convolution kernels of different sizes are aligned in the time dimension;

[0100] S223, multi-scale feature concatenation; the four multi-scale feature values ​​after truncation are concatenated. In the channel dimension, that is, the number of features C Splice and restore to the original input of TCN The same number of features, get the concatenated feature tensor , the formula is:

[0101] ;

[0102] in, express Is a shape of A real tensor of , C represents the number of features, N Indicates the number of sequences, represents the time step, Indicates concatenating multiple features in the channel dimension;

[0103] S224, multi-layer perceptron MLP mapping; multi-layer perceptron MLP processes the concatenated feature tensor through two fully connected layers , two fully connected layers include linear layer Linear and ReLU activation function; the concatenated feature tensor First pass through a linear layer Linear, then through the ReLU activation function, and then through a linear layer Linear to restore the initial input of the TCN module Same time step T,Finally, we get the output of the first expansion initial layer DIL , the formula is:

[0104] ;

[0105] in, express is a shape of A real tensor of , Represents the mapping function of the multilayer perceptron;

[0106] S225, after the same process, the output of the second expansion initial layer DIL is obtained ;

[0107] S23, output , The final output of the TCN module is obtained by performing dot product multiplication through the tanh activation function and the sigmoid activation function respectively. , the formula is:

[0108] ;

[0109] in, express is a shape of A real tensor of , C represents the number of features, N Indicates the number of sequences, T represents the time step, represents the tanh activation function, represents the Sigmoid activation function, represents dot product multiplication;

[0110] In this embodiment, the tanh activation function is used as a filter, and the Sigmoid activation function is used as a gate function to control the amount of feature information that the filter can pass to the next module; the data processed by these two activation functions adds a nonlinear factor, that is, enhances the expression ability.

[0111] S3, build the UnetTSF module, taking the output of the TCN module as the initial input;

[0112] As a preferred implementation of step S3, the following steps are specifically included:

[0113] S31, the final output of the TCN module As input, multi-scale features are extracted and fused based on the U-Net structure to obtain the fusion features of multi-scale features ;

[0114] More specifically, Figure 4 As shown in Figure 1, the specific process of introducing the feature pyramid network FPN for multi-scale feature extraction and fusion includes:

[0115] S311, pooling layer; construct a four-layer pyramid structure, each layer uses a pooling layer to achieve feature extraction, and obtain , respectively, are the multi-scale temporal features extracted by the pooling operation of the 1st, 2nd, 3rd, and 4th layers, and the formula is expressed as:

[0116] ;

[0117] in, represents the average pooling operation, C represents the number of features, N Indicates the number of sequences, Represents the time step of each multi-scale temporal feature; the time step of the first layer Equal to the initial input of the TCN module Time step T The time steps of the remaining layers are based on the time step of the previous layer, calculated by the time step formula It turns out that the formula is:

[0118] ;

[0119] in, Indicates the padding size of the input data edge before the pooling operation. Indicates the size of the sliding window during the pooling operation, Indicates the number of steps the sliding window moves during the pooling operation; in this embodiment, is 3, is 2, is 1;

[0120] S312, linear layer mapping; multi-scale temporal features Mapped into intermediate features through linear layers , the formula is:

[0121] ;

[0122] in, Represents a linear transformation, and extracts features through a fully connected layer;

[0123] S313, multi-scale feature fusion; based on a four-layer pyramid structure, intermediate features are fused from bottom to top The splicing in the time dimension is to first Layer and The intermediate features of the layer are concatenated, and the concatenated features are then passed through a linear layer to generate the first New intermediate features of the layer , repeat the operation until the new intermediate features of the first layer are output , the formula is:

[0124] ;

[0125] in, Represents the new intermediate features after the 1st, 2nd, and 3rd layers are concatenated and linearly transformed. represents a linear transformation, Represents a splicing operation;

[0126] Finally, the new intermediate features of layer 1 It is the fusion feature of multi-scale features ;

[0127] The feature pyramid network FPN introduced in this embodiment continuously reduces the dimension and integrates the multi-scale features through the top-down pooling layer and linear layer, screens out useless redundant information and enhances the feature expression ability, and then splices the features at different time steps from the bottom to the top, and finally obtains the top-level output containing rich semantic information, that is, the fusion feature of multi-scale features. ; From the overall TCN-UnetTSF model proposed in this invention, the fusion features of multi-scale features It also takes into account both local and global features;

[0128] S32, fusion features of multi-scale features Through a linear layer and reshape operation, the fusion features of the reshaped multi-scale features are obtained. , the formula is:

[0129] ;

[0130] in, represents the transformation matrix of the linear layer, and is a C×C The transformation matrix, Represents the fusion features of the reshaped multi-scale features is a shape of A real tensor of , C represents the number of features, N Indicates the number of sequences, T represents the time step, To reshape the operation;

[0131] S33. Finally, a linear layer is used to fuse the reshaped multi-scale features. Convert to point prediction results , which is the final output of the UnetTSF module, is expressed as:

[0132] ;

[0133] Among them, Linear represents linear transformation, Represents point prediction results is a scalar; therefore, after the multi-scale features are extracted and fused, the battery capacity data prediction results are displayed as point data scalars in the time dimension, and the prediction effect can be obtained intuitively.

[0134] S4, training and testing based on TCN module and UnetTSF module to obtain the lithium-ion battery capacity prediction results;

[0135] As a preferred implementation of step S4, the following steps are specifically included:

[0136] S41. The lithium-ion battery data is divided into a training set and a test set; the training set is divided into batch sizes After segmentation and preprocessing, the model is input into the TCN module and the UnetTSF module for training to obtain the trained TCN-UnetTSF model. ;

[0137] S42, then the test set is also divided into batch sizes Segmentation, after preprocessing to get the test input , input it into the trained TCN-UnetTSF model and get the test results , the formula is as follows:

[0138] ;

[0139] in, Refers to the test results is included A batch of point data scalars;

[0140] That is, the predicted result of the lithium-ion battery capacity is obtained.

[0141] In this example, the "leave one out" method is used for training and testing. After four iterations, one battery data is retained for testing each time, and finally all four batteries can be tested. All data are normalized to the range of [0, 1] by dividing by the rated capacity of the battery (Rated_Capacity = 2.0), and the normalized data is split according to the batch size (batch_size=16), and then reshaped into the shape The tensor is input into the TCN-UnetTSF model. The TCN module extracts multi-scale features in the time series, and the UnetTSF module is used to fuse and reshape the features, thereby generating more accurate capacity prediction results.

[0142] During the specific test process, Figure 1 As shown, using the lithium battery capacity data provided by NASA, a group of 18650 batteries (a total of four batteries, No. 5, No. 6, No. 7 and No. 18) were selected to run three different operation modes at room temperature (24°C): charging, discharging and EIS impedance measurement. The charging process uses a constant current (CC) mode of 1.5A to charge until the battery voltage reaches 4.2V, and then continues to charge in a constant voltage (CV) mode until the charging current drops to 20mA; the discharge process uses a constant current (CC) mode of 2A to discharge until the battery voltage drops to 2.7V, 2.5V, 2.2V and 2.5V respectively; impedance measurement is performed by electrochemical impedance spectroscopy (EIS) from a frequency range of 0.1Hz to 5kHz; considering the impact of EIS measurement on capacity, No. 5, No. 6 and No. 7 batteries were measured 278 times, while No. 18 battery was measured 53 times. The end condition of the experiment is: when the battery reaches the end of life (EOL) standard-the rated capacity drops by 30% (from 2Ah to 1.4Ah), the experiment stops. The experiment includes 616 small processes in total, with 168 or 132 complete cycles.

[0143] The test results obtained are as follows Figure 5 As shown, the results of the method proposed in the present invention under single-step prediction and multi-step prediction are shown. Although the two different prediction strategies perform differently on different batteries, they both show the good effect of the lithium-ion battery capacity prediction method proposed in the present invention. The single-step prediction result shows that the short-term prediction result of the method is very consistent with the actual situation, and the multi-step prediction result shows that the long-term prediction result of the method also has high accuracy and reliability.

[0144] In addition, compared with other prediction methods in the prior art, such as Figure 6As shown, the lithium-ion battery capacity prediction method based on the TCN-UnetTSF model proposed in the present invention is compared with five baseline methods (RNN, LSTM, GRU, Dual-LSTM and DeTransformer), and the specific indicators include relative error (RE), mean absolute error (MAE) and root mean square error (RMSE). It can be seen from the figure that the proposed model is superior to other baseline methods in all indicators, especially in the RE indicator, the TCN-UnetTSF model is only 0.0452, which is much lower than other baseline methods. This shows that through the combination of TCN and UnetTSF modules, the method proposed in the present invention can more accurately capture the changing trend of the battery health status and provide more accurate capacity prediction.

[0145] In summary, the lithium-ion battery capacity prediction method based on the TCN-UnetTSF model proposed in the present invention combines the advantages of the TCN module in extracting multi-scale features under time dependence and the superiority of the UnetTSF module in multi-scale feature fusion. Through the organic combination of the two and the complementary advantages, the accuracy of lithium-ion battery capacity prediction is improved, and the robustness and accuracy of the overall model are enhanced.

[0146] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine different embodiments or examples described in this specification and the features of different embodiments or examples, unless they are contradictory.

[0147] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, which can be embodied in any computer-readable medium for use by an instruction execution system, apparatus or device (such as a computer-based system, a system including a processor or other system that can fetch instructions from an instruction execution system, apparatus or device and execute instructions), or used in combination with these instruction execution systems, apparatuses or devices.

[0148] The above implementation methods have been described in detail. Specific examples are used herein to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of ​​the present invention, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.

Claims

1. A lithium-ion battery capacity prediction method based on the TCN-UnetTSF model, characterized in that: The method specifically comprises the following steps: S1. Preprocessing lithium-ion battery capacity data; S2, constructing a TCN module, using the pre-processed lithium-ion battery capacity data as initial input; step S2 specifically includes the following steps: S21,TCN module includes two expansion initial layers DIL, one of which has an output connected to a tanh activation function and the other connected to a sigmoid activation function; S22, two expansion initial layers DIL for the initial input X of TCN re Perform the same process and get the output X L ' and X R '; S23, output X L ', X R 'The final output Y of the TCN module is obtained by performing dot product multiplication through the tanh activation function and the sigmoid activation function respectively TCN , the formula is: in, Represents Y TCN is a real tensor of shape C×N×T, where C represents the number of features, N represents the number of sequences, T represents the time step, tanh(·) represents the tanh activation function, σ(·) represents the sigmoid activation function, and ⊙ represents the dot product multiplication; S3, constructing a UnetTSF module, taking the output of the TCN module as the initial input; step S3 specifically includes the following steps: S31, the final output Y of the TCN module TCN As input, multi-scale features are extracted and fused based on the U-Net structure to obtain the fusion feature O of the multi-scale features; S32, pass the fusion feature O of the multi-scale feature through a linear layer and perform a reshape operation to obtain the reshaped fusion feature O' of the multi-scale feature, which is expressed as: in, represents the transformation matrix of the linear layer, and it is a C×C transformation matrix, The fusion feature O' representing the reshaped multi-scale feature is a real tensor with a shape of C×N×T, where C represents the number of features, N represents the number of sequences, T represents the time step, and reshape(·) is the reshaping operation; S33. Finally, a linear layer is used to transform the fusion feature O' of the reshaped multi-scale features into the point prediction result O", which is the final output of the UnetTSF module. The formula is expressed as: Among them, Linear represents linear transformation, Indicates that the point prediction result O" is a scalar; S4. Training and testing are performed based on the TCN module and the UnetTSF module to obtain the lithium-ion battery capacity prediction results.

2. The lithium-ion battery capacity prediction method based on the TCN-UnetTSF model according to claim 1, characterized in that: Step S1 specifically includes the following steps: S11. Obtain the original capacity data X of the lithium-ion battery from the lithium-ion battery dataset provided by NASA; S12. Divide the original capacity data X by the rated capacity to normalize it to the range of 0 to 1. The formula is: Among them, X is the original capacity data, C0 is the rated capacity of the lithium-ion battery, and X normalized is the normalized data; S13, reshape the normalized data into the shape required by the TCN-UnetTSF model to obtain the initial input X for the TCN module re , the formula is: Among them, X re is the reshaped data, i.e. the initial input of the TCN module, represents the real tensor shape, Represents X re is a real tensor of shape C×N×T, where C represents the number of features, N represents the number of sequences, T represents the time step, and reshape(·) represents the reshaping operation.

3. The lithium-ion battery capacity prediction method based on the TCN-UnetTSF model according to claim 1, characterized in that: In step S22, the initial layer DIL is expanded to the initial input X of TCN re The specific processing is as follows: S221, dilated convolution; initial input X of TCN module re The input is sent to a dilation initialization layer DIL, and then a set of one-dimensional causal dilation convolution layers with gradually increasing convolution kernels [S1, S2, S3, S4] are used to extract multi-scale features under time dependence. No padding operation is performed during the convolution process, and four multi-scale features X1, X2, X3, and X4 are output. The formula is expressed as follows: Among them, X1, X2, X3, and X4 are four multi-scale features after convolution with different convolution kernels S1, S2, S3, and S4, respectively. Indicates the size is S i The convolution operation is performed with a one-dimensional convolution kernel; the number of channels of each multi-scale feature mapping to the convolution kernel is That is, the number of features C is divided equally into The number of sequences N remains unchanged, and the time step becomes TS i +1; S222, time dimension feature extraction: Taking the feature with the least time dimension, that is, the shortest time step T, as the standard, the four multi-scale features are extracted to obtain four multi-scale features with the same time dimension. Since the convolution kernel S4 is the largest, X4 has the least time dimension. Taking X4 as the standard, the four multi-scale features X1', X2', X3', and X4' are extracted. The formula is expressed as: Among them, [...,-(T-S4+1):] refers to indexing forward from the end of the array and uniformly intercepting the values ​​of the last T-S4+1 time steps in the time dimension; S223, multi-scale feature concatenation: The four multi-scale feature values ​​X1', X2', X3', and X4' are concatenated on the channel dimension, i.e., the number of features C, to restore them to the same size as the initial input X of the TCN. re The same number of features, get the concatenated feature tensor X L , the formula is: in, Represents X L It is a real tensor of shape C×N×(T-S4+1), where C represents the number of features, N represents the number of sequences, T-S4+1 represents the time step, and Concat(·) represents concatenating multiple features in the channel dimension; S224, multi-layer perceptron MLP mapping; multi-layer perceptron MLP processes the concatenated feature tensor X through two fully connected layers L , two fully connected layers include linear layer Linear and ReLU activation function; the concatenated feature tensor X L First, it passes through a linear layer, then through the ReLU activation function, and then through a linear layer to restore the initial input X of the TCN module. re The same time step T finally gets the output X of the first expansion initial layer DIL L ', the formula is expressed as: in, Represents X L ' is a real tensor of shape C×N×T, MLP(·) represents the mapping function of the multilayer perceptron; S225, after the same process, the output X of the second expansion initial layer DIL is obtained R '.

4. The lithium-ion battery capacity prediction method based on the TCN-UnetTSF model according to claim 1, characterized in that: In step S31, the feature pyramid network FPN is introduced to realize the extraction and fusion of multi-scale features. The specific process includes the following steps: S311, pooling layer; construct a four-layer pyramid structure, each layer uses a pooling layer to implement feature extraction, and obtains Z1, Z2, Z3, and Z4, which are the multi-scale temporal features extracted by the pooling operation of the 1st, 2nd, 3rd, and 4th layers, respectively. The formula is expressed as: Among them, AvgPool(·) represents the average pooling operation, C represents the number of features, N represents the number of sequences, and T i Represents the time step of each multi-scale temporal feature, i = 1, 2, 3, 4; the time step T1 of the first layer is equal to the initial input X of the TCN module re The time step of each layer is T, and the time step of the remaining layers is based on the time step of the previous layer, which is obtained by the time step calculation formula len(·), which is expressed as: Among them, padding represents the padding size of the input data edge before the pooling operation, kernel_size represents the size of the sliding window during the pooling operation, and stride represents the number of steps the sliding window moves during the pooling operation; S312, linear layer mapping: The multi-scale temporal features Z1, Z2, Z3, and Z4 are respectively mapped to intermediate features E1, E2, E3, and E4 through the linear layer. The formula is expressed as follows: Among them, Linear(·) represents linear transformation, and features are extracted through the fully connected layer; S313, multi-scale feature fusion; based on the four-layer pyramid structure, the intermediate features E1, E2, E3, and E4 are spliced ​​from bottom to top in the time dimension, that is, the intermediate features of the i-th layer and the i-1-th layer are first spliced, and the spliced ​​features are then passed through a linear layer to generate a new intermediate feature D of the i-1-th layer. i-1 , repeat the operation until the new intermediate feature D1 of the first layer is output. The formula is expressed as: Among them, D1, D2, and D3 represent the new intermediate features after the concatenation and linear transformation of the 1st, 2nd, and 3rd layers, Linear(·) represents linear transformation, and Concat(·) represents concatenation operation; Finally, the new intermediate feature D1 of the first layer is used as the fusion feature O of the multi-scale features.

5. The lithium-ion battery capacity prediction method based on the TCN-UnetTSF model according to claim 1, characterized in that: Step S4 specifically includes the following steps: S41, the lithium-ion battery data is divided into a training set and a test set; the training set is divided according to the batch size B, and after preprocessing, it is input into the TCN module and the UnetTSF module in sequence for training to obtain the trained TCN-UnetTSF model Model(·); S42, the test set is also divided into batch size B, and the test input is obtained after preprocessing Input it into the trained TCN-UnetTSF model Model(·) to get the test result O pred , the formula is as follows: in, Refers to the test results O pred is a point data scalar containing B batches; That is, the predicted result of the lithium-ion battery capacity is obtained.