Abnormality detection method and device for battery module

By building a digital twin model, performing fault injection and simulation operations, generating data sets and training deep neural networks, the problems of high virtual detection rates and leakage detection rates in existing battery abnormality detection methods are solved, and more accurate battery module abnormality detection is achieved.

CN119596147APending Publication Date: 2025-03-11WANBANG DIGITAL ENERGY CO LTD +1
View PDF 0 Cites 5 Cited by

Patent Information

Application Number
CN202411647537.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-18
Publication Date
2025-03-11

AI Technical Summary

Technical Problem

The existing battery abnormality detection methods have high false detection rates and leakage detection rates, and ignore the spatial relationship and interaction between the cells.

Method used

By building a digital twin model including the battery pack model and the charging system model, fault injection and simulation runs are performed, simulation run data sets are generated, and deep neural networks are trained based on this data set, and abnormal detection is performed based on the spatial relationship between the cells.

Benefits of technology

It improves the accuracy of abnormal detection of battery modules, reduces false detection rates and missed detection rates, and can capture the status of the battery system more comprehensively.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119596147A_ABST
    Figure CN119596147A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of battery detection, and particularly provides an anomaly detection method and device for a battery module, and the method comprises the steps: constructing a digital twin model which comprises a battery pack model and a charging system model; performing fault injection on the digital twin model; performing simulation operation on the digital twin model after fault injection to generate a simulation operation data set; constructing a deep neural network, and training the deep neural network based on the simulation operation data set; acquiring battery data of a to-be-detected battery module, and inputting the battery data into the trained deep neural network to obtain an output result; and judging whether the to-be-detected battery module is abnormal or not according to the simulation operation data set and the output result. Therefore, fault injection and simulation operation are carried out on the basis of the digital twinborn model, abundant training data are provided for the deep neural network, the spatial relationship between the battery cells is considered, the accuracy of anomaly detection can be improved, and the false detection rate and the omission ratio can be reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of battery detection, and in particular to a method for detecting anomalies of a battery module and a device for detecting anomalies of a battery module. Background Art

[0002] Battery modules are prone to various abnormal conditions during long-term use, such as overvoltage, overtemperature, capacity attenuation, etc. These abnormal conditions may lead to decreased battery performance and increased safety risks. Therefore, developing an efficient and accurate battery abnormality detection method is crucial to ensure the safe operation of the battery.

[0003] At present, battery anomaly detection methods can be divided into two categories. The first category is density-based anomaly detection methods, which include local outlier factors (LOF) and clustering algorithms. The other category of battery anomaly detection methods is based on statistics and machine learning. However, these anomaly detection methods still have defects, and they have high false detection rates and missed detection rates. Summary of the invention

[0004] In order to solve one of the above technical problems, the present invention proposes the following technical solution.

[0005] The first aspect of the present invention proposes a method for detecting anomalies in a battery module, comprising the following steps: constructing a digital twin model including a battery pack model and a charging system model; injecting faults into the digital twin model; simulating the digital twin model after the fault injection to generate a simulation operation data set; constructing a deep neural network, and training the deep neural network based on the simulation operation data set; obtaining battery data of a battery module to be detected, and inputting the battery data into the trained deep neural network to obtain an output result; and judging whether an abnormality occurs in the battery module to be detected based on the simulation operation data set and the output result.

[0006] In addition, the abnormality detection method of the battery module according to the above embodiment of the present invention may also have the following additional technical features.

[0007] According to one embodiment of the present invention, the expression of the battery pack model is:

[0008]

[0009] Among them, SOC is the state of charge of the battery cell; SOC0 is the state of charge of the battery cell at the initial moment; C N is the rated capacity of the battery cell; V c Indicates the working voltage across the battery cell; I cRepresents the working current of the battery cell; R0 represents the equivalent internal resistance of the battery cell; V1 and V2 represent the terminal voltages of two sets of parallel polarized resistors and capacitors; R1 and R2 represent the two polarized internal resistance values; C1 and C2 represent the two polarized capacitor values; OCV represents the open circuit voltage of the battery cell; EMF represents the equilibrium electromotive force of the battery cell; V h Indicates the cell rebound voltage, L h represents adjustable inductance, which is used to indicate the influence of historical current on hysteresis voltage, and β represents current amplification factor.

[0010] According to one embodiment of the present invention, the charging system model includes a photovoltaic charging system model and a constant current-constant voltage charger model, wherein the photovoltaic charging system model is expressed as:

[0011]

[0012] Among them, U and I represent the input voltage and current of the photovoltaic charging system respectively; I ph Represents the photocurrent, I d Represents the diode reverse saturation current, I sh represents the parallel resistance branch current, is the diode current equation, I0 is the diode reverse saturation current, A is the PN junction ideal factor, T is the absolute temperature, q is the electron charge; R s Represents the series resistance, R sh represents the parallel resistance and K represents the Boltzmann constant.

[0013] According to an embodiment of the present invention, the abnormality detection method of a battery module is characterized by further comprising:

[0014] The expression of the photovoltaic charging system model is modified, specifically including:

[0015] Simplify formula (4) to:

[0016]

[0017] Among them, I sc I represents the photocurrent when the parallel resistance branch current is ignored. sc =I ph ; B represents the simplification coefficient to be determined, C represents the parallel capacitance to be determined; U oc is the open circuit voltage; assuming that at the maximum power point U = U m , I=I m , then the model description for the battery maximum power point is:

[0018]

[0019] Among them, Im Indicates the current value at the maximum power point; U m Indicates the voltage value at the maximum power point; under normal temperature conditions Much greater than 1, we get:

