A method and system for fault diagnosis of lithium-ion batteries based on time series analysis

By combining time series analysis and a static hybrid expert convolutional network model with CPU and GPU heterogeneous platforms, high-accuracy and low-latency detection of lithium-ion battery faults is achieved, solving the problems of low diagnostic accuracy and difficult embedded deployment in existing technologies. It is applicable to electric vehicles and energy storage systems.

CN121348113BActive Publication Date: 2026-04-03CENT SOUTH UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-12-16
Publication Date
2026-04-03

AI Technical Summary

Technical Problem

Existing lithium-ion battery fault diagnosis methods have low accuracy, making it difficult to meet the safety and reliability requirements of battery systems. Furthermore, existing models are difficult to deploy in real time on resource-constrained embedded hardware platforms.

Method used

A time series analysis-based approach is adopted to construct a time series by acquiring the voltage, current, and temperature signals of lithium-ion batteries. Preprocessing and periodic feature extraction are then performed, and a static hybrid expert convolutional network model is used for fault diagnosis. Embedded deployment is achieved on CPU and GPU heterogeneous platforms using the ONNX model.

Benefits of technology

It improves the accuracy of fault diagnosis for lithium-ion batteries and realizes real-time fault detection with low latency and low power consumption on an embedded hardware platform, making it suitable for resource-constrained environments such as electric vehicles and energy storage systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121348113B_ABST
    Figure CN121348113B_ABST
Patent Text Reader

Abstract

This application discloses a method and system for fault diagnosis of lithium-ion batteries based on time series analysis. The method involves preprocessing the time series to obtain a preprocessed time series; extracting periodic features based on the preprocessed time series; reconstructing the preprocessed time series using the periodic features to obtain a two-dimensional reconstruction matrix; and generating a mask matrix using the periodic features. The two-dimensional reconstruction matrix and the mask matrix are then multiplied element-wise to obtain an element-wise multiplication result. This result is input into a trained static hybrid expert convolutional network model to obtain a target feature vector. The target feature vector is then input into a fully connected neural network to generate a target reconstruction sequence. The reconstruction error between the target reconstruction sequence and the preprocessed time series is calculated. Based on this reconstruction error, fault diagnosis is performed on the lithium-ion battery to be diagnosed, yielding a fault diagnosis result. This application can improve the accuracy of fault diagnosis for lithium-ion batteries.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of battery fault diagnosis technology, and in particular to a lithium-ion battery fault diagnosis method and system based on time series analysis. Background Technology

[0002] Lithium-ion batteries, with their high energy density and long cycle life, are widely used in electric vehicles, energy storage systems, and mobile electronic devices. However, during operation, lithium-ion batteries undergo continuous complex electrochemical and thermodynamic reactions. Long-term influence from factors such as ambient temperature, charge / discharge rate, and aging can lead to varying degrees of failure in lithium-ion batteries. The severity can progress from initial increased polarization to capacity decay, and even dangerous situations like internal short circuits. If these failures are not detected in time, they can trigger thermal runaway accidents, posing serious safety risks. Therefore, online monitoring and fault diagnosis of lithium-ion battery operating status have become key technologies for ensuring the safe and reliable operation of battery systems.

[0003] Currently, research on lithium-ion battery fault diagnosis both domestically and internationally mainly focuses on three types of methods: knowledge-based analysis methods, model-based inference methods, and data-driven intelligent algorithms. However, the accuracy of existing methods for lithium-ion battery fault diagnosis is relatively low. Summary of the Invention

[0004] This application aims to propose a method and system for fault diagnosis of lithium-ion batteries based on time series analysis, which can improve the accuracy of fault diagnosis of lithium-ion batteries.

[0005] In a first aspect, embodiments of this application provide a lithium-ion battery fault diagnosis method based on time series analysis, the method comprising:

[0006] Acquire multiple lithium-ion battery signals of the lithium-ion battery to be diagnosed, and construct the multiple lithium-ion battery signals into a time series, the multiple lithium-ion battery signals including voltage, current and temperature;

[0007] The time series is preprocessed to obtain a preprocessed time series;

[0008] Based on the preprocessed time series, periodic features are extracted;

[0009] The preprocessed time series is reconstructed using the periodic features to obtain a two-dimensional reconstruction matrix, and a mask matrix is ​​generated using the periodic features.

[0010] The two-dimensional reconstruction matrix is ​​multiplied element-wise with the mask matrix to obtain the element-wise multiplication result;

[0011] The element-wise multiplication result is input into the trained static hybrid expert convolutional network model to obtain the target feature vector;

[0012] The target feature vector is input into a fully connected neural network to generate a target reconstruction sequence;

[0013] The reconstruction error between the target reconstruction sequence and the preprocessed time series is calculated. Based on the reconstruction error, the lithium-ion battery to be diagnosed is subjected to fault diagnosis to obtain the fault diagnosis result.

[0014] Compared with the prior art, the first aspect of this application has the following beneficial effects:

[0015] This method acquires multiple lithium-ion battery signals from the lithium-ion battery to be diagnosed and constructs them into a time series, including voltage, current, and temperature. The time series is preprocessed to obtain a preprocessed time series. Periodic features are extracted from the preprocessed time series. The preprocessed time series is reconstructed using these periodic features to obtain a two-dimensional reconstruction matrix, and a mask matrix is ​​generated using the periodic features. The two-dimensional reconstruction matrix and the mask matrix are multiplied element-wise to obtain the element-wise multiplication result. This result is input into a trained static hybrid expert convolutional network model to obtain a target feature vector. The target feature vector is then input into a fully connected neural network to generate a target reconstruction sequence. The reconstruction error between the target reconstruction sequence and the preprocessed time series is calculated. Based on this reconstruction error, fault diagnosis is performed on the lithium-ion battery to be diagnosed, yielding the fault diagnosis result. Thus, by first extracting periodic features, the main periodic components in the battery's operating state can be identified; then, the preprocessed time series is reconstructed using the periodic features to generate a mask matrix, completing a unified mapping from spectral analysis to static tensor input, which can provide a unified input for subsequent static hybrid expert convolutional network models and deployment inference; then, the target feature vector is extracted through the trained static hybrid expert convolutional network model to perform fault diagnosis on the lithium-ion battery to be diagnosed, which can improve the accuracy of lithium-ion battery fault diagnosis.

[0016] In some embodiments, the preprocessing of the time series to obtain a preprocessed time series includes:

[0017] The time series is standardized to obtain a standardized time series;

[0018] The standardized time series is input into the embedding layer to obtain embedded features, which are then used as the preprocessed time series.

[0019] In some implementations, extracting periodic features based on the preprocessed time series includes:

[0020] The preprocessed time series is rearranged into a matrix to obtain the rearranged matrix;

[0021] Based on the rearranged matrix, construct a real matrix and an imaginary matrix of fixed dimensions;

[0022] Calculate the amplitude spectrum based on the real part matrix and the imaginary part matrix;

[0023] Based on the amplitude spectrum, calculate the average amplitude of each sampling point across all samples and channels;

[0024] The average amplitudes are arranged according to the time dimension, and a fixed-dimensional discrete Fourier transform is performed on the average amplitudes arranged according to the time dimension to obtain the spectrum analysis results.

[0025] Multiple frequency indexes corresponding to amplitudes are selected from the spectrum analysis results. The amplitude is the maximum amplitude selected from the spectrum analysis results, or the current maximum amplitude in the spectrum analysis results after excluding the previously selected maximum amplitude.

[0026] Based on the sampling time sequence length and the frequency point index, a period set is calculated, and all periods in the period set are used as period features.

[0027] In some implementations, reconstructing the preprocessed time series using the periodic features to obtain a two-dimensional reconstruction matrix, and generating a mask matrix using the periodic features, includes:

[0028] The preprocessed time series is padded with zeros using the periodic features to obtain the padded time series and the total length of the padded time series.

[0029] Based on the periodic characteristics and the total length, the zero-padded time series is rearranged to obtain a two-dimensional reconstruction matrix;

[0030] A mask matrix is ​​generated based on the row index, column index, and the periodic features.

[0031] In some implementations, the trained static hybrid expert convolutional network model includes a shared network and a routing network, the routing network including multiple experts. The step of inputting the element-wise multiplication result into the trained static hybrid expert convolutional network model to obtain the target feature vector includes:

[0032] The element-wise multiplication result is input into the shared network to obtain the output result of the shared network;

[0033] The element-wise multiplication result is input into the routing network, and each expert in the routing network performs feature extraction on the element-wise multiplication result to obtain multiple feature vectors extracted by the experts.

[0034] Based on the amplitude of the preprocessed time series under the main frequency index, calculate the gating weight corresponding to each expert;

[0035] Based on the gating weights, the feature vectors extracted by each expert are weighted and summed to obtain the output of the routing network;

[0036] The output of the shared network and the output of the routing network are added together to obtain the target feature vector.

[0037] In some implementations, the method further includes, in addition to, inputting the element-wise multiplication result into a trained static hybrid expert convolutional network model:

[0038] The quantization step size in quantization-aware training is:

[0039] ;

[0040] in, Indicates the quantization step size. Indicates the initial quantization step size. Indicates the quantization range coefficient. Experts In the passage Average frequency domain amplitude, This represents the maximum value in the set of average frequency domain amplitudes for all experts and channels. Indicates the number of experts. Indicates the number of channels. Represents the stability constant. This indicates the number of frequency points selected. Represents a periodic set. Frequency index The quantization weights below, Represents absolute value. Indicates the nonlinear attenuation coefficient;

[0041] Based on the quantization step size, the static hybrid expert convolutional network model is subjected to quantization-aware training to obtain a trained static hybrid expert convolutional network model.

[0042] In some implementations, the method further includes, before obtaining the fault diagnosis result:

[0043] The ONNX model is constructed by extracting periodic features, reconstructing time series, generating masks, and using a trained static hybrid expert convolutional network model.

[0044] Export the ONNX model and deploy the ONNX model to an edge hardware platform, which includes a CPU and a GPU.

[0045] When the ONNX model is run, the periodic feature extraction, time series reconstruction, and mask generation are performed on the CPU, while the trained static hybrid expert convolutional network model is performed on the GPU.

[0046] Secondly, embodiments of this application also provide a lithium-ion battery fault diagnosis system based on time series analysis, the system comprising:

[0047] A time series construction unit is used to acquire multiple lithium-ion battery signals of the lithium-ion battery to be diagnosed, and construct the multiple lithium-ion battery signals into a time series, wherein the multiple lithium-ion battery signals include voltage, current and temperature;

[0048] A time series preprocessing unit is used to preprocess the time series to obtain a preprocessed time series;

[0049] A periodic feature extraction unit is used to extract periodic features based on the preprocessed time series;

[0050] A time series reconstruction unit is used to reconstruct the preprocessed time series using the periodic features to obtain a two-dimensional reconstruction matrix, and to generate a mask matrix using the periodic features.

[0051] The element-wise multiplication unit is used to multiply the two-dimensional reconstruction matrix and the mask matrix element-wise to obtain the element-wise multiplication result;

[0052] The feature vector acquisition unit is used to input the element-wise multiplication result into the trained static hybrid expert convolutional network model to obtain the target feature vector;

[0053] A reconstruction sequence generation unit is used to input the target feature vector into a fully connected neural network to generate a target reconstruction sequence;

[0054] The battery fault diagnosis unit is used to calculate the reconstruction error between the target reconstruction sequence and the preprocessed time series, and to perform fault diagnosis on the lithium-ion battery to be diagnosed based on the reconstruction error, thereby obtaining the fault diagnosis result.

[0055] Thirdly, embodiments of this application also provide an electronic device, including at least one control processor and a memory for communicatively connecting to the at least one control processor; the memory stores instructions executable by the at least one control processor, the instructions being executed by the at least one control processor to enable the at least one control processor to perform a lithium-ion battery fault diagnosis method based on time series analysis as described above.

[0056] Fourthly, embodiments of this application also provide a computer-readable storage medium storing computer-executable instructions for causing a computer to execute a time-series analysis-based lithium-ion battery fault diagnosis method as described above.

[0057] It is understood that the beneficial effects of the second to fourth aspects compared with the related technologies are the same as the beneficial effects of the first aspect compared with the related technologies. Please refer to the relevant description in the first aspect above, which will not be repeated here. Attached Figure Description

[0058] The above and / or additional aspects and advantages of this application will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which:

[0059] Figure 1 This is a flowchart illustrating an embodiment of the lithium-ion battery fault diagnosis method based on time series analysis provided in this application;

[0060] Figure 2 This is a schematic diagram of the overall structure of a lithium-ion battery fault diagnosis system in the best embodiment of the lithium-ion battery fault diagnosis method based on time series analysis provided in this application.

[0061] Figure 3 This is a schematic diagram of the static hybrid expert convolutional network model structure in the best embodiment of the lithium-ion battery fault diagnosis method based on time series analysis provided in this application;

[0062] Figure 4 This is a schematic diagram of post-quantization inference in the best embodiment of the lithium-ion battery fault diagnosis method based on time series analysis provided in this application;

[0063] Figure 5 This is a schematic diagram of the original quantitative perception training in the best embodiment of the lithium-ion battery fault diagnosis method based on time series analysis provided in this application;

[0064] Figure 6 This is a schematic diagram of periodic-sensitive quantitative perception training in the best embodiment of the lithium-ion battery fault diagnosis method based on time series analysis provided in this application.

[0065] Figure 7 This is an embedded flowchart of the preferred embodiment of the lithium-ion battery fault diagnosis method based on time series analysis provided in this application;

[0066] Figure 8 This is a schematic diagram of an embodiment of the lithium-ion battery fault diagnosis system based on time series analysis provided in this application;

[0067] Figure 9 This is a schematic diagram of the structure of an embodiment of the electronic device provided in this application. Detailed Implementation

[0068] The embodiments of this application are described in detail below. Examples of these embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain this application, and should not be construed as limiting this application.

[0069] In the description of this application, the use of terms such as "first," "second," etc., is for the purpose of distinguishing technical features only and should not be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated or the order of the technical features indicated.

[0070] In the description of this application, it should be understood that the orientation descriptions, such as up, down, etc., are based on the orientation or positional relationship shown in the accompanying drawings, and are only for the convenience of describing this application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this application.

[0071] In the description of this application, it should be noted that, unless otherwise explicitly defined, terms such as "setup," "installation," and "connection" should be interpreted broadly, and those skilled in the art can reasonably determine the specific meaning of the above terms in this application in conjunction with the specific content of the technical solution.

[0072] Existing methods for fault diagnosis of lithium-ion batteries have relatively low accuracy. Therefore, to address the problems of existing technologies, this application proposes a lithium-ion battery fault diagnosis method and system based on time series analysis.

[0073] Reference Figure 1 This application provides a flowchart illustrating a lithium-ion battery fault diagnosis method based on time series analysis. This method is applied to electronic devices, such as servers or mobile terminals. Figure 1As shown, the lithium-ion battery fault diagnosis method based on time series analysis may include the following steps:

[0074] Step S101: Obtain multiple lithium-ion battery signals of the lithium-ion battery to be diagnosed, and construct a time series of multiple lithium-ion battery signals, including voltage, current and temperature;

[0075] Step S102: Preprocess the time series to obtain the preprocessed time series;

[0076] Step S103: Extract periodic features based on the preprocessed time series;

[0077] Step S104: Reconstruct the preprocessed time series using periodic features to obtain a two-dimensional reconstruction matrix, and generate a mask matrix using periodic features.

[0078] Step S105: Multiply the two-dimensional reconstruction matrix and the mask matrix element by element to obtain the element-by-element multiplication result;

[0079] Step S106: Input the element-wise multiplication result into the trained static hybrid expert convolutional network model to obtain the target feature vector;

[0080] Step S107: Input the target feature vector into a fully connected neural network to generate a target reconstruction sequence;

[0081] Step S108: Calculate the reconstruction error between the target reconstruction sequence and the preprocessed time series. Based on the reconstruction error, perform fault diagnosis on the lithium-ion battery to be diagnosed and obtain the fault diagnosis result.

[0082] In this embodiment, multiple lithium-ion battery signals of the lithium-ion battery to be diagnosed are acquired and constructed into a time series, including voltage, current, and temperature. The time series is preprocessed to obtain a preprocessed time series. Based on the preprocessed time series, periodic features are extracted. The preprocessed time series is reconstructed using the periodic features to obtain a two-dimensional reconstruction matrix, and a mask matrix is ​​generated using the periodic features. The two-dimensional reconstruction matrix and the mask matrix are multiplied element-wise to obtain an element-wise multiplication result. The element-wise multiplication result is input into a trained static hybrid expert convolutional network model to obtain a target feature vector. The target feature vector is input into a fully connected neural network to generate a target reconstruction sequence. The reconstruction error between the target reconstruction sequence and the preprocessed time series is calculated. Based on the reconstruction error, fault diagnosis is performed on the lithium-ion battery to be diagnosed to obtain a fault diagnosis result. Thus, by first extracting periodic features, the main periodic components in the battery's operating state can be identified; then, the preprocessed time series is reconstructed using the periodic features to generate a mask matrix, completing a unified mapping from spectral analysis to static tensor input, which can provide a unified input for subsequent static hybrid expert convolutional network models and deployment inference; then, the target feature vector is extracted through the trained static hybrid expert convolutional network model to perform fault diagnosis on the lithium-ion battery to be diagnosed, which can improve the accuracy of lithium-ion battery fault diagnosis.

[0083] The above-mentioned construction of multiple lithium-ion battery signals into a time series can be achieved by arranging multiple lithium-ion battery signals in chronological order to construct a time series.

[0084] The aforementioned preprocessing of time series can include standardization, normalization, and other preprocessing techniques.

[0085] The aforementioned static hybrid expert convolutional network model can be a network model that includes an Inception module, a GELU activation function, and an Inception module.

[0086] The Inception module described above can be a multi-branch convolutional structure, with different branches using different kernel sizes (such as 1×1, 3×3, 5×5) to capture features at different scales.

[0087] The fully connected neural network described above can be a special case of a feedforward neural network, in which each neuron is connected to all neurons in the previous layer.

[0088] The reconstruction error between the target reconstructed sequence and the preprocessed time series can be calculated using the mean square error.

[0089] The above-mentioned fault diagnosis based on reconstruction error can be performed on the lithium-ion battery to be diagnosed. When the reconstruction error is greater than the threshold, the lithium-ion battery to be diagnosed is determined to be faulty; when the reconstruction error is less than or equal to the threshold, the lithium-ion battery to be diagnosed is determined to be normal.

[0090] In some implementations, the time series is preprocessed to obtain a preprocessed time series, including:

[0091] The time series is standardized to obtain the standardized time series;

[0092] The standardized time series is input into the embedding layer to obtain embedded features, which are then used as the preprocessed time series.

[0093] In this embodiment, by standardizing the time series, it is possible to ensure that different feature dimensions have similar numerical ranges, thereby avoiding gradient instability caused by differences in units during network training. By inputting the standardized time series into the embedding layer, this embedding process not only enhances the model's ability to represent complex temporal structures, but also provides a stable and rich feature foundation for subsequent frequency domain analysis.

[0094] In some implementations, periodic features are extracted based on the preprocessed time series, including:

[0095] The preprocessed time series is rearranged into a matrix to obtain the rearranged matrix;

[0096] Based on the rearranged matrix, construct a fixed-dimensional real matrix and imaginary matrix;

[0097] Calculate the amplitude spectrum based on the real and imaginary matrices;

[0098] Based on the amplitude spectrum, calculate the average amplitude of each sampling point across all samples and channels;

[0099] The average amplitudes are arranged according to the time dimension, and a fixed-dimensional discrete Fourier transform is performed on the average amplitudes arranged according to the time dimension to obtain the spectrum analysis results.

[0100] Select frequency indexes corresponding to multiple amplitudes from the spectrum analysis results. The amplitude is the maximum amplitude selected from the spectrum analysis results, or the current maximum amplitude in the spectrum analysis results after excluding the previously selected maximum amplitude.

[0101] Based on the sampling time sequence length and frequency index, calculate the period set, and use all periods in the period set as period features.

[0102] In this embodiment, by extracting periodic features, the main periodic components in the battery's operating state can be identified. To avoid shape incompatibility issues caused by the dynamic operator during the derivation stage, this embodiment implements a fixed-dimensional discrete Fourier transform that can be recognized by ONNX by explicitly defining the real and imaginary matrices.

[0103] The aforementioned fixed-dimensional discrete Fourier transform can be an efficient algorithm for computing the discrete Fourier transform (DFT), used to transform time series signals from the time domain to the frequency domain, thereby extracting the periodic features of the signal.

[0104] In some implementations, the preprocessed time series is reconstructed using periodic features to obtain a two-dimensional reconstruction matrix, and a mask matrix is ​​generated using periodic features, including:

[0105] The preprocessed time series is padded with zeros using periodic features to obtain the padded time series and the total length of the padded time series;

[0106] Based on the periodic characteristics and total length, the zero-padded time series is rearranged to obtain a two-dimensional reconstruction matrix;

[0107] A mask matrix is ​​generated based on the row index, column index, and periodic characteristics.

[0108] In this embodiment, the preprocessed time series is reconstructed using periodic features to obtain a two-dimensional reconstruction matrix, and a mask matrix is ​​generated using periodic features, thus completing a unified mapping from spectral analysis to static tensor input, which can provide a unified input for subsequent static hybrid expert convolutional network models and deployment inference.

[0109] The row and column indices mentioned above can be the row and column indices in a matrix.

[0110] In some implementations, the trained static hybrid expert convolutional network model includes a shared network and a routing network. The routing network includes multiple experts, and the element-wise multiplication result is input into the trained static hybrid expert convolutional network model to obtain the target feature vector, including:

[0111] The result of element-wise multiplication is input into the shared network to obtain the output of the shared network;

[0112] The element-wise multiplication result is input into the routing network, and each expert in the routing network extracts features from the element-wise multiplication result to obtain multiple feature vectors extracted by experts.

[0113] Calculate the gating weight for each expert based on the amplitude of the preprocessed time series under the main frequency index;

[0114] Based on the gating weights, the feature vectors extracted by each expert are weighted and summed to obtain the output of the routing network.

[0115] The target feature vector is obtained by adding the output of the shared network and the output of the routing network.

[0116] In this embodiment, multi-scale feature extraction is performed through a shared network and a routing network, and feature fusion is performed on the multi-scale features to obtain feature vectors with rich content. This strengthens the feature expression of the main periodic components and lays a good data foundation for subsequent fault diagnosis of lithium-ion batteries, thereby improving the accuracy of lithium-ion battery fault diagnosis.

[0117] The aforementioned shared network may include the Inception module, the GELU activation function, and the Inception module.

[0118] The aforementioned experts may include the Inception module, the GELU activation function, and the Inception module.

[0119] In some implementations, the method further includes, in addition to, inputting the element-wise multiplication result into a trained static hybrid expert convolutional network model:

[0120] The quantization step size in quantization-aware training is:

[0121] ;

[0122] in, Indicates the quantization step size. Indicates the initial quantization step size. Indicates the quantization range coefficient. Experts In the passage Average frequency domain amplitude, This represents the maximum value in the set of average frequency domain amplitudes for all experts and channels. Indicates the number of experts. Indicates the number of channels. Represents the stability constant. This indicates the number of frequency points selected. Represents a periodic set. Frequency index The quantization weights below, Represents absolute value. Indicates the nonlinear attenuation coefficient;

[0123] Based on the quantization step size, a quantization-aware training method is used to train the static hybrid expert convolutional network model, resulting in a well-trained static hybrid expert convolutional network model.

[0124] In this embodiment, by constructing the quantization step size in quantization-aware training, adaptive quantization at the convolutional channel level is achieved, enabling the model to maintain a high-fidelity representation of periodic features even under low-bit quantization conditions.

[0125] The aforementioned quantization-aware training can be a technique that introduces quantization simulation during the training phase. By dynamically mapping floating-point weights and activation values ​​to low-bit integers, the model can maintain high precision and low computational load on embedded platforms.

[0126] In some implementations, the method further includes, before obtaining the fault diagnosis results:

[0127] The ONNX model is constructed by extracting periodic features, reconstructing time series, generating masks, and using a trained static hybrid expert convolutional network model.

[0128] Export the ONNX model and deploy it to an edge hardware platform, which includes both CPU and GPU.

[0129] When running the ONNX model, periodic feature extraction, time series reconstruction, and mask generation are performed on the CPU, while the trained static hybrid expert convolutional network model is performed on the GPU.

[0130] In this embodiment, by having the CPU and GPU work together, the system can complete the diagnostic calculation of multi-cycle features within millisecond-level latency, thereby improving the efficiency of lithium-ion battery fault diagnosis and saving time costs.

[0131] The ONNX model described above is an open deep learning model exchange format that supports cross-framework export and deployment.

[0132] To facilitate understanding by those skilled in the art, a set of preferred embodiments is provided below:

[0133] Currently, research on lithium-ion battery fault diagnosis both domestically and internationally mainly focuses on three types of methods: knowledge-based analysis methods, model-based inference methods, and data-driven intelligent algorithms. Knowledge-based analysis methods rely on expert experience, rule bases, or logical judgments to identify battery faults, such as expert systems, fuzzy logic reasoning, fault tree analysis, and threshold determination methods. These methods are simple in structure and highly interpretable, and were widely used in early battery management systems. However, due to their over-reliance on expert experience, they lack adaptability and generalization capabilities, making it difficult to cope with complex and changing operating conditions.

[0134] Model-based fault diagnosis methods identify faults by establishing electrochemical or thermodynamic models and using residual analysis. Typical research includes electrochemical-thermal coupling models used to detect internal short-circuit faults in lithium-ion batteries. These methods can theoretically reflect the internal mechanisms of batteries with relatively high accuracy and are suitable for in-depth mechanistic analysis. However, their modeling process is complex, requiring extremely high parameter accuracy and boundary conditions, resulting in high computational costs and making it difficult to meet the real-time requirements of practical battery management systems (BMS).

[0135] With the growth of data scale and the development of artificial intelligence technology, data-driven intelligent algorithms have gradually become the mainstream direction of lithium-ion battery fault diagnosis research. These methods collect operational data such as voltage, current, and temperature, and use this data to build data-driven machine learning models. These models then learn the mapping relationship between battery state and fault characteristics, achieving fault detection and classification. Although data-driven methods have strong self-learning and adaptive capabilities, their accuracy depends on a large amount of high-quality training data. Due to the low frequency of battery fault events, data acquisition is extremely costly. At the same time, limited by the way data features are utilized, most existing methods only focus on static features, failing to effectively capture the time-dependent relationships during charging and discharging, resulting in insufficient ability to identify early or subtle faults.

[0136] While existing lithium-ion battery fault diagnosis methods have made some progress at different levels, they still have significant shortcomings overall, including:

[0137] 1. Traditional diagnostic methods based on knowledge or threshold rules rely too much on human experience and cannot adapt to the complexity of battery operating environments and the diversity of operating conditions, thus failing to identify new types of faults.

[0138] 2. Although model-based diagnostic methods have a certain theoretical accuracy, their establishment process depends on the precise parameters and boundary conditions of the internal electrochemical equations of the battery. The model calculation is complex and the solution cost is high, making it difficult to meet the real-time detection requirements of the vehicle BMS system.

[0139] 3. While data-driven intelligent algorithms (including deep learning methods) overcome the model dependency problem, their diagnostic performance is highly dependent on large-scale, high-quality training datasets, while obtaining real battery fault data is difficult and costly. Due to this limitation, existing models often rely solely on static features or single-step prediction signals for fault judgment, making it difficult to effectively capture the dynamic features and periodic changes during the charging and discharging process. Consequently, their identification performance for slowly evolving faults such as early internal short circuits is unsatisfactory.

[0140] 4. Although deep learning models have advantages in automatic feature extraction and complex pattern recognition, their complex structure, large parameter scale, and high computational cost make them unsuitable for direct deployment on resource-constrained embedded hardware platforms, thus limiting their real-time application in vehicle battery management systems.

[0141] 5. The disconnect between model deployment and training frameworks makes engineering implementation difficult. Most existing deep learning methods are developed in the Python environment using frameworks such as PyTorch / TensorFlow. When porting the dynamic graph computation or certain operators (such as the standard DFT) they rely on to embedded inference engines in the C / C++ environment (such as TensorRT and RKNN models), problems such as operator incompatibility and inability to handle dynamic shapes often occur, leading to model conversion failures or severe performance degradation, which limits the application of advanced algorithms on resource-constrained devices.

[0142] In summary, existing technologies struggle to balance the accuracy of battery fault diagnosis with lightweight models, while excessive model complexity limits their real-time performance.

[0143] To address the aforementioned problems, this embodiment aims to propose a time-series analysis-based method for lithium-ion battery fault diagnosis and embedded deployment. This method ensures high diagnostic accuracy while achieving static model structure, deployable computational processes, and low-power inference. Specifically, this embodiment achieves these objectives through the following methods:

[0144] At the algorithm level, a periodic feature extraction mechanism based on fixed-dimensional discrete Fourier transform (DFT) and periodic mask matrix is ​​proposed. This mechanism can automatically detect the main period and identify the effective data region while keeping the computation dimension fixed, thereby realizing the static mapping from one-dimensional time series to two-dimensional time series tensor and fully exploring the periodicity of battery operation signal.

[0145] At the model structure level, a static hybrid expert convolutional network model (Static-MoE model) is designed, replacing the traditional attention mechanism with a multi-period parallel expert structure. Each expert corresponds to a different frequency branch, and the gating weights are calculated from the frequency domain amplitude using the Softmax function. Combined with a Periodic Sensitivity Quantization Function (PSQF), adaptive quantization at the convolutional channel level is achieved, enabling the model to maintain a high-fidelity representation of periodic features even under low-bit quantization conditions.

[0146] At the deployment level, a lightweight implementation framework integrating algorithm and deployment is constructed. This framework maintains a consistent computational topology during the training and export phases, utilizing fixed-dimensional DFT matrices and mask-generated nodes to replace dynamic DFT operators, giving the ONNX model static shape features that can be directly converted into TensorRT or RKNN models. During the inference phase, a heterogeneous collaborative mechanism between the central processing unit (CPU) and graphics processing unit (GPU) enables periodic detection and parallel expert computation. Combined with an adaptive energy consumption control strategy, millisecond-level real-time inference and low-power operation are achieved on edge devices.

[0147] Through the above design, this embodiment fully considers hardware constraints in the algorithm design stage, and realizes a complete unified link from data acquisition, periodic feature modeling, convolutional feature learning to embedded deployment. It can achieve high-precision, low-latency and low-power fault diagnosis of lithium-ion batteries on resource-constrained vehicle or edge computing platforms, and provide an engineeringable solution for the safety monitoring and early warning of BMS systems.

[0148] This embodiment proposes a lithium-ion battery fault diagnosis and embedded deployment method based on time series analysis. This method combines frequency domain period extraction, two-dimensional time series reconstruction, and deep convolutional network feature fusion techniques to achieve high-precision fault detection and anomaly identification of battery operating status. Furthermore, it achieves efficient deployment on an embedded hardware platform through model compression and ONNX export technology. The overall system structure includes: a data acquisition and preprocessing module, a period feature extraction module, a two-dimensional time series reconstruction module, a convolutional feature learning and fault identification module, and an embedded model deployment module. Specifically, it includes the following components:

[0149] (1) System overall structure.

[0150] like Figure 2 As shown, the system in this embodiment consists of four functional modules: a data acquisition and preprocessing module, a periodic feature extraction and two-dimensional temporal reconstruction module, a convolutional feature extraction and fusion module, and an embedded model deployment module. The system completes information exchange through a unified data bus interface, realizing a complete functional chain from signal acquisition and feature extraction to fault identification and early warning.

[0151] The data acquisition and preprocessing module is used to acquire operating parameters such as voltage, current, and temperature from the lithium-ion battery system in real time and convert them into time-series input signals, providing a basis for subsequent analysis. The periodic feature extraction module, based on an improved Fast Fourier Transform algorithm, performs spectral analysis and periodic extraction of the signal on a fixed-dimensional DFT matrix, thereby identifying the main periodic components in the battery's operating state. Using the extracted periodic information, the one-dimensional time series is periodically divided and reconstructed to construct a corresponding two-dimensional time-series feature map (i.e., a two-dimensional reconstruction matrix), so that the dynamic features within and between periods are simultaneously and explicitly expressed in the spatial structure.

[0152] Building upon this foundation, the convolutional feature extraction and fusion module utilizes a static hybrid expert network structure, employing a combination of depthwise separable convolution and Inception-GELU-Inception multi-branch feature blocks to perform multi-scale feature extraction and fusion of the two-dimensional temporal feature map. This module reduces computational complexity through depthwise separable convolution and strengthens the feature representation of key cyclic components through an expert-weighted fusion mechanism, enabling anomaly identification in battery operation. Finally, the embedded model deployment module uses ONNX export and model compression technology to efficiently deploy the trained model to automotive or edge hardware platforms (such as Jetson Nano, RK3588, and STM32), thereby achieving real-time inference and online fault warning.

[0153] (2) Data acquisition and preprocessing module.

[0154] This module is used to acquire operating parameters from the lithium-ion battery system in real time, including signals such as voltage, current, and temperature, and organize them into a time series input suitable for network analysis. Let the input signal be... (i.e., time series) is represented as:

[0155] (1);

[0156] in, This indicates the sampling time sequence length, and each sampling point contains feature dimensions such as current, voltage, and temperature.

[0157] Before signals enter a neural network model, the raw data needs to be standardized to eliminate dimensional differences and improve the stability of network model training. For input tensors... ,in For batch size, For the feature dimension, the preprocessing process includes the following steps:

[0158] First, the time mean is calculated to obtain the average value of each feature over the entire sequence, specifically:

[0159] (2);

[0160] Then, the standard deviation is calculated to characterize the dispersion of the data distribution, specifically:

[0161] (3);

[0162] Finally, a standardization operation is performed, and the input signal is standardized according to the following formula:

[0163] (4);

[0164] in, Indexes indicating the dimension of statistic calculation, such as data [B,T,C], typically dim=1: time-standardized (zero mean, unit variance for each sample / feature on its time axis); dim=2: feature-standardized (zero mean, unit variance for each feature across each time step). This represents the mean operator. Represents the variance operator. This represents the standardized signal (i.e., the standardized time series).

[0165] This process ensures that different feature dimensions have similar numerical ranges, thereby avoiding gradient instability caused by differences in units during network training.

[0166] The standardized signal is input into the data embedding layer, where the original multidimensional time series signal is mapped to a higher-dimensional feature space, and the embedded features (i.e., the preprocessed time series) are output. for:

[0167] (5);

[0168] The embedded features serve as input to the subsequent periodic feature extraction module. This embedding process not only enhances the model's ability to represent complex temporal structures but also provides a stable and rich feature foundation for subsequent frequency domain analysis. The embedding layer in this embodiment is a well-known embedding layer to those skilled in the art, and the specific structure of the embedding layer is not described in detail in this embodiment.

[0169] (3) Periodic feature extraction and two-dimensional time series reconstruction module.

[0170] This module transforms the one-dimensional time-series form of lithium-ion battery operating signals into a fixed-dimensional two-dimensional tensor that can be stably computed in embedded systems, providing a unified input for subsequent static hybrid expert convolutional network models and deployment inference. To ensure structural consistency of the model during the derivation and inference stages, this embodiment proposes an ONNX-friendly fixed-dimensional Fourier transform and period detection mechanism, and on this basis, realizes two-dimensional time-series reconstruction and periodic mask matrix generation, thereby completing a unified mapping from spectrum analysis to static tensor input.

[0171] (I) Fixed-dimensional discrete Fourier transform and period detection.

[0172] To avoid shape incompatibility issues caused by dynamic operators during the derivation stage, this embodiment implements a fixed-dimensional discrete Fourier transform (DFT) that can be recognized by ONNX by explicitly defining the real and imaginary matrices. Input time series for First, rearrange it into a matrix. And construct a fixed-dimensional real part matrix and imaginary part matrix:

[0173] (6);

[0174] in, This represents the real part of the complex weight matrix. The imaginary part of the complex weight matrix is ​​represented by the following expression: , The number of DFT points.

[0175] The real parts are calculated using matrix multiplication. With the imaginary part :

[0176] (7);

[0177] The amplitude spectrum is calculated using the following formula:

[0178] (8);

[0179] Then, the average value was taken across batch and channel dimensions to obtain the overall amplitude distribution:

[0180] (9);

[0181] in, Indicates the first The average amplitude of each sampling point across all samples and channels. This indicates the number of samples, i.e., the number of signal sequences input simultaneously. This indicates the number of channels, that is, the number of independent signal channels in each sample. Indicates the first The sample, the first The first channel in the The amplitude at each sampling point; a batch can contain multiple sampling points.

[0182] To avoid DC component interference, Set to zero. Arrange the average amplitudes along the time dimension, and perform a fixed-dimensional Discrete Fourier Transform (DFT) on the time-series average amplitudes to obtain the spectrum analysis results. From the spectrum analysis results, select the one with the largest amplitude. Frequency point index Calculate the corresponding set of periods (i.e., periodic characteristics):

[0183] (10);

[0184] in, Indicates the first Frequency point index, For periodic sets .

[0185] The calculation process consists entirely of ONNX static operators such as matrix multiplication, squaring, square root extraction, and Top-K, without the need for custom DFT nodes. It can be run directly on backends such as RKNN and TensorRT after the model is exported, achieving consistent periodicity detection across platforms.

[0186] (ii) Two-dimensional static timing reconstruction.

[0187] To map a one-dimensional signal into a static two-dimensional structure, this embodiment is based on the period. The signal is padded with zeros and rearranged to make its length... It is divisible by the period. The length after zero padding and the two-dimensional reconstruction are defined as follows:

[0188] (11);

[0189] in, Indicates the current period The two-dimensional reconstruction matrix below shows that the row dimension corresponds to time segments and the column dimension corresponds to sampling points within a single period. This represents the time series after zero padding. This indicates a zero-padding operation. This represents the total length after padding, used to ensure that the signal length can be periodically measured. Divisible This represents the modulo operation. This represents a two-dimensional reconstruction operation. The reconstruction process fixes the input and output dimensions during the graph construction phase, thus avoiding dynamic shape issues.

[0190] (III) Generation of periodic mask matrix.

[0191] To eliminate the impact of zero-padding regions on feature learning, this embodiment further generates a periodic mask matrix. Used to identify the valid range:

[0192] (12);

[0193] in, Indicates row index, Indicates column index, Indicates the period In the mask matrix below, the first line, number The values ​​that a column element can take.

[0194] During the training and inference phases, the system uses a unified approach. As a two-dimensional input, it enables explicit separation of periodic information and optimization of sparse computation. This mask matrix is ​​written into the ONNX graph structure during the derivation stage as a fixed constant node, ensuring consistency of computation across various hardware platforms.

[0195] (iv) Multi-period mapping and output interface.

[0196] For sets All cycles Repeat the above reconstruction and mask generation process to form periodic feature pairs. .

[0197] These features are written into the ONNX computation graph with fixed dimensions during the export phase, and at runtime, the CPU performs periodic detection and mask generation, while the GPU performs convolutional feature extraction for the corresponding period in parallel. Because Since the graph is determined during construction and all input tensors have fixed shapes, this module achieves a one-to-one structural mapping between the period and experts with the subsequent static hybrid expert convolutional network, providing a unified input basis for subsequent algorithm-deployment integrated inference.

[0198] (4) Convolutional feature learning and fault identification module.

[0199] This module is the core part of the entire model, such as Figure 3 As shown. This embodiment constructs a Static-MoE convolutional feature learning framework (i.e., a static-MoE convolutional network model) based on a two-dimensional temporal reconstruction tensor. It includes a routing network and a sharing network. The routing network consists of multiple experts, each of whom... The network consists of a series of Inception modules, GELU, and Inception modules. A shared network comprises a set of Inception modules, GELU, and Inception modules. Assume that a candidate period set has been obtained during the training / export phase based on a fixed-dimensional Fourier transform and principal period selection. The number of experts is taken to be the same as the number of DFT components, i.e. And it is fixed as a constant during export. All experts compute simultaneously during inference and the input / output shapes are consistent, without involving conditional control flow or dynamic routing. Gating weights Generated by statically differentiable tensor operators, the final output is a linear weighted sum of the results from various experts, thus ensuring the complete static nature of the computation graph and cross-backend portability. The Inception module structure is a multi-scale convolution kernel. An Inception module often contains convolutions of various scales, such as 1x1, 3x3, and 5x5 kernels. The convolutions can employ depthwise separable convolution, which separates the traditional convolution operation, performing single-channel convolution first and then channel mapping to reduce the number of parameters.

[0200] Static MoE fusion employs a static approach with full expert parallelism and continuous gating:

[0201] (13);

[0202] The gating weights can be driven by frequency domain amplitudes or generated by a lightweight gating network. To highlight the period-expert correspondence, this embodiment uses amplitude-driven Softmax:

[0203] (14);

[0204] in, This is a temperature coefficient, which is fixed as a constant during the derivation stage to ensure numerical consistency. This represents the output of the shared network. Indicates the first Each expert outputs results. Indicates the first The gating weights corresponding to each expert Indicates period The two-dimensional reconstruction matrix below, Indicates period The mask matrix below, Indicates the input time series Index of main frequency points The amplitude below, Indicates the input time series Frequency point index The amplitude below, This represents the absolute value operation. This indicates element-wise multiplication.

[0205] Target feature vector Target reconstruction sequence generated by fully connected neural network That is, the reconstruction result of the input signal. During the model training phase, the mean squared error (MSE) is minimized. To optimize the target, the reconstruction error is obtained. During the inference stage, the fault is determined based on the thresholding result of the reconstruction error. That is, when the reconstruction error is greater than the threshold, it is determined to be a fault; otherwise, it is determined to be normal (i.e., when the reconstruction error is less than or equal to the threshold, it is determined to be normal). Since E and k are fixed before the derivation, and formulas (13) and (14) only contain tensor algebra operations, the overall network maintains a completely static topology on ONNX / RKNN / TensorRT.

[0206] After completing the design of the static hybrid expert convolutional feature extraction framework described above, to further improve the accuracy preservation and robustness of the model in low-byte embedded deployment, this embodiment introduces a Quantization Aware Training (QAT) mechanism during the model training phase, such as... Figures 4 to 6 As shown, this mechanism explicitly simulates the quantization process of weights and activations during training, enabling the network to adapt in advance to accuracy perturbations caused by fixed-point quantization while maintaining end-to-end differentiability. Building upon this, to enhance quantization robustness and deployment performance, this embodiment further introduces a per-expert-per-channel periodicity-sensitive quantization (PSQF) mechanism in the quantization-aware training of convolutional weights.

[0207] Building upon quantization perception training, the quantization step size is expanded to... (expert ,aisle ):

[0208] (15);

[0209] in, Indicates the initial quantization step size. Indicates the quantization range coefficient. Indicated as an expert In the passage Average frequency domain amplitude, This represents the maximum value in the set of average frequency domain amplitudes across all expert channels. Represents the stability constant, usually as ( ), Represents the nonlinear attenuation coefficient. Indicates the number of frequency points selected. This represents the frequency index. The quantization weights are obtained through a period-sensitive quantization sensing mechanism. As the actual weights for subsequent deployment. It should be noted that the Quantization Aware Training Mechanism (QAT) in this embodiment is a training mechanism known to those skilled in the art. This embodiment simply extends the quantization step size in the Quantization Aware Training Mechanism, and is therefore called the Periodic Sensitive Quantization Mechanism (PSQF).

[0210] (5) Embedded model deployment module.

[0211] To achieve real-time diagnosis of the model in vehicle edge devices, this embodiment proposes a lightweight embedded implementation framework that integrates algorithm and deployment (e.g., Figure 7 (As shown). This framework maintains consistency in computational topology during model training, export, and inference phases, achieving end-to-end optimization from periodic feature extraction to embedded execution. The overall process uses fixed-dimensional DFT matrix computation, periodic mask generation, periodic sensitive quantization (PSQF) mechanism, and CPU-GPU heterogeneous collaborative inference as core technologies, establishing a unified mapping between algorithm structure and hardware deployment.

[0212] During the training phase, the system performs periodic-sensitive quantization-aware training on the convolutional channels of each expert in the Static-MoE convolutional network model according to formula (15). By establishing an adaptive mapping relationship between the frequency domain amplitude and the weight quantization step size, the model can still maintain a high-fidelity expression of periodic features after low-bit quantization. After training, the weights and gating parameters are statically written into the ONNX computation graph during the export phase. It should be noted that the model in this embodiment refers to the Static-MoE convolutional network model.

[0213] In the model export stage, this embodiment directly uses fixed-dimensional DFT real and imaginary matrices to achieve periodicity detection, avoiding the use of any dynamic DFT operators. The system will export the model... and By fixing these as constant nodes, the Fourier transform, amplitude calculation, and Top-K frequency selection processes all exist in a static form, involving matrix multiplication, squaring, square root extraction, and indexing operations. The detected set of periods... Corresponding two-dimensional reconstruction tensor and mask matrix It is synchronously embedded in the ONNX static graph structure, thus ensuring that the shape and number of channels of the input data are completely consistent across different platforms. This export mechanism does not require custom operators; it is implemented entirely by combining native ONNX operators and can be directly deployed to backends such as TensorRT and RKNN.

[0214] During operation, the system employs a CPU-GPU heterogeneous collaborative inference mechanism: periodic feature extraction, 2D temporal reconstruction, and mask generation modules are executed on the CPU, leveraging its general computing and data management advantages; convolutional expert branches and gated fusion calculations run in parallel on the GPU, meaning the static hybrid expert convolutional network model is executed on the GPU to fully utilize parallel computing power. The CPU and GPU achieve overlapping execution of data transfer and task scheduling through asynchronous memory queues, ensuring the system completes multi-period feature diagnostic calculations within millisecond-level latency. Specifically, after completing the convolutional diagnostic calculations for multi-period features, the system outputs the reconstructed result of the input signal. During edge-side inference, the system... The reconstruction error is calculated and used as a fault score for anomaly measurement. When the score is higher than a preset threshold, the system triggers a fault alarm, records the corresponding abnormal segment, or reports the diagnostic results; when the score is lower than the threshold, the system is deemed to be operating normally. It should be noted that the threshold in this embodiment can be adjusted according to actual conditions, and this embodiment does not impose a specific limitation.

[0215] In summary, this embodiment optimizes the algorithm design by incorporating hardware constraints. Through the collaborative implementation of periodic sensitive quantization, fixed-dimensional Fourier operators, periodic mask matrices, and heterogeneous inference mechanisms, the training model and the deployment model maintain complete structural consistency. This overcomes the problems of dynamic shape incompatibility and quantization accuracy degradation that easily occur in existing deep learning models on embedded platforms. It provides a cross-platform portable embedded intelligent diagnostic solution for lithium-ion battery management systems, which is real-time and stable.

[0216] (6) Overall workflow.

[0217] The overall implementation of this embodiment mainly includes data acquisition and preprocessing, fixed-dimensional DFT and periodic mask generation, static hybrid expert convolution feature extraction and fusion, model compression and embedded deployment, and online detection and threshold judgment.

[0218] First, the system collects real-time operating data such as voltage, current, and temperature from the battery management system (BMS) and performs standardization and filtering preprocessing to eliminate dimensional differences and noise effects between different sensing quantities. Then, it uses fixed-dimensional discrete Fourier transform (DFT) to calculate the frequency domain amplitude distribution of the signal, determines the main periodic components through Top-K frequency selection, and generates corresponding periodic mask matrices to identify the effective time region, achieving a static mapping from a one-dimensional time series to a two-dimensional time series tensor.

[0219] Building upon this foundation, the system extracts multi-scale features within and between periods using a Static-MoE (Static Hybrid Expert Convolutional Network). Each expert corresponds to a different periodic branch, and the gating weights are calculated from the frequency domain amplitude using Softmax, achieving a unified approach to period selection and feature fusion. During training, the convolutional weights are optimized using Period-Sensitive Quantization (PSQF) to ensure the model maintains feature representation accuracy even after low-bit quantization. The trained and optimized model is exported in ONNX format and converted to RKNN or TensorRT models for deployment on edge computing hardware platforms.

[0220] During operation, the system employs a CPU-GPU heterogeneous collaborative inference mechanism: the CPU handles periodic detection, 2D time-series reconstruction, and mask generation, while the GPU performs convolution calculations and gating fusion by various experts in parallel, achieving millisecond-level low-latency online diagnosis. When a fault score exceeds a set threshold, the system automatically triggers an alarm and records abnormal segments, thereby enabling real-time safety monitoring and early fault warning of the battery system.

[0221] Through the above technical solutions, this embodiment constructs a complete technical chain from data acquisition, periodic feature modeling, two-dimensional reconstruction, convolutional feature learning to lightweight deployment, realizing high-precision, low-latency and low-power operation of lithium-ion battery fault diagnosis, which can be widely used in embedded intelligent diagnostic scenarios of new energy vehicle battery management systems and energy storage systems.

[0222] (7) Application scenario description.

[0223] The lithium-ion battery fault diagnosis and embedded deployment method based on time series analysis in this embodiment can be widely applied to battery safety management scenarios in new energy vehicles, power storage systems and intelligent manufacturing equipment. It is especially suitable for real-time diagnostic tasks such as early internal short circuit detection, thermal runaway risk warning and sensor anomaly identification.

[0224] 1. Online diagnostics of the vehicle battery management system (BMS).

[0225] The algorithm in this embodiment can be directly embedded into the vehicle BMS main control unit or the battery module management slave control board. By interfacing with current, voltage, and temperature sampling channels, it receives battery operating data in real time and performs online inference. When the system detects an anomaly, it can immediately send a warning signal to the vehicle control unit (VCU), achieving millisecond-level thermal safety response and battery isolation protection, effectively preventing the spread of thermal runaway.

[0226] 2. Monitoring the operation of the Battery Energy Storage System (BESS).

[0227] For large-scale energy storage power stations, the algorithm in this embodiment can be deployed in edge gateways or industrial computing units to achieve distributed monitoring of multiple battery clusters. By analyzing the temperature and voltage fluctuation cycle characteristics of each cluster, the system can achieve cross-cluster anomaly consistency identification and multi-source early warning decision-making without affecting energy management and control, ensuring the long-term stable operation of the energy storage system.

[0228] Through the aforementioned application scenarios, this embodiment demonstrates excellent applicability throughout the entire lifecycle of power batteries, enabling a unified algorithm framework and deployment mode from cell production and vehicle operation to maintenance management. This technology boasts significant advantages such as cross-platform compatibility, real-time monitoring, and scalable deployment, substantially improving the safety, reliability, and operational intelligence of lithium-ion battery systems.

[0229] Compared with the prior art, the technical solution of this embodiment has the following advantages:

[0230] Currently, the most mature fault diagnosis methods for lithium-ion batteries mainly include model-based mechanistic analysis methods and data-driven deep learning methods. The former has higher theoretical accuracy, but it is complex to model and has poor real-time performance; the latter, although it has self-learning capabilities, fails to make full use of the periodic characteristics of time series and is difficult to identify weak abnormal signals such as early internal short circuits.

[0231] The lithium-ion battery fault diagnosis and embedded deployment method proposed in this embodiment, based on time series analysis, is the first to combine fixed-dimensional DFT periodic analysis with two-dimensional convolutional features. This not only accurately characterizes the dynamic characteristics of the battery operation process but also achieves real-time diagnosis on embedded devices through lightweight model architecture design and model quantization. This method effectively overcomes the shortcomings of traditional models, such as high computational cost and difficulty in deployment, providing a high-precision, low-latency, and feasible new solution for the safety monitoring and fault early warning of lithium-ion battery systems.

[0232] Reference Figure 8 This application also provides a lithium-ion battery fault diagnosis system based on time series analysis. The system includes a time series construction unit 801, a time series preprocessing unit 802, a periodic feature extraction unit 803, a time series reconstruction unit 804, an element-wise multiplication unit 805, a feature vector acquisition unit 806, a reconstructed sequence generation unit 807, and a battery fault diagnosis unit 808, wherein:

[0233] The time series construction unit 801 is used to acquire multiple lithium-ion battery signals of the lithium-ion battery to be diagnosed, and construct the multiple lithium-ion battery signals into a time series. The multiple lithium-ion battery signals include voltage, current and temperature.

[0234] The time series preprocessing unit 802 is used to preprocess the time series to obtain the preprocessed time series;

[0235] The periodic feature extraction unit 803 is used to extract periodic features based on the preprocessed time series.

[0236] The time series reconstruction unit 804 is used to reconstruct the preprocessed time series through periodic features to obtain a two-dimensional reconstruction matrix, and to generate a mask matrix through periodic features.

[0237] The element-wise multiplication unit 805 is used to multiply the two-dimensional reconstruction matrix and the mask matrix element-wise to obtain the element-wise multiplication result;

[0238] The feature vector acquisition unit 806 is used to input the element-wise multiplication result into the trained static hybrid expert convolutional network model to obtain the target feature vector;

[0239] The reconstruction sequence generation unit 807 is used to input the target feature vector into a fully connected neural network to generate the target reconstruction sequence.

[0240] The battery fault diagnosis unit 808 is used to calculate the reconstruction error between the target reconstruction sequence and the preprocessed time series. Based on the reconstruction error, the fault diagnosis is performed on the lithium-ion battery to be diagnosed, and the fault diagnosis result is obtained.

[0241] It should be noted that since the lithium-ion battery fault diagnosis system based on time series analysis in this embodiment is based on the same inventive concept as the lithium-ion battery fault diagnosis method based on time series analysis described above, the corresponding content in the method embodiment is also applicable to this system embodiment, and will not be described in detail here.

[0242] Reference Figure 9 This application also provides an electronic device, which includes:

[0243] At least one memory;

[0244] At least one processor;

[0245] At least one program;

[0246] The program is stored in memory, and the processor executes at least one program to implement the lithium-ion battery fault diagnosis method based on time series analysis described above in this disclosure.

[0247] This electronic device can be any smart terminal, including mobile phones, tablets, personal digital assistants (PDAs), and in-vehicle computers.

[0248] The electronic devices according to embodiments of this application will now be described in detail.

[0249] The processor 1600 can be implemented using a general-purpose central processing unit (CPU), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this disclosure.

[0250] The memory 1700 can be implemented as a read-only memory (ROM), static storage device, dynamic storage device, or random access memory (RAM). The memory 1700 can store the operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 1700 and is called and executed by the processor 1600 to execute the lithium-ion battery fault diagnosis method based on time series analysis of the embodiments of this disclosure.

[0251] The input / output interface 1800 is used to implement information input and output.

[0252] The communication interface 1900 is used to enable communication and interaction between this device and other devices. Communication can be achieved through wired means (such as USB, Ethernet cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.).

[0253] Bus 2000 transmits information between various components of the device (e.g., processor 1600, memory 1700, input / output interface 1800, and communication interface 1900);

[0254] The processor 1600, memory 1700, input / output interface 1800 and communication interface 1900 are connected to each other within the device via bus 2000.

[0255] This disclosure also provides a storage medium, which is a computer-readable storage medium storing computer-executable instructions for causing a computer to execute the above-described lithium-ion battery fault diagnosis method based on time series analysis.

[0256] Memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory may optionally include memory remotely located relative to the processor, and these remote memories can be connected to the processor via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.

[0257] The embodiments described in this disclosure are for the purpose of more clearly illustrating the technical solutions of this disclosure and do not constitute a limitation on the technical solutions provided by this disclosure. As those skilled in the art will know, with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by this disclosure are also applicable to similar technical problems.

[0258] Those skilled in the art will understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of this disclosure, and may include more or fewer steps than shown, or combine certain steps, or different steps.

[0259] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0260] Those skilled in the art will understand that all or some of the steps in the methods disclosed above, as well as the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or suitable combinations thereof.

[0261] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0262] It should be understood that in this application, "at least one (item)" means one or more, and "more than" means two or more. "And / or" is used to describe the relationship between related objects, indicating that three relationships can exist. For example, "A and / or B" can represent three cases: only A exists, only B exists, and both A and B exist simultaneously, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one (item) of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one (item) of a, b, or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.

[0263] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0264] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0265] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0266] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes multiple instructions to cause an electronic device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing programs, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks. The embodiments of this application have been described in detail above with reference to the accompanying drawings, but this application is not limited to the above embodiments. Various changes can be made within the scope of knowledge possessed by those skilled in the art without departing from the spirit of this application.

Claims

1. A fault diagnosis method for lithium-ion batteries based on time series analysis, characterized in that, The method includes: Acquire multiple lithium-ion battery signals of the lithium-ion battery to be diagnosed, and construct the multiple lithium-ion battery signals into a time series, the multiple lithium-ion battery signals including voltage, current and temperature; The time series is preprocessed to obtain a preprocessed time series; Based on the preprocessed time series, periodic features are extracted; The preprocessed time series is reconstructed using the periodic features to obtain a two-dimensional reconstruction matrix, and a mask matrix is ​​generated using the periodic features. The two-dimensional reconstruction matrix is ​​multiplied element-wise with the mask matrix to obtain the element-wise multiplication result; The element-wise multiplication result is input into the trained static hybrid expert convolutional network model to obtain the target feature vector, including: The quantization step size in quantization-aware training is: ; ; in, Indicates the quantization step size. Indicates the initial quantization step size. Indicates the quantization range coefficient. Experts In the passage Average frequency domain amplitude, This represents the maximum value in the set of average frequency domain amplitudes for all experts and channels. Experts and channels Average frequency domain amplitude, Indicates the number of experts. Indicates the number of channels. Represents the stability constant. This indicates the number of frequency points selected. Represents a periodic set. Frequency index The quantization weights below, Represents absolute value. Indicates the nonlinear attenuation coefficient; Based on the quantization step size, the static hybrid expert convolutional network model is subjected to quantization-aware training to obtain a trained static hybrid expert convolutional network model. The trained static hybrid expert convolutional network model includes a shared network and a routing network, and the routing network includes multiple experts. The element-wise multiplication result is input into the shared network to obtain the output result of the shared network; The element-wise multiplication result is input into the routing network, and each expert in the routing network performs feature extraction on the element-wise multiplication result to obtain multiple feature vectors extracted by the experts. Based on the amplitude of the preprocessed time series under the main frequency index, calculate the gating weight corresponding to each expert; Based on the gating weights, the feature vectors extracted by each expert are weighted and summed to obtain the output of the routing network; The output of the shared network and the output of the routing network are added together to obtain the target feature vector; The target feature vector is input into a fully connected neural network to generate a target reconstruction sequence; The reconstruction error between the target reconstruction sequence and the preprocessed time series is calculated. Based on the reconstruction error, the lithium-ion battery to be diagnosed is subjected to fault diagnosis to obtain the fault diagnosis result.

2. The lithium-ion battery fault diagnosis method based on time series analysis according to claim 1, characterized in that, The preprocessing of the time series to obtain the preprocessed time series includes: The time series is standardized to obtain a standardized time series; The standardized time series is input into the embedding layer to obtain embedded features, which are then used as the preprocessed time series.

3. The lithium-ion battery fault diagnosis method based on time series analysis according to claim 1, characterized in that, The extraction of periodic features based on the preprocessed time series includes: The preprocessed time series is rearranged into a matrix to obtain the rearranged matrix; Based on the rearranged matrix, construct a real matrix and an imaginary matrix of fixed dimensions; Calculate the amplitude spectrum based on the real part matrix and the imaginary part matrix; Based on the amplitude spectrum, calculate the average amplitude of each sampling point across all samples and channels; The average amplitudes are arranged according to the time dimension, and a fixed-dimensional discrete Fourier transform is performed on the average amplitudes arranged according to the time dimension to obtain the spectrum analysis results. Multiple frequency indexes corresponding to amplitudes are selected from the spectrum analysis results. The amplitude is the maximum amplitude selected from the spectrum analysis results, or the current maximum amplitude in the spectrum analysis results after excluding the previously selected maximum amplitude. Based on the sampling time sequence length and the frequency point index, a period set is calculated, and all periods in the period set are used as period features.

4. The lithium-ion battery fault diagnosis method based on time series analysis according to claim 1, characterized in that, The process of reconstructing the preprocessed time series using the periodic features to obtain a two-dimensional reconstruction matrix, and generating a mask matrix using the periodic features, includes: The preprocessed time series is padded with zeros using the periodic features to obtain the padded time series and the total length of the padded time series. Based on the periodic characteristics and the total length, the zero-padded time series is rearranged to obtain a two-dimensional reconstruction matrix; A mask matrix is ​​generated based on the row index, column index, and the periodic features.

5. The lithium-ion battery fault diagnosis method based on time series analysis according to claim 1, characterized in that, Before obtaining the fault diagnosis results, the method further includes: The ONNX model is constructed by extracting periodic features, reconstructing time series, generating masks, and using a trained static hybrid expert convolutional network model. Export the ONNX model and deploy the ONNX model to an edge hardware platform, which includes a CPU and a GPU. When the ONNX model is run, the periodic feature extraction, time series reconstruction, and mask generation are performed on the CPU, while the trained static hybrid expert convolutional network model is performed on the GPU.

6. A lithium-ion battery fault diagnosis system based on time series analysis, characterized in that, The system includes: A time series construction unit is used to acquire multiple lithium-ion battery signals of the lithium-ion battery to be diagnosed, and construct the multiple lithium-ion battery signals into a time series, wherein the multiple lithium-ion battery signals include voltage, current and temperature; A time series preprocessing unit is used to preprocess the time series to obtain a preprocessed time series; A periodic feature extraction unit is used to extract periodic features based on the preprocessed time series; A time series reconstruction unit is used to reconstruct the preprocessed time series using the periodic features to obtain a two-dimensional reconstruction matrix, and to generate a mask matrix using the periodic features. The element-wise multiplication unit is used to multiply the two-dimensional reconstruction matrix and the mask matrix element-wise to obtain the element-wise multiplication result; The feature vector acquisition unit is used to input the element-wise multiplication result into the trained static hybrid expert convolutional network model to obtain the target feature vector, including: The quantization step size in quantization-aware training is: ; ; in, Indicates the quantization step size. Indicates the initial quantization step size. Indicates the quantization range coefficient. Experts In the passage Average frequency domain amplitude, This represents the maximum value in the set of average frequency domain amplitudes for all experts and channels. Experts and channels Average frequency domain amplitude, Indicates the number of experts. Indicates the number of channels. Represents the stability constant. This indicates the number of frequency points selected. Represents a periodic set. Frequency index The quantization weights below, Represents absolute value. Indicates the nonlinear attenuation coefficient; Based on the quantization step size, the static hybrid expert convolutional network model is subjected to quantization-aware training to obtain a trained static hybrid expert convolutional network model. The trained static hybrid expert convolutional network model includes a shared network and a routing network, and the routing network includes multiple experts. The element-wise multiplication result is input into the shared network to obtain the output result of the shared network; The element-wise multiplication result is input into the routing network, and each expert in the routing network performs feature extraction on the element-wise multiplication result to obtain multiple feature vectors extracted by the experts. Based on the amplitude of the preprocessed time series under the main frequency index, calculate the gating weight corresponding to each expert; Based on the gating weights, the feature vectors extracted by each expert are weighted and summed to obtain the output of the routing network; The output of the shared network and the output of the routing network are added together to obtain the target feature vector; A reconstruction sequence generation unit is used to input the target feature vector into a fully connected neural network to generate a target reconstruction sequence; The battery fault diagnosis unit is used to calculate the reconstruction error between the target reconstruction sequence and the preprocessed time series, and to perform fault diagnosis on the lithium-ion battery to be diagnosed based on the reconstruction error, thereby obtaining the fault diagnosis result.

7. An electronic device, characterized in that, It includes at least one control processor and a memory for communicatively connecting to the at least one control processor; the memory stores instructions executable by the at least one control processor, which, when executed by the at least one control processor, enable the at least one control processor to perform the lithium-ion battery fault diagnosis method based on time series analysis as described in any one of claims 1 to 5.

8. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions for causing a computer to perform the time-series analysis-based lithium-ion battery fault diagnosis method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Robot Fleet Management for Value Chain Networks

    US20220187847A1

  • Eigenvalue decomposition apparatus, radio communication apparatus, method, and non-transitory computer readable medium

    US20230388157A1