Battery charge state estimation method and system based on embedded domain knowledge neural network
Through the neural network method based on embedded domain knowledge, the SocNet model of feature extraction, SOC look-up and summing modules is used to solve the problem of large errors in complex environments in traditional SOC estimation methods, and high accuracy and high reliability are achieved. Lithium battery SOC estimate.
Patent Information
- Application Number
- CN202411573423.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-06
- Publication Date
- 2025-02-25
- Estimated Expiration
- 2044-11-06
AI Technical Summary
Traditional lithium battery SOC estimation methods show obvious limitations in complex and variable working environments, especially with significant errors under extreme temperature conditions, and the ‘black box’ nature of deep learning models leads to a lack of interpretability.
Using a neural network method based on embedded domain knowledge, the SocNet neural network model is trained through historical battery operation data, corresponding time values and historical SOC as sample sets. The model includes feature extraction module, SOC look-up module and summing module for More accurately estimate the charge state of lithium batteries.
It improves the accuracy and stability of SOC estimation in a changing environment, reduces errors, enhances the interpretability and robustness of the model, and achieves high-precision and high-reliability SOC estimation.
Smart Images

Figure CN119511113A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of lithium battery health management technology, and more specifically to a method and system for estimating the state of charge of a battery based on an embedded domain knowledge neural network. Background Art
[0002] With the widespread application of electric vehicles, renewable energy storage systems and portable electronic devices, lithium batteries have become energy storage devices for many systems. The SOC (State-of-charge) of a lithium battery is a key indicator to measure its remaining power and health status, which is crucial for the optimization of lithium battery prediction and PHM (Prognostic and Health Management). Accurate estimation of SOC not only helps to extend battery life, but also ensures the safety and performance of the device. However, traditional SOC estimation methods show obvious limitations when facing complex and changing working environments.
[0003] Traditional SOC estimation methods mainly include coulomb counting method, open circuit voltage method and model-based methods. These methods usually rely on fixed parameters and ideal working conditions, but in actual applications, the working environment of lithium batteries is often affected by external factors such as temperature and load changes, resulting in inaccurate estimation results of traditional methods. In the application of lithium batteries, geographical location, day and night alternation, and seasonal changes will significantly change the ambient temperature, affect the electrochemical reaction rate and internal resistance of lithium batteries, and thus affect the accurate estimation of SOC. Especially under extreme temperature conditions, the errors of traditional methods are more significant, so data-driven methods are widely used, especially those based on deep learning.
[0004] In the field of temperature-robust SOC estimation methods, although deep learning models have demonstrated powerful predictive capabilities in many applications, their "black box" nature and lack of interpretability often make users doubt their effectiveness.
[0005] Therefore, it is necessary to design a new method that can estimate SOC more accurately in complex and changing working environments, effectively reduce errors, and improve the accuracy of SOC estimation with strong reliability. Summary of the invention
[0006] The purpose of the present invention is to overcome the defects of the prior art and provide a method and system for estimating the state of charge of a battery based on a neural network with embedded domain knowledge.
[0007] To achieve the above object, the present invention adopts the following technical solution: a method for estimating battery state of charge based on a neural network with embedded domain knowledge, comprising:
[0008] Acquiring battery operation data, wherein the battery operation data includes battery discharge terminal voltage, current, temperature data and corresponding battery capacity data;
[0009] The battery operation data is input into the embedded domain knowledge neural network to estimate the battery state of charge to obtain an estimation result; wherein the embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as a sample set into a SocNet neural network model for training, and the SocNet neural network model includes a feature extraction module with a special path, a SOC lookback module and a summation module;
[0010] The estimation result is outputted.
[0011] The further technical solution is: the embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as sample sets into the SocNet neural network model for training, including:
[0012] Define the current SOC of the battery;
[0013] Obtain historical battery operation data, corresponding time values and historical SOC;
[0014] Normalizing the historical battery operation data, the corresponding time value and the historical SOC, and combining them with the current SOC of the battery to form a sample set;
[0015] Dividing the sample set into a training set, a validation set and a test set;
[0016] Build SocNet neural network model;
[0017] Use the training set and validation set to perform 10-fold cross validation, calculate the average network loss, and end the validation when the average network loss is less than the set threshold, and record the optimal network hyperparameters of the SocNet neural network model;
[0018] The training set and the validation set are mixed into a new training set, the SocNet neural network model is set using the optimal network hyperparameters, training is performed, and the model is saved;
[0019] The saved model is tested using the test set, and the estimated battery capacity value is recorded to obtain the embedded domain knowledge neural network.
[0020] Its further technical solution is: the feature extraction module includes a convolutional neural network layer, a pooling and flattening layer, a special path and a first multi-layer perceptron module connected in sequence; wherein, the first multi-layer perceptron module includes an input layer, a fully connected hidden layer with a ReLU activation function and a linear output layer.
[0021] A further technical solution is: the battery operation data is input into the embedded domain knowledge neural network to estimate the battery state of charge to obtain an estimation result, including:
[0022] Inputting the battery operation data into the embedded domain knowledge neural network;
[0023] generating a first hidden state using a feature extraction module;
[0024] Generate the second hidden state using the SOC lookback module;
[0025] The first hidden state and the second hidden state are summed to obtain an estimation result.
[0026] A further technical solution is: the step of generating the first hidden state by using the feature extraction module comprises:
[0027] Extracting spatial and temporal relationships among voltage, current, temperature, and historical SOC in the battery operation data using a convolutional neural network layer;
[0028] Pool and flatten the output of the convolutional neural network layer to form a feature vector;
[0029] Connect the current and time values at the current moment with the feature vector to form a new input vector;
[0030] The concatenated feature vector is processed to generate the first hidden state.
[0031] A further technical solution is: the method of generating the second hidden state by using the SOC lookback module includes:
[0032] Save the SOC value for a period of time in the past;
[0033] The SOC value is processed by a second multilayer perceptron module to obtain a second hidden state, wherein the second multilayer perceptron module includes a sequentially connected input layer, a fully connected hidden layer with a ReLU activation function, and a linear output layer.
[0034] The present invention also provides a battery state of charge estimation system based on an embedded domain knowledge neural network, comprising:
[0035] A data acquisition unit, used to acquire battery operation data, wherein the battery operation data includes battery discharge terminal voltage, current, temperature data and corresponding battery capacity data;
[0036] An estimation unit, used for inputting the battery operation data into an embedded domain knowledge neural network to perform battery state of charge estimation to obtain an estimation result; wherein the embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as a sample set into a SocNet neural network model for training, and the SocNet neural network model includes a feature extraction module with a special path, a SOC lookback module and a summation module;
[0037] An output unit is used to output the estimation result.
[0038] Its further technical solution is: the estimation unit comprises:
[0039] An input subunit, used for inputting the battery operation data into the embedded domain knowledge neural network;
[0040] A feature extraction subunit, configured to generate a first hidden state using a feature extraction module;
[0041] A look-back subunit, used for generating a second hidden state using a SOC look-back module;
[0042] A summing subunit is used to sum the first hidden state and the second hidden state to obtain an estimation result.
[0043] Its further technical solution is: the feature extraction subunit includes:
[0044] A relationship extraction module, for extracting the spatial and temporal relationship between the voltage, current, temperature and historical SOC in the battery operation data using a convolutional neural network layer;
[0045] The pooling and flattening module is used to pool and flatten the output of the convolutional neural network layer to form a feature vector;
[0046] A connection module is used to connect the current and time values at the current moment with the feature vector to form a new input vector;
[0047] The vector processing module is used to process the connected feature vector to generate a first hidden state.
[0048] Its further technical solution is: the looking back subunit includes:
[0049] The saving module is used to save the SOC value of the past period of time;
[0050] The SOC value processing module is used to process the SOC value using a second multi-layer perceptron module to obtain a second hidden state, wherein the second multi-layer perceptron module includes a sequentially connected input layer, a fully connected hidden layer with a ReLU activation function, and a linear output layer.
[0051] The beneficial effects of the present invention compared with the prior art are as follows: the present invention forms a complete battery operation data set by acquiring the battery discharge terminal voltage, current, temperature and capacity data. These data are input into the neural network SocNet with embedded domain knowledge to estimate the state of charge (SOC). SocNet is trained with historical data and SOC sample sets, and has feature extraction, SOC lookback and summation modules, which can effectively identify complex patterns. The dynamic adaptability of the model enhances the accuracy and stability in a changing environment. Finally, through the output estimation result, high-precision and high-reliability SOC estimation is achieved.
[0052] The present invention is further described below in conjunction with the accompanying drawings and specific embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying any creative work.
[0054] Figure 1 A schematic diagram of an application scenario of a method for estimating battery state of charge based on a neural network with embedded domain knowledge provided by an embodiment of the present invention;
[0055] Figure 2 A schematic diagram of a flow chart of a method for estimating a battery state of charge based on a neural network with embedded domain knowledge provided in an embodiment of the present invention;
[0056] Figure 3 A schematic block diagram of a battery state of charge estimation system based on an embedded domain knowledge neural network provided by an embodiment of the present invention;
[0057] Figure 4 A schematic block diagram of a computer device provided for an embodiment of the present invention;
[0058] Figure 5 A schematic diagram of the workflow of a neural network with embedded domain knowledge provided by an embodiment of the present invention;
[0059] Figure 6 A schematic diagram of the structure of a first multi-layer perceptron module provided by an embodiment of the present invention;
[0060] Figure 7 A schematic diagram of the structure of a second multi-layer perceptron module provided by an embodiment of the present invention;
[0061] Figure 8 A schematic diagram of the training process of a neural network with embedded domain knowledge provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0062] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0063] It should be understood that when used in this specification and the appended claims, the terms "include" and "comprises" indicate the presence of described features, integers, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or combinations thereof.
[0064] It should also be understood that the terms used in this specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. As used in the specification of the present invention and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include plural forms.
[0065] It should be further understood that the term "and / or" used in the present description and the appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0066] See also Figure 1 and Figure 2 , Figure 1 A schematic diagram of an application scenario of a battery state of charge estimation method based on an embedded domain knowledge neural network provided in an embodiment of the present invention. Figure 2A schematic flow chart of a method for estimating the state of charge of a battery based on an embedded domain knowledge neural network provided in an embodiment of the present invention. The method for estimating the state of charge of a battery based on an embedded domain knowledge neural network is applied to a server. The server interacts with a terminal for data. The current and time values at the current moment are combined with the output of the convolutional neural network to reduce possible information loss when passing through the network layer. At the same time, the SOC lookback mechanism uses historical SOC data as the input of the multi-layer perceptron to adjust the current SOC according to the past SOC. Finally, the output of the feature extraction module with a special path is added to the SOC lookback output to obtain the SOC value at the current moment. This structural design combines the domain knowledge of the Coulomb counting method. Specifically, the SOC estimation model calculates the battery capacity through the relationship between the voltage, current, temperature, time and historical SOC during battery discharge. By monitoring the discharge parameters of the battery and combining the time and the recorded historical SOC, the SOC of the battery can be estimated more accurately. This method incorporates domain knowledge into the neural network, significantly improving the interpretability and robustness of the model, enabling it to effectively learn complex nonlinear relationships and maintain stable performance under different temperature conditions. By combining the advantages of data-driven and knowledge-driven approaches, the model can not only provide accurate SOC estimation but also provide reasonable explanations for the results.
[0067] Figure 2 FIG. 1 is a flow chart of a method for estimating battery state of charge based on a neural network with embedded domain knowledge provided by an embodiment of the present invention. Figure 2 As shown, the method includes the following steps S110 to S150.
[0068] S110, obtaining battery operation data, wherein the battery operation data includes battery discharge terminal voltage, current, temperature data and corresponding battery capacity data.
[0069] In addition, the battery operation data also includes the corresponding time.
[0070] The process of obtaining battery operation data is crucial, and this data includes the following aspects:
[0071] Battery discharge terminal voltage: Monitoring the change in the battery terminal voltage during the discharge process can reflect the battery's health status and discharge efficiency. The change in voltage helps analyze the battery's performance under different loads and identify potential faults.
[0072] Current: Recording current data can help understand the discharge intensity and rate of the battery. The relationship between current and battery capacity is the basis for SOC (state of charge) estimation. By analyzing current changes, the remaining energy of the battery can be better predicted.
[0073] Temperature data: Temperature is an important factor affecting battery performance. The operating characteristics of the battery may be different at different temperatures. Monitoring temperature changes can help optimize the battery's operating conditions and provide proper protection and management in high or low temperature environments.
[0074] Battery capacity data: Obtaining battery capacity data is the key to understanding the battery status. Capacity reflects the total amount of energy that a battery can store. Through capacity data, the remaining power and life of the battery can be evaluated, and the battery usage strategy can be optimized.
[0075] Corresponding moments: It is very important to record the timestamp of each set of data, which can establish the relationship between battery operation data and time. This is of great significance for analyzing the changing trend of battery performance, making timing predictions, and optimizing charging / discharging strategies.
[0076] By integrating a variety of operating data, the battery's SOC can be estimated more accurately, reducing the risk of information loss and improving the reliability of the estimation results. Visualizing the relationship between the battery's operating parameters and SOC makes the model output more transparent and easier for users to understand and analyze. Monitoring operating data under different environmental conditions allows the battery management system to adjust its operating strategy in real time to adapt to temperature changes and load requirements, ensuring that the battery operates in the best condition. Through real-time analysis of battery operating data, potential faults or abnormal conditions can be quickly identified, and measures can be taken to prevent them, extending the battery's service life.
[0077] The accumulated operating data can be used for subsequent algorithm optimization and model training to improve the intelligence level of the battery management system and make it more adaptable to the needs of different application scenarios.
[0078] Overall, obtaining comprehensive battery operation data not only improves the intelligence level of battery management, but also significantly improves battery performance and safety, providing users with a better user experience.
[0079] S120, inputting the battery operation data into the embedded domain knowledge neural network to estimate the battery state of charge to obtain an estimation result; wherein the embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as sample sets into the SocNet neural network model for training, and the SocNet neural network model includes a feature extraction module with a special path, a SOC lookback module and a summation module.
[0080] In one embodiment, if Figure 8 As shown, the above embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as sample sets into the SocNet neural network model for training, including:
[0081] Define the current SOC of the battery; specifically, Among them, C t represents the battery capacity at time t, and C0 represents the initial capacity of the battery; if capacity loss occurs, the capacity value at the previous moment is assigned to the moment of loss;
[0082] Obtain historical battery operation data, corresponding time values and historical SOC;
[0083] Normalizing the historical battery operation data, the corresponding time value and the historical SOC, and combining them with the current SOC of the battery to form a sample set;
[0084] The sample set is divided into a training set, a validation set and a test set; specifically, the sample set is divided into a training set, a validation set and a test set according to temperature. The collection range of the battery data set is the minimum operating temperature T min To the maximum operating temperature T max , select the ambient temperature as T min 、T max And in T min To T max The temperature selected in the middle interval is used as the training set, and the other temperatures are used as the validation set and the test set, so that the ratio of the training set, the validation set, and the test set is close to 6:1:3.
[0085] Build SocNet neural network model;
[0086] Use the training set and validation set to perform 10-fold cross validation, calculate the average network loss, and end the validation when the average network loss is less than the set threshold. Record the optimal network hyperparameters of the SocNet neural network model, including learning rate, batch size, network lookback length, convolution kernel size, and number of hidden layer neurons.
[0087] The training set and the validation set are mixed into a new training set, the SocNet neural network model is set using the optimal network hyperparameters, training is performed, and the model is saved;
[0088] The saved model is tested using the test set, and the estimated battery capacity value is recorded to obtain the embedded domain knowledge neural network.
[0089] By using historical battery operation data, corresponding time values, and historical SOC as input, the model can learn the behavior of the battery more comprehensively, thereby improving the accuracy of SOC estimation. Processing the capacity loss enables the model to still provide reasonable SOC estimation in the face of battery performance degradation, enhancing the robustness of the model. Normalizing the input data can eliminate the influence between different dimensions, making model training more stable and converging faster. Dividing the training set, validation set, and test set according to temperature can ensure the generalization ability of the model under different environmental conditions, making it more reliable in practical applications. Through 10-fold cross-validation, the performance of the model can be effectively evaluated, the risk of overfitting can be reduced, and the prediction ability of the model on new data can be improved. Recording the optimal network hyperparameters can improve the learning efficiency and accuracy of the model, making the training process more efficient. Saving the trained model facilitates rapid deployment and use in practical applications in the future, improving the practicality of the model.
[0090] This method can adapt to different operating temperature ranges, enhance the applicability of the model under various environmental conditions, and ensure that good performance can be maintained in different application scenarios. The ability of the saved model is evaluated through the test set, which can provide reliable battery capacity prediction for practical applications and help users better manage and use batteries.
[0091] Overall, this method not only improves the accuracy and reliability of SOC estimation, but also enhances the adaptability of the model under various environmental conditions, providing strong support for the optimization of the battery management system.
[0092] In addition, the feature extraction module includes a convolutional neural network layer, a pooling and flattening layer, a special path and a first multi-layer perceptron module connected in sequence; wherein the first multi-layer perceptron module includes an input layer, a fully connected hidden layer with a ReLU activation function and a linear output layer.
[0093] In one embodiment, if Figure 5 As shown, the above step S120 may include steps S121 to S124.
[0094] S121, inputting the battery operation data into the embedded domain knowledge neural network;
[0095] S122. Generate a first hidden state using a feature extraction module.
[0096] In this embodiment, the first hidden state refers to the output of the multi-layer perceptron (MLP) module, which represents an intermediate representation obtained after feature extraction and processing. This representation contains important features and information of battery operation data (such as voltage, current, temperature and historical SOC).
[0097] Specifically, the first hidden state is generated through the following steps:
[0098] Feature extraction: Use convolutional neural network (CNN) layers to extract spatial and temporal relationships of input data.
[0099] Pooling and flattening: Pooling the CNN output and then flattening it into a feature vector to form a vector that can be input to subsequent models
[0100] Feature connection: Connect the current and time information at the current moment with the feature vector to form a new input vector (length ).
[0101] Multilayer Perceptron Processing: The concatenated vector is input into the MLP module and processed through the fully connected layer and activation function to generate the first hidden state (h1).
[0102] The role of the first hidden state is to serve as the input of the subsequent model, helping the model capture the potential characteristics of the battery state, thereby improving the ability to estimate and predict battery performance.
[0103] In one embodiment, the above-mentioned step S122 may include steps S1221 - S1224 .
[0104] S1221. Use a convolutional neural network layer to extract the spatial and temporal relationship between the voltage, current, temperature and historical SOC in the battery operation data.
[0105] The spatial and temporal relationships among voltage, current, temperature, and historical SOC refer to the interactions and dependencies of these variables at different points in time.
[0106] Spatial relationships: This involves the mutual influence between voltage, current, temperature, and SOC at the same moment. For example, at a certain point in time, a change in voltage may affect the state of current and SOC. Convolutional neural networks can effectively capture the correlation and patterns between these variables through their convolutional layers.
[0107] Temporal relationships: This refers to the dynamic changes of these variables in a time series. For example, changes in current may affect changes in SOC after a certain delay, or changes in temperature may show a certain pattern with changes in voltage. By processing historical data, convolutional neural networks can identify these temporal dependencies and trends.
[0108] In summary, convolutional neural networks can learn the complex relationships between these variables in space and time through feature extraction, thereby more accurately estimating the state and performance of the battery.
[0109] Specifically, the Convolutional Neural Network (CNN) layer structure is used at the beginning of feature extraction to extract the spatial relationship between different inputs and the temporal relationship between different historical quantities. The input sequence of the neural network, that is, the voltage sequence, current sequence, temperature sequence, SOC sequence with a history length of L, and the corresponding time series are stacked into a 5×L matrix H, which passes through two convolutional layers, named Conv1 and Conv2, and their convolution kernel sizes are both (10, 3).
[0110] S1222. Pool and flatten the output of the convolutional neural network layer to form a feature vector.
[0111] In this embodiment, the output of the second convolutional layer Conv2 is flattened into a feature vector after passing through the pooling layer. Its length is
[0112] S1223. Connect the current and time values at the current moment with the feature vector to form a new input vector.
[0113] In this embodiment, a special path is established to connect the current moment and the corresponding time value with Connect to form a length of Vector.
[0114] S1224. Process the connected feature vector to generate a first hidden state.
[0115] In this embodiment, the first multi-layer perceptron (MLP) module is used at the end of feature extraction and is named MLP1. The input of MLP1 is the length of S213. The feature vector of the special path is connected, and the output is the hidden state h1.
[0116] Specifically, Figure 6 As shown in Figure 1, the structure of the MLP1 module is an input layer, a fully connected hidden layer with a ReLU activation function, and a linear output layer. The input of the MLP1 module is denoted as x1, and the hidden layer weight matrix and bias vector are W 1,1 and B 1,1 .
[0117] The output of the hidden layer is represented as: h 1,0 =ReLU(W 1,1 x1+b 1,1 );
[0118] Among them, the ReLU activation function is defined as: ReLU(z)=max(0,z);
[0119] The weight matrix and bias vector of the output layer are W 1,2 and b 1,2 The output h1 of MLP1 is expressed as: h1 = W 1,2 h 1,0 +b 1,2 ;
[0120] Substituting the output of the hidden layer into the expression, the complete MLP1 model is expressed as: h1 = W 1,2 ReLU(W 1,1 x1+b 1,1 )+b 1,2 .
[0121] S123, using the SOC lookback module to generate a second hidden state.
[0122] In this embodiment, the second hidden state refers to the hidden layer output generated by the second multi-layer perceptron module. This process is to combine the information of the historical SOC value to improve the estimation of the current state.
[0123] Specifically, the second hidden state is the processed output in MLP2, which reflects the understanding and modeling of past SOC values. This hidden state, combined with the first hidden state, can provide more comprehensive information to estimate the current SOC.
[0124] By adding the first hidden state and the second hidden state, the model can comprehensively utilize the current current information and historical SOC data to improve the SOC estimation accuracy. This mechanism ensures that the model has stronger robustness when facing dynamic and complex environments.
[0125] In one embodiment, the above-mentioned step S123 may include steps S1231 - S1232 .
[0126] S1231. Save the SOC value for a period of time in the past.
[0127] In this embodiment, the SOC value of the past time period L is saved as SOC t-L:t-1 In the training of the neural network SocNet, the real SOC value in the training data is used; in the testing and application of the neural network SocNet, the past estimation results of the model are saved as SOC t-L:t-1 .
[0128] S1232. Use a second multilayer perceptron module to process the SOC value to obtain a second hidden state, wherein the second multilayer perceptron module includes a sequentially connected input layer, a fully connected hidden layer with a ReLU activation function, and a linear output layer.
[0129] like Figure 7 As shown, the second multi-layer perceptron module MLP2 is used at the end of the SOC lookback mechanism. The input of NLP2 is the SOC described in S221. t-L:t-1 , the output is the hidden state h2.
[0130] The input of the MLP2 module is denoted as x2, and the hidden layer weight matrix and bias vector are W 2,1 and b 2,1 .
[0131] The output of the hidden layer is represented as: h 2,0 =ReLU(W 2,1 x2+b 2,1 );
[0132] Among them, the ReLU activation function is defined as: ReLU(z)=max(0,z);
[0133] The weight matrix and bias vector of the output layer are W 2,2 and b 2,2 The output h2 of MLP2 is expressed as:
[0134] h2=W 2,2 h 2,0 +b 2,2 ;
[0135] Substituting the output of the hidden layer into the expression, the complete MLP1 model is expressed as: h2 = W 2,2 ReLU(W 2,1 x1+b 2,1 )+b 2, 2.
[0136] S124: sum the first hidden state and the second hidden state to obtain an estimation result.
[0137] Specifically, Among them, I t is the current at time t. The output SOC of the neural network model SocNet t , which is the sum of the output of MLP1 and the output of MLP2.
[0138] By extracting key features from battery operation data (such as voltage, current, temperature, and SOC), the model can more accurately reflect the true state of the battery, thereby improving the ability to predict battery performance.
[0139] Convolutional neural networks effectively learn spatial and temporal relationships in battery data, which helps identify dependencies and dynamic changes between variables, leading to a more comprehensive understanding of the battery's operating conditions.
[0140] By saving the SOC values over a period of time, the model can use historical information to enhance the judgment of the current status and improve the reliability of the prediction.
[0141] The use of a step-by-step modular approach (feature extraction, SOC review, etc.) makes the system structure clear and easy to maintain and improve. Different modules can be optimized independently and flexibly adapted to different application scenarios.
[0142] Using a multi-layer perceptron to process features can effectively reduce computational complexity, while using the ReLU activation function to accelerate the training process.
[0143] In summary, this method can effectively improve the accuracy of battery state estimation and the predictive ability of the model through the application of deep learning technology, which is of great significance to the development of battery management systems.
[0144] S130: Output the estimation result.
[0145] The estimation results are output to the terminal display.
[0146] The method of this embodiment can more accurately estimate the state of battery (SOC) in complex and changing working environments by embedding domain knowledge into the combination of coulomb counting and deep learning. Especially under extreme temperature conditions, this method can significantly reduce errors and improve the accuracy of SOC estimation. The robustness of the model under temperature changes is enhanced, and the feature extraction module of specific pathways and the SOC lookback mechanism enable the model to maintain stable performance at different temperatures.
[0147] The SOC lookback mechanism uses historical SOC data to dynamically correct and optimize the current SOC, ensuring the continuity and accuracy of the estimated results, especially in long-term operation and significant environmental changes, providing more reliable estimates. Geographical differences, day and night changes, and seasonal changes all affect the ambient temperature, and this method effectively responds to these changes and ensures the stability and reliability of SOC estimation.
[0148] Existing deep learning models often lack interpretability due to their "black box" characteristics, causing users to doubt their effectiveness. The method of this embodiment improves the transparency of the model by incorporating domain knowledge, allowing users to better understand and trust the prediction results. This interpretability not only helps users understand the operating mechanism of the model, but also enhances their confidence in the results.
[0149] The combined data-driven and knowledge-driven approach makes full use of existing empirical knowledge and data advantages to improve the overall performance of the model, making SOC estimation more accurate, stable and easy to understand. This method is applicable to various lithium battery application scenarios, including electric vehicles, renewable energy storage systems and portable electronic devices. The required data only includes the battery voltage, current, temperature and corresponding time values.
[0150] The above-mentioned method for estimating the battery state of charge based on a neural network with embedded domain knowledge forms a complete battery operation data set by acquiring the battery discharge terminal voltage, current, temperature and capacity data. These data are input into the neural network SocNet with embedded domain knowledge for state of charge (SOC) estimation. SocNet is trained with historical data and SOC sample sets, and has feature extraction, SOC lookback and summation modules, which can effectively identify complex patterns. The dynamic adaptability of the model enhances accuracy and stability in a changing environment. Finally, through the output estimation results, high-precision and high-reliability SOC estimation is achieved.
[0151] Figure 3 is a schematic block diagram of a battery state of charge estimation system 300 based on an embedded domain knowledge neural network provided by an embodiment of the present invention. Figure 3 As shown, corresponding to the above-mentioned method for estimating the battery state of charge based on an embedded domain knowledge neural network, the present invention also provides a system 300 for estimating the battery state of charge based on an embedded domain knowledge neural network. The system 300 for estimating the battery state of charge based on an embedded domain knowledge neural network includes a unit for executing the above-mentioned method for estimating the battery state of charge based on an embedded domain knowledge neural network, and the system can be configured in a server. Specifically, please refer to Figure 3 The battery state of charge estimation system 300 based on embedded domain knowledge neural network includes a data acquisition unit 301, an estimation unit 302 and an output unit 303.
[0152] The data acquisition unit 301 is used to acquire battery operation data, wherein the battery operation data includes battery discharge terminal voltage, current, temperature data and corresponding battery capacity data; the estimation unit 302 is used to input the battery operation data into the embedded domain knowledge neural network to estimate the battery state of charge to obtain an estimation result; wherein the embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as sample sets into the SocNet neural network model for training, and the SocNet neural network model includes a feature extraction module with a special path, a SOC lookback module and a summation module; the output unit 303 is used to output the estimation result.
[0153] In one embodiment, the estimating unit 302 includes:
[0154] An input subunit is used to input the battery operation data into the embedded domain knowledge neural network; a feature extraction subunit is used to generate a first hidden state using a feature extraction module; a lookback subunit is used to generate a second hidden state using an SOC lookback module; and a summation subunit is used to sum the first hidden state and the second hidden state to obtain an estimation result.
[0155] In one embodiment, the feature extraction subunit includes:
[0156] A relationship extraction module, for extracting the spatial and temporal relationship between the voltage, current, temperature and historical SOC in the battery operation data using a convolutional neural network layer;
[0157] The pooling and flattening module is used to pool and flatten the output of the convolutional neural network layer to form a feature vector;
[0158] A connection module is used to connect the current and time values at the current moment with the feature vector to form a new input vector;
[0159] The vector processing module is used to process the connected feature vector to generate a first hidden state.
[0160] In one embodiment, the looking back subunit includes:
[0161] The saving module is used to save the SOC value of the past period of time;
[0162] The SOC value processing module is used to process the SOC value using a second multi-layer perceptron module to obtain a second hidden state, wherein the second multi-layer perceptron module includes a sequentially connected input layer, a fully connected hidden layer with a ReLU activation function, and a linear output layer.
[0163] It should be noted that technicians in the relevant field can clearly understand that the specific implementation process of the above-mentioned battery state of charge estimation system 300 based on embedded domain knowledge neural network and each unit can refer to the corresponding description in the aforementioned method embodiment, and for the convenience and conciseness of the description, it will not be repeated here.
[0164] The above-mentioned battery state of charge estimation system 300 based on embedded domain knowledge neural network can be implemented in the form of a computer program. The computer program can be used in Figure 4 Runs on the computer device shown.
[0165] See also Figure 4 , Figure 45 is a schematic block diagram of a computer device provided in an embodiment of the present application. The computer device 500 may be a server, wherein the server may be an independent server or a server cluster composed of multiple servers.
[0166] See also Figure 4 The computer device 500 includes a processor 502 , a memory and a network interface 505 connected via a system bus 501 , wherein the memory may include a non-volatile storage medium 503 and an internal memory 504 .
[0167] The non-volatile storage medium 503 can store an operating system 5031 and a computer program 5032. The computer program 5032 includes program instructions, and when the program instructions are executed, the processor 502 can execute a battery state of charge estimation method based on an embedded domain knowledge neural network.
[0168] The processor 502 is used to provide computing and control capabilities to support the operation of the entire computer device 500 .
[0169] The internal memory 504 provides an environment for the operation of the computer program 5032 in the non-volatile storage medium 503. When the computer program 5032 is executed by the processor 502, the processor 502 can execute a battery state of charge estimation method based on an embedded domain knowledge neural network.
[0170] The network interface 505 is used to communicate with other devices over the network. Figure 4 The structure shown in the figure is merely a block diagram of a portion of the structure related to the solution of the present application, and does not constitute a limitation on the computer device 500 to which the solution of the present application is applied. The specific computer device 500 may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0171] The processor 502 is used to run the computer program 5032 stored in the memory to implement the following steps:
[0172] Acquire battery operation data, wherein the battery operation data includes battery discharge terminal voltage, current, temperature data and corresponding battery capacity data; input the battery operation data into an embedded domain knowledge neural network to estimate the battery state of charge to obtain an estimation result; wherein the embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as a sample set into a SocNet neural network model for training, and the SocNet neural network model includes a feature extraction module with a special path, a SOC lookback module and a summation module; output the estimation result.
[0173] In one embodiment, when the processor 502 implements the step of inputting historical battery operation data, corresponding time values, and historical SOC as sample sets into the SocNet neural network model for training, the embedded domain knowledge neural network specifically implements the following steps:
[0174] Define the current SOC of the battery; obtain historical battery operation data, corresponding time values and historical SOC; normalize the historical battery operation data, corresponding time values and historical SOC, and combine them with the current SOC of the battery to form a sample set; divide the sample set into a training set, a validation set and a test set; build a SocNet neural network model; use the training set and the validation set to perform 10-fold cross-validation, calculate the average network loss, and when the average network loss is less than the set threshold, end the validation and record the optimal network hyperparameters of the SocNet neural network model; mix the training set and the validation set into a new training set, use the optimal network hyperparameters to set the SocNet neural network model, perform training, and save the model; use the test set to test the saved model, and record the estimated battery capacity value to obtain an embedded domain knowledge neural network.
[0175] Among them, the feature extraction module includes a convolutional neural network layer, a pooling and flattening layer, a special path and a first multi-layer perceptron module connected in sequence; wherein, the first multi-layer perceptron module includes an input layer, a fully connected hidden layer with a ReLU activation function and a linear output layer.
[0176] In one embodiment, when the processor 502 implements the step of inputting the battery operation data into the embedded domain knowledge neural network to estimate the battery state of charge to obtain an estimation result, the processor 502 specifically implements the following steps:
[0177] The battery operation data is input into the embedded domain knowledge neural network; a first hidden state is generated by using a feature extraction module; a second hidden state is generated by using a SOC lookback module; and the first hidden state and the second hidden state are summed to obtain an estimation result.
[0178] In one embodiment, when the processor 502 implements the step of generating the first hidden state by using the feature extraction module, the processor 502 specifically implements the following steps:
[0179] A convolutional neural network layer is used to extract the spatial and temporal relationship between the voltage, current, temperature and historical SOC in the battery operation data; the output of the convolutional neural network layer is pooled and flattened to form a feature vector; the current and time values at the current moment are connected to the feature vector to form a new input vector; the connected feature vector is processed to generate a first hidden state.
[0180] In one embodiment, when the processor 502 implements the step of generating the second hidden state by using the SOC lookback module, the processor 502 specifically implements the following steps:
[0181] The SOC value of the past period of time is saved; and the SOC value is processed by a second multilayer perceptron module to obtain a second hidden state, wherein the second multilayer perceptron module includes a sequentially connected input layer, a fully connected hidden layer with a ReLU activation function, and a linear output layer.
[0182] It should be understood that in the embodiment of the present application, the processor 502 may be a central processing unit (CPU), and the processor 502 may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0183] It can be understood by those skilled in the art that all or part of the processes in the method for implementing the above embodiment can be completed by instructing the relevant hardware through a computer program. The computer program includes program instructions, and the computer program can be stored in a storage medium, which is a computer-readable storage medium. The program instructions are executed by at least one processor in the computer system to implement the process steps of the embodiment of the above method.
[0184] Therefore, the present invention also provides a storage medium. The storage medium may be a computer-readable storage medium. The storage medium stores a computer program, wherein when the computer program is executed by a processor, the processor executes the following steps:
[0185] Acquire battery operation data, wherein the battery operation data includes battery discharge terminal voltage, current, temperature data and corresponding battery capacity data; input the battery operation data into an embedded domain knowledge neural network to estimate the battery state of charge to obtain an estimation result; wherein the embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as a sample set into a SocNet neural network model for training, and the SocNet neural network model includes a feature extraction module with a special path, a SOC lookback module and a summation module; output the estimation result.
[0186] In one embodiment, when the processor executes the computer program to implement the step that the embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values, and historical SOC as sample sets into the SocNet neural network model for training, the processor specifically implements the following steps:
[0187] Define the current SOC of the battery; obtain historical battery operation data, corresponding time values and historical SOC; normalize the historical battery operation data, corresponding time values and historical SOC, and combine them with the current SOC of the battery to form a sample set; divide the sample set into a training set, a validation set and a test set; build a SocNet neural network model; use the training set and the validation set to perform 10-fold cross-validation, calculate the average network loss, and when the average network loss is less than the set threshold, end the validation and record the optimal network hyperparameters of the SocNet neural network model; mix the training set and the validation set into a new training set, use the optimal network hyperparameters to set the SocNet neural network model, perform training, and save the model; use the test set to test the saved model, and record the estimated battery capacity value to obtain an embedded domain knowledge neural network.
[0188] Among them, the feature extraction module includes a convolutional neural network layer, a pooling and flattening layer, a special path and a first multi-layer perceptron module connected in sequence; wherein, the first multi-layer perceptron module includes an input layer, a fully connected hidden layer with a ReLU activation function and a linear output layer.
[0189] In one embodiment, when the processor executes the computer program to implement the step of inputting the battery operation data into the embedded domain knowledge neural network to estimate the battery state of charge to obtain an estimation result, the processor specifically implements the following steps:
[0190] The battery operation data is input into the embedded domain knowledge neural network; a first hidden state is generated by using a feature extraction module; a second hidden state is generated by using a SOC lookback module; and the first hidden state and the second hidden state are summed to obtain an estimation result.
[0191] In one embodiment, when the processor executes the computer program to implement the step of generating the first hidden state by using the feature extraction module, the processor specifically implements the following steps:
[0192] A convolutional neural network layer is used to extract the spatial and temporal relationship between the voltage, current, temperature and historical SOC in the battery operation data; the output of the convolutional neural network layer is pooled and flattened to form a feature vector; the current and time values at the current moment are connected to the feature vector to form a new input vector; the connected feature vector is processed to generate a first hidden state.
[0193] In one embodiment, when the processor executes the computer program to implement the step of generating the second hidden state by using the SOC lookback module, the processor specifically implements the following steps:
[0194] The SOC value of the past period of time is saved; and the SOC value is processed by a second multilayer perceptron module to obtain a second hidden state, wherein the second multilayer perceptron module includes a sequentially connected input layer, a fully connected hidden layer with a ReLU activation function, and a linear output layer.
[0195] The storage medium may be a USB flash drive, a mobile hard disk, a read-only memory (ROM), a magnetic disk, or an optical disk, etc., which are computer-readable storage media that can store program codes.
[0196] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in terms of function in the above description. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.
[0197] In the several embodiments provided by the present invention, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the system embodiments described above are only schematic. For example, the division of each unit is only a logical function division, and there may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed.
[0198] The steps in the method of the embodiment of the present invention can be adjusted in order, combined and deleted according to actual needs. The units in the system of the embodiment of the present invention can be combined, divided and deleted according to actual needs. In addition, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0199] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, terminal, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention.
[0200] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed by the present invention, and these modifications or replacements should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims.
Claims
1. A battery state of charge estimation method based on a neural network with embedded domain knowledge, characterized in that: include: Acquiring battery operation data, wherein the battery operation data includes battery discharge terminal voltage, current, temperature data and corresponding battery capacity data; The battery operation data is input into the embedded domain knowledge neural network to estimate the battery state of charge to obtain an estimation result; wherein the embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as a sample set into a SocNet neural network model for training, and the SocNet neural network model includes a feature extraction module with a special path, a SOC lookback module and a summation module; The estimation result is outputted.
2. The method for estimating battery state of charge based on a neural network with embedded domain knowledge according to claim 1, characterized in that: The embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as sample sets into the SocNet neural network model for training, including: Define the current SOC of the battery; Obtain historical battery operation data, corresponding time values and historical SOC; Normalizing the historical battery operation data, the corresponding time value and the historical SOC, and combining them with the current SOC of the battery to form a sample set; Dividing the sample set into a training set, a validation set and a test set; Build SocNet neural network model; Use the training set and validation set to perform 10-fold cross validation, calculate the average network loss, and end the validation when the average network loss is less than the set threshold, and record the optimal network hyperparameters of the SocNet neural network model; The training set and the validation set are mixed into a new training set, the SocNet neural network model is set using the optimal network hyperparameters, training is performed, and the model is saved; The saved model is tested using the test set, and the estimated battery capacity value is recorded to obtain the embedded domain knowledge neural network.
3. The method for estimating battery state of charge based on a neural network with embedded domain knowledge according to claim 2, characterized in that: The feature extraction module includes a convolutional neural network layer, a pooling and flattening layer, a special path and a first multi-layer perceptron module connected in sequence; wherein the first multi-layer perceptron module includes an input layer, a fully connected hidden layer with a ReLU activation function and a linear output layer.
4. The method for estimating battery state of charge based on a neural network with embedded domain knowledge according to claim 3, characterized in that: The step of inputting the battery operation data into the embedded domain knowledge neural network to estimate the battery state of charge to obtain an estimation result includes: Inputting the battery operation data into an embedded domain knowledge neural network; generating a first hidden state using a feature extraction module; Generate the second hidden state using the SOC lookback module; The first hidden state and the second hidden state are summed to obtain an estimation result.
5. The method for estimating battery state of charge based on a neural network with embedded domain knowledge according to claim 4, characterized in that: The step of generating the first hidden state by using the feature extraction module includes: Extracting spatial and temporal relationships among voltage, current, temperature, and historical SOC in the battery operation data using a convolutional neural network layer; Pool and flatten the output of the convolutional neural network layer to form a feature vector; Connect the current and time values at the current moment with the feature vector to form a new input vector; The concatenated feature vector is processed to generate the first hidden state.
6. The method for estimating battery state of charge based on a neural network with embedded domain knowledge according to claim 4, characterized in that: The method of generating the second hidden state by using the SOC lookback module includes: Save the SOC value for a period of time in the past; The SOC value is processed by a second multilayer perceptron module to obtain a second hidden state, wherein the second multilayer perceptron module includes a sequentially connected input layer, a fully connected hidden layer with a ReLU activation function, and a linear output layer.
7. A battery state of charge estimation system based on a neural network with embedded domain knowledge, characterized in that: include: A data acquisition unit, used to acquire battery operation data, wherein the battery operation data includes battery discharge terminal voltage, current, temperature data and corresponding battery capacity data; An estimation unit, used for inputting the battery operation data into an embedded domain knowledge neural network to perform battery state of charge estimation to obtain an estimation result; wherein the embedded domain knowledge neural network is obtained by inputting historical battery operation data, corresponding time values and historical SOC as a sample set into a SocNet neural network model for training, and the SocNet neural network model includes a feature extraction module with a special path, a SOC lookback module and a summation module; An output unit is used to output the estimation result.
8. The battery state of charge estimation system based on embedded domain knowledge neural network according to claim 7 is characterized in that: The estimation unit comprises: An input subunit, used for inputting the battery operation data into the embedded domain knowledge neural network; A feature extraction subunit, configured to generate a first hidden state using a feature extraction module; A look-back subunit, used for generating a second hidden state using a SOC look-back module; A summing subunit is used to sum the first hidden state and the second hidden state to obtain an estimation result.
9. The method for estimating battery state of charge based on a neural network with embedded domain knowledge according to claim 8, characterized in that: The feature extraction subunit comprises: A relationship extraction module, for extracting the spatial and temporal relationship between the voltage, current, temperature and historical SOC in the battery operation data using a convolutional neural network layer; The pooling and flattening module is used to pool and flatten the output of the convolutional neural network layer to form a feature vector; A connection module is used to connect the current and time values at the current moment with the feature vector to form a new input vector; The vector processing module is used to process the connected feature vector to generate a first hidden state.
10. The battery state of charge estimation system based on embedded domain knowledge neural network according to claim 8, characterized in that: The looking back subunit comprises: The saving module is used to save the SOC value of the past period of time; The SOC value processing module is used to process the SOC value using a second multi-layer perceptron module to obtain a second hidden state, wherein the second multi-layer perceptron module includes a sequentially connected input layer, a fully connected hidden layer with a ReLU activation function, and a linear output layer.
Citation Information
Patent Citations
Vehicle battery state-of-charge estimation method based on deep neural network
CN110488202A
Lithium ion battery state-of-charge estimation method based on deep neural network
CN112067998A
Lithium battery charge state estimation method based on graph convolution
CN113033104A
Lithium battery charge state prediction method, apparatus and device, and readable storage medium
CN114966436A
Spacecraft lithium battery health state estimation method based on physical information neural network
CN116413629A
Cited By
Battery state prediction method based on lithium manganate characteristic modeling
CN122017578A