[0020]

[0021] According to the open circuit voltage condition, formula (7) is rearranged and substituted into formula (5), and we get:

[0022]

[0023] The parameters in formulas (5) and (6) are modified by the following formula to make the model performance closer to the actual working conditions:

[0024]

[0025] Where T is the temperature, T ref is the temperature under standard conditions, is the temperature correction; s is the light intensity, s ref is the light intensity under standard conditions, is the light intensity correction; a, b, c are correction coefficients; U′ oc , I′ m , U′ m They are the corrected open-circuit voltage of the solar cell, the current and voltage at the maximum power point.

[0026] According to one embodiment of the present invention, the constant current-constant voltage charger model includes a charging execution module and a charging control module, wherein the charging execution module includes a controlled current source, a controlled voltage source and a relay, the controlled current source and the controlled voltage source are respectively used to complete constant current and constant voltage charging actions to the battery, the relay is used to switch the charging mode, and the charging control module is used to control the action of the relay.

[0027] According to one embodiment of the present invention, fault injection is performed on the digital twin model, including: establishing a fault mode library; selecting a fault mode from the fault mode library as needed, and injecting the selected fault mode into the digital twin model, wherein, during fault injection, the time point at which the fault occurs is set in the time dimension and / or the battery cell position where the fault occurs is set in the space dimension.

[0028] According to one embodiment of the present invention, the deep neural network includes a temporal attention network, a spatial attention network and a feature fusion network, wherein the output ends of the temporal attention network and the spatial attention network are respectively connected to the input end of the feature fusion network.

[0029] According to one embodiment of the present invention, the deep neural network also includes a one-dimensional convolutional network, a prediction network, a reconstruction network and a loss function, wherein the output end of the one-dimensional convolutional network is respectively connected to the input ends of the temporal attention network and the spatial attention network, the output end of the feature fusion network is also respectively connected to the input ends of the prediction network and the reconstruction network, the feature fusion network includes a connected fully connected layer and LSTM, the prediction network includes three stacked fully connected layers, and the reconstruction network includes a connected RNN network and a fully connected layer.

[0030] According to one embodiment of the present invention, the deep neural network is trained based on a simulation operation data set, including: preprocessing the simulation operation data set to obtain a training set and a test set; and using the training set to train the deep neural network.

[0031] According to one embodiment of the present invention, the simulation operation data set is preprocessed to obtain a training set and a test set, including: resampling the obtained simulation operation data set according to a sampling interval; dividing the resampled simulation operation data set into standby, charging and discharging data according to the battery working state; further dividing the standby, charging and discharging data into a normal data set and an abnormal data set; respectively normalizing and sliding window processing the normal data set and the abnormal data set in turn; dividing the processed normal data set into a training set, a test set and a validation set.

[0032] According to one embodiment of the present invention, judging whether an abnormality occurs in the battery module to be detected based on the simulation operation data set and the output result includes: determining the upper quartile and the lower quartile in the test set, and calculating an abnormality detection threshold accordingly; comparing the output result with the abnormality detection threshold, and judging whether an abnormality occurs in the battery module to be detected based on the comparison result.

[0033] According to one embodiment of the present invention, the anomaly detection threshold is calculated by the following formula:

[0034] Th=Q3+k(Q3-Q1) (17)

[0035] Among them, Th is the anomaly detection threshold, Q1 and Q3 represent the upper quartile and lower quartile respectively, and k represents the adjustment coefficient.

[0036] The second aspect of the present invention proposes an abnormality detection device for a battery module, comprising: a construction module, used to construct a digital twin model including a battery pack model and a charging system model; an injection module, used to inject faults into the digital twin model; a simulation module, used to simulate the digital twin model after the fault injection to generate a simulation operation data set; a training module, used to construct a deep neural network, and train the deep neural network based on the simulation operation data set; a detection module, used to obtain battery data of a battery module to be detected, and input the battery data into the trained deep neural network to obtain an output result; a judgment module, used to judge whether the battery module to be detected has an abnormality based on the simulation operation data set and the output result.

[0037] The technical solution of the embodiment of the present invention performs fault injection and simulation operation based on the digital twin model, provides rich training data for the deep neural network, takes into account the spatial relationship between battery cells, and can improve the accuracy of anomaly detection and reduce false detection rate and missed detection rate. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] Figure 1 The figure is a flow chart of a method for detecting abnormality of a battery module according to an embodiment of the present invention.

[0039] Figure 2 A schematic diagram of a second-order equivalent circuit model provided by the present invention.

[0040] Figure 3 Schematic diagram of the photovoltaic charging system model.

[0041] Figure 4 Schematic diagram of the structure of a deep neural network.

[0042] Figure 5 Schematic diagram of the multi-head attention mechanism.

[0043] Figure 6 A graph showing the relationship between multiple variables.

[0044] Figure 7 Flowchart for acquiring and preprocessing simulation run data.

[0045] Figure 8 Schematic diagram of a block diagram of a battery module abnormality detection device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0046] 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 only 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.

[0047] Existing battery anomaly detection methods based on statistics and machine learning still have defects. They ignore the spatial relationship between cells and treat each cell as an independent entity for modeling and detection. However, in actual battery systems, cells influence and interact with each other, and their abnormal behavior may cause a chain reaction in the entire system. This practice of ignoring spatial relationships limits the detection algorithm's comprehensive grasp of the entire system status, resulting in a high false detection rate and missed detection rate in actual applications of anomaly detection algorithms.

[0048] To this end, an embodiment of the present invention proposes a battery module anomaly detection method, which can fully consider the spatial relationship and interaction between battery cells in the battery module, and improve the accuracy of anomaly detection and reduce false detection rate and missed detection rate by integrating time and space information in the data.

[0049] Figure 1 The figure is a flow chart of a method for detecting abnormality of a battery module according to an embodiment of the present invention.

[0050] like Figure 1 As shown, the abnormality detection method of the battery module includes the following steps S1 to S6.

[0051] The abnormality detection method of the battery module of the embodiment of the present invention can be applied to various types of battery modules, has good versatility and feasibility, and can effectively improve the abnormality detection effect of the battery module. For example, it can be applied to lithium batteries in electric vehicles and energy storage systems.

[0052] S1, build a digital twin model including the battery pack model and the charging system model.

[0053] Specifically, the digital twin model is used to build a digital twin model of the battery module that includes subsystems such as the battery pack and the charging system. The models of each component module of the system, namely the battery pack model and the charging system model, are constructed. The coupling relationship between the systems is considered to construct a digital twin model that fully considers the spatial distribution characteristics and coupling relationship between battery cells.

[0054] S2, perform fault injection into the digital twin model.

[0055] Fault injection refers to injecting any possible fault or preset fault into the model through any feasible means, such as modifying model parameters or model results.

[0056] Specifically, based on the digital twin model constructed above, faults are injected into the digital twin model by modifying model parameters and model structure, etc. The faults meet the internal or external fault types that occur during the operation of the battery, so as to further expand the model and increase the modeling capability of the fault module. It is possible to establish a mathematical description of various degradation mechanisms of battery cells, such as capacity attenuation, internal resistance increase, thermal runaway, etc., simulate the coupled propagation of heat and current between the cells inside the battery pack, and describe the diffusion and propagation process of the fault.

[0057] By injecting faults into the digital twin model, it is possible to accurately and fully simulate various operating conditions, faults, and internal and external characteristics of the battery cells in actual battery application scenarios.

[0058] S3, simulate the digital twin model after fault injection to obtain a simulation operation data set.

[0059] Specifically, the digital twin model with injected fault is simulated and run, that is, the model is simulated and run in fault mode to simulate the system operation status when the actual fault occurs, and a simulation operation data set is generated to prepare data for subsequent network training and result detection.

[0060] S4, builds a deep neural network and trains the deep neural network based on the simulation operation data set.

[0061] Specifically, a deep neural network based on the graph attention mechanism can be constructed according to the internal data types and characteristics of the battery, which can better meet the abnormality detection needs of the battery module. The simulation run data set is preprocessed and used to train the deep neural network to improve the generalization of the network. The trained deep neural network is used for abnormality detection of the battery module.

[0062] S5, obtaining battery data of the battery module to be tested, and inputting the battery data into the trained deep neural network to obtain an output result.

[0063] S6, judging whether an abnormality occurs in the battery module to be detected according to the simulation operation data set and the output result.

[0064] Specifically, the battery data of the battery module to be detected is collected in real time, input into the trained deep neural network, and the output result is obtained. The abnormal threshold is determined according to the simulation operation data set, and the output result is compared with the abnormal detection threshold to determine whether the battery module to be detected is abnormal. If the output result exceeds the threshold, it means that the battery module to be detected is abnormal, and a corresponding alarm is issued or necessary measures are taken to deal with it.

[0065] The embodiment of the present invention constructs a digital twin model including a battery pack model and a charging system model through digital twin technology, and performs fault injection based on the model to achieve flexible working condition setting and fault injection, simulate multiple abnormal modes in application scenarios, and provide training data for deep neural networks. The deep neural network fully considers the correlation and interaction between the internal characteristic data of the battery, and uses the graph attention network to improve the accuracy of anomaly detection.

[0066] Compared with related technologies, it not only fully considers the spatial distribution characteristics and coupling relationships between battery cells, but also can inject various faults and perform simulation operations. The simulation operation data set is used to train the deep neural network, which improves the detection accuracy of the network and thus improves the accuracy of anomaly detection.

[0067] Therefore, the abnormality detection method of the battery module of the embodiment of the present invention performs fault injection and simulation operation based on the digital twin model, provides rich training data for the deep neural network, takes into account the spatial relationship between battery cells, and can improve the accuracy of abnormality detection and reduce the false detection rate and missed detection rate.

[0068] In one embodiment of the present invention, the charging system model includes a photovoltaic charging system model and a constant current-constant voltage charger model.

[0069] In one example, a constant current-constant voltage charger model includes a charging execution module and a charging control module, wherein the charging execution module includes a controlled current source, a controlled voltage source and a relay, the controlled current source and the controlled voltage source are respectively used to complete constant current and constant voltage charging actions to the battery, the relay is used to switch the charging mode, and the charging control module is used to control the relay action.

[0070] The following uses the energy storage battery pack as an example to build a digital twin model of the battery pack model and the charging system model.

[0071] Step S1 is to construct a digital twin model including a battery pack model and a charging system model, including the following sub-steps:

[0072] Sub-step 1.1: Use a second-order circuit model to mathematically model it, and use actual battery cell operation data for calibration to establish a battery pack model to describe the changes in SOC, voltage, and current of the battery during the charging and discharging process.

[0073] The battery SOC is described using the ampere-hour integration method:

[0074]

[0075] Among them, SOC is the state of charge of the battery cell, SOC0 is the state of charge of the battery cell at the initial moment, C N is the rated capacity of the battery cell.

[0076] The voltage across the cell is described by a second-order equivalent circuit. Its open-circuit voltage is determined by the equilibrium potential voltage and the rebound voltage. The actual output voltage of the cell is simulated by a second-order equivalent circuit that regards the open-circuit voltage as a voltage source. Figure 2 shown.

[0077] In order to describe the dynamic characteristics of the battery cell, its open circuit voltage, equivalent internal resistance, and RC value need to be calculated. The battery model is relatively simple and easy to build using MATLAB / Simulink. Based on circuit theorems and laws, the model equation is described as shown below.

[0078]

[0079] Among them, V c Indicates the working voltage across the cell, I c represents the working current of the battery cell, R0 represents the equivalent internal resistance of the battery cell, V1 and V2 represent the terminal voltages of two sets of parallel polarized resistors and capacitors, R1 and R2 represent the two polarized internal resistance values, C1 and C2 represent the two polarized capacitor values, OCV represents the open circuit voltage of the battery cell, EMF represents the equilibrium electromotive force of the battery cell, V h Indicates the cell rebound voltage, L h represents adjustable inductance, which is used to indicate the influence of historical current on hysteresis voltage, and β represents current amplification factor.

[0080] The above completes the mathematical description of the dynamic characteristics of the battery. The mathematical model takes the battery operating current as input, and the battery operating voltage and state of charge as output. The model is confirmed by setting the battery equivalent internal resistance, open circuit voltage and RC parameters.

[0081] Sub-step 1.2: For the energy storage lithium batteries in the energy storage power station, the energy storage lithium battery pack is the smallest unit of the power storage part in the energy storage power station, and is usually composed of several battery cells in a series-parallel topology. Due to the characteristics of large capacity, high current tolerance, and poor cell consistency of energy storage lithium batteries, the cells in the battery pack in the simulation model are connected in series. An energy storage battery pack is composed of ten energy storage lithium batteries with a capacity of 280Ah connected in series, and each battery cell is equipped with a voltage sensor and a passive balancing circuit. The input content of the simulation circuit model of the energy storage lithium battery pack is as follows:

[0082] (1) Cell SOC: represents the initial state of charge (%) of different cells in the battery pack. It is assumed that the initial SOC of each cell is the same.

[0083] (2) Balancing resistor value: indicates the passive balancing resistor value of each battery cell in the battery pack, in ohms (Ω).

[0084] The model output is as follows:

[0085] (1) Battery pack SOC: It indicates the equivalent state of charge of the battery pack, which is the average SOC value of each battery cell (%).

[0086] (2) Battery pack operating voltage: represents the voltage across the battery pack during the simulation process, in volts (V).

[0087] (3) Battery pack operating current: refers to the current flowing through the battery pack during the simulation process. Charging is positive and discharging is negative. The unit is ampere (A).

[0088] Sub-step 1.3: Photovoltaic charging system model and parameter setting.

[0089] Photovoltaic power generation is the process of converting photovoltaics into electrical energy using the photoelectric effect. Under light, the semiconductor material in the photovoltaic cell absorbs photons, causing electrons to jump from the valence band to the conduction band, forming electron-hole pairs, which are separated under the action of the electric field, thereby forming current and generating electrical energy.

[0090] In the process of building the photovoltaic charging system model, we mainly focus on the output voltage-current relationship and power curve of the photovoltaic charging system, and realize the output power control of the photovoltaic charging system by stabilizing the output voltage. Figure 3 shown.

[0091] The descriptive equation of the model is as follows:

[0092]

[0093] Rearranging formula (3) yields:

[0094]

[0095] Among them, U and I represent the input voltage and current of the photovoltaic charging system respectively; I ph Represents the photocurrent, I d Represents the diode reverse saturation current, I sh represents the parallel resistance branch current, is the diode current equation, I0 is the diode reverse saturation current, A is the PN junction ideality factor, T is the absolute temperature, and q is the electron charge 1.6×10 -19 C; R s Represents the series resistance, R sh represents the parallel resistance, K represents the Boltzmann constant 1.38×10 -23 J / K.

[0096] In one embodiment, the battery module abnormality detection method further includes modifying the expression of the photovoltaic charging system model, specifically including:

[0097] The above formula (4) can be simplified as follows:

[0098]

[0099] Among them, I sc I represents the photocurrent when the parallel resistance branch current is ignored. sc =I ph ; B represents the simplification coefficient to be determined, C represents the parallel capacitance to be determined; U oc is the open circuit voltage; assuming that at the maximum power point U = U m , I=I m , then the model description for the battery maximum power point is:

[0100]

[0101] Among them, I m Indicates the current value at the maximum power point; U m Indicates the voltage value at the maximum power point; under normal temperature conditions, it can be considered is much greater than 1, we can conclude that:

[0102]

[0103] According to the open circuit voltage condition, formula (7) is rearranged and substituted into formula (5), and we get:

[0104]

[0105] The parameters in formulas (5) and (6) are modified by the following formula to make the model performance closer to the actual working conditions:

[0106]

[0107] Where T is the temperature, T ref is the temperature under standard conditions, is the temperature correction; s is the light intensity, the unit is W / m 2 ,s ref is the light intensity under standard conditions, taking 1000W / m 2 , is the light intensity correction value, in W / m 2 ; a, b, c are correction coefficients; U′ oc , I′ m , U′ m They are the corrected open-circuit voltage of the solar cell, the current and voltage at the maximum power point.

[0108] Sub-step 1.4: The constant current-constant voltage charger model integrates the constant current charger and the constant voltage charger and their control models, which can be used to simulate the charging conditions and perform performance tests on the battery cells. The energy storage battery pack in the simulation model can be composed of ten energy storage lithium battery cells with a capacity of 280Ah connected in series, and its constant current charging current is set to 80A, that is, the charging rate is 0.29C. It has been experimentally measured that the energy storage battery pack enters the end of the charging voltage platform area when the working voltage is about 40V and the state of charge is about 88%, so the voltage threshold is selected as 40V, that is, when the voltage at both ends of the energy storage lithium battery pack reaches 40V in the charging state, the constant current charging is stopped immediately, and the charging mode is switched to charge the battery pack at a constant voltage of 40V. When the charging current is less than 0.56A, the charging is stopped to complete a charging experiment.

[0109] The constant current-constant voltage charger (simulation) model is mainly divided into two parts:

[0110] (1) Charging execution module: The charging execution module is mainly composed of a controlled current source, a controlled voltage source and a relay. The controlled source completes the constant current and constant voltage charging action to the battery, and the relay is responsible for the conversion of the charging mode;

[0111] (2) Charging control module: The charging control module is built based on the Stateflow module in Simulink. The module determines the current charging status by collecting information such as the charging current, charging voltage, and SOC of the battery pack during the charging process. When the voltage threshold and current threshold are reached, the module outputs a relay control signal to control the relay action, thereby realizing the conversion of the charging mode and stopping charging.

[0112] In one embodiment, step S2, i.e., injecting faults into the digital twin model, includes: establishing a fault mode library; selecting a fault mode from the fault mode library as needed, and injecting the selected fault mode into the digital twin model, wherein, during fault injection, the time point at which the fault occurs is set in the time dimension and / or the battery cell position at which the fault occurs is set in the space dimension.

[0113] Specifically, a fault injection system is built. Based on the previously constructed digital twin model of the battery module, the model is further expanded to increase the modeling capability of the fault module, establish a mathematical description of various degradation mechanisms of battery cells, such as capacity attenuation, internal resistance increase, thermal runaway, etc., simulate the coupled propagation of heat and current between the cells inside the battery pack, and describe the diffusion and propagation process of the fault. It mainly consists of the following sub-steps:

[0114] Sub-step 2.1: Establishment of fault mode library: Build a fault mode library based on various possible fault modes of the battery system, such as single cell failure, thermal runaway, abnormal charging and discharging, etc. Each fault mode corresponds to corresponding parameter settings, such as fault occurrence time, fault severity, etc. The fault mode library covers various single faults and compound faults.

[0115] Sub-step 2.2: Fault injection method design: Write a fault injection module that can select a specific fault mode from the fault mode library; inject the selected fault mode into the corresponding subsystem of the digital twin model by modifying model parameters, changing the model structure, etc., to simulate the fault occurrence process; fault injection can set the time point of the fault occurrence in the time dimension and determine the location of the battery cell where the fault occurs in the spatial dimension.

[0116] The digital twin model after fault injection is simulated and run. For various fault modes, a large number of simulation run data sets including abnormal conditions are generated by running the digital twin model simulation under the fault mode, providing support for the subsequent deep neural network training.

[0117] In one embodiment, Figure 4 As shown, the deep neural network includes a temporal attention network, a spatial attention network and a feature fusion network, wherein the output ends of the temporal attention network and the spatial attention network are respectively connected to the input end of the feature fusion network.

[0118] Further, refer to Figure 4 The deep neural network also includes a one-dimensional convolutional network, a prediction network, a reconstruction network and a loss function, wherein the output end of the one-dimensional convolutional network is respectively connected to the input end of the temporal attention network and the spatial attention network, the output end of the feature fusion network is also respectively connected to the input end of the prediction network and the reconstruction network, the feature fusion network includes a connected fully connected layer and LSTM, the prediction network includes three stacked fully connected layers, and the reconstruction network includes a connected RNN network and a fully connected layer.

[0119] Specifically, first, one-dimensional convolution is used to extract features in the short time period of the data. Next, the spatiotemporal attention mechanism is used to extract temporal and spatial features. The spatiotemporal features are fused through the fully connected layer and the LSTM network. Finally, the fused features are sent to the prediction network and the reconstruction network respectively, and the anomaly score can be obtained by comparing the reconstruction error and the prediction error. This structure makes full use of spatiotemporal information, and performs effective feature extraction and learning through the attention mechanism and the fusion network, including the following sub-steps:

[0120] Sub-step 4.1: Design a one-dimensional convolutional network with the same number of convolutional layers as the input data feature dimension, 760, a convolution sum size of 3*3, and a stride of 1. After this step, the input data dimension becomes (b, 40, 758), where b represents the batch size.

[0121] Sub-step 4.2: Design a temporal attention network and use a multi-head self-attention mechanism to calculate attention in the temporal dimension. The multi-head attention mechanism is as follows Figure 5 As shown ( Figure 5 FC represents a fully connected layer (Fully Connected layer), and the specific calculation formula is:

[0122]

[0123] Among them, head i represents the output of the i-th attention head, Q i represents the query vector of the ith attention head, K i represents the key vector of the i-th attention head, V i Represents the value vector of the i-th attention head, Attention(Q i ,K i ,V i ) represents the attention output of the i-th attention head; represents the attention weight of the i-th attention head, d k is the value vector V i The dimension of , T represents the matrix transposition operation MultiHead(Q,K,V) represents the set of outputs of the attention head, Concat(head1,...,head s ) represents the concatenation of the outputs of all attention heads, W O is the linear transformation weight matrix to be learned, z is the input vector, W i Q , W i K and W i V are the weight matrices to be learned, and the superscripts are labeled weight matrices corresponding to the query vector, key vector, and value vector, respectively, and have no operational meaning.

[0124] Sub-step 4.3: Design a spatial attention network, in order to capture the spatial characteristics between multiple input variables and the relationship between multiple variables. The multivariate time series is designed as a complete graph, where each node represents a variable and each edge represents the relationship between two corresponding features. In this way, the relationship between adjacent nodes can be captured by the graph attention network. Figure 6 is a graph of the relationships among multiple variables. Figure 6 In SOCi , U i , T i Respectively represent the state of charge SOC, output voltage and surface temperature of the i-th battery in the battery module. Then the graph attention network is used to capture the correlation between each variable, and the calculation method is as follows:

[0125] e(v j ,v j′ )=a T LeakyReLU(W[v j ||v j′ ]) (11)

[0126]

[0127] ν j =(SOC j ,U j ,T j )

[0128] Among them, e(v j ,v j′ ) is the attention coefficient between a pair of adjacent nodes, v j and v j′ represents two adjacent nodes, a is a learnable weight vector, T represents a matrix transpose operation, W is a learnable feature transformation matrix, LeakyReLU(W(v j ||v j′ )) The similarity is calculated using the LeakyReLU (·) activation function, α jj′ Represents the adjacent node v j and v j′ The attention score of the adjacent node v j′ For node v j The importance of softma(xe(v j v, j′ )) represents the adjacent node v j and v j′ The attention coefficient is calculated using the softmax() activation function, N(v j ) represents node v j The set of neighbor nodes, v j =(SOC j ,U j ,T j ) represents the composition of the node vector, SOC j is the state-of-charge element of the cell contained in the jth node, U j Indicates the cell terminal voltage data contained in the jth node, T j Represents the cell temperature data contained in the jth node.

[0129] Sub-step 4.4: Design a feature fusion network. The feature fusion network consists of a fully connected layer and LSTM to further integrate temporal attention representation and other features.

[0130] Sub-step 4.5: Design a prediction network to predict the value at the next time point. The present invention stacks three fully connected layers after the LSTM layer.

[0131] Sub-step 4.6: Design a reconstruction network for generating a reconstruction of the observed data from the latent representation space. The present invention designs an RNN network and a fully connected layer after the LSTM layer.

[0132] Sub-step 4.7: Design a loss function to measure the performance of the reconstruction model and guide the training of the model. For the reconstruction model, the reconstruction error is used as the loss function, and the mean squared error (MSE) is used as the loss function to measure the difference between the reconstructed data and the original observed data.

[0133] Given the original observation data x and the reconstructed data x recon , MSE loss function L r It can be expressed as:

[0134]

[0135] Where N is the total number of samples of observed data, x n is the nth sample of the observed data, is the corresponding reconstruction data.

[0136] For the prediction model, the prediction error is used as the loss function L p :

[0137]

[0138] Among them, y n is the nth label of the predicted data, is the corresponding predicted data.

[0139] The error and anomaly score L of the entire model can be expressed as:

[0140] L=L r +L p (14)

[0141] In one embodiment, the training of the deep neural network based on the simulation operation data set in step S3 may include: preprocessing the simulation operation data set to obtain a training set and a test set; and training the deep neural network using the training set.

[0142] Furthermore, the simulation operation data set is preprocessed to obtain a training set and a test set, including: resampling the obtained simulation operation data set according to a sampling interval; dividing the resampled simulation operation data set into standby, charging and discharging data according to the battery working state; further dividing the standby, charging and discharging data into a normal data set and an abnormal data set; normalizing and sliding window processing are performed on the normal data set and the abnormal data set respectively; and dividing the processed normal data set into a training set, a test set and a validation set.

[0143] Specifically, before training, Figure 7 As shown in the figure, the simulation run data set is preprocessed through the following sub-steps:

[0144] Sub-step 4.8: Obtain simulation data set: Obtain sensor data of each battery cell from the battery pack model, including information such as voltage, current, and SOC. This data can be obtained through the sensor model in the system.

[0145] Sub-step 4.9: Resampling: Select an appropriate sampling interval, resample the acquired data, balance the distribution of samples in time, and obtain a new sample set. The sampling interval can be 5s.

[0146] Sub-step 4.10: Working condition division: divide the data into standby, charging and discharging data according to the battery working status.

[0147] Sub-step 4.11: Fault classification: The data is divided into an abnormal data set and a normal data set according to whether the battery module fails.

[0148] Sub-step 4.12: Perform maximum and minimum normalization on the divided data. The maximum and minimum normalization method can eliminate the scale data differences and help the algorithm better learn the relationship between features. The formula is shown in (15):

[0149]

[0150] Among them, x and x′ are the input data before and after normalization respectively; x min and x max are the minimum and maximum values ​​in the data before normalization.

[0151] Sub-step 4.13: Process the normalized data through a sliding time window as input data for the subsequent neural network. The format of the processed input data X and label value Y is as shown in the formula.

[0152]

[0153] Among them, x′ mis the normalized data at time m, w1 is the length of the time window, X′ m , Y m ′ are the input and predicted labels of the neural network at time m, and the input value is the normalized data [x′ m ,x′ m+1 ,...,x′ m+w1 ], the predicted value is the first data x′ after the time window m+w1+1 .

[0154] Sub-step 4.14: Divide the normal data into training set, test set and validation set in a ratio of 8:1:1.

[0155] After the above preprocessing, the dimension of each input data is (w1, f), where w1 is the length of the time window and f is the dimension of the feature at each moment. In the present invention, w1 and f are 40 and 760 respectively.

[0156] In one embodiment, step S5, i.e., judging whether an abnormality occurs in the battery module to be detected based on the simulation operation data set and the output result, may include: determining the upper quartile and the lower quartile in the test set, and calculating the abnormality detection threshold accordingly; comparing the output result with the abnormality detection threshold, and judging whether an abnormality occurs in the battery module to be detected based on the comparison result.

[0157] Furthermore, the anomaly detection threshold is calculated by the following formula:

[0158] Th=Q3+k(Q3-Q1) (17)

[0159] Among them, Th is the anomaly detection threshold, Q1 and Q3 represent the upper quartile and lower quartile respectively, and k represents the adjustment coefficient.

[0160] Different values ​​can be set for k to adjust the accuracy of anomaly detection. It can be set to 3. When the anomaly score in the anomaly step 2 is greater than Th, it is considered an anomaly.

[0161] Finally, the battery module abnormality is judged by inputting the real-time collected battery data into the trained neural network model, and the output result of the network is compared with the threshold to judge whether the battery module is abnormal. If the output result exceeds the threshold, a corresponding alarm is issued or necessary measures are taken to deal with it.

[0162] Through the specific implementation of the above steps, the present invention can effectively detect abnormal conditions of the battery module and provide accurate abnormal warning and processing measures, thereby improving the safety and reliability of the battery module.

[0163] In summary, the embodiment of the present invention proposes a battery module anomaly detection method based on a battery module digital twin and a deep neural network that integrates spatiotemporal information. First, a battery module digital twin model including subsystems such as battery cells, battery packs, and charging systems is constructed, which fully considers the spatial distribution characteristics and coupling relationships between battery cells. On this basis, a deep neural network anomaly detection model that integrates temporal and spatial information is designed. Combined with the self-attention mechanism and the graph attention network, it can fully extract the spatiotemporal characteristics of the battery cells inside the battery module during detection. In order to train and optimize this deep neural network model, a large amount of training data containing various types of fault conditions is generated using the digital twin model. In practical applications, the monitoring data is input into the trained deep neural network, the network automatically extracts temporal and spatial features, and the output result is compared with the preset threshold to determine whether the battery module is abnormal. Compared with the existing methods, this method can better utilize the internal spatiotemporal information of the battery module and improve the accuracy and reliability of anomaly detection.

[0164] Corresponding to the battery module abnormality detection method of the above embodiment, the present invention further provides a battery module abnormality detection device.

[0165] Figure 8 Schematic diagram of a block diagram of a battery module abnormality detection device according to an embodiment of the present invention.

[0166] like Figure 8 As shown, the abnormality detection device of the battery module includes a construction module 10, an injection module 20, a simulation module 30, a training module 40, a detection module 50 and a judgment module 60.

[0167] Among them, the construction module 10 is used to construct a digital twin model including a battery pack model and a charging system model; the injection module 20 is used to inject faults into the digital twin model; the simulation module 30 is used to simulate the digital twin model after fault injection to generate a simulation operation data set; the training module 40 is used to construct a deep neural network and train the deep neural network based on the simulation operation data set; the detection module 50 is used to obtain the battery data of the battery module to be detected, and input it into the trained deep neural network to obtain the output result; the judgment module 60 is used to judge whether the battery module to be detected is abnormal based on the simulation operation data set and the output result.

[0168] It should be noted that the specific implementation of the abnormality detection device for the battery module can refer to the specific implementation of the abnormality detection method for the battery module mentioned above, and to avoid redundancy, it will not be described in detail here.

[0169] The abnormality detection device for the battery module of the embodiment of the present invention performs fault injection and simulation operation based on the digital twin model, provides rich training data for the deep neural network, takes into account the spatial relationship between battery cells, and can improve the accuracy of abnormality detection and reduce the false detection rate and missed detection rate.

[0170] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. 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 invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Although the embodiments of the present invention have been shown and described above, it can be understood that the above embodiments are exemplary and cannot be construed as limitations on the present invention, and those of ordinary skill in the art can change, modify, replace and modify the above embodiments within the scope of the present invention.

Claims

1. A method for detecting abnormality of a battery module, characterized in that: The following steps are involved: Build a digital twin model including the battery pack model and the charging system model; Performing fault injection on the digital twin model; Perform simulation operation on the digital twin model after fault injection to generate a simulation operation data set; Constructing a deep neural network, and training the deep neural network based on the simulation operation data set; Obtain battery data of the battery module to be tested, and input it into the trained deep neural network to obtain output results; Whether an abnormality occurs in the battery module to be detected is determined according to the simulation operation data set and the output result.

2. The abnormality detection method of a battery module according to claim 1, characterized in that: The expression of the battery pack model is: Among them, SOC is the state of charge of the battery cell; SOC0 is the state of charge of the battery cell at the initial moment; C N is the rated capacity of the battery cell; V c Indicates the working voltage across the battery cell; I c Represents the working current of the battery cell; R0 represents the equivalent internal resistance of the battery cell; V1 and V2 represent the terminal voltages of two sets of parallel polarized resistors and capacitors; R1 and R2 represent the two polarized internal resistance values; C1 and C2 represent the two polarized capacitor values; OCV represents the open circuit voltage of the battery cell; EMF represents the equilibrium electromotive force of the battery cell; V h Indicates the cell rebound voltage, L h represents adjustable inductance, which is used to indicate the influence of historical current on hysteresis voltage, and β represents current amplification factor.

3. The abnormality detection method of a battery module according to claim 1, characterized in that: The charging system model includes a photovoltaic charging system model and a constant current-constant voltage charger model, wherein the expression of the photovoltaic charging system model is: Among them, U and I represent the input voltage and current of the photovoltaic charging system respectively; I ph Represents the photocurrent, I d Represents the diode reverse saturation current, I sh represents the parallel resistance branch current, is the diode current equation, I0 is the diode reverse saturation current, A is the PN junction ideal factor, T is the absolute temperature, q is the electron charge; R s Represents the series resistance, R sh represents the parallel resistance and K represents the Boltzmann constant.

4. The abnormality detection method of the battery module according to claim 3, characterized in that: Also includes: The expression of the photovoltaic charging system model is modified, specifically including: Simplify formula (4) to: Among them, I sc I represents the photocurrent when the parallel resistance branch current is ignored. sc =I ph ; B represents the simplification coefficient to be determined, C represents the parallel capacitance to be determined; U oc is the open circuit voltage; assuming that at the maximum power point U = U m , I=I m , then the model description for the battery maximum power point is: Among them, I m Indicates the current value at the maximum power point; U m Indicates the voltage value at the maximum power point; under normal temperature conditions Much greater than 1, we get: According to the open circuit voltage condition, formula (7) is rearranged and substituted into formula (5), and we get: The parameters in formulas (5) and (6) are modified by the following formula to make the model performance closer to the actual working conditions: Where T is the temperature, T ref is the temperature under standard conditions, is the temperature correction; s is the light intensity, s ref is the light intensity under standard conditions, is the light intensity correction; a, b, c are correction coefficients; U′ oc , I′ m , U′ m They are the corrected open-circuit voltage of the solar cell, the current and voltage at the maximum power point.

5. The abnormality detection method of a battery module according to claim 3, characterized in that: The constant current-constant voltage charger model includes a charging execution module and a charging control module, wherein the charging execution module includes a controlled current source, a controlled voltage source and a relay, the controlled current source and the controlled voltage source are respectively used to complete constant current and constant voltage charging actions to the battery, the relay is used to switch the charging mode, and the charging control module is used to control the action of the relay.

6. The abnormality detection method of a battery module according to claim 1, characterized in that: Performing fault injection on the digital twin model, including: Establish a failure mode library; A fault mode is selected from the fault mode library as needed, and the selected fault mode is injected into the digital twin model, wherein, during fault injection, the time point at which the fault occurs is set in the time dimension and / or the battery cell position at which the fault occurs is set in the space dimension.

7. The abnormality detection method of a battery module according to claim 1, characterized in that: The deep neural network includes a temporal attention network, a spatial attention network and a feature fusion network, wherein the output ends of the temporal attention network and the spatial attention network are respectively connected to the input end of the feature fusion network.

8. The abnormality detection method of a battery module according to claim 7, characterized in that: The deep neural network also includes a one-dimensional convolutional network, a prediction network, a reconstruction network and a loss function, wherein the output end of the one-dimensional convolutional network is respectively connected to the input ends of the temporal attention network and the spatial attention network, the output end of the feature fusion network is also respectively connected to the input ends of the prediction network and the reconstruction network, the feature fusion network includes a connected fully connected layer and LSTM, the prediction network includes three stacked fully connected layers, and the reconstruction network includes a connected RNN network and a fully connected layer.

9. The abnormality detection method of a battery module according to claim 1, characterized in that: The deep neural network is trained based on the simulation operation data set, including: Preprocessing the simulation run data set to obtain a training set and a test set; The deep neural network is trained using the training set.

10. The abnormality detection method of a battery module according to claim 9, characterized in that: Preprocessing the simulation run data set to obtain a training set and a test set includes: Resampling the obtained simulation run data set according to the sampling interval; The resampled simulation run data set is divided into standby, charging and discharging data according to the battery working status; The standby, charging and discharging data are further divided into normal data sets and abnormal data sets; The normal data set and the abnormal data set are normalized and processed by sliding windows respectively; The processed normal data set is divided into training set, test set and validation set.

11. The abnormality detection method of a battery module according to claim 9, characterized in that: Judging whether the battery module to be detected is abnormal according to the simulation operation data set and the output result includes: Determine the upper quartile and the lower quartile in the test set and calculate the anomaly detection threshold accordingly; The output result is compared with the abnormality detection threshold, and whether the battery module to be detected is abnormal is determined according to the comparison result.

12. The abnormality detection method of a battery module according to claim 11, characterized in that: The anomaly detection threshold is calculated by the following formula: Th=Q3+k(Q3-Q1) (17) Among them, Th is the anomaly detection threshold, Q1 and Q3 represent the upper quartile and lower quartile respectively, and k represents the adjustment coefficient.

13. A battery module abnormality detection device, characterized in that: include: A building module for building a digital twin model including a battery pack model and a charging system model; An injection module, used to inject faults into the digital twin model; A simulation module is used to simulate the digital twin model after fault injection to generate a simulation operation data set; A training module, used for constructing a deep neural network and training the deep neural network based on the simulation operation data set; The detection module is used to obtain the battery data of the battery module to be detected and input it into the trained deep neural network to obtain the output result; A judgment module is used to judge whether an abnormality occurs in the battery module to be detected according to the simulation operation data set and the output result.

Citation Information

Cited By

  • Energy consumption prediction and energy-saving control method adopting deep neural network

    CN120406136A

  • Battery pack thermal runaway protection method and system

    CN120754484A

  • A battery pack thermal runaway protection method and system

    CN120754484B

  • Fault diagnosis method, device and equipment for flight control system of unmanned aerial vehicle and storage medium

    CN121115718A

  • Power battery online safety detection system, method and equipment based on digital twinning and medium

    CN121432217A