A machine learning-based electric vehicle battery thermal runaway prediction method and system
Patent Information
- Application Number
- CN202611108207.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-24
- Publication Date
- 2026-10-16
- Estimated Expiration
- 2046-07-24
AI Technical Summary
传统的拓扑图多基于电池包内部固定的物理空间位置进行构建,无法准确表征单体电芯在不同充放电阶段以及不同热分布状态下动态变化的真实关联关系
[0015]采用上述技术方案的发明,具有如下优点:
Smart Images

Figure CN122613206B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of electric vehicle power battery safety monitoring technology, specifically to a method and system for predicting thermal runaway of electric vehicle batteries based on machine learning. Background Technology
[0002] With the widespread adoption of electric vehicles, the safe operation of power batteries has become a core concern in the industry. Battery thermal runaway can lead to vehicle safety accidents, making early prediction before thermal runaway occurs crucial for engineering applications. Existing data-driven methods often directly utilize raw operational data such as voltage, current, and temperature collected by the battery management system to build predictive models. However, during actual vehicle operation, battery conditions are affected by vehicle acceleration, regenerative braking, and ambient temperature fluctuations. These voltage fluctuations caused by conventional load changes mask subtle anomalies resulting from latent faults such as early internal short circuits, making early feature extraction difficult.
[0003] When detecting anomalies in the correlation between individual battery cells, existing technologies typically construct spatial topology graph networks for feature extraction. Traditional topology graphs are mostly constructed based on fixed physical locations within the battery pack, failing to accurately represent the dynamic and real-world correlations between individual cells under different charging and discharging stages and thermal distribution states. Furthermore, most existing prediction models rely on supervised learning paradigms, requiring a large amount of data with precise fault labels for network training. Due to the high cost and scarcity of real thermal runaway fault data, models face a data bottleneck, struggling to obtain sufficient samples for network training. In addition, existing anomaly detection mechanisms generally employ pre-set fixed thresholds, ignoring individual differences and aging evolution across different vehicles throughout their lifecycle. This static approach cannot adapt to complex real-world operating environments, easily leading to false alarms or missed alarms during the prediction phase. Consequently, the reliability and generalization ability of existing warning systems under complex real-world conditions fail to meet the requirements of automotive safety applications. Summary of the Invention
[0004] To address the shortcomings of existing technologies, this invention proposes a machine learning-based method and system for predicting thermal runaway in electric vehicle batteries, thereby solving the aforementioned technical problems.
[0005] Firstly, a machine learning-based method for predicting thermal runaway in electric vehicle batteries is provided, including: Collect multi-dimensional operational data of each individual battery cell, including actual measured voltage, charging and discharging current and surface temperature, and perform sliding time window segmentation on the multi-dimensional operational data to form time window data blocks; The time window data block is input into the equivalent circuit model to calculate the theoretical expected voltage of each individual cell within the corresponding time window, and an electrothermal residual sequence is generated based on the difference between the actual measured voltage and the theoretical expected voltage. Based on the correlation between the electrothermal residual sequences of each individual cell, a dynamic topological spatiotemporal graph corresponding to the current time window is constructed. The correlation is characterized by the correlation coefficient and / or difference cosine similarity between the electrothermal residual sequences. Perform data augmentation processing on the dynamic topology spatiotemporal graph to generate a first data augmentation view and a second data augmentation view; The first data augmentation view and the second data augmentation view are used as samples to perform comparative learning training on the input feature encoder to obtain the feature extraction network; Under real-time vehicle operating conditions, a real-time dynamic topology spatiotemporal graph is constructed based on the real-time electrothermal residual sequence, and the real-time dynamic topology spatiotemporal graph is input into the feature extraction network to obtain the feature vector corresponding to the recent time window to construct the recent feature distribution. Calculate the distribution distance metric between the recent characteristic distribution and the baseline characteristic distribution, and execute a thermal runaway early warning action based on the comparison result between the distribution distance metric and the early warning threshold.
[0006] In a preferred embodiment of the present invention, the step of inputting the time window data block into the equivalent circuit model, calculating the theoretical expected voltage of each individual cell within the corresponding time window, and generating an electrothermal residual sequence based on the difference between the actual measured voltage and the theoretical expected voltage includes: obtaining the current state of charge and surface temperature of the individual cell, reading the corresponding theoretical reference parameters from a multidimensional parameter lookup table; calculating the theoretical expected voltage based on the trunk line charging and discharging current or the individual cell equivalent input current, combined with the polarization voltage obtained by discretely solving the ordinary differential equation and the theoretical reference parameters; performing a differential operation between the actual measured voltage and the theoretical expected voltage at the same sampling time to obtain a single-point residual value, and splicing the single-point residual values in chronological order to form the electrothermal residual sequence of the corresponding individual cell. This process constructs a response reference under normal operating conditions using an equivalent circuit model, and performs differential calculations between the actual collected data and the calculated reference, which can filter out conventional terminal voltage fluctuations caused by load changes such as vehicle acceleration and regenerative braking, and improve the signal-to-noise ratio of early signs of thermal runaway such as small internal short circuits.
[0007] Furthermore, the construction of the dynamic topological spatiotemporal graph corresponding to the current time window based on the correlation between the electrothermal residual sequences of each individual battery cell includes: calculating the Pearson correlation coefficient of the electrothermal residual sequences of each individual battery cell within the current time window; performing adjacent sampling point difference on the electrothermal residual sequences of each individual battery cell to obtain the residual change rate vector, and calculating the first-order time difference cosine similarity of the residual change rate vectors between individual battery cells; weighting and fusing the Pearson correlation coefficient and the first-order time difference cosine similarity to calculate the initial edge weights; performing nonnegation processing on the initial edge weights and adding self-connection weights at the diagonal positions before normalization to obtain a normalized dynamic adjacency matrix; and constructing the dynamic topological spatiotemporal graph by combining the normalized dynamic adjacency matrix with the node feature matrix composed of the electrothermal residual sequences. The above steps combine the statistical correlation of the electrothermal residual in the overall amplitude evolution with the consistency in the direction of local short-term changes. They can adaptively generate a graph network adjacency structure that reflects the current real physical state within each time window, thus solving the problem that fixed-position topology is difficult to represent dynamic evolution states.
[0008] Furthermore, the data augmentation process performed on the dynamic topological spatiotemporal graph to generate a first data augmented view and a second data augmented view includes the following steps for generating the first data augmented view: introducing a time offset limited to a preset time window length on the time axis; performing time-dimension offset sampling on the original electrothermal residual sequence to obtain a time-offset residual sequence; using the time-offset residual sequence as new feature input for graph nodes, while keeping the normalized dynamic adjacency matrix of the dynamic topological spatiotemporal graph unchanged, to construct the first data augmented view. This operation introduces a local translation in the time dimension, providing homogeneous feature inputs with temporal phase differences for subsequent network models.
[0009] Furthermore, the step of performing data augmentation processing on the dynamic topology spatiotemporal graph to generate a first data augmented view and a second data augmented view also includes the step of generating the second data augmented view: extracting the physical parameter vectors called by the equivalent circuit model within the current time window, and statistically analyzing the covariance matrix of the physical parameter vectors under the current state of charge and temperature range; introducing a random perturbation vector that follows a multivariate normal distribution with zero vector as the mean and the covariance matrix or the modified covariance matrix as the covariance, performing numerical perturbation on the physical parameter vector based on physical parameter boundary constraints, and generating a perturbed physical parameter vector; substituting the perturbed physical parameter vector into the equivalent circuit model to calculate a new theoretical expected voltage, generating an accompanying residual sequence, and using the accompanying residual sequence as node features and combining it with the normalized dynamic adjacency matrix of the dynamic topology spatiotemporal graph to construct the second data augmented view. This step combines the covariance statistical characteristics of normal vehicle aging or parameter fluctuations to apply reasonable perturbations to the underlying circuit parameters within the allowable physical constraints, generating enhanced samples with actual physical meaning. This avoids the problem of adding noise to pure numerical values and destroying the inherent regularity of the residual sequence.
[0010] Furthermore, the step of using the first and second data augmented views as samples to perform comparative learning training on the input feature encoder to obtain the feature extraction network includes: inputting the first and second data augmented views into the feature encoder containing graph convolutional network layers and gated recurrent unit layers, and outputting a first global latent space feature vector and a second global latent space feature vector after forward propagation and pooling processing, respectively; using the first and second global latent space feature vectors from the same time window data block as positive sample pairs, and global latent space feature vectors from different time window data blocks as negative sample pairs; calculating the contrastive loss function values of the positive and negative sample pairs within the same training batch, and iteratively optimizing the network parameters of the feature encoder through gradient descent. This processing mechanism constructs an unsupervised contrastive learning framework, minimizing the feature distance between views that are from the same source but have undergone different dimensional augmentation processing, and maximizing the feature distance between views from different sources, enabling the network to learn the essential laws and spatiotemporal topological representations of normal operating data without fault labels.
[0011] Furthermore, the step of constructing a real-time dynamic topology spatiotemporal graph based on the real-time electrothermal residual sequence under real-time vehicle operating conditions, and inputting the real-time dynamic topology spatiotemporal graph into the feature extraction network to obtain feature vectors corresponding to recent time windows to construct a recent feature distribution includes: calling the feature extraction network that has completed training and frozen weight parameters during vehicle operation; constructing a real-time dynamic topology spatiotemporal graph based on the real-time electrothermal residual sequence, inputting it into the feature extraction network to obtain the latent spatial feature vectors corresponding to the current time window; and extracting the set of latent spatial feature vectors obtained within the most recent consecutive time windows to construct the recent feature distribution.
[0012] Furthermore, the warning threshold is a dynamic warning threshold. Before executing the thermal runaway warning action, a step of generating the dynamic warning threshold is included. The dynamic warning threshold is used to compare with the distribution distance metric. The step of generating the dynamic warning threshold includes: calculating the distribution distance metric sequence between the characteristic distribution under historical normal conditions and the baseline characteristic distribution using p-Wasserstein distance; selecting a preset high quantile in the distribution distance metric sequence as the tail start threshold; calculating the exceedance amount of distance samples greater than the tail start threshold, fitting the exceedance amount using a generalized Pareto distribution, and calculating the corresponding exceedance quantile value according to a preset confidence level; and using the sum of the tail start threshold and the exceedance quantile value as the dynamic warning threshold. The tail extreme value distribution of the distribution distance metric under normal conditions is modeled using extreme value theory, enabling the generated warning threshold to adaptively adjust according to individual differences and health status of different vehicles.
[0013] Furthermore, the step of calculating the distribution distance metric between the recent feature distribution and the baseline feature distribution, and executing a thermal runaway early warning action based on the comparison result between the distribution distance metric and the dynamic early warning threshold, includes: approximating the joint distribution transfer matrix using an iterative algorithm with an entropy regularization term; calculating the real-time p-Wasserstein distance between the recent feature distribution and the baseline feature distribution as the real-time distribution distance metric; comparing the real-time distribution distance metric with the corresponding dynamic early warning threshold; and if the real-time distribution distance metric exceeds the dynamic early warning threshold for a number of consecutive time steps that reach a preset early warning confirmation window length, then triggering a thermal runaway early warning signal.
[0014] Secondly, a machine learning-based electric vehicle battery thermal runaway prediction system is provided, including: The data acquisition module is used to collect multi-dimensional operating data of each individual battery cell, including actual measured voltage, charging and discharging current and surface temperature, and to perform sliding time window segmentation on the multi-dimensional operating data to form time window data blocks; The data preprocessing module, connected to the data acquisition module, is used to input the time window data block into the equivalent circuit model, calculate the theoretical expected voltage of each individual cell within the corresponding time window, and generate an electrothermal residual sequence based on the difference between the actual measured voltage and the theoretical expected voltage. The model training module, connected to the data preprocessing module, is used to construct a dynamic topological spatiotemporal graph corresponding to the current time window based on the correlation between the electrothermal residual sequences of each individual battery cell; the correlation is characterized by the correlation coefficient and / or difference cosine similarity between the electrothermal residual sequences; data augmentation processing is performed on the dynamic topological spatiotemporal graph to generate a first data augmented view and a second data augmented view; the first data augmented view and the second data augmented view are used as samples to perform comparative learning training on the input feature encoder to obtain a feature extraction network; The online prediction module is connected to the data preprocessing module and the model training module, respectively. It is used to construct a real-time dynamic topology spatiotemporal graph based on the real-time electrothermal residual sequence under real-time vehicle operating conditions, and call the feature extraction network to process the real-time dynamic topology spatiotemporal graph to obtain the feature vector corresponding to the recent time window to construct the recent feature distribution; calculate the distribution distance metric between the recent feature distribution and the baseline feature distribution, and execute thermal runaway early warning action based on the comparison result between the distribution distance metric and the early warning threshold.
[0015] The invention employing the above technical solution has the following advantages: 1. This invention extracts the electrothermal residual sequence by introducing an equivalent circuit model, which filters out the drastic voltage fluctuations caused by normal vehicle driving conditions and improves the signal-to-noise ratio for characterizing small deviations in early latent faults inside battery cells.
[0016] 2. This invention combines the overall change trend with the local difference direction to calculate the node edge weights of the graph, thereby realizing the dynamic adaptive construction of the battery topology. This enables the model to capture the spatiotemporal correlation characteristics of the battery pack that change with the charging and discharging behavior and the evolution of heat distribution.
[0017] 3. This invention constructs a dual-branch data augmentation view based on time-dimensional offset sampling and physical parameter boundary constraint numerical perturbation. Combined with a self-supervised contrastive learning network, it can extract deep-level state representations from massive amounts of normal operation data without relying on manually labeled fault labels, thus solving the training bottleneck problem caused by the scarcity of thermal runaway data.
[0018] 4. In the online prediction stage of this invention, a statistical distribution distance calculation mechanism is introduced, and the tail data of the normal state is fitted with a generalized Pareto distribution based on the extreme value theory to generate a dynamic warning threshold that conforms to the individual state of the vehicle, thereby reducing the probability of misjudgment and missed detection in the thermal runaway prediction system. Attached Figure Description
[0019] To more clearly illustrate the specific embodiments of the present invention, the accompanying drawings used in the specific embodiments will be briefly described below. In all the drawings, the elements or parts are not necessarily drawn to scale.
[0020] Figure 1 This is a schematic diagram of the architecture of the machine learning-based electric vehicle battery thermal runaway prediction system of the present invention. Figure 2 This is a schematic diagram illustrating the self-supervised model training and thermal runaway early warning principle of the present invention; Figure 3 This is a flowchart illustrating the machine learning-based method for predicting thermal runaway in electric vehicle batteries according to the present invention. Figure 4 This is a schematic diagram illustrating the data acquisition and time-series sequence segmentation principle in step S100 of the present invention. Figure 5 This is a schematic diagram of the construction principle of the electrothermal residual sequence based on the equivalent circuit in step S200 of the present invention; Figure 6 This is a schematic diagram illustrating the principle of constructing the dynamic topological spatiotemporal graph in step S300 of the present invention. Figure 7 This is a schematic diagram for generating the data augmentation view in step S400 of the present invention; Figure 8 This is a schematic diagram of the training principle of the self-supervised spatiotemporal graph comparison network in step S500 of the present invention; Figure 9 This is a schematic diagram illustrating the principle of online prediction of thermal runaway based on manifold spatial distribution measure in step S600 of the present invention.
[0021] Figure label: 10. Data acquisition module; 20. Data preprocessing module; 30. Model training module; 31. Data augmentation unit; 32. Feature encoder; 33. Contrastive loss calculation unit; 40. Online prediction module. Detailed Implementation
[0022] The embodiments of the technical solution of the present invention will now be described in detail with reference to the accompanying drawings. These embodiments are merely illustrative of the technical solution of the present invention and are therefore intended to limit the scope of protection of the present invention.
[0023] like Figure 1 As shown, a machine learning-based electric vehicle battery thermal runaway prediction system is provided, including a data acquisition module 10, a data preprocessing module 20, a model training module 30, and an online prediction module 40.
[0024] The data acquisition module 10 is connected to the vehicle battery management system and is used to collect multi-dimensional operating data of each individual battery cell at a preset sampling frequency during vehicle operation. The multi-dimensional operating data includes the actual measured voltage, mains charging and discharging current, and surface temperature.
[0025] The data acquisition module 10 is also used to divide the continuously acquired multidimensional running data into time windows according to the set sliding window length and sliding step size, forming multiple sets of time window data blocks.
[0026] The data preprocessing module 20 is connected to the data acquisition module 10 and is configured with an equivalent circuit model.
[0027] The data preprocessing module 20 calculates the theoretical expected voltage of the corresponding individual cell based on the trunk line charging and discharging current and the surface temperature of the individual cell in the time window data block, and in combination with the state of charge of the corresponding individual cell, through an equivalent circuit model.
[0028] The data preprocessing module 20 calculates the difference between the actual measured voltage and the theoretical expected voltage to obtain the electrothermal residual sequence of the corresponding single cell, and uses the electrothermal residual sequence as input data for subsequent model training and online prediction.
[0029] like Figure 2 As shown, the model training module 30 has a built-in self-supervised neural network model. The model training module 30 includes a data augmentation unit 31, a feature encoder 32, and a contrastive loss calculation unit 33.
[0030] The data enhancement unit 31 is used to receive the dynamic topology spatiotemporal graph; the dynamic topology spatiotemporal graph is composed of the electrothermal residual sequence and the corresponding normalized dynamic adjacency matrix.
[0031] The data augmentation unit 31 performs data augmentation processing on the dynamic topology spatiotemporal graph to generate a first data augmentation view and a second data augmentation view from data blocks in the same time window.
[0032] The first data augmented view can be generated through time dimension offset operations, and the second data augmented view can be generated through operations based on physical parameter boundary perturbations.
[0033] The feature encoder 32 is configured as a neural network structure formed by cascading graph convolutional network layers and gated recurrent unit layers.
[0034] The feature encoder 32 is used to receive the first data augmentation view and the second data augmentation view, and aggregates the spatial topological features between individual cells through the graph convolutional network layer, and extracts the temporal evolution features of the operating state of individual cells through the gated recurrent unit layer.
[0035] After the above processing, the feature encoder 32 outputs the dimensionality-reduced latent space feature vector.
[0036] The contrastive loss calculation unit 33 is used to construct the contrastive learning loss function. The contrastive loss calculation unit 33 receives the latent space feature vector output by the feature encoder 32, calculates the feature similarity of positive sample pairs within the same time window and the feature similarity of negative sample pairs within the different time windows, and updates the network weight parameters of the feature encoder 32 using the backpropagation algorithm based on the calculation results.
[0037] The online prediction module 40 is connected to the data preprocessing module 20 and the model training module 30.
[0038] During the actual operation of the vehicle, the online prediction module 40 calls the feature encoder 32 after completing self-supervised training to process the real-time electrothermal residual sequence, and constructs a dynamic topological spatiotemporal graph corresponding to the current time window based on the real-time electrothermal residual sequence to generate a real-time latent space feature vector.
[0039] The online prediction module 40 constructs a recent feature distribution based on the real-time latent space feature vector and calculates the Wasserstein distance between the recent feature distribution and the long historical baseline feature distribution.
[0040] The online prediction module 40 is also equipped with a dynamic early warning threshold generation mechanism based on extreme value theory; when the Wasserstein distance exceeds the dynamic early warning threshold and the preset triggering conditions are met, the online prediction module 40 outputs an early warning signal for battery thermal runaway.
[0041] like Figure 3 As shown, this invention provides a machine learning-based method for predicting thermal runaway in electric vehicle batteries. This method can be executed by the aforementioned machine learning-based electric vehicle battery thermal runaway prediction system, and specifically includes the following steps: Step S100: Collect multi-dimensional operating data of each individual cell in the battery pack, and perform sliding time window segmentation on the multi-dimensional operating data to form multiple sets of time window data blocks.
[0042] Step S200: Input the time window data block into the equivalent circuit model, calculate the theoretical expected voltage of each individual cell within the corresponding time window, and generate an electrothermal residual sequence based on the difference between the actual measured voltage and the theoretical expected voltage.
[0043] Step S300: Based on the electrothermal residual sequence of each individual cell, calculate the Pearson correlation coefficient and the first-order time difference cosine similarity between individual cells, and adaptively update the adjacency matrix weights of the graph network according to the calculation results to construct a dynamic topological spatiotemporal graph.
[0044] Step S400: Perform random time dimension offset sampling and numerical perturbation based on physical parameter boundary constraints on the dynamic topology spatiotemporal graph to generate a first data augmentation view and a second data augmentation view for comparison network training.
[0045] In step S500, the first data augmentation view and the second data augmentation view are input into the feature encoder 32 to obtain the corresponding latent space feature vectors, and the contrastive loss function value within the same training batch is calculated.
[0046] The feature encoder 32 includes graph convolutional network layers and gated recurrent unit layers, forming a feature extraction network for self-supervised training.
[0047] The model training module 30 iteratively optimizes the network parameters of the feature encoder 32 through gradient descent to obtain a feature extraction network that has completed self-supervised training.
[0048] Step S600: Obtain the recent feature distribution under the real-time operating conditions of the vehicle, and calculate the distribution distance metric between the recent feature distribution and the baseline feature distribution.
[0049] The online prediction module 40 determines whether the distribution distance metric has continuously reached the preset trigger condition based on the dynamic early warning threshold at the individual cell level or battery pack level; when the distribution distance metric reaches the preset trigger condition, it executes the thermal runaway early warning action.
[0050] like Figure 4 As shown, in a specific embodiment of the present invention, in step S100, the data acquisition module 10 acquires the underlying battery operating condition data during vehicle operation, and performs sliding time window segmentation on the continuously acquired data to form a fixed-dimensional time window data block that can be processed by subsequent equivalent circuit analysis and neural network model.
[0051] Step S100 specifically includes the following steps: Step S101: The data acquisition module 10 acquires multi-dimensional operating data of each individual battery cell.
[0052] The data acquisition module 10 communicates with the vehicle battery management system and acquires battery operation data through the vehicle's underlying voltage sampling channel, current sampling channel, and temperature sampling channel.
[0053] At any discrete time point Data acquisition module 10 acquires the first data from the battery pack. Actual measured voltage of individual battery cells Surface temperature And the charging and discharging current of the mains flowing through the battery pack. .
[0054] in, This is the physical location number of a single battery cell, ranging from 1 to M, where M represents the total number of single battery cells in the battery pack.
[0055] Actual measured voltage Surface temperature and trunk line charging and discharging current Together constitute the first Individual battery cells at discrete time points Multidimensional operational data.
[0056] In this embodiment, a single cell can be a single cell in a series branch, or it can be an equivalent single unit composed of several parallel cells.
[0057] When the battery pack has parallel branches, the data acquisition module 10 or the data preprocessing module 20 calculates the main line charging and discharging current based on the branch current sampling value, the equivalent impedance of the parallel unit, or the current sharing estimation result provided by the battery management system. This is converted into the equivalent input current of the corresponding single cell or equivalent single unit, so that the current input of the subsequent equivalent circuit model is consistent with the object being analyzed.
[0058] In step S102, the data acquisition module 10 performs sliding time window segmentation on the continuously acquired multidimensional running data.
[0059] After acquiring continuous multidimensional operational data, the data acquisition module 10 processes the data according to a preset time window length. and sliding step size Extract data along the time axis. The time window length is specified. Indicates the number of discrete sampling points contained in a single time window data block; sliding step size. This indicates the interval between the starting positions of two adjacent time windows.
[0060] Let the sampling period of the continuous acquisition process be . Then the first The set of time steps covered by a time window data block can be represented as: ;in, For the first The starting sampling time of each time window data block on the global time axis.
[0061] In the Within the first time window data block, the data acquisition module 10 will... The actual measured voltage, surface temperature, and corresponding current input of each individual battery cell are arranged in chronological order to form a discrete sequence of data of fixed length.
[0062] The data acquisition module 10 performs the same time window segmentation process on each individual cell, so that the data collected under different running lengths and different operating conditions are organized into time window data blocks with a unified time dimension.
[0063] After format alignment is completed, the data acquisition module 10 outputs multiple sets of time window data blocks to the data preprocessing module 20 as input data for subsequent calculation of the theoretical expected voltage.
[0064] like Figure 5 As shown, in one specific embodiment of the present invention, the data preprocessing module 20 receives the time window data block output by the data acquisition module 10 and performs equivalent circuit residual construction processing on the time window data block. During vehicle operation, driving acceleration, braking energy recovery, and changes in ambient temperature will all cause normal fluctuations in the terminal voltage and surface temperature of individual battery cells; the amplitude of such fluctuations is usually higher than the voltage drift caused by the early stage of a small internal short circuit. If the original voltage sequence is directly input into the subsequent feature extraction network, the weak fault features are easily covered by the conventional load response.
[0065] To this end, the data preprocessing module 20 incorporates a Thevenin equivalent circuit model and calculates the theoretical terminal voltage of a normal cell under the same operating conditions based on the current state of charge, temperature, and current. Subsequently, the actual measured terminal voltage is differentiated from the theoretically expected voltage to obtain the electrothermal residual sequence after stripping the dynamic response of the conventional load. The electrothermal residual sequence referred to here is a time series primarily composed of the temperature-compensated equivalent circuit voltage residual, in which surface temperature participates in model parameter indexing and dynamic correction.
[0066] Step S200 specifically includes the following steps: Step S201: The data preprocessing module 20 obtains the core physical parameters of the current single cell.
[0067] The parameters of the equivalent circuit model vary with the state of charge and temperature of the individual battery cell. For discrete sampling times... The next For each individual battery cell, the data preprocessing module 20 obtains its state of charge. and surface temperature .
[0068] Among them, the state of charge It can be obtained by the ampere-hour integration method, the extended Kalman filter method, or a combination of the two; this state of charge estimation process is a routine process in the field of battery management, and this embodiment is not limited to a specific estimation algorithm.
[0069] The data preprocessing module 20 pre-stores a multi-dimensional parameter lookup table. This multi-dimensional parameter lookup table is obtained through single-cell calibration experiments under normal aging conditions, and the calibration experiments may include hybrid power pulse capability characteristic testing. The multi-dimensional parameter lookup table is at least based on the state of charge. and surface temperature Store open-circuit voltage as the index dimension. Ohmic internal resistance Polarization internal resistance and polarization capacitors .
[0070] At the current sampling time Data preprocessing module 20 and As the input index, the corresponding theoretical benchmark parameters are read from the multidimensional parameter lookup table using linear interpolation, bilinear interpolation, or multidimensional interpolation methods. , , and .when or When the value falls between adjacent grid points in the calibration table, the interpolation result is used as the current parameter; when it exceeds the calibration boundary, a boundary limit value or a preset safety parameter value can be used to avoid interruption of model calculation.
[0071] During continuous vehicle operation, the data preprocessing module 20 can also perform online correction on the theoretical reference parameters read from the multidimensional parameter lookup table based on recursive least squares, extended Kalman filtering, or other conventional parameter identification algorithms, and use the corrected parameters as the calculation parameters for the equivalent circuit model within the current time window. When online correction is not enabled, the data preprocessing module 20 directly uses the theoretical reference parameters output from the multidimensional parameter lookup table.
[0072] Step S202: The data preprocessing module 20 calculates the theoretical expected voltage of a single battery cell.
[0073] The theoretical expected voltage represents the terminal voltage that a fault-free individual cell should exhibit under its current state of charge, temperature, and external current. The data preprocessing module 20 will process the trunk line charging and discharging current. Alternatively, based on the battery pack series-parallel topology and the equivalent input current of a single cell obtained from sensor polarity conversion, this can be introduced into the Kirchhoff voltage equation of the Thevenin equivalent circuit. For ease of description, the above-mentioned trunk line charging and discharging current or single cell equivalent input current will be uniformly referred to as... .
[0074] No. Each individual cell at the sampling time Theoretical expected voltage Calculate according to the following formula: ; in, For the first Each individual cell at the sampling time The theoretical expected voltage; This is the open-circuit voltage corresponding to the current state of charge. The current internal resistance of the ohm; This represents the current polarization voltage.
[0075] polarization voltage This is used to characterize the dynamic voltage hysteresis caused by concentration polarization and electrochemical polarization within a single battery cell. The polarization voltage satisfies the following first-order linear ordinary differential equation: ; in, For polarization internal resistance, It is a polarizing capacitor.
[0076] Data preprocessing module 20 according to sampling interval The above ordinary differential equations are solved by discretization. Using Euler discretization, the recursive formula for the polarization voltage is: ; When the current time window is not the first time the window is calculated, The initial value inherits the polarization voltage calculation value from the end of the previous time window; when the current time window is the first calculation window after the vehicle is first powered on, It can be initialized to 0, or initialized to the initial polarization voltage estimated based on the difference between the resting voltage and the open-circuit voltage. The data preprocessing module 20 recursively obtains the values at each sampling time in chronological order. Then, substituting into the terminal voltage equation, we obtain the corresponding theoretical expected voltage. .
[0077] In step S203, the data preprocessing module 20 generates an electrothermal residual sequence.
[0078] Data preprocessing module 20 at the same sampling time Read the first Actual measured terminal voltage of a single battery cell and compared with the theoretical expected voltage obtained in step S202 Perform the difference operation to obtain the single-point residual value at that sampling time. : ; The single-point residual value This indicates the deviation of the actual terminal voltage from the predicted value of the normal equivalent circuit. Because... It already includes current state of charge, temperature, current surge, ohmic voltage drop, and polarization voltage hysteresis. It can mitigate the large voltage fluctuations caused by normal operating conditions such as acceleration and regenerative braking to a certain extent, allowing subsequent characteristic encoders to focus more on the slow voltage drift that may occur in the early stages of a small internal short circuit.
[0079] In containing Within a time window of 1 sampling point, let the continuous sampling time be 1 / 2. The data preprocessing module 20 concatenates the residual values of each single point in chronological order to form the first... Electrothermal residual sequence vector of individual battery cells : ; The data preprocessing module 20 performs the above calculations on each individual cell within the battery pack to obtain the corresponding electrothermal residual sequence for each individual cell. After completing the residual construction for all individual cells, the data preprocessing module 20 outputs the electrothermal residual sequence to subsequent modules for network topology feature extraction and anomaly identification.
[0080] like Figure 6 As shown, in a specific embodiment of the present invention, the model training module 30 receives the electrothermal residual sequence output by the data preprocessing module 20, and constructs a dynamic topological spatiotemporal diagram corresponding to the current time window based on the correlation and change trend between the residual sequences of each individual cell.
[0081] In actual battery packs, individual cells not only have physical adjacency relationships, but may also exhibit cross-spatial correlations due to bus connections, thermal diffusion paths, sampling link consistency, and series-parallel electrical coupling. If graph network edge weights are set solely based on the geometric distance or fixed arrangement of individual cells, dynamic correlations formed during residual evolution are easily overlooked. Therefore, the model training module 30 does not use a fixed adjacency matrix, but instead adaptively generates an adjacency matrix within each time window based on the statistical correlation and temporal consistency of the electrothermal residual sequence.
[0082] Step S300 specifically includes the following steps: Step S301: The model training module 30 defines the node attributes of the topological spatiotemporal graph.
[0083] Model training module 30 constructs a spatiotemporal graph network to characterize the state correlations of individual cells within a battery pack, denoted as... .in, Represents a set of nodes. Let the set of edges be denoted as . Let the battery pack contain a total of . For each individual battery cell, the node set is... Includes Each graph node corresponds to a single battery cell.
[0084] For the The graph node, the model training module 30 will output the first node from the data preprocessing module 20. Individual cell thermal residual sequence vector This serves as the input feature for that node. If the current time window contains... If there are 10 sampling points, then the node features can be represented as: ; Therefore, the node characteristics of all individual cells within the current time window can form a feature matrix. , among which, the The row corresponds to the first The electrothermal residual sequence of individual battery cells.
[0085] Step S302: The model training module 30 calculates the Pearson correlation coefficient between graph nodes.
[0086] For the set of nodes Any two graph nodes and The model training module 30 extracts the corresponding electrothermal residual sequence vector. and And calculate the Pearson correlation coefficient between the two within the current time window. The Pearson correlation coefficient can be calculated using the following formula: ; in, Represents the electrothermal residual sequence and Covariance between and They represent and The standard deviation.
[0087] In a specific calculation method, if and They represent and The mean within the current time window, then It can be written as: ; The Pearson correlation coefficient is used to characterize the overall degree of synchronization between two individual battery cells deviating from the normal baseline within the current time window. To avoid the denominator being zero due to a constant sequence, when... =0 or When =0, the model training module 30 will Set to 0.
[0088] In step S303, the model training module 30 extracts the first-order time difference of the electrothermal residual sequence and calculates the cosine similarity of the first-order time difference vector.
[0089] Model training module: 30 pairs of electrothermal residual sequences Perform differential sampling on adjacent sampling points to obtain the residual rate of change vector of the i-th individual cell. To facilitate engineering implementation, the model training module 30 uses discrete difference approximation of the first-order time derivative. For The rate of change of the residuals can be expressed as: ; in, The sampling period is the time interval between adjacent sampling points.
[0090] In this embodiment, It can be represented as: ; Alternatively, during implementation, the first sampling point can be padded using forward differencing or by copying adjacent differencing values, thus... and Maintain the same dimensions.
[0091] For graph nodes and The model training module 30 calculates the first-order difference vector between the two. and Cosine similarity between : ; in, This represents the dot product of two difference vectors. and Let L2 norms of the corresponding difference vectors be denoted as . This is a preset non-zero minimum constant used to avoid a denominator of zero. In this embodiment, Set to 10 -8 .
[0092] Cosine similarity is used to measure the consistency of the rising or falling direction of the residuals of two individual battery cells over a short time scale. When the overall magnitude correlation of the two residual sequences is not obvious, but their local change directions are synchronized, this index can still provide supplementary information for the edge weights.
[0093] Step S304: The model training module 30 fuses correlation features and rate of change features to update the dynamic adjacency matrix.
[0094] Model training module 30 uses the Pearson correlation coefficient obtained in step S302. Similarity with the first-order time difference cosine obtained in step S303 Perform fusion and compute graph nodes. With graph nodes Initial edge weights between : ; in, and is a weighting coefficient used to adjust the proportion of overall relevance and consistency of local changes in topology construction. and The values of are all in the range [0,1], and satisfy . In this embodiment, and All are set to 0.5; in other implementations, the value can be set to 0.5 if the condition is met. Under the given conditions, the values of both are determined through the validation set.
[0095] Considering that both the Pearson correlation coefficient and cosine similarity may be negative, and that the adjacency matrix in this embodiment is used to represent the non-negative connection strength between nodes, the model training module 30 performs non-negativity processing on the initial edge weights to obtain non-negative edge weights. : ; for In this situation, the model training module 30 can first... Set the value to 0, and then uniformly add self-joins before subsequent normalization; alternatively, retain the node's own correlation and merge it with the self-join weights. To ensure consistency in the matrix normalization process, this implementation method preferably adopts the former approach, i.e., first set the value to 0. =0, then add the identity matrix.
[0096] Subsequently, the model training module 30 trains the non-negative adjacency matrix. Add self-connect weights to the diagonal positions to obtain .in, for An identity matrix of order 30. Model training module 30 is based on... Construct the degree matrix degree matrix The diagonal elements satisfy: ; Model training module 30 further... Perform symmetric normalization to obtain the normalized dynamic adjacency matrix. : ; In one alternative implementation, to reduce the storage and computational burden on the edge computing device, the model training module 30 can also... Perform sparsity reduction. Specifically, for each graph node... Only retain the one with the largest edge weight. The edges corresponding to each of the adjacent nodes are set, and the weights of the remaining edges are reset to 0. Among these, In this embodiment, the value is a positive integer less than the total number of individual battery cells M. Set to 5. If the subsequent graph convolutional network uses an undirected graph structure, the model training module 30 performs symmetry processing on the adjacency matrix after sparsification, for example, by... Updated to Alternatively, retain the larger value among the bidirectional edge weights.
[0097] Through the above processing, the model training module 30 can form a dynamic topology that matches the current residual evolution state within each time window. For individual cells with similar residual deviation trends and consistent change directions, the corresponding edge weights in the adjacency matrix are higher; for individual cells with no obvious correlation in residual changes, the corresponding edge weights are lower or sparsified to zero.
[0098] Model training module 30 will normalize the adjacency matrix This is used as dynamic topological information for the current time window, and it is combined with the node feature matrix. They are used together as input to subsequent graph convolutional networks so that the graph convolutional networks can aggregate the correlation features between individual battery cells in the spatial dimension.
[0099] like Figure 7 As shown, in a specific embodiment of the present invention, in step S400, the model training module 30 performs data augmentation processing on the dynamic topological spatiotemporal graph through the data augmentation unit 31 to generate two sets of augmented views for self-supervised comparative training.
[0100] The two sets of augmented views originate from the same time window data block, but differ in their temporal and physical parameter perturbation methods. Therefore, the model training module 30 can construct positive sample pairs for comparative learning without relying on thermal runaway fault labels.
[0101] Step S400 specifically includes the following steps: In step S401, the data augmentation unit 31 generates a first data augmentation view.
[0102] Data augmentation unit 31 augments the original dynamic topology spatiotemporal graph Apply a random time dimension offset sampling operation.
[0103] Specifically, the data augmentation unit 31 introduces a time offset on the time axis. And targeting the electrothermal residual sequence vector in the original node features. Resampling is performed to obtain the time-shifted residual sequence. Among them, time offset This represents the sampling offset applied along the time axis, and its value is limited to a preset fractional multiple of the time window length. For example, You can select from the following range: ; in, The time window length, This indicates the floor function.
[0104] When the time offset corresponds to a non-integer sampling time, the data augmentation unit 31 obtains the residual value at the corresponding time through linear interpolation.
[0105] Sampling positions that exceed the original time window range after time offset can be filled in from adjacent historical sampling points or subsequent sampling points acquired consecutively. When adjacent sampling points cannot be obtained, boundary value copying, mirror filling, or linear interpolation can be used to fill in the gaps, ensuring that the generated first data augmentation view still has a length of [missing information]. The node feature sequence.
[0106] Data augmentation unit 31 uses the residual sequence after time offset As new feature inputs for graph nodes, while maintaining the normalized dynamic adjacency matrix corresponding to the current time window. Without changing, the first data augmentation view is constructed. .
[0107] In step S402, the data augmentation unit 31 extracts the covariance matrix of the core physical parameters.
[0108] Data augmentation unit 31 extracts the core physical parameters obtained by calling or online correction of the equivalent circuit model within the current time window.
[0109] In this embodiment, the data enhancement unit 31 will... The ohmic internal resistance of a single battery cell and polarization capacitor Combined into a physical parameter vector Its expression is as follows: ; Data augmentation unit 31 statistically analyzes the covariance matrix of physical parameter vectors under the current state of charge and temperature range based on parameter identification records accumulated during the vehicle's historical normal operation cycle. .
[0110] When the statistically obtained covariance matrix When the positive definiteness requirement is not met, the data augmentation unit 31 adds a preset minimum regularization term to its diagonal position to obtain a corrected covariance matrix, so that it meets the numerical calculation requirements of multivariate normal sampling.
[0111] For example, it can be corrected as follows: ; in, To preset a very small positive number, It is the identity matrix. In this embodiment, Set to 10 -6 .
[0112] In step S403, data augmentation unit 31 calculates the perturbation vector constrained by the physical boundary.
[0113] Data augmentation unit 31 introduces random perturbation vectors Random perturbation vector It follows a multivariate normal distribution with mean zero, and its covariance matrix is... ;when After regularization, its covariance matrix is the corrected one. .
[0114] When the modified covariance matrix is used, its distribution can be expressed as: ; Data augmentation unit 31 combines the original physical parameter vector Generate the perturbed physical parameter vector : ; in, The perturbation intensity hyperparameter has a value range of (0,1). In this embodiment, the perturbation intensity hyperparameter... Set it to 0.1.
[0115] In one implementation, the data enhancement unit 31 can also enhance the perturbed physical parameter vector based on preset physical boundaries of the ohmic internal resistance and polarization capacitance. The parameters are trimmed so that the perturbed parameters remain within the allowable range for the corresponding individual cell under normal operating conditions.
[0116] The preset physical boundary is determined based on the minimum and maximum values of the parameters corresponding to the current state of charge and temperature range in the multidimensional parameter lookup table. When the perturbed physical parameter is less than the corresponding minimum value, the physical parameter is set to the minimum value; when the perturbed physical parameter is greater than the corresponding maximum value, the physical parameter is set to the maximum value.
[0117] In step S404, the data augmentation unit 31 generates a second data augmentation view.
[0118] Data augmentation unit 31 will perturb the physical parameter vector The parameters in the model are replaced with the corresponding parameters in the equivalent circuit model, and the replaced parameters are substituted into the Kirchhoff voltage equation and polarization voltage calculation process of the equivalent circuit model.
[0119] Subsequently, data augmentation unit 31, following the same differential calculation process as in step S200, calculates a new theoretical expected voltage using the perturbed ohmic resistance and polarization capacitance, and subtracts the theoretical expected voltage from the actual measured voltage to generate the associated residual sequence corresponding to the current time window. .
[0120] Data augmentation unit 31 will accompany the residual sequence As the second set of node features, combined with the normalized dynamic adjacency matrix corresponding to the current time window. To build and form a second data augmentation view .
[0121] First data augmentation view Second data augmentation view All data originate from the same time window data block and share the normalized dynamic adjacency matrix corresponding to that time window. .
[0122] Data augmentation unit 31 will construct the first data augmentation view. Second data augmentation view The parallel output is sent to feature encoder 32 to perform subsequent network forward propagation.
[0123] like Figure 8 As shown, in a specific embodiment of the present invention, in step S500, the model training module 30 uses a contrastive learning mechanism to perform self-supervised training on the feature encoder 32.
[0124] The model training module 30 uses two sets of data augmented views from the same time window data block as positive sample pairs and data augmented views from different time window data blocks as negative sample pairs, and updates the network weight parameters of the feature encoder 32 by using a contrastive loss function.
[0125] Step S500 specifically includes the following steps: Step S501: The model training module 30 determines the network structure of the feature encoder 32.
[0126] The feature encoder 32 is configured as a neural network structure formed by cascading graph convolutional network layers and gated recurrent unit layers.
[0127] For the battery pack Individual battery cell and time window length The node feature matrix received by the feature encoder 32 can be represented as: ,in, Indicates the first The node feature matrix corresponds to each time window data block, and each row in the matrix corresponds to the electrothermal residual sequence of a single battery cell.
[0128] The convolutional network layer receives the feature matrix of the node. and the normalized dynamic adjacency matrix generated in step S300 We perform weighted aggregation on the residual features of a single battery cell and the residual features of its associated cells to obtain intermediate features that contain spatial topological association information.
[0129] Specifically, for the first The first time window At each sampling time, the model training module 30 extracts the electrothermal residual values of all M individual cells at that sampling time, forming the corresponding sampling time node features, and utilizes the normalized dynamic adjacency matrix corresponding to the current time window. Perform graph convolution processing on the node features at the sampling time to obtain the spatial topological features corresponding to that sampling time.
[0130] Subsequently, the gated recurrent unit layer receives intermediate features and extracts their temporal dependencies that change along the time step. The model training module 30, according to the order of sampling times, assembles the spatial topological features corresponding to each sampling time within the current time window into a temporal feature sequence, and inputs the temporal feature sequence into the gated recurrent unit layer.
[0131] After processing by graph convolutional network layers and gated recurrent unit layers, the feature encoder 32 outputs a node-level latent space feature matrix. Its dimension can be represented as ,in, The hidden layer feature dimension is preset. In this embodiment, the feature encoder 32 includes two graph convolutional network layers and one gated recurrent unit layer. The output feature dimension of the graph convolutional network layer and the hidden state dimension of the gated recurrent unit layer are both set to 64.
[0132] To accommodate the window-level similarity calculation of the subsequent contrastive loss function, the feature encoder uses 32 pairs of node-level latent space feature matrices. Perform pooling to obtain the global latent space feature vector corresponding to the current time window. In this embodiment, average pooling is used; in other embodiments, max pooling or attention-weighted pooling may also be used.
[0133] In step S502, the feature encoder 32 performs a forward propagation of the enhanced view.
[0134] During the model training phase, the model training module 30 selects data blocks from time windows during the vehicle's historical operation that do not exhibit thermal runaway alarms, over-temperature fault codes, over-voltage fault codes, or under-voltage fault codes, and whose current, temperature, and state of charge are within the allowable operating range, as normal training samples.
[0135] The model training module 30 divides the normal training samples into a training set and a validation set according to the chronological order of the data blocks in the historical running data. In this embodiment, the ratio of the number of samples in the training set to the validation set is 8:2, and the validation set is used to determine the contrast loss temperature coefficient. And evaluate the training status of feature encoder 32.
[0136] The model training module 30 generates the first data augmentation view from the data augmentation unit 31. Second data augmentation view Input feature encoder 32.
[0137] Feature encoder 32 in processing the first data augmentation view Second data augmentation view They share the same set of network weight parameters.
[0138] First data augmentation view After forward propagation by the feature encoder 32, the first node-level latent space feature matrix is output. The first global latent space feature vector is obtained through pooling. .
[0139] Second data augmentation view After forward propagation by feature encoder 32, the second node-level latent space feature matrix is output. The second global latent space feature vector is obtained through pooling. .
[0140] Step S503: The comparison loss calculation unit 33 constructs comparison learning sample pairs.
[0141] Assume the current training batch contains Different time window data blocks; for the first data block within a batch A data block with a time window, and a first global latent spatial feature vector generated from the data block with that time window. Second global latent space feature vector This constitutes a positive sample pair.
[0142] For the global latent spatial feature vectors generated by data blocks in different time windows within a batch, the comparison loss calculation unit 33 uses them as negative sample pairs.
[0143] In other words, the object of the similarity calculation by the comparison loss calculation unit 33 is the time window-level feature vector, rather than a single sampling point data or a single sensor data.
[0144] To avoid the formation of false negative samples due to overlapping sampling data between adjacent sliding time windows, the contrast loss calculation unit 33 can exclude other time windows with an interval less than a preset interval from the negative sample set, or reduce their negative sample weights.
[0145] In step S504, the contrast loss calculation unit 33 calculates the contrast loss function and updates the network parameters of the feature encoder 32.
[0146] The comparison loss calculation unit 33 performs similarity calculation on the global latent space feature vector output by the feature encoder 32.
[0147] For any two global latent space feature vectors and The comparison loss calculation unit 33 uses a cosine similarity function to calculate the similarity between the two in the latent space, denoted as . The calculation formula is as follows: ; in, This represents the L2 norm.
[0148] The contrast loss calculation unit 33 uses the InfoNCE contrast loss function to optimize the feature encoder 32.
[0149] For the first in the training batch Each time window data block, and its corresponding loss value It can be calculated using the following formula: ; in, For training batch size, The temperature coefficient hyperparameter is used to scale the similarity between sample features and adjust the smoothness of the probability distribution. Before model training, a grid search method is used to... The model was trained using values of 0.05, 0.1, 0.2, 0.3, and 0.5, and the value that minimized the average contrastive loss on the validation set was selected as the training parameter. The final value of . In this embodiment, Set it to 0.1.
[0150] The contrastive loss calculation unit 33 summarizes the loss values corresponding to each time window within the training batch to obtain the average contrastive loss. : ; Subsequently, the contrast loss calculation unit 33 calls the backpropagation algorithm to calculate the average contrast loss. The gradient of the weight parameters of the feature encoder 32 network.
[0151] Let the network weight parameters of feature encoder 32 be... The learning rate is Then, the model training module 30 can update the network weight parameters in the following way: ; in, This represents the set of all learnable weight matrices and bias vectors for the convolutional network layers and gated recurrent unit layers in the feature encoder 32. The learning rate represents the step size for updating network parameters, and its value ranges from 10. -4 ~10 -3 ; Represents the average contrastive loss function value For network parameter set The set of gradients obtained after taking partial derivatives.
[0152] Let the first The set of network parameters at the next iteration is The updated set of network parameters is then: ; The model training module 30 calculates the gradient set using the backpropagation algorithm and updates the network parameters according to the above formula after each training batch is completed. In this embodiment, the learning rate... Set to 10 -3 After multiple training rounds, the model training module 30 obtains a feature extraction network that has completed self-supervised training.
[0153] In one optional implementation, the graph convolutional network has 1 to 3 layers, the gated recurrent unit layer has a hidden dimension of 16 to 128, and the training batch size is... The temperature coefficient ranges from 16 to 256. The value is between 0.05 and 0.5, and the learning rate is 10.-4 ~10 -3 The training sessions consist of 50 to 300 rounds.
[0154] The network parameters mentioned above can be set according to the number of individual battery cells in the battery pack, the computing power of the edge computing platform, and the size of the training samples.
[0155] like Figure 9 As shown, in a specific embodiment of the present invention, in step S600, the online prediction module 40 performs unsupervised anomaly determination during the actual vehicle operation phase.
[0156] The online prediction module 40 calls the feature encoder 32, which has completed training and frozen weight parameters, to extract the latent spatial feature vector corresponding to the current time window, and judges whether the battery has an early risk of thermal runaway based on the distribution distance between the recent feature distribution and the historical baseline feature distribution.
[0157] Step S600 specifically includes the following steps: Step S601: The online prediction module 40 extracts the latent space feature vector in real time.
[0158] During the real-vehicle deployment phase, after the model training module 30 completes offline training, it freezes the network weight parameters of the feature encoder 32. The online prediction module 40 then uses the feature encoder 32 with its weight parameters frozen as the real-time feature extraction network.
[0159] During vehicle operation, the online prediction module 40 receives the electrothermal residual sequence corresponding to the current time window and calculates the Pearson correlation coefficient and first-order time difference cosine similarity between individual cells in the current time window according to the dynamic topology construction method in step S300.
[0160] The online prediction module 40 generates the dynamic adjacency matrix corresponding to the current time window based on the above calculation results, and performs nonnegation, self-connection addition and normalization processing on the dynamic adjacency matrix.
[0161] The processed dynamic adjacency matrix and the real-time electrothermal residual sequence together constitute the dynamic topological spatiotemporal graph of the current time window.
[0162] The online prediction module 40 inputs the dynamic topological spatiotemporal graph into the feature encoder 32 after freezing the weight parameters, and outputs the node-level latent spatial feature matrix corresponding to the current time window through forward propagation calculation of graph convolutional network layers and gated recurrent unit layers.
[0163] When a single-cell level early warning is executed, the online prediction module 40 extracts the node-level potential spatial feature vector corresponding to each single cell.
[0164] When a battery pack-level early warning is executed, the online prediction module 40 performs pooling processing on the node-level latent space feature matrix to obtain the battery pack-level latent space feature vector.
[0165] During the online prediction phase, the feature encoder 32 only performs forward propagation computation and does not perform backward gradient update.
[0166] Step S602: The online prediction module 40 constructs the recent feature distribution and the baseline feature distribution.
[0167] The online prediction module 40 extracts a set of latent spatial feature vectors obtained within a set of recent consecutive time windows based on a set recent statistical window, and constructs a recent feature distribution. In one embodiment, the recent statistical window may contain 10 to 30 recent consecutive time windows. In this embodiment, the recent statistical window contains 20 recent consecutive time windows.
[0168] When executing a single-unit level early warning, the online prediction module 40 targets the first... Recent Feature Distribution of Individual Battery Cells .
[0169] When a battery pack-level early warning is executed, the online prediction module 40 constructs a recent feature distribution at the battery pack level. .
[0170] Simultaneously, the online prediction module 40 reads the historical normal operation data of the target vehicle and constructs a baseline feature distribution. In this embodiment, the potential spatial feature vectors corresponding to 200 time windows are selected from the historical normal operation data to form the baseline feature distribution.
[0171] The time window corresponding to the historical normal operation data must meet at least the following conditions: no thermal runaway alarm, no over-temperature fault code, no over-voltage fault code, no under-voltage fault code, and the current, temperature, and state of charge are within the allowable operating range.
[0172] When executing a single-unit level early warning, the online prediction module 40 is the first... Baseline characteristic distribution corresponding to maintenance of individual battery cells .
[0173] When a battery pack-level early warning is executed, the online prediction module 40 maintains the battery pack-level baseline feature distribution. .
[0174] When the system has triggered a warning or the vehicle is in an abnormal fault state, the online prediction module 40 pauses the incorporation of the potential spatial feature vector of the current time window into the baseline feature distribution. When the vehicle returns to normal operation and continues for a preset normal confirmation period, the online prediction module 40 can incorporate the newly acquired normal potential spatial feature vector into the baseline feature distribution and recalculate the p-Wasserstein distance sequence and dynamic warning threshold under historical normal conditions based on the updated baseline feature distribution.
[0175] Step S603: The online prediction module 40 calculates the distribution distance metric between the recent feature distribution and the baseline feature distribution.
[0176] The online prediction module 40 uses p-Wasserstein distance to calculate the distribution distance metric between the recent feature distribution and the baseline feature distribution.
[0177] When a single-unit level early warning is executed, the online prediction module 40 calculates the... Recent characteristic distribution of individual battery cells Baseline Feature Distribution The p-Wasserstein distance between them is denoted as .
[0178] When a battery pack-level early warning is issued, the online prediction module 40 calculates the recent feature distribution at the battery pack level. Baseline feature distribution at the battery pack level The p-Wasserstein distance between them is denoted as .
[0179] For including Recent feature distribution of a feature sample and including Baseline feature distribution of each feature sample Its p-Wasserstein distance can be calculated using the following formula: ; in, This represents the recent feature distribution composed of latent spatial feature vectors corresponding to several consecutive recent time windows. It represents the baseline feature distribution composed of latent spatial feature vectors under historical normal conditions; Represents recent characteristic distribution The number of feature samples included. Represents baseline characteristic distribution The number of feature samples contained therein; Represents recent characteristic distribution The first in 1 eigenvector Represents baseline characteristic distribution The first in 1 eigenvector This represents the Euclidean distance between two eigenvectors. The distance order is... For joint distributed transfer matrix, Indicates the first eigenvectors To the eigenvectors Assigned transmission weights; This indicates that it satisfies the recent characteristic distribution. Baseline characteristic distribution The set of transfer matrices constrained by the edge distribution.
[0180] Joint distributed transmission matrix It satisfies the marginal probability distribution constraint. If the recent feature distribution... and baseline characteristic distribution Using uniform weights, the constraint conditions can be expressed as: ; ; ; In one implementation, the distance order In this embodiment, the distance order is either 1 or 2. Take 2.
[0181] In the specific calculation, the online prediction module 40 first calculates the distance between each feature vector in the recent feature distribution and each feature vector in the baseline feature distribution, forming a cost matrix. The elements of the cost matrix are: ; To reduce the computational complexity of online calculations, the online prediction module 40 can use the Sinkhorn iterative algorithm with an entropy regularization term to approximate the solution of the joint distribution transfer matrix. .
[0182] The online prediction module 40 constructs an initial transmission weight matrix based on the cost matrix C and preset entropy regularization term weight coefficients. Specifically, the online prediction module 40 constructs the initial transmission weight matrix based on the cost matrix C. Constructing the kernel matrix and the kernel matrix As the initial transfer weight matrix for performing row-column alternation normalization, the elements in the kernel matrix are calculated according to the following formula: ; in, The weight coefficient for the entropy regularization term.
[0183] The online prediction module 40 performs alternating normalization on each row and column of the initial transmission weight matrix according to the aforementioned marginal probability distribution constraints. Specifically, each row normalization makes the sum of the elements in the a-th row of the transmission weight matrix approach a certain value. Each column normalization makes the sum of the elements in the b-th column of the transfer weight matrix approach 1 / 2. .
[0184] The online prediction module 40 repeatedly performs the row normalization and column normalization until the maximum error between the sum of the row elements and the sum of the column elements of the transmission weight matrix and the corresponding marginal probabilities is less than a preset convergence threshold, or the number of iterations reaches a preset maximum number of iterations. The transmission weight matrix obtained when the iteration stops is then used as the approximately optimal joint distribution transmission matrix. .
[0185] In this embodiment, the entropy regularization term weight coefficient is set to 0.05, and the preset convergence threshold is set to 10. -6 The maximum number of iterations is preset to 100.
[0186] The online prediction module 40 will approximate the optimal joint distribution transfer matrix. Substituting into the p-Wasserstein distance calculation formula above, calculate the weighted sum of the distances between each transmission weight and its corresponding feature vector, and then perform... The power operation yields the distribution distance metric corresponding to the current time window.
[0187] When using a single-unit level early warning, the formula... and Replace with and To obtain the distribution distance metric .
[0188] When using battery pack-level warnings, the formula... and Replace with and To obtain the distribution distance metric .
[0189] In step S604, the online prediction module 40 generates a dynamic early warning threshold and triggers a thermal runaway early warning signal based on the distribution distance metric.
[0190] The online prediction module 40 generates dynamic early warning thresholds based on the p-Wasserstein distance sequence calculated under historical normal conditions.
[0191] Specifically, the online prediction module 40 selects multiple recent statistical windows in the historical normal operation data in chronological order, and for each recent statistical window, it uses the same distance order, entropy regularization term weight coefficient, iteration stopping condition and p-Wasserstein distance calculation method described in step S603 to calculate the distribution distance metric between the feature distribution corresponding to the recent statistical window and the baseline feature distribution. The multiple distribution distance metrics are arranged in chronological order to form the p-Wasserstein distance sequence under the historical normal state.
[0192] The online prediction module 40 sorts the p-Wasserstein distance sequences under historical normal conditions according to their numerical values and selects a preset high quantile as the tail start threshold. In one implementation, the preset high quantile is the 95th percentile.
[0193] For any historical distance sample When it is greater than the tail start threshold At that time, the online prediction module 40 calculates its excess. : ; The online prediction module 40 uses a generalized Pareto distribution to evaluate the exceedance samples. A fitting was performed, and the shape parameters of the generalized Pareto distribution were solved using the maximum likelihood estimation method. and scale parameters .
[0194] Subsequently, the online prediction module 40 calculates the corresponding transcendental quantile value based on the preset confidence level through the inverse operation of the cumulative distribution function of the generalized Pareto distribution. and set the tail start threshold With transcendental quantile The sum is used as a dynamic early warning threshold. In this embodiment, the preset confidence level is set to 99%.
[0195] When a single-cell level early warning is executed, the online prediction module 40 fits a corresponding dynamic early warning threshold for each single cell based on its historical normal distance sequence. .
[0196] When a battery pack-level early warning is issued, the online prediction module 40 fits a dynamic early warning threshold based on the historical normal distance sequence at the battery pack level. .
[0197] The online prediction module 40 compares the distribution distance metric calculated in real time with the corresponding dynamic early warning threshold.
[0198] In the single-unit level early warning mode, the online prediction module 40 will... Real-time distance corresponding to each individual battery cell Its dynamic early warning threshold Compare them.
[0199] In the battery pack-level early warning mode, the online prediction module 40 will predict the real-time distance at the battery pack level. With battery pack level dynamic warning threshold Compare them.
[0200] To avoid misjudgments caused by fluctuations in a single calculation, the online prediction module 40 is equipped with an early warning confirmation window.
[0201] when consecutively exceeding When the time step count reaches the warning confirmation window length, the online prediction module 40 triggers the first warning. Thermal runaway warning signal for individual battery cells.
[0202] when consecutively exceeding When the number of time steps reaches the length of the warning confirmation window, the online prediction module 40 triggers a battery pack-level thermal runaway warning signal. In one embodiment, the length of the warning confirmation window is 5 to 10 consecutive time steps.
[0203] The online prediction module 40 sends the thermal runaway early warning signal to the vehicle control center via the vehicle bus.
[0204] In one embodiment of the invention, the system is deployed between the battery management system and the vehicle controller of an electric vehicle. The data acquisition module 10 acquires the actual measured voltage, surface temperature, and battery pack current of each individual cell via the vehicle bus; the data preprocessing module 20 performs equivalent circuit model calculations and generates an electrothermal residual sequence in the vehicle controller; the model training module 30 can complete self-supervised training on a cloud server or offline training platform and distribute the trained feature encoder 32 to the vehicle; the online prediction module 40 calls the frozen-weight feature encoder 32 to generate real-time latent spatial features during vehicle operation, calculates the Wasserstein distance between the real-time feature distribution and the historical baseline feature distribution, and outputs an early warning signal for thermal runaway to the vehicle controller when the dynamic warning threshold is continuously exceeded. Upon receiving the warning signal, the vehicle controller can execute at least one safety response action, such as reducing the charge / discharge rate, enhancing cooling, limiting power output, or disconnecting the high-voltage circuit.
[0205] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention, and they should all be covered within the scope of the claims and specification of the present invention.
Claims
1. A machine learning-based method for predicting thermal runaway in electric vehicle batteries, characterized in that, include: Collect multi-dimensional operational data for each individual battery cell, including actual measured voltage, main line charging and discharging current, and surface temperature, and perform sliding time window segmentation on the multi-dimensional operational data to form time window data blocks; The time window data block is input into the equivalent circuit model to calculate the theoretical expected voltage of each individual cell within the corresponding time window, and an electrothermal residual sequence is generated based on the difference between the actual measured voltage and the theoretical expected voltage. Based on the correlation between the electrothermal residual sequences of each individual cell, a dynamic topological spatiotemporal graph corresponding to the current time window is constructed. The correlation is characterized by the correlation coefficient and difference cosine similarity between the electrothermal residual sequences. Perform data augmentation processing on the dynamic topology spatiotemporal graph to generate a first data augmentation view and a second data augmentation view; The first data augmentation view and the second data augmentation view are used as samples to perform comparative learning training on the input feature encoder to obtain the feature extraction network; Under real-time vehicle operating conditions, a real-time dynamic topology spatiotemporal graph is constructed based on the real-time electrothermal residual sequence, and the real-time dynamic topology spatiotemporal graph is input into the feature extraction network to obtain the feature vector corresponding to the recent time window to construct the recent feature distribution. Calculate the distribution distance metric between the recent characteristic distribution and the baseline characteristic distribution, and execute a thermal runaway early warning action based on the comparison result between the distribution distance metric and the early warning threshold.
2. The method for predicting thermal runaway of electric vehicle batteries based on machine learning according to claim 1, characterized in that, The step of inputting the time window data block into the equivalent circuit model, calculating the theoretical expected voltage of each individual cell within the corresponding time window, and generating an electrothermal residual sequence based on the difference between the actual measured voltage and the theoretical expected voltage includes: Obtain the current state of charge and surface temperature of a single cell, and read the corresponding theoretical reference parameters from the multidimensional parameter lookup table; Based on the main line charging and discharging current or the equivalent input current of a single cell, combined with the polarization voltage obtained by discretely solving the ordinary differential equation and the theoretical reference parameters, the theoretical expected voltage is calculated. The equivalent input current of a single cell is obtained by converting the main line charging and discharging current according to the series and parallel topology of the battery pack and the polarity of the sensor when there are parallel branches in the battery pack. The actual measured voltage and the theoretical expected voltage at the same sampling time are subjected to differential operation to obtain single-point residual values, and the single-point residual values are spliced together in time order to form the electrothermal residual sequence of the corresponding single cell.
3. The method for predicting thermal runaway of electric vehicle batteries based on machine learning according to claim 1, characterized in that, The construction of a dynamic topological spatiotemporal graph corresponding to the current time window, based on the correlation between the electrothermal residual sequences of each individual battery cell, includes: Calculate the Pearson correlation coefficient of the electrothermal residual sequence of each individual cell within the current time window; The residual rate vector is obtained by performing adjacent sampling point difference on the electrothermal residual sequence of each individual cell, and the first-order time difference cosine similarity of the residual rate vectors between individual cells is calculated. The Pearson correlation coefficient and the first-order time difference cosine similarity are weighted and fused to calculate the initial edge weights; The initial edge weights are nonnegated and self-connection weights are added to the diagonal positions before normalization to obtain a normalized dynamic adjacency matrix. The normalized dynamic adjacency matrix and the node feature matrix composed of the electrothermal residual sequence are used to construct the dynamic topological spatiotemporal graph.
4. The method for predicting thermal runaway of electric vehicle batteries based on machine learning according to claim 1, characterized in that, The step of performing data augmentation processing on the dynamic topological spatiotemporal graph to generate a first data augmentation view and a second data augmentation view includes the step of generating the first data augmentation view: Introduce a time offset on the timeline that is limited to a preset time window length; The original electrothermal residual sequence is sampled with a time dimension offset to obtain the time-off residual sequence; The residual sequence after the time offset is used as the new feature input for the graph nodes, and the normalized dynamic adjacency matrix of the dynamic topological spatiotemporal graph is kept unchanged to construct the first data augmentation view.
5. The method for predicting thermal runaway of electric vehicle batteries based on machine learning according to claim 1, characterized in that, The step of performing data augmentation processing on the dynamic topological spatiotemporal graph to generate a first data augmentation view and a second data augmentation view further includes the step of generating the second data augmentation view: Extract the physical parameter vectors called by the equivalent circuit model within the current time window, and calculate the covariance matrix of the physical parameter vectors under the current state of charge and temperature range; A random perturbation vector that follows a multivariate normal distribution with zero vector as mean and the covariance matrix or the modified covariance matrix as covariance is introduced, and numerical perturbation based on physical parameter boundary constraints is performed on the physical parameter vector to generate the perturbated physical parameter vector. The perturbated physical parameter vector is substituted into the equivalent circuit model to calculate the new theoretical expected voltage, generating an accompanying residual sequence. The accompanying residual sequence is used as a node feature and combined with the normalized dynamic adjacency matrix of the dynamic topology spatiotemporal graph to construct the second data augmentation view.
6. The method for predicting thermal runaway of electric vehicle batteries based on machine learning according to claim 1, characterized in that, The step of using the first data augmented view and the second data augmented view as samples to perform comparative learning training on the input feature encoder to obtain the feature extraction network includes: The first data augmentation view and the second data augmentation view are input into the feature encoder, which includes a graph convolutional network layer and a gated recurrent unit layer. After forward propagation and pooling, the first global latent space feature vector and the second global latent space feature vector are output respectively. The first global latent space feature vector and the second global latent space feature vector from the same time window data block are used as positive sample pairs, and global latent space feature vectors from different time window data blocks are used as negative sample pairs. Calculate the contrastive loss function values of the positive and negative sample pairs within the same training batch, and iteratively optimize the network parameters of the feature encoder using gradient descent.
7. The method for predicting thermal runaway of electric vehicle batteries based on machine learning according to claim 1, characterized in that, Under real-time vehicle operating conditions, a real-time dynamic topology spatiotemporal graph is constructed based on the real-time electrothermal residual sequence, and the real-time dynamic topology spatiotemporal graph is input into the feature extraction network to obtain feature vectors corresponding to recent time windows to construct recent feature distributions, including: The feature extraction network, which has completed training and frozen its weight parameters, is invoked during the vehicle operation phase. A real-time dynamic topological spatiotemporal graph is constructed based on the real-time electrothermal residual sequence, and the feature extraction network is input to obtain the latent spatial feature vector corresponding to the current time window. Extract the set of latent spatial feature vectors obtained within several recent consecutive time windows to construct the recent feature distribution.
8. The method for predicting thermal runaway of electric vehicle batteries based on machine learning according to claim 1, characterized in that, The warning threshold is a dynamic warning threshold. Before executing the thermal runaway warning action, the method further includes a step of generating the dynamic warning threshold. The dynamic warning threshold is used to compare with the distribution distance metric. The step of generating the dynamic warning threshold includes: The p-Wasserstein distance is used to calculate the sequence of distribution distance values between the characteristic distribution under historical normal conditions and the baseline characteristic distribution; A preset high-resolution point in the distribution distance metric sequence is selected as the tail start threshold; Calculate the exceedance of distance samples that are greater than the tail start threshold, fit the exceedance using a generalized Pareto distribution, and calculate the corresponding exceedance quantile based on a preset confidence level. The sum of the tail start threshold and the exceedance quantile value is used as the dynamic warning threshold.
9. The method for predicting thermal runaway of electric vehicle batteries based on machine learning according to claim 8, characterized in that, The step of calculating the distribution distance metric between the recent feature distribution and the baseline feature distribution, and executing a thermal runaway early warning action based on the comparison result between the distribution distance metric and the dynamic early warning threshold, includes: An iterative algorithm with entropy regularization is used to approximate the joint distribution transfer matrix, and the p-Wasserstein distance between the recent feature distribution and the baseline feature distribution in real time is calculated as the real-time distribution distance metric. The real-time distribution distance metric is compared with the corresponding dynamic warning threshold. If the real-time distribution distance metric exceeds the dynamic warning threshold for a number of consecutive time steps, and the preset warning confirmation window length is reached, a thermal runaway warning signal is triggered.
10. A machine learning-based electric vehicle battery thermal runaway prediction system, used to execute the machine learning-based electric vehicle battery thermal runaway prediction method as described in any one of claims 1-9, characterized in that, include: The data acquisition module is used to collect multi-dimensional operating data of each individual cell, including actual measured voltage, main line charging and discharging current and surface temperature, and to perform sliding time window segmentation on the multi-dimensional operating data to form time window data blocks; The data preprocessing module, connected to the data acquisition module, is used to input the time window data block into the equivalent circuit model, calculate the theoretical expected voltage of each individual cell within the corresponding time window, and generate an electrothermal residual sequence based on the difference between the actual measured voltage and the theoretical expected voltage. The model training module, connected to the data preprocessing module, is used to construct a dynamic topological spatiotemporal graph corresponding to the current time window based on the correlation between the electrothermal residual sequences of each individual battery cell; the correlation is characterized by the correlation coefficient and difference cosine similarity between the electrothermal residual sequences. Perform data augmentation processing on the dynamic topology spatiotemporal graph to generate a first data augmentation view and a second data augmentation view; The first data augmentation view and the second data augmentation view are used as samples to perform comparative learning training on the input feature encoder to obtain the feature extraction network; The online prediction module is connected to both the data preprocessing module and the model training module. It is used to call the feature extraction network to construct a real-time dynamic topology spatiotemporal graph based on the real-time electrothermal residual sequence under real-time vehicle operating conditions. The real-time dynamic topology spatiotemporal graph is then input into the feature extraction network to obtain the feature vector corresponding to the recent time window to construct the recent feature distribution. The distribution distance metric between the recent feature distribution and the baseline feature distribution is calculated, and a thermal runaway warning action is executed based on the comparison between the distribution distance metric and the warning threshold.
Citation Information
Patent Citations
Electric vehicle battery thermal runaway early warning method and system and computer program product
CN121871449A
Thermal imaging anomaly detection method and system for battery pack of electric vehicle
CN121973633A