Lithium battery state of health estimation method fusing piecewise gating encoding and degraded trajectory constraint

CN122983707APending Publication Date: 2026-10-27TONGJI UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611477837.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-22
Publication Date
2026-10-27

AI Technical Summary

Technical Problem

但若直接采用固定退化模型作为强约束,容易抑制数据驱动网络对局部非线性退化行为的学习;若仅依赖网络自身预测,又可能在小样本训练、跨电池迁移或后期外推时产生不符合退化规律的预测轨迹

Benefits of technology

1.利用分块序列建模机制,将长序列划分为多个局部块并结合块内局部计算与块间线性记忆聚合,降低了相较于全局密集注意力的长序列计算压力,提升了资源受限场景的部署可行性。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122983707A_ABST
    Figure CN122983707A_ABST
Patent Text Reader

Abstract

The application discloses a lithium battery state of health evaluation method fusing block gating encoding and degradation trajectory constraint, and relates to the field of lithium battery state of health evaluation. The method comprises offline training and online evaluation processes. In the offline stage: historical cycle data is preprocessed, a health characteristic is extracted, and an input window is constructed; a degradation curve is fitted to obtain a degradation calibration value for soft constraint; the window input is input into a block gating degradation encoding network, local quadratic similarity calculation within blocks, linear memory aggregation between blocks, and multi-scale local gating fusion are performed to generate a prediction value; a joint loss function is constructed based on the true label and the degradation calibration value to train the network. In the online stage: the parameters are reused to process online data input into the network to output an estimated value, and the consistency deviation of the estimated value and the degradation calibration value is calculated to output an abnormal prompt. The application considers global trends and local dynamic characteristics, and improves the evaluation accuracy and generalization ability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of lithium battery health status assessment, and in particular to a lithium battery health status assessment method that integrates block gating coding and degradation trajectory constraints. Background Technology

[0002] Lithium-ion batteries are widely used in electric transportation, energy storage power stations, distributed energy systems, and aerospace equipment. With increasing cycle count, degradation phenomena occur within the battery, including loss of cyclic lithium, loss of active materials, thickening of the interfacial film, enhanced polarization, and increased internal resistance. These degradations manifest as capacity reduction, shortened charge / discharge duration, and altered voltage response characteristics. The State of Health (SOH) value is typically used to characterize the degree to which a battery retains its current usable capacity relative to its rated or initial capacity, and is a crucial indicator for battery safety management and lifespan prediction. Existing methods for assessing state of health mainly include mechanistic model-based methods, empirical degradation model-based methods, and data-driven methods.

[0003] In existing technologies, mechanistic model-based methods can explain the battery aging process from the perspectives of electrochemical reactions, diffusion mass transfer, and interfacial side reactions, such as pseudo-two-dimensional electrochemical models. Related research obtains structural parameters by disassembling the battery and uses genetic algorithms to identify unknown parameters in the model, establishing capacity calculation rules for online estimation. However, these methods typically rely on precise material and structural parameters and involve solving complex partial differential equations, resulting in high model construction costs. Different battery types require different models, making direct deployment in resource-constrained battery management systems difficult. Empirical degradation model-based methods have a simple structure and can be used to describe the overall trend of capacity decline with cycle count. Related research extracts health characteristics through capacity increment analysis and combines Gaussian process regression and exponential empirical models for prediction and parameter correction. However, these models typically rely on pre-defined functional forms, have limited expressive power, and struggle to accurately capture capacity regeneration, local inflection points, short-term fluctuations, and degradation differences between individual batteries.

[0004] To overcome the limitations of traditional models, data-driven deep learning methods have been widely adopted, capable of learning nonlinear mapping relationships from historical operational data. Related research has extracted multiple health indicators from charging voltage, current, and temperature, estimating them using a fusion model of convolutional neural networks and long short-term memory networks, or constructing attention models by combining capacity increment and differential voltage analysis methods to improve accuracy and robustness. However, recurrent neural networks and their variants suffer from low sequential computation efficiency during sequence processing and are prone to information forgetting in long-sequence degradation modeling; while convolutional neural networks can effectively extract local features, their ability to characterize long-range dependencies is insufficient; attention-based models, although capable of global dependency modeling, experience rapidly increasing computational complexity with sequence length and are not sensitive enough to local degradation patterns and multi-scale fluctuations. Furthermore, some studies have attempted to introduce degradation law constraints into data-driven models to improve the physical plausibility of prediction results, such as embedding physical lifetime models into neural networks or using physical information neural networks to solve partial differential equations. However, if a fixed degradation model is directly used as a strong constraint, it is easy to inhibit the learning of local nonlinear degradation behavior by the data-driven network; if only the network's own prediction is relied upon, it may produce prediction trajectories that do not conform to the degradation law during small sample training, cross-cell transfer or later extrapolation.

[0005] In summary, current evaluation methods generally suffer from the following common shortcomings: existing model structures are mostly based on general deep learning frameworks, making it difficult to specifically design for the non-stationarity and multi-scale features of battery degradation sequences; at the same time, the integration between physical constraints and sequence modeling structures is not tight enough, often remaining at the level of simple superposition of loss functions, lacking a deep coupling mechanism for degradation patterns and feature evolution processes; furthermore, existing models generally lack the ability to collaboratively model local neighborhood features, global memory, and multi-scale local dynamics, resulting in insufficient ability to characterize complex degradation behaviors such as capacity recovery and local fluctuations; and, under conditions of limited data volume, short cycle segments, or abnormal fluctuations, the model's predictive stability and cross-battery generalization ability are still significantly insufficient.

[0006] Therefore, in order to address the above-mentioned shortcomings, this invention proposes a lithium battery health status assessment method that integrates block gating coding and degradation trajectory constraints. Summary of the Invention

[0007] To simultaneously model global degradation trends and extract local dynamic features while keeping computational complexity under control, and to introduce degradation law constraints during model training to improve prediction consistency, this application provides a lithium battery health status assessment method that integrates block-gated coding and degradation trajectory constraints.

[0008] A lithium battery health status assessment method integrating block gating coding and degradation trajectory constraints, including offline training process and online assessment process; The offline training process includes: Read historical cycle operation data of lithium battery, sort by cycle number and sampling time, identify charging segment, discharging segment and resting segment, and preprocess outlier, missing point and time misalignment data to obtain preprocessed charge and discharge data; Candidate health characteristics related to capacity degradation were extracted from preprocessed charge-discharge data, and health characteristic sequences were obtained by screening based on correlation, monotonicity and cross-cell stability. The health representation sequence is standardized using a preset window of length N, and the health representation vectors corresponding to consecutive cycles are used as the training input window. The degradation baseline curve is fitted based on the cyclic index of historical samples, and the degradation calibration value is obtained by normalization of the training interval; wherein, the degradation calibration value is only used as a soft constraint signal in the training stage and does not directly output the health status prediction result. The training input window is input into the block-gated degradation coding network. Local degradation fluctuation features are extracted by intra-block local quadratic similarity calculation, and global degradation trend features are extracted by inter-block linear memory aggregation. A gate tensor is generated by multi-scale local gate branches. The hybrid block attention and the gate tensor are fused with residual gate to output the predicted value of lithium battery health status. The data fitting loss is calculated based on the real health status label and the predicted value of the lithium battery health status. The degradation consistency loss is calculated based on the degradation calibration value and the predicted value of the lithium battery health status. A joint loss function is constructed to train the network offline. The optimal model parameters, feature standardized statistical parameters, degradation baseline curve parameters and normalized parameters are saved. The online assessment process includes: Acquire online running data, reuse the saved feature standardization statistical parameters to process and construct the inference input window, input the trained network to output the current lithium battery health state estimate; after obtaining the cycle index, calculate the consistency deviation between the health state estimate and the degradation calibration value, and output an abnormal consistency prompt when the consistency deviation meets the abnormal judgment condition.

[0009] The long sequence degradation process is divided into multiple local subsequences. The traditional global dense attention structure is replaced by intra-block local quadratic similarity calculation and inter-block linear memory aggregation. This reduces computational complexity while achieving joint modeling of local degradation fluctuations and global degradation trends. The hybrid block attention output is adaptively modulated by multi-scale local gate control branches to enhance the ability to identify local fluctuations, short-term anomalies and inflection point changes in capacity decay. The predicted trajectory is subject to soft constraints through output-level degradation consistency loss, so that the prediction results can fit the real samples while maintaining a reasonable overall degradation trend, taking into account both trend consistency and local nonlinearity expression ability.

[0010] Preferably, the true health status label is determined according to the ratio of the maximum capacity that the battery can discharge in the current cycle to the battery's rated capacity, and the normalized label expression is: Health status in percentage form: ;in, For the first A cycle of real health status labels; For the first The maximum capacity that can be released in a cycle; This refers to the battery's rated capacity. For the first The percentage of cycles in the lithium battery's state of health.

[0011] Preferably, the candidate health characteristics include at least: the time taken for the terminal voltage to rise from a first preset voltage value to a second preset voltage value during the charging process, the duration of the constant current discharge stage, the charging time within a specified state of charge window, the charging amount, the average voltage, the maximum voltage, the minimum voltage, the end voltage of the window, and the incremental capacity peak value, peak voltage, peak area, and differential capacity statistics within the window calculated from the voltage-capacity curve.

[0012] Preferably, the health characteristic sequence is standardized using training set statistics, calculated using the following formula: ; in, For the standardized first The first cycle The original health characteristics of the microorganisms; For the first The first cycle Original health characteristics; and The first The mean and standard deviation of the original health representations of the dimension in the training set; To prevent tiny constants with a denominator of zero.

[0013] Preferably, the expression for the degradation baseline curve is: ;in, Circular index; , , and These are the parameters to be fitted; The degradation calibration value is calculated as follows: ;in, For the first Degradation calibration values ​​for each sample; and These are the minimum and maximum values ​​of the degradation baseline curve within the training interval, respectively; is a tiny constant for preventing the denominator from being zero; is the value of the degraded reference curve at the th cycle, is the cycle index corresponding to the th sample.

[0014] Preferably, the block-wise gated degradation encoding network comprises: a feature embedding layer, a shared linear projection layer, a hybrid block attention unit, a multi-scale local gating branch, a residual gated fusion unit, a compressed feedforward mapping unit, a pooling layer, and a health state regression output layer; wherein the training process of the block-wise gated degradation encoding network comprises: inputting the input tensor corresponding to the training input window into the feature embedding layer to obtain an embedded feature, which is expressed as: ; wherein, is the embedded feature; is the input tensor corresponding to the training input window; is the weight matrix of the feature embedding layer; is the bias term of the feature embedding layer; after normalizing the embedded feature, inputting the normalized embedded feature into the shared linear projection layer for linear transformation, and splitting it into three sub-representations , and ; wherein, the sub-representation is used for the multi-scale local gating branch; the sub-representation is used for value information transfer; the sub-representation is used for similarity index calculation; the sub-representation , the sub-representation and the sub-representation are respectively divided into a plurality of sequence blocks along the time dimension according to a preset block length; if the preset window length cannot be exactly divided by the preset block length, zero vectors are padded at the sequence end of each sub-representation, and the sub-representations are rearranged into block tensors to obtain the block-processed sub-representations; wherein, the padded sequence length is expressed as: ; wherein, is the sequence length that meets the complete block division requirement after being padded with zero vectors; is the number of sequence blocks; is the preset block length; the block-processed sub-representation is sent to the multi-scale local gating branch, and the block-processed sub-representation and the sub-representation are sent to the hybrid block attention unit for parallel processing; by the hybrid block attention unit, the block-processed sub-representation For similarity indexing, use the sub-representation after block division. Perform calculations on the value information, specifically: In the intra-block local quadratic similarity path, the sub-representations after block division Similarity projection is performed to obtain the query vector and key vector. After rotation angle encoding, the local similarity score between the query vector and the key vector is calculated. The ReLU squared kernel transform is performed on the local similarity score to obtain the local weight. The local weight is then applied to the sub-representation after block division. Get partial output; In the inter-block linear memory aggregation path, the sub-representations after block division Perform linear projection to obtain inter-block query vectors and key vectors. Perform an outer product operation between the key vectors and the corresponding value vectors to construct block memories. Aggregate the block memories to obtain a memory tensor. Read the memory tensor from the inter-block query vectors to obtain the global output. Add the local output to the global output to complete local-global fusion. After restoring the original sequence length and removing padding, perform an output linear mapping to output hybrid block attention. The multi-scale local control branch is represented by a block-based sub-representation. Perform operations on the input and output a gated tensor; The hybrid block attention and the gate tensor are input into the residual gated fusion unit, and element-wise multiplication and fusion are performed to obtain the fused features; The fused features are fed into the compressed feedforward mapping unit, where feature expansion, activation, linear compression, random deactivation, and residual connection processing are performed sequentially to output the processed sequence features. The processed sequence features are input into the pooling layer for pooling processing, and then sent to the health status regression output layer to output the predicted value of the lithium battery health status.

[0015] Preferably, the hybrid block attention unit includes intra-block local quadratic similarity calculation and inter-block linear memory aggregation; the sub-representations after block division are rearranged into dimensions. The block tensor; where, Batch size; The number of sequence blocks; The preset block length; For implicit feature dimensions; In the intra-block local quadratic similarity path: for the sub-representations after block division Perform query projection and key projection to obtain the intra-block query vector. and intra-block key vector ; Using rotation angle position encoding RoPE to determine relative position offset and Apply a rotational phase transformation to obtain the phase-transformed intra-block query vector. and intra-block key vector ;Calculate the local fraction within the block as follows: ;in, For local fractions within the block; The query vector dimension is used; a ReLU squared kernel transformation is performed on the local scores within the block to obtain the local weights. Combine the local weights with the sub-representations after block division. Perform matrix multiplication to obtain local output; In the inter-block linear memory path: the sub-representation after block division Perform inter-block query projection and key projection to obtain the inter-block query vector. and inter-block key vector ;according to The memory tensor is constructed and aggregated by taking the outer product of the key vector and the corresponding value vector of each sequence block and summing them along the time dimension; where, For the first The memory representation corresponding to each block; For the inter-block path, the first The key vector at each time step; The value representation after block division is the first The value vector of each time step; the global output is obtained by performing a linear readout of the memory tensor using the inter-block query vector; The hybrid block attention is obtained by adding the local output to the global output and then performing an output linear mapping.

[0016] Preferably, the multi-scale local control branch is represented by a sub-branch. As input, depthwise separable one-dimensional convolutions with kernel lengths of 1×3, 1×5, and 1×7 are used to extract local response features at three different time scales. The three local response features are concatenated and then linearly fused and SE channel recalibrated sequentially. After SiLU activation and Sigmoid function operation, a gated tensor is generated. The residual gated fusion unit fuses the hybrid block attention with the gated tensor element-wise, outputting fused features; wherein, the expression of the fused features is: ;in, The fusion feature; For the hybrid block attention; Let this be the gate tensor; The fused features are fed into the compressed feedforward mapping unit, where feature expansion, activation, linear compression, random deactivation, and residual connection processing are performed sequentially to output the final processed sequence features.

[0017] Preferably, the joint loss function is expressed as follows: ; in, The data fitting loss between the predicted health status of the lithium battery and the actual health status label; The degradation consistency loss between the predicted health status of the lithium battery and the degradation calibration value; and These are the loss weighting coefficients; The degradation consistency loss weights are dynamically adjusted with each training round: in the early stages of training, the constraint weights are maintained or increased to enhance the degradation trend constraint, and in the later stages of training, the constraint weights are reduced to release the network's ability to learn local nonlinear degradation features.

[0018] In summary, this application includes at least one of the following beneficial technical effects: 1. By utilizing a block-based sequence modeling mechanism, long sequences are divided into multiple local blocks and combined with local computation within blocks and linear memory aggregation between blocks. This reduces the computational pressure on long sequences compared to global dense attention and improves the deployment feasibility in resource-constrained scenarios.

[0019] 2. By leveraging multi-scale local branch control, multi-scale local responses can be extracted through depth-separable one-dimensional convolutional branches with different kernel lengths, enhancing the ability to identify local fluctuations in capacity decay, short-term anomalies, and inflection point changes.

[0020] 3. By applying soft constraints to the predicted trajectory through output-level degradation consistency loss, the prediction results can maintain a reasonable overall degradation trend while closely matching the real samples. The soft constraints preserve the expressive power of capacity regeneration, local nonlinearity, and individual differences.

[0021] 4. By utilizing training set statistics standardization, time-order partitioning, and online consistency deviation detection, the impact of data leakage and abnormal degradation fragments on evaluation results is reduced, making it suitable for small sample sizes, incomplete sampling, and cross-battery scenarios.

[0022] 5. With the help of modular network structure design, each component module can flexibly adjust the feature dimension, sequence block length, multi-scale gating structure and calibration weight parameters according to different battery types, data sampling frequency and actual deployment requirements, so as to adapt to the health status assessment needs under multiple scenarios and working conditions. Attached Figure Description

[0023] Figure 1 A flowchart illustrating the lithium battery health status assessment method that integrates block gating coding and degradation trajectory constraints, provided in an embodiment of this application. Figure 2 This is a structural block diagram of the overall structure of the lithium battery health status assessment system provided in the embodiments of this application; Figure 3A schematic flowchart illustrating the overall process of the lithium battery SOH evaluation method provided in the embodiments of this application; Figure 4 This is a schematic diagram of the block-gated degenerate coding network structure provided in the embodiments of this application; Figure 5 A flowchart illustrating the hybrid block attention calculation process provided in this application embodiment, including intra-block local quadratic similarity calculation and inter-block linear memory aggregation; Figure 6 A schematic diagram of the multi-scale local departmental branch structure provided in the embodiments of this application; Figure 7 This is a schematic diagram of the structure of the degradation trajectory calibration module and the output stage consistency constraint provided in the embodiments of this application; Figure 8 A scatter plot of the predicted results of the SOH assessment method provided in the embodiments of this application on the test set; Figure 9 A bar chart showing the prediction error of the SOH evaluation method provided in the embodiments of this application on the test set. Detailed Implementation

[0024] The following is in conjunction with the appendix Figures 1 to 9 This application will be described in further detail.

[0025] This application discloses a method for assessing the health status of lithium batteries that integrates block gating coding and degradation trajectory constraints.

[0026] Example 1 The lithium battery health status assessment method in this embodiment includes two stages: an offline training process and an online assessment process. The overall process is as follows: Figure 3 As shown; Figure 1 As shown, the offline training process is executed according to the following steps: S1. Read the historical cycle operation data of the lithium battery, sort the historical cycle operation data according to the cycle number and sampling time, identify the charging segment, discharging segment and resting segment, and preprocess the outliers, missing points and time misaligned data in the historical cycle operation data to obtain preprocessed charging and discharging data. S2. Extract candidate health characteristics related to capacity degradation from the preprocessed charge and discharge data, and screen the candidate health characteristics based on correlation, monotonicity and cross-cell stability to obtain a health characteristic sequence. S3. Standardize the health representation sequence according to a preset window of length N, and construct the health representation vectors corresponding to consecutive cycles as the training input window; S4. Fit the degradation baseline curve based on the cyclic index of historical samples, and perform training interval normalization on the degradation baseline curve to obtain the degradation calibration value. S5. Input the training input window into the block-gated degradation coding network, extract local degradation fluctuation features through intra-block local quadratic similarity calculation, extract global degradation trend features through inter-block linear memory aggregation, and perform residual gated modulation fusion through multi-scale local gated branches to obtain the predicted value of lithium battery health status. S6. Calculate the data fitting loss based on the real health status label and the predicted value of the lithium battery health status, calculate the degradation consistency loss based on the degradation calibration value and the predicted value of the lithium battery health status, construct a joint loss function from the data fitting loss and the degradation consistency loss, and perform offline training on the block-gated degradation coding network. S7. Save the optimal model parameters, feature standardized statistical parameters, degradation baseline curve parameters and normalization parameters obtained from training, and save the window length, block length, feature order and anomaly detection threshold for use in the online evaluation stage.

[0027] The online assessment process is performed according to the following steps: S8. Obtain online operating data of lithium batteries and reuse the standardized statistical parameters of features saved during the training phase to process the online health characterization; S9. Assemble online sequence samples into inference input windows according to window length N; S10. Input the inference input window into the trained block-gated degradation coding network and output the current health state estimate of the lithium battery. S11. After obtaining the cycle index, calculate the consistency deviation between the health status estimate and the degradation calibration value. When the consistency deviation meets the anomaly judgment condition, output an abnormal consistency prompt to identify abnormal situations such as capacity recovery, accelerated degradation, sensor offset or sudden change in operating conditions. Otherwise, output the health status estimate.

[0028] The following combination Figures 4 to 7 The specific implementation process of each step is explained.

[0029] This embodiment uses lithium-ion battery data collected from a laboratory cycle aging platform as input. Each record includes at least the cycle number. The system collects data on sampling time, voltage, current, capacity, and charge / discharge status. Data is then sorted in ascending order by cycle number and sampling time to identify charging, discharging, and resting periods. Duplicate timestamps, obvious jumps, or points exceeding preset physical ranges are removed. Linear interpolation or nearest-neighbor interpolation is used for a small number of consecutive missing points. The processed data is saved by cycle number.

[0030] To facilitate implementation and ensure that the technical solution is clear and reproducible, this embodiment provides an exemplary hyperparameter configuration; each parameter can be adjusted within the corresponding value range according to the battery type, data scale and deployment scenario, and none of them exceed the protection scope of this application. Specifically: the preset window length N is 30 (range 10-100), the sliding stride is 1 (range 1-5), and the preset block length is 10 (range 5-30); the number of health representation dimensions is 12 (range 6-20); the network hidden feature dimension is 64 (range 32-256), and the dimension of each of the three sub-representations is 64; the number of output channels for each branch of the depthwise separable one-dimensional convolution is 64 (range 32-128); the SE channel recalibration compression ratio is 4 (range 2-8); the expansion factor of the compressed feedforward mapping is 4 (range 2-8); the random inactivation rate is 0.1 (range 0.05-0.3); the batch size is 64 (range 16-256); the maximum number of training epochs is 200 (range 50-500); and the initial learning rate is 0.001 (range 1×10⁻⁶). -4 ~1×10 -2 The lifespan threshold is 0.8 (range 0.7–0.9); the anomaly detection threshold is 0.05 (range 0.02–0.10); and the number of consecutive abnormal cycles is 3 (range 2–5). In data preprocessing, the effective range of the terminal voltage is a preset allowable voltage range V_min≤V≤V_max (example: 0–5V), which is set by different battery systems. The effective range of the current is a preset allowable current range (example: not exceeding 1.5 times the rated value), which is determined based on the rated capacity, test conditions, or equipment range. Linear interpolation is used to complete the data when the consecutive missing length does not exceed a preset time threshold or a preset number of sampling points (example: 3 sampling points, range 1–5). In the loss weights, the data fitting loss weights are... Set the value to 1.0 (range 0.5–2.0), for the degradation consistency loss weight. Take 0.1 (value range 0.01 to 1.0).

[0031] To ensure the reproducibility of the implementation process, the data processing module organizes each sampling point into records. ;in, The cyclic index; Sampling time; Terminal voltage; For current; This refers to capacity or cumulative power consumption. This indicates the charging, discharging, or resting state. The module should first be pressed... Grouped, then based on The system divides the system into charging and discharging segments; it also marks time reversals, repeated timestamps, and discontinuous sampling intervals within the same cycle. Records marked as abnormal are not included in health characterization statistics. Missing points are interpolated only when the missing length is within a preset fillable range; otherwise, the cycle is marked as an invalid sample.

[0032] (1) Health labeling, health characterization, and standardization. Let the first... The maximum capacity that can be released in each cycle is Rated capacity is The normalized health status labels and percentages are calculated using the following formulas: ; ; ; in, In good health; This represents the maximum capacity that can be released at present. For the first A cycle of real health status labels; For the first The maximum capacity that can be released in a cycle; This refers to the battery's rated capacity. For the first The percentage of cycles in the lithium battery's state of health.

[0033] when When the voltage drops to a preset lifespan termination threshold (0.8 in the example, ranging from 0.7 to 0.9), it can be used as a lifespan warning basis. Each cycle extracts candidate health characteristics, including at least: the time taken for the terminal voltage to rise from a first preset voltage value to a second preset voltage value during charging (in this embodiment, the first preset voltage value is 2.8V and the second preset voltage value is 4.2V, i.e., the time taken for the terminal voltage to rise from 2.8V to 4.2V during the charging phase), the duration of the constant current discharge phase, the charging time within a specified state of charge window (in this embodiment, the state of charge window is 20% to 80% SOC), the charging amount within the window, the average voltage, the maximum voltage, the minimum voltage, the end voltage of the window, and the incremental capacity peak value, peak voltage, peak area, and differential capacity statistics within the window calculated from the voltage-capacity curve, expressed as: ; in, For the first The health representation vector obtained by the loop extraction; For the first The first cycle The original health characterization value of the dimension; This refers to the number of dimensions of health characteristics, i.e., the number of types of health characteristics retained after screening.

[0034] For the extracted candidate health characteristics, calculate their linear correlation coefficient, rank correlation coefficient, mutual information, and monotonicity index with the SOH label. Retain candidate features with an absolute value of linear correlation coefficient with the SOH label of not less than 0.7, an absolute value of rank correlation coefficient of not less than 0.6, and a cross-cycle variation coefficient of not more than 0.3. For any two candidate features, if the absolute value of their linear correlation coefficient is not less than 0.95, they are judged as highly redundant, and only the one with a stronger correlation with the SOH label is retained. Remove features with unclear physical meaning or highly redundant with other candidate features, and retain features with good cross-cycle stability and strong correlation with capacity decay as the final health characteristics.

[0035] To eliminate differences in units and orders of magnitude among different features, the input features are standardized using training set statistics, specifically: ; in, For the standardized first The first cycle The original health characteristics of the microorganisms; For the first The first cycle Original health characteristics; and The first The mean and standard deviation of the original health representations of the dimension in the training set; To prevent tiny constants with a denominator of zero.

[0036] To enable the model to learn the degenerate temporal relationships between consecutive cycles, a pre-defined window method is used to construct the input samples. Let the window length be... Then, take the first The samples at the end of the window in a loop can be represented as: ; in, For the first Each loop represents an input window sample at the end of the window; ~ The standardized health representation vector covers the first... To the 1 cycle (total) (a continuous cycle); During batch training, multiple samples are combined into a three-dimensional input tensor: , This is the input tensor after combining multiple samples during batch training; This refers to the batch size.

[0037] The SOH label at the end of the window or in the next cycle is used as the supervision label; training, validation, and test data are divided in chronological order.

[0038] During sample construction, if an invalid cycle exists within a window, the window is discarded according to preset rules or filled with adjacent valid cycles of the same cell, and a completion marker is recorded; the completion marker is not used as input for health representation. Training set statistics and This statistic is calculated only from the valid window of the training set, and the validation and test sets must not update it in reverse.

[0039] (2) For example Figure 7 As shown, degradation trajectory calibration is performed. A capacity or SOH degradation sample from the training interval is selected for cyclic indexing. Using the variable as the independent variable, a nonlinear least squares method (e.g., the Levenberg-Marquardt algorithm) is used to fit the bi-exponential degradation baseline curve, as shown in the formula: Where, is the circular index. ; , , and These are the parameters to be fitted; Normalize the degradation calibration values ​​within the training interval: ;in, For the first Degradation calibration values ​​for each sample; and These are the minimum and maximum values ​​of the degradation baseline curve within the training interval, respectively; To prevent tiny constants with a denominator of zero; For the degradation baseline curve in the 1st The value taken at each loop point For the first The cyclic index corresponds to each sample; the normalization parameter remains unchanged during the validation, testing, and online evaluation phases.

[0040] As an alternative implementation, the degradation baseline curve can also be a piecewise exponential curve, a Logistic curve, a Verhulst curve, or a polynomial-exponential combination curve. The corresponding parameters are fitted according to the training interval and the training interval is normalized. Its function is the same as that of the double exponential degradation baseline curve.

[0041] (3) Block-gated degenerate coding network.

[0042] like Figure 4As shown, the embodiment of the present invention constructs a block-wise gated degradation encoding network, which is used to learn the non-linear mapping relationship between the health representation sequence and the battery SOH. This network mainly includes a feature embedding layer, a shared linear projection layer, a hybrid block-wise attention unit, a multi-scale local gating branch, a residual gated fusion unit, a compressive feedforward mapping unit, a pooling layer, and a health state regression output layer. The specific process is as follows: First, the input tensor corresponding to the training input window is input to the feature embedding layer to obtain an embedded feature, which is expressed as: ; where, is the embedded feature; is the input tensor corresponding to the training input window; is the weight matrix of the feature embedding layer; is the bias term of the feature embedding layer; The embedded feature is normalized, then input to the shared linear projection layer for linear transformation, and split into , , three paths, specifically as follows: ; where, the sub-representation is used for the multi-scale local gating branch; the sub-representation is used for value information transfer; the sub-representation is used for similarity index calculation; denotes the layer normalization operation, denotes splitting along the channel dimension; and respectively denote the weight matrix and the bias term of the shared linear projection layer.

[0043] The sub-representation , the sub-representation and the sub-representation are respectively divided into a plurality of sequence blocks along the time dimension according to a preset block length; if the preset window length cannot be exactly divided by the preset block length, zero vectors are padded at the end of the sequence of each sub-representation, and rearranged into block tensors to obtain the block-wise sub-representations; wherein the padded sequence length is expressed as: ; where, is the sequence length that meets the complete block requirement after padding with zero vectors; is the number of sequence blocks; is the preset block length; The block-wise sub-representation can be expressed as: ; where, is the block-wise sub-representation (similarity index representation); is the batch size; is the number of sequence blocks; Preset block length; This refers to the implicit feature dimension.

[0044] like Figure 5 As shown, in the intra-block local quadratic similarity calculation, the model projects the similarity index representation to obtain the intra-block query vector and key vector: ;in, This is the query vector within the block; The key vector within the block; and These represent the intra-block query projection matrix and the intra-block key projection matrix, respectively. Using rotation angle position encoding (RoPE) to determine relative position offset and Apply a rotational phase transformation to obtain the phase-transformed intra-block query vector. and intra-block key vector Specifically: Where RoPE (Rotary Position Embedding) represents the rotation angle position encoding. Then, the local score within the block is calculated: ;in, For local fractions within the block; For query vector dimensions; Furthermore, the local weights are obtained by applying the ReLU squared kernel to the local scores: Combine the local weights with the sub-representations after block division. Perform matrix multiplication to obtain local output; In the inter-block linear memory path: inter-block query projection and key projection are performed on the sub-representations after block partitioning to obtain the inter-block query vector and inter-block key vector, specifically: ;in, This is the inter-block query vector; The inter-block key vector; and These represent the inter-block query projection matrix and the inter-block key projection matrix, respectively. Then construct the memory representation of each block: according to The memory tensor is constructed and aggregated by taking the outer product of the key vector and the corresponding value vector of each sequence block and summing them along the time dimension; where, For the first The memory representation corresponding to each block; For the inter-block path, the first The key vector at each time step; The value representation after block division is the first A vector of values ​​for each time step; Then, the global output is obtained by performing a linear readout of the memory tensor using the inter-block query vector, as shown below: .

[0045] Finally, the local output within a block is added to the global output between blocks, and the hybrid block attention is obtained through a linear output mapping: ; For mixed block attention; For local output; For global output; To output the linear mapping weight matrix.

[0046] like Figure 6 As shown, further, the multi-scale local control branches are represented by sub-branches. As input, depthwise separable one-dimensional convolutions with kernel lengths of 1×3, 1×5, and 1×7 are used, where "1×" indicates no expansion in the non-temporal dimension, to extract local response features at three different time scales; specifically: ; in, The output features of the branch with a convolutional kernel length of 3 (capturing short-term local responses); The output features of the branch with a kernel length of 5 (capturing mid-term local responses); The output features of the branch with a convolution kernel length of 7 (capturing local responses in a wider neighborhood); For depthwise separable one-dimensional convolutions, the subscripts 3 / 5 / 7 represent the kernel lengths, corresponding to different temporal neighborhood ranges.

[0047] Then, the local responses at different scales are stitched together: ;in, These are the spliced ​​multi-scale local features; This is a feature splicing operation.

[0048] A comprehensive local representation is obtained through linear fusion and channel recalibration: ;in, To integrate and recalibrate multi-scale local features; For the compression-excitation channel recalibration operation, different feature channels are adaptively weighted according to their importance; The linear fusion weight matrix is ​​a multi-scale local feature matrix that maps the spliced ​​features to a unified dimension. Furthermore, the SiLU (Sigmoid Linear Unit) activation function and the Sigmoid function are used to generate gated tensors: ;in, It is a gate tensor with a value range of (0,1), used for element-wise adaptive modulation of the hybrid block attention output; Furthermore, a residual-gated fusion unit is used to fuse the hybrid block attention output with the gating tensor: ;in, Features of fusion; For mixed block attention; For gating tensors; The gated fusion result, after being linearly mapped and connected to the output, is input into a compressed feedforward mapping unit. This unit includes layer normalization, linear expansion, SiLU activation, linear compression, random deactivation, and residual output, and its expression can be summarized as follows: ;in, For learnable residual weights; and Let represent the linear expansion matrix and the linear compression matrix in the feedforward mapping, respectively; The output linear mapping matrix represents the gated fusion features; This represents the sequence representation of the gated fusion result after output mapping and connection of the first residual; This represents the sequence representation after compressed feedforward mapping and second residual connection. For layer normalization; This is a random deactivation operation.

[0049] After one or more coding units are stacked, the final sequence representation is pooled. Pooling can be either mean pooling or end pooling. If mean pooling is used, then: ;in, This is the sequence-level health status representation vector obtained after pooling; for The Middle Feature representation of each time step.

[0050] If end-pooling is used, then: ;in, The end of the window, i.e., the first Feature representation of each time step.

[0051] Finally, the predicted SOH value is obtained through the health status regression output layer: ;in, The predicted SOH value of the battery output by the model; Output the mapping function for health status regression.

[0052] (4) Joint training. Calculate separately for each of the M samples in a batch.

[0053] A joint training mechanism with single output and multiple constraints is adopted. For the... There are training samples, and the true SOH label is... The model predicts the value. The degradation calibration value is .

[0054] The data fitting loss is defined as: ; Degradation consistency loss is defined as: ; The final joint loss function is: ;in, The data fitting loss between the predicted health status of the lithium battery and the actual health status label; The degradation consistency loss between the predicted health status of the lithium battery and the degradation calibration value; and These are the loss weighting coefficients; In an embodiment, A value of 0.1 (ranging from 0.01 to 1.0) can be set as a fixed small weight or dynamically adjusted according to the training epochs. For example, in the early stages of training, the weight of the degradation consistency loss can be appropriately increased to allow the model to form a reasonable degradation trend; in the later stages of training, the weight of the degradation consistency loss can be reduced to allow the model to more fully fit the local fluctuations and nonlinear changes in the real samples.

[0055] The model is trained using the backpropagation algorithm to update parameters. The Adam optimizer can be used (example initial learning rate is 0.001, range 1×10). -4 ~1×10 -2 The algorithm iteratively optimizes the system (and iterates with each training round). Each training round includes the following steps: inputting a batch of samples into the block-gated degradation coding network; performing forward propagation to obtain the SOH prediction value; and calculating the SOH prediction value based on the real health status label and degradation calibration value. , and Perform backpropagation to calculate gradients; update network parameters based on the optimizer; calculate validation error on the validation set and determine whether to save the current optimal model.

[0056] Training stops if the maximum number of training epochs is reached (200 in the example, ranging from 50 to 500), the validation set error does not decrease for several consecutive epochs (10 consecutive epochs in the example), or the joint loss function falls below a preset threshold. After training, the system saves the following: model weight parameters, feature standardization parameters, degradation baseline curve parameters, normalization parameters, window length, block length, feature order, and anomaly detection threshold. These parameters can be saved as binary model files, structured configuration files, or database records for use during online evaluation.

[0057] (5) During the online evaluation phase, the system first reads the real-time or incremental operating data of the lithium battery to be evaluated. The real-time data can be collected by the battery management system, experimental testing platform or energy storage monitoring terminal, including parameters such as cycle number, sampling time, voltage, current, capacity, and charge / discharge status.

[0058] The system follows the same data processing rules as the offline training phase to handle outliers, complete missing values, align time, and unify units. It then uses the health representation extraction method determined during the training phase to construct the health representation vector corresponding to the current loop or the current sampling segment. Subsequently, the system standardizes the real-time health representation using the mean and standard deviation saved during the training phase, and takes the most recent value. The input window is constructed using a loop or sampling segment.

[0059] The input window is fed into the trained block-gated degradation coding network, and the SOH estimate of the lithium battery at the current cycle or the current sampling time is obtained through forward propagation: ;in, The estimated SOH value of the battery output by the model; The optimal model parameters are saved for the offline training phase; A battery input window constructed for the online phase.

[0060] If the online system can obtain the current circular index Then, the current degradation calibration value can be calculated simultaneously based on the degradation trajectory calibration module. And calculate the deviation between the model predictions and the degradation calibration values: ;in, For the first Consistency deviation between the predicted value and the degradation calibration value corresponding to each cycle or sampling window.

[0061] when If the value exceeds a preset threshold, or exceeds the threshold in multiple consecutive loop windows, the system can output an abnormal consistency warning to help determine whether the battery has abnormal conditions such as capacity recovery, accelerated degradation, sensor misalignment, or sudden changes in operating conditions. It should be noted that this consistency judgment result is only used as auxiliary diagnostic information and does not directly replace the SOH estimate output by the model.

[0062] For the lithium battery to be evaluated, the system will output the current window's output. This serves as an estimate of the SOH (State of Harm) of the battery at the current cycle or current sampling time. If SOH is expressed as a percentage, it can be written as: ; in, Indicates the first The battery health status corresponding to each cycle or sampling window. This represents the normalized SOH estimate from the model output. If it is necessary to statistically analyze the battery health level over a specific time period or several cycles, the average SOH of the battery within the statistical period can be calculated. ;in, Indicates the number of valid samples within the statistical period. Indicates the first The estimated state of harm (SOH) of the battery for each sampling point or cycle. This statistical result can be used to reflect the overall health level and degradation trend of the battery within a specified time range.

[0063] (6) Online evaluation implementation steps. The online evaluation is performed according to the following steps, with the example parameters for each step remaining consistent with those in the offline training phase: ① Data acquisition: Read the real-time or incremental operating data of the battery to be evaluated, including cycle number, sampling time, voltage, current, capacity and charge / discharge status, and cache the most recent N cycles (N is 30, with a value range of 10 to 100). ② Data Processing: Following the same data processing rules as the offline training phase, outliers exceeding the preset physical range are removed; the preset physical range includes: the terminal voltage being within a preset allowable voltage range. (Example) (0V is meaningless in actual engineering implementation, so the value does not include 0V). The preset allowable voltage range is set by different battery systems. The current is within the preset allowable current range (for example, not exceeding 1.5 times the rated value). The preset allowable current range is determined based on the rated capacity, test conditions, or equipment range. For data with a continuous missing length not exceeding the preset time threshold or the preset number of sampling points (for example, not exceeding 3 sampling points), linear interpolation is used to complete the data and time alignment is performed. ③Health characterization extraction: Construct the health characterization vector of the current cycle according to the health characterization extraction method disclosed in this embodiment (1), including at least the time taken for the terminal voltage to rise from 2.8V to 4.2V, the duration of the constant current discharge stage, the charging time and charging amount within the 20% to 80% SOC window, the average voltage, maximum voltage, minimum voltage, end voltage of the window, as well as the incremental capacity peak value, peak voltage, peak area and differential capacity statistics within the window; ④Standardization and window construction: The mean and standard deviation of each feature saved in the training phase are reused to standardize the online health representation, and the N most recent valid loops are used to construct the inference input window; if there are less than N valid loops, the "window is not full" status is output and the system waits for subsequent data, or the window is formed according to the completion rules determined in the training phase, but the standardized statistical parameters in the training phase are not modified. ⑤ Model Inference: Input the inference input window into the trained block-gated degradation coding network, and output the estimated value of the lithium battery health status in the current cycle through forward propagation; ⑥ Calibration and Deviation Calculation: Obtain the current cycle index, calculate the current degradation calibration value using the degradation baseline curve parameters saved during the training phase, and calculate the consistency deviation between the health status estimate and the degradation calibration value; ⑦ Anomaly detection: When the consistency deviation exceeds the preset threshold (0.05 in the example, with a value range of 0.02 to 0.10) and continues for more than 3 consecutive cycles (with a value range of 2 to 5), an abnormal consistency prompt is output to identify abnormal situations such as capacity recovery, accelerated degradation, sensor offset, or sudden changes in operating conditions; otherwise, an estimated health status value is output. ⑧ Output Results: Output the health status estimate, degradation calibration value, consistency deviation, cycle index, sampling time and abnormal consistency prompts to a structured file or monitoring platform to form a traceable assessment record.

[0064] Experimental Setup. Experimental data were collected from a laboratory cyclic aging platform using full-lifecycle charge-discharge cycle data of commercial 18650 ternary lithium-ion batteries (rated capacity 2.0Ah, charging cut-off voltage 4.2V, discharging cut-off voltage 2.8V). A total of 96 batteries were used, with approximately 1000 cycles per battery. The sampling period was 1 second, and the ambient temperature was maintained at 25°C. Training, validation, and test sets were divided according to battery number, with a ratio of approximately 7:1:2. All cycles of the same battery were assigned to only one set. Training set statistics were calculated only from the effective window of the training set; validation and test set statistics were not updated. The model structure, health characteristics, window length, and hyperparameters were set according to the exemplary configuration in Example 1. The comparison methods include: a full model variant with the degradation consistency loss removed, CNN-LSTM (two layers of convolutional and two layers of long short-term memory stacked together), and a global attention network (using standard multi-head self-attention instead of hybrid block attention units). Each comparison method employs the same data processing, feature extraction, windowing, and evaluation process as the full model, with network parameter counts kept to a similar order of magnitude. All methods are trained on the same training set and evaluated on the same test set. Table 1 shows the prediction performance comparison of each method on the test set, and Table 2 shows the performance comparison of different degradation consistency loss weight schemes under small sample conditions.

[0065] Refer to Table 1, which shows a comparison of the predictive performance of different health status assessment methods on the test set.

[0066] Table 1. Comparison of predictive performance of different health status assessment methods on the test set. Under the same data processing and evaluation metrics, the prediction performance of the complete model of this invention on the test set compared with three other methods—removing degradation consistency loss, CNN-LSTM, and global attention—is shown in Table 1. The scatter distribution of the prediction results of the complete model of this invention on the test set is shown in Table 1. Figure 8 As shown, the prediction error distribution is as follows: Figure 9 As shown.

[0067] The complete model employs a local quadratic similarity path to capture differences between adjacent degenerate segments, a linear memory path to preserve long-range trends, multi-scale gating to select responses at different time scales, and degradation consistency loss to suppress unfounded trend drift. Therefore, under the same data processing and evaluation metrics, the complete model is expected to improve both error and trend consistency simultaneously.

[0068] (7) Results output and visualization After the online evaluation is completed, the system outputs the estimated SOH value, degradation calibration value, degradation calibration deviation, cycle index, sampling time, and abnormal consistency prompts of the lithium battery to a structured file or database. The output format includes, but is not limited to, CSV files, Excel files, JSON files, database records, SOH change curves, or monitoring platform interfaces.

[0069] Example 2 This embodiment illustrates the implementation method when there are few training samples, incomplete cycling segments, or individual differences between the battery to be evaluated and the training battery. Early cycling segments of multiple batteries are selected as the training set, and the validation set and test set are divided according to the battery number to ensure that data from the same test battery are not included in the training set; health characterization, standardization, preset window, degradation curve, network forward process, and online output are all consistent with Embodiment 1.

[0070] In practice, data partitioning is performed using the battery number as the grouping key: first, cyclic sorting and feature extraction are completed within each battery; then, complete batteries are assigned to training, validation, or test sets to avoid adjacent cycles of the same battery appearing in both the training and test sets. For test batteries containing only partial cycles, their N most recent valid cycles are used to form the online inference input window. If there are fewer than N data points, output "window not full" status and wait for subsequent data, or form a window according to the established filling rules, but do not modify the standardized parameters during the training phase.

[0071] In this embodiment, the online deployment is completed collaboratively by the edge acquisition end and the evaluation end: the edge acquisition end is only responsible for caching the voltage, current, time, capacity, and charge / discharge status of the most recent N cycles; the evaluation end reuses the standardized statistical parameters of the features saved during the training phase to standardize the online health characterization, calculates the degradation calibration value of the current cycle based on the degradation baseline curve parameters fitted in the training interval, and loads the optimal model parameters saved during training to complete one forward inference, outputting the current lithium battery health status estimate; the inference result, along with consistency deviation and abnormal consistency prompts, is written back to the battery number, cycle number, and timestamp to form a traceable record.

[0072] This embodiment uses a double exponential degradation baseline curve and normalized degradation calibration values ​​to generate a degradation calibration signal; when different batteries have different cycle start points or capacity scales, parameters are fitted in the training interval of each battery. , , and The network is normalized using the minimum and maximum values ​​of its respective training intervals. The forward process of the network still sequentially performs the following steps: input embedding, sub-representation splitting, sequence padding, query vector and key vector projection, rotation position encoding (RoPE), intra-block local quadratic similarity, inter-block linear memory aggregation, multi-scale depthwise separable convolution, channel recalibration, residual gated fusion, and compressed feedforward mapping.

[0073] During training, the data fitting loss weights are kept dominant, with a higher weight for degradation consistency loss in the early stages and gradually reduced as the validation set error stabilizes. This dynamic weighting allows the network to first establish a reasonable degradation trajectory before learning capacity regeneration and individual differences. In the online phase, the network feeds forward to output the current cycle SOH estimate and calculates the consistency deviation between the model prediction and the degradation calibration value.

[0074] The complete model of this invention is compared with two schemes: "fixed large weights with degenerate consistency loss" and "no degenerate consistency loss". Table 2 is used to illustrate the evaluation organization method under small sample conditions.

[0075] Table 2 Comparison of health status assessment performance of different schemes under small sample conditions The degradation consistency loss does not force the degradation curve as the output, but rather applies a soft constraint to the output layer. Therefore, when the tested battery experiences a capacity recovery or local operating condition changes, the data fitting term can still cause the predicted value to deviate from the baseline curve, and the model simultaneously uses consistency bias to indicate anomalies. This allows the overall degradation direction to be maintained under small sample conditions while retaining responsiveness to individual differences.

[0076] When the validation set error no longer improves within a certain number of consecutive training epochs, the λ² decay phase can be initiated earlier; if the degradation curve deviates from the true health status label for a long period, the current state should be maintained. Alternatively, the degradation curve parameters can be refitted and training can continue. This adjustment is based on the number of training epochs and validation set metrics, without changing the network structure described in the claims, and without directly using the degradation calibration values ​​as online output.

[0077] The system outputs the estimated SOH value, degradation calibration value, consistency deviation, abnormal consistency prompts, and statistical periodic average SOH for the current cycle or sampling window. The output can be saved as CSV, Excel, database records, or monitoring platform messages and used for lifespan warning, operation and maintenance, and anomaly verification.

[0078] Example 3 This embodiment also provides a lithium battery health status assessment system for implementing the lithium battery health status assessment methods described in Embodiments 1 and 2 above. Figure 2 As shown, the system includes a data processing module, a health characterization construction module, a degradation trajectory calibration module, a block-gated degradation coding module, an offline training module, and an online evaluation module.

[0079] The data processing module sorts historical or online operating data of lithium batteries, identifies charge / discharge / rest periods, handles outliers, completes missing values, and performs time-aligned preprocessing to obtain preprocessed charge / discharge data. The health characterization construction module extracts candidate health characters from the preprocessed charge / discharge data, filters them based on correlation, monotonicity, and cross-battery stability to obtain a health characterization sequence, performs standardization, and constructs an input window according to a preset window length. The degradation trajectory calibration module fits a degradation baseline curve based on a historical sample cyclic index, normalizes the training interval of the degradation baseline curve to generate degradation calibration values, which are only used as soft constraint signals during the training phase and do not directly output health state prediction results. The block-gated degradation coding module includes a feature embedding layer, a shared linear projection layer, a hybrid block attention unit, and multiple... The system comprises a scale-based local gated branch, a residual gated fusion unit, a compressed feedforward mapping unit, a pooling layer, and a health status regression output layer. A hybrid block attention unit configures intra-block local quadratic similarity paths and inter-block linear memory paths. A multi-scale local gated branch configures multi-path depthwise separable one-dimensional convolutions and SE channel recalibration sub-units to generate gated tensors. An offline training module constructs a joint loss function including data fitting loss and degradation consistency loss, performs offline network training, and saves the optimal model parameters, feature-standardized statistical parameters, degradation baseline curve parameters, and normalized parameters. An online evaluation module loads the optimal model parameters and feature-standardized statistical parameters, processes online running data, outputs lithium battery health status estimates, calculates consistency deviations, and outputs abnormal consistency alerts when anomaly detection conditions are met.

[0080] The system in this embodiment can be implemented by software, hardware, or a combination of both, and can be deployed in a battery management system, edge computing node, or energy storage monitoring server. During the online evaluation phase, the trained model can be converted into a lightweight inference format such as ONNX or TensorRT to meet the real-time inference requirements of the edge. The specific working process of the system when executing the above method is the same as that in Embodiments 1 and 2, and will not be repeated here.

[0081] The above are all preferred embodiments of this application, and are not intended to limit the scope of protection of this application. Therefore, all equivalent changes made in accordance with the structure, shape and principle of this application should be covered within the scope of protection of this application.

Claims

1. A lithium battery health status assessment method integrating block-gated coding and degradation trajectory constraints, characterized in that, This includes offline training processes and online evaluation processes; The offline training process includes: Read historical cycle operation data of lithium battery, sort by cycle number and sampling time, identify charging segment, discharging segment and resting segment, and preprocess outlier, missing point and time misalignment data to obtain preprocessed charge and discharge data; Candidate health characteristics related to capacity degradation were extracted from preprocessed charge-discharge data, and health characteristic sequences were obtained by screening based on correlation, monotonicity and cross-cell stability. The health representation sequence is standardized using a preset window of length N, and the health representation vectors corresponding to consecutive cycles are used as the training input window. The degradation baseline curve is fitted based on the historical sample cyclic index, and the degradation calibration value is obtained by normalizing the training interval. The training input window is input into the block-gated degradation coding network. Local degradation fluctuation features are extracted by intra-block local quadratic similarity calculation, and global degradation trend features are extracted by inter-block linear memory aggregation. A gate tensor is generated by multi-scale local gate branches. The hybrid block attention and the gate tensor are fused with residual gate to output the predicted value of lithium battery health status. The data fitting loss is calculated based on the real health status label and the predicted value of the lithium battery health status; the degradation consistency loss is calculated based on the degradation calibration value and the predicted value of the lithium battery health status. A joint loss function is constructed to train the network offline, and the optimal model parameters, feature standardized statistical parameters, degradation baseline curve parameters and normalized parameters are saved. The online assessment process includes: Acquire online running data, reuse the saved feature standardization statistical parameters to process and construct the inference input window, input the trained network to output the current lithium battery health state estimate; after obtaining the cycle index, calculate the consistency deviation between the health state estimate and the degradation calibration value, and output an abnormal consistency prompt when the consistency deviation meets the abnormal judgment condition.

2. The lithium battery health status assessment method based on the fusion of block-gated coding and degradation trajectory constraints according to claim 1, characterized in that, The true health status label is determined based on the ratio of the maximum capacity that the battery can discharge in the current cycle to the battery's rated capacity. The normalized label expression is: Health status in percentage form: ;in, For the first A cycle of real health status labels; For the first The maximum capacity that can be released in a cycle; This refers to the battery's rated capacity. For the first The percentage of cycles in the lithium battery's state of health.

3. The lithium battery health status assessment method based on the fusion of block-gated coding and degradation trajectory constraints according to claim 1, characterized in that, The candidate health characteristics include at least the following: the time it takes for the terminal voltage to rise from a first preset voltage value to a second preset voltage value during the charging process, the duration of the constant current discharge stage, the charging time within a specified state of charge window, the charging amount, the average voltage, the maximum voltage, the minimum voltage, the end voltage of the window, and the incremental capacity peak value, peak voltage, peak area, and differential capacity statistics within the window calculated from the voltage-capacity curve.

4. The lithium battery health status assessment method based on the fusion of block-gated coding and degradation trajectory constraints according to claim 1, characterized in that, The health characteristic sequences are standardized using training set statistics, calculated as follows: ; in, For the standardized first The first cycle The original health characteristics of the microorganisms; For the first The first cycle Original health characteristics; and The first The mean and standard deviation of the original health representations of the dimension in the training set; To prevent tiny constants with a denominator of zero.

5. The lithium battery health status assessment method based on the fusion of block-gated coding and degradation trajectory constraints according to claim 1, characterized in that, The expression for the degradation baseline curve is: ;in, Circular index; , , and These are the parameters to be fitted; The degradation calibration value is calculated as follows: ;in, For the first Degradation calibration values ​​for each sample; and These are the minimum and maximum values ​​of the degradation baseline curve within the training interval, respectively; To prevent tiny constants with a denominator of zero; For the degradation baseline curve in the 1st The value taken at each loop point For the first The circular index corresponding to each sample.

6. The lithium battery health status assessment method based on the fusion of block-gated coding and degradation trajectory constraints according to claim 1, characterized in that, The block-gated degenerate coding network includes: a feature embedding layer, a shared linear projection layer, a hybrid block attention unit, a multi-scale local gated branch, a residual gated fusion unit, a compressed feedforward mapping unit, a pooling layer, and a health state regression output layer. The training process of the block-gated degenerate coding network includes: The input tensor corresponding to the training input window is input into the feature embedding layer to obtain the embedded features, represented as follows: ;in, For embedded features; The input tensor corresponding to the training input window; The weight matrix of the feature embedding layer; For the bias term of the feature embedding layer; After normalizing the embedded features, they are input into the shared linear projection layer for linear transformation and then split into three sub-representations. , and ; where, child represents For use in multi-scale local control branches; sub-representation For use in value information transmission; sub-representation For use in similarity index calculation; dividing the sub-representation , the sub-representation and the sub-representation into a plurality of sequence blocks respectively along the time dimension according to a preset block length; if the preset window length cannot be exactly divided by the preset block length, zero vectors are padded at the end of the sequence of each sub-representation, and rearrangement is performed to form a block tensor, so as to obtain the blocked sub-representations; The length of the padded sequence is expressed as: ;in, The length of the sequence that meets the requirements for complete block segmentation after being padded with zero vectors; The number of sequence blocks; The preset block length; The sub-representations after partitioning The multi-scale local control branch is fed into the sub-representation after partitioning. Hezi means The data is fed into the hybrid block attention unit for parallel processing. The hybrid block attention unit is represented by a block-based sub-representation. For similarity indexing, use the sub-representation after block division. Perform calculations on the value information, specifically: In the intra-block local quadratic similarity path, the sub-representations after block division Similarity projection is performed to obtain the query vector and key vector. After rotation angle encoding, the local similarity score between the query vector and the key vector is calculated. The ReLU squared kernel transform is performed on the local similarity score to obtain the local weight. The local weight is then applied to the sub-representation after block division. Get partial output; In the inter-block linear memory aggregation path, the sub-representations after block division Perform linear projection to obtain inter-block query vectors and key vectors. Perform an outer product operation between the key vectors and the corresponding value vectors to construct block memories. Aggregate the block memories to obtain a memory tensor. Read the memory tensor from the inter-block query vectors to obtain the global output. Add the local output to the global output to complete local-global fusion. After restoring the original sequence length and removing padding, perform an output linear mapping to output hybrid block attention. The multi-scale local control branch is represented by a block-based sub-representation. Perform operations on the input and output a gated tensor; The hybrid block attention and the gate tensor are input into the residual gated fusion unit, and element-wise multiplication and fusion are performed to obtain the fused features; The fused features are fed into the compressed feedforward mapping unit, where feature expansion, activation, linear compression, random deactivation, and residual connection processing are performed sequentially to output the processed sequence features. The processed sequence features are input into the pooling layer for pooling processing, and then sent to the health status regression output layer to output the predicted value of the lithium battery health status.

7. The lithium battery health status assessment method based on the fusion of block-gated coding and degradation trajectory constraints according to claim 6, characterized in that, The hybrid block-based attention unit includes intra-block local quadratic similarity calculation and inter-block linear memory aggregation; the sub-representations after block division are rearranged into dimensions. The block tensor; where, Batch size; The number of sequence blocks; The preset block length; For implicit feature dimensions; In the intra-block local quadratic similarity path: for the sub-representations after block division Perform query projection and key projection to obtain the intra-block query vector. and intra-block key vector ; Using rotation angle position encoding RoPE to determine relative position offset and Apply a rotational phase transformation to obtain the phase-transformed intra-block query vector. and intra-block key vector ;Calculate the local fraction within the block as follows: ;in, For local fractions within the block; The query vector dimension is used; a ReLU squared kernel transformation is performed on the local scores within the block to obtain the local weights. Combine the local weights with the sub-representations after block division. Perform matrix multiplication to obtain local output; In the inter-block linear memory path: the sub-representation after block division Perform inter-block query projection and key projection to obtain the inter-block query vector. and inter-block key vector ;according to The memory tensor is constructed and aggregated by taking the outer product of the key vector and the corresponding value vector of each sequence block and summing them along the time dimension; where, For the first The memory representation corresponding to each block; For the inter-block path, the first The key vector at each time step; The value representation after block division is the first The value vector of each time step; the global output is obtained by performing a linear readout of the memory tensor using the inter-block query vector; The hybrid block attention is obtained by adding the local output to the global output and then performing an output linear mapping.

8. The lithium battery health status assessment method based on the fusion of block-gated coding and degradation trajectory constraints according to claim 6, characterized in that, The multi-scale local control branch is represented by a sub-branch. As input, depthwise separable one-dimensional convolutions with kernel lengths of 1×3, 1×5, and 1×7 are used to extract local response features at three different time scales. The three local response features are concatenated and then linearly fused and SE channel recalibrated sequentially. After SiLU activation and Sigmoid function operation, a gated tensor is generated. The residual gated fusion unit fuses the hybrid block attention with the gated tensor element-wise, outputting fused features; wherein, the expression of the fused features is: ;in, The fusion feature; For the hybrid block attention; Let this be the gate tensor; The fused features are fed into the compressed feedforward mapping unit, where feature expansion, activation, linear compression, random deactivation, and residual connection processing are performed sequentially to output the final processed sequence features.

9. The lithium battery health status assessment method based on the fusion of block-gated coding and degradation trajectory constraints according to claim 1, characterized in that, The joint loss function is expressed as follows: ; in, The data fitting loss between the predicted health status of the lithium battery and the actual health status label; The degradation consistency loss between the predicted health status of the lithium battery and the degradation calibration value; and These are the loss weighting coefficients; The degradation consistency loss weights are dynamically adjusted with each training round: in the early stages of training, the constraint weights are maintained or increased to enhance the degradation trend constraint, and in the later stages of training, the constraint weights are reduced to release the network's ability to learn local nonlinear degradation features.