Vehicle battery fault diagnosis method and device and storage medium

By processing vehicle battery charging information using a pre-defined neural operator architecture, the problems of high computational resource requirements, high false alarm rate, and high data acquisition cost in existing technologies are solved, achieving highly accurate and reliable fault diagnosis.

CN121276352APending Publication Date: 2026-01-06CHONGQING SELIS PHOENIX INTELLIGENT INNOVATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511677788.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-17
Publication Date
2026-01-06

AI Technical Summary

Technical Problem

Existing vehicle battery fault diagnosis technologies suffer from problems such as high computational resource requirements, high false alarm rates, high data acquisition costs, and a lack of interpretability and physical basis for the models.

Method used

A pre-defined neural operator architecture is adopted to process charging information through spectral convolutional layers and model layers, predict current and state of charge, and judge faults by combining charging error and threshold. The fault threshold is determined by minimizing the total expected cost function.

Benefits of technology

It improves the accuracy and reliability of fault diagnosis, reduces the difficulty of data acquisition, enhances the ability to generalize to unknown fault types, controls the false alarm rate to below 5%, and improves detection sensitivity by 28%.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121276352A_ABST
    Figure CN121276352A_ABST
Patent Text Reader

Abstract

The invention provides a vehicle battery fault diagnosis method and device and a storage medium, and the method comprises the steps: for each to-be-detected vehicle battery, predicting a predicted current and a predicted state of charge corresponding to each charging segment according to the charging information of each charging segment of the to-be-detected vehicle battery and a preset neural operator architecture; for each charging segment, determining a corresponding charging error according to the predicted current, the predicted charge state, the actual current and the actual charge state corresponding to the charging segment; for each to-be-detected vehicle battery, determining an average charging error according to the charging error corresponding to each charging segment of the to-be-detected vehicle battery and a preset first threshold value; and determining each fault vehicle battery according to the average charging error of each to-be-detected vehicle battery and a preset fault threshold. According to the technical scheme, the effect of improving the fault diagnosis accuracy is achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of fault diagnosis technology, specifically to a method, device and storage medium for diagnosing vehicle battery faults. Background Technology

[0002] Current fault diagnosis technologies for vehicle batteries, specifically lithium-ion batteries, are mainly divided into two categories: model-based and data-driven. The first is model-based fault diagnosis methods, including equivalent circuit models, electrochemical models, and thermal models. Specifically, fault detection is achieved by constructing a physical representation of the battery system. However, high-fidelity electrochemical models require large computational resources, making them difficult to meet the requirements of real-time vehicle diagnostics. Simplified models, such as equivalent circuit models, reduce computational load but sacrifice necessary physical details. Moreover, parameter identification under dynamic real-world conditions is extremely challenging; laboratory-calibrated thresholds often fail in practical applications, leading to a significant increase in false alarm rates. The second is data-driven methods, which include signal processing techniques and machine learning solutions. Signal processing techniques use mathematical transformations to process battery data, but they often miss less obvious fault types, and setting reliable detection thresholds under complex and changing driving conditions remains difficult. While machine learning solutions can automatically identify fault features in data, they heavily rely on large amounts of accurately labeled fault data, which is scarce and expensive to obtain in real battery systems. Artificially simulated data often fails to capture the full complexity of actual fault modes and environmental changes. Furthermore, complex machine learning models can become "black boxes," lacking interpretability and physical basis, which hinders diagnostic reliability and deployment confidence. Summary of the Invention

[0003] In view of the above-mentioned defects or deficiencies in the prior art, this application aims to provide a vehicle battery fault diagnosis method, device and storage medium to improve the accuracy of fault diagnosis.

[0004] This application provides a method for diagnosing vehicle battery faults, the method comprising: For each vehicle battery to be tested, based on the charging information of each charging segment of the vehicle battery to be tested and the preset neural operator architecture, the predicted current and predicted state of charge of each charging segment are predicted. For each charging segment, the charging error corresponding to the charging segment is determined based on the predicted current, predicted state of charge, actual current, and actual state of charge corresponding to the charging segment. For each vehicle battery to be tested, the average charging error of the vehicle battery to be tested is determined based on the charging error corresponding to each charging segment of the vehicle battery to be tested and a preset first threshold. Based on the average charging error of the batteries in each vehicle under test and the preset fault threshold, the batteries of each faulty vehicle are determined. According to the technical solution provided in the embodiments of this application, optionally, the preset neural operator architecture includes a spectral convolutional layer and a model layer, and the preset neural operator architecture is constructed based on the following method: In the spectral convolutional layer, for each normal charging segment, the normal charging information of each normal charging segment is subjected to Fourier transform to obtain the charging spectrum corresponding to each normal charging information. For each charging spectrum, the charging spectrum is split according to each preset low frequency band to obtain each low frequency spectrum corresponding to the charging spectrum. Convolution processing is performed on each low frequency spectrum corresponding to the charging spectrum to obtain the target convolution value corresponding to the charging spectrum. In the model layer, the model layer is trained based on the target convolution values, normal current, and normal state of charge corresponding to each normal charging segment.

[0005] According to the technical solution provided in the embodiments of this application, optionally, the preset neural operator architecture further includes a projection layer, and after obtaining the target convolution value corresponding to the charging spectrum, it further includes: In the projection layer, for each normal charging segment, the target convolution values ​​corresponding to the normal charging segment are projected into a preset space to obtain the target projection values ​​corresponding to the normal charging segment. Accordingly, in the model layer, training the model layer based on the target convolution values, normal current, and normal state of charge corresponding to each normal charging segment includes: In the model layer, the model layer is trained based on the target projection values, normal current, and normal state of charge corresponding to each normal charging segment.

[0006] According to the technical solution provided in the embodiments of this application, optionally, determining the charging error corresponding to the charging segment based on the predicted current, predicted state of charge, actual current, and actual state of charge corresponding to the charging segment includes: The first error is determined based on the predicted current, the actual current, and the preset first normalization function corresponding to the charging segment; The second error is determined based on the predicted state of charge, the actual state of charge, and the preset second normalization function corresponding to the charging segment. The charging error corresponding to the charging segment is determined based on the first error, the second error, and the preset weight.

[0007] According to the technical solution provided in the embodiments of this application, optionally, determining the average charging error of the vehicle battery under test based on the charging error corresponding to each charging segment of the battery under test and a preset first threshold includes: The number of charging segments to be processed is determined based on a preset first threshold and the number of charging segments of the vehicle battery to be detected. Based on the charging error corresponding to each charging segment of the vehicle battery to be tested, they are sorted in a preset order, and the charging segments that meet the number requirements for the number of charging segments to be processed are taken as the charging segments to be processed. The average charging error of the vehicle battery under test is determined based on the charging error corresponding to each charging segment to be processed and the number of charging segments to be processed.

[0008] Optionally, the technical solution provided in the embodiments of this application may also include: Determine the threshold for each candidate fault based on the preset threshold range and preset step size; For each candidate fault threshold, the true positive rate and false positive rate corresponding to the candidate fault threshold are determined based on the average charging error of each known vehicle battery, the fault state of each known vehicle battery, the number of known normal vehicle batteries, the number of known abnormal vehicle batteries, and the candidate fault threshold. The preset fault threshold is determined based on the true positive rate and false positive rate corresponding to each candidate fault threshold, the minimization of the total expected cost function, and each preset constraint condition. The function for minimizing the total expected cost is constructed based on the true positive rate, false positive rate, failure rate, cost of a single failure not detected, and cost of a single inspection. The preset constraints include constraints corresponding to the failure rate, cost of a single failure not detected, and cost of a single inspection.

[0009] According to the technical solution provided in the embodiments of this application, optionally, the function for minimizing the total expected cost is constructed in the following manner: The true positive rate and failure rate are used to determine the true positive probability, and the false positive rate and failure rate are used to determine the false positive probability. Based on the true positive probability, the false positive probability, and the cost per inspection, determine the expected cost of detecting the fault; Based on the true positive rate, the probability of not detecting a fault is determined, and based on the probability of not detecting a fault, the fault rate, and the cost of not detecting a fault in a single instance, the expected cost of not detecting a fault is determined. Construct an economic cost function based on the expected cost of detecting a fault and the expected cost of not detecting a fault; A function to minimize the total expected cost is constructed with the objective of minimizing the total expected cost of each candidate fault threshold on the economic cost function.

[0010] Optionally, the technical solution provided in the embodiments of this application may also include: Divide the known vehicle batteries into a predetermined number of subsets; For each subset, the portion of the known vehicle batteries excluding the subset is determined as the training set corresponding to the subset; For each training set, based on minimizing the total expected cost function and each preset constraint, and according to the preset threshold range, preset step size, and the average charging error of each known vehicle battery, the fault state of each known vehicle battery, the number of known normal vehicle batteries, and the number of known abnormal vehicle batteries in the training set, the local optimal threshold corresponding to the training set is determined. The preset fault threshold is determined based on the local optimal threshold corresponding to each training set.

[0011] This application also provides an electronic device, the electronic device comprising: Processor and memory; The processor executes the steps of the vehicle battery fault diagnosis method as described in any embodiment by calling programs or instructions stored in the memory.

[0012] This application also provides a computer-readable storage medium storing a program or instructions that cause a computer to perform the steps of the vehicle battery fault diagnosis method as described in any embodiment.

[0013] In summary, this application proposes a vehicle battery fault diagnosis method. For each vehicle battery under test, based on the charging information of each charging segment and a pre-constructed neural operator architecture, the method predicts the current and state of charge (SOC) corresponding to each charging segment. This allows for accurate prediction of the charging current and SOC using the pre-constructed neural operator architecture. Furthermore, for each charging segment, the method determines the charging error based on the predicted current, predicted SOC, actual current, and actual SOC, thus assessing the degree of deviation of each charging segment. For each vehicle battery under test, the method determines the average charging error based on the charging errors of each charging segment and a pre-constructed first threshold, thereby comprehensively obtaining an evaluation standard for the vehicle battery under test. Finally, based on the average charging error of each vehicle battery under test and a pre-constructed fault threshold, the method identifies each faulty vehicle battery, thereby improving the accuracy of fault diagnosis. Attached Figure Description

[0014] Figure 1 This is a flowchart of a vehicle battery fault diagnosis method provided in an embodiment of this application; Figure 2 This is a flowchart of another vehicle battery fault diagnosis method provided in the embodiments of this application; Figure 3This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0015] The present application will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and not intended to limit it. Furthermore, it should be noted that, for ease of description, only the parts relevant to the invention are shown in the accompanying drawings.

[0016] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.

[0017] Figure 1 This is a flowchart of a vehicle battery fault diagnosis method provided in an embodiment of this application. See also... Figure 1 The specific methods for diagnosing vehicle battery faults include: S110. For each vehicle battery to be tested, based on the charging information of each charging segment of the vehicle battery to be tested and the pre-built preset neural operator architecture, predict the predicted current and predicted state of charge corresponding to each charging segment.

[0018] The vehicle battery under test is the battery that requires fault detection. A charging segment is a portion of charging data obtained from the battery management system of the vehicle under test, cut to a preset length. For example, each charging segment can record data for 128 time steps at 10-second intervals, forming a complete 1280-second charging cycle. Charging information consists of key parameters collected according to a unified communication protocol standard during the charging process, including aggregate voltage, maximum single-cell voltage, minimum single-cell voltage, maximum temperature, and minimum temperature. The preset neural operator architecture can be understood as an inverse system field-current neural operator architecture, used to predict the vehicle battery's current and state of charge based on the charging information. The predicted current and predicted state of charge are the current and state of charge predicted by the preset neural operator architecture during normal charging from the charging segment of the vehicle battery under test.

[0019] Specifically, for each vehicle battery under test, the same method can be used to predict the current and state of charge. Taking one vehicle battery under test as an example, the following steps are taken: The charging segments of the vehicle battery under test are acquired, and the charging information corresponding to each segment is determined. For each charging segment, the charging information corresponding to that segment is used as input to a pre-built neural operator architecture for prediction, which yields the predicted current and predicted state of charge for that segment. Thus, the predicted current and predicted state of charge for each charging segment of each vehicle battery under test can be obtained.

[0020] Optionally, the charging information acquisition stage can employ a three-level cleaning mechanism: First, filtering out data records containing abnormal characters or format errors; second, filtering based on physical plausibility checks, such as removing abnormal data with voltage values ​​exceeding the 1.5V-5.0V range or temperature values ​​exceeding the -20°C-80°C range; third, filtering out invalid charging processes where the nuclear charge number change is less than 5%. The standard dataset composed of each charging segment after the above processing contains high-quality steady-state charging time-series signals, providing reliable input for subsequent neural operator architectures.

[0021] Based on the above example, the preset neural operator architecture includes spectral convolutional layers and model layers, and is constructed in the following manner: In the spectral convolutional layer, for each normal charging segment, the normal charging information of each normal charging segment is subjected to Fourier transform to obtain the charging spectrum corresponding to each normal charging information. For each charging spectrum, the charging spectrum is split according to each preset low frequency band to obtain each low frequency spectrum corresponding to the charging spectrum. Convolution processing is performed on each low frequency spectrum corresponding to the charging spectrum to obtain the target convolution value corresponding to the charging spectrum. In the model layer, the model layer is trained based on the target convolution values, normal current, and normal state of charge corresponding to each normal charging segment.

[0022] The spectral convolutional layer is used for spectral transformation and convolution processing. The model layer provides the parameter mapping model. A normal charging segment is a non-faulty charging segment. Normal charging information is the charging information corresponding to a normal charging segment. The charging spectrum is the spectrum obtained by performing a Fourier transform on the charging information. The preset low-frequency bands are a pre-defined number of low-frequency bands, such as the first 20 low-frequency bands. The low-frequency spectrum is a portion of the charging spectrum corresponding to each preset low-frequency band. The target convolution value is the value obtained by convolving multiple low-frequency spectra corresponding to a given charging spectrum. Normal current and normal state of charge are the actual current and actual state of charge collected for the normal charging segment.

[0023] Specifically, in the spectral convolutional layer, a Fourier transform is performed on each normal charging information segment for each normal charging segment, and the resulting spectrum is the charging spectrum corresponding to that normal charging information. For each charging spectrum, the charging spectrum is split according to each preset low-frequency band, which yields the low-frequency spectrum corresponding to each preset low-frequency band. Then, convolution processing is performed on each low-frequency spectrum corresponding to the charging spectrum, and the resulting convolution value is the target convolution value corresponding to the charging spectrum. Using the target convolution values ​​corresponding to each charging spectrum for each normal charging segment, as well as the normal current and normal state of charge acquired when acquiring the normal charging segment, the model in the model layer can be trained so that the model layer can map the corresponding current and state of charge.

[0024] Building upon the above example, the pre-defined neural operator architecture also includes a projection layer. After obtaining the target convolution value corresponding to the charging spectrum, the following operations can be performed based on the projection layer: In the projection layer, for each normal charging segment, the target convolution values ​​corresponding to the normal charging segment are projected into a preset space to obtain the target projection values ​​corresponding to the normal charging segment.

[0025] The preset space can be a pre-defined high-dimensional space, and its dimension should be greater than the number of categories of the target convolutional values. For example, the target convolutional values ​​can form 5-dimensional data, and the preset space can be a 64-dimensional latent space. The target projected values ​​are the high-dimensional data obtained after projecting onto the preset space.

[0026] Specifically, in the projection layer, for each normal charging segment, the target convolution values ​​corresponding to each normal charging information of the normal charging segment are projected as a whole into a preset space to expand the dimension and obtain the target projection values ​​corresponding to the normal charging segment.

[0027] Based on the above example, the subsequent steps need to be adaptively adjusted. This can be achieved by training the model layer in the following way, based on the target convolution values, normal current, and normal state of charge corresponding to each normal charging segment: In the model layer, the model layer is trained based on the target projection values, normal current, and normal state of charge corresponding to each normal charging segment.

[0028] Specifically, by using the target projection values ​​corresponding to each normal charging segment, as well as the normal current and normal state of charge acquired when acquiring that normal charging segment, the model in the model layer can be trained so that the model layer can map the corresponding current and state of charge.

[0029] Understandably, the implementation of a pre-defined neural operator architecture during the construction phase involves five technical steps: Step 1. Input Parameter Field Construction The input parameter field a(x) consists of time-series measurements of five key physical quantities (charging information):

[0030] in, Indicates the total voltage. and These represent the maximum and minimum single-cell voltages, respectively. and These represent the maximum and minimum temperatures, respectively. The design of this input parameter field explicitly captures the multiphysics coupling characteristics of the battery system, particularly the intrinsic relationship between voltage imbalance and temperature gradient.

[0031] Step 2. Spectral Convolutional Layer Design Fourier transform is used to process the data in the frequency domain; the first 20 low-frequency modes (preset low-frequency bands) are retained to characterize the slowly changing thermal transients and the state of charge (SOC) progression; the target convolution value is obtained by performing convolution operations on each spectrum.

[0032] Step 3. Initial Projection and Feature Extraction (Projection Layer) Mapping the 5-dimensional input parameters to a 64-dimensional latent space (preset space) enhances the model's ability to express the complexity of multi-physics coupling, enabling neural operators to capture subtle interactions in electrochemical-thermodynamic processes.

[0033] Step 4. Model Training (Model Layer Training) To avoid contamination by fault features during training using only normal charging segments, the following loss function can be constructed:

[0034] Where N is the number of training samples (the number of normal charging segments), and t is the time step. These are the actual values ​​(normal current and normal state of charge). These are predicted values ​​(predicted current and predicted state of charge).

[0035] Data augmentation techniques can be applied during training, including random time pruning (e.g., pruning ratio 0.8-1.0) and adding Gaussian noise (σ=0.01), to enhance the model's robustness to sensor inaccuracies. Through this training strategy, the model layers can accurately learn the multiphysics coupling relationships under normal conditions, providing a benchmark for subsequent fault detection.

[0036] Step 5. Model Validation and Optimization (Model Layer Validation and Optimization) The model performance was evaluated using 5-fold cross-validation, and the root mean square error (RMSE) of the current and SOC predictions was calculated.

[0037] The model optimization objective can be set to ensure that RMSE_current (root mean square error of current) < 0.15A and RMSE_SOC (root mean square error of state of charge) < 0.1%, so as to ensure that the prediction accuracy meets the fault detection requirements.

[0038] An innovative pre-defined neural operator architecture is employed to accurately model multi-physics coupling relationships. The core innovation of this architecture lies in using time-frequency domain spectral convolution to process input data (charging information), effectively capturing the complex spatiotemporal dependencies between voltage distribution and temperature gradient. Unlike traditional neural networks, the pre-defined neural operator architecture directly processes data in the frequency domain, retaining the first 20 low-frequency patterns (pre-defined low-frequency band) to characterize slowly changing thermal transients and state of charge progression, while filtering out high-frequency noise interference. The input parameter field a(x) consists of time-series measurements of five key physical quantities: total voltage, maximum single-cell voltage, minimum single-cell voltage, maximum temperature, and minimum temperature, forming a 128×5 input tensor; the solution field is used to predict current and SOC, forming a 128×2 output tensor. Specifically, training is performed only using normal charging segments to ensure the model learns normal multi-physics interactions, avoiding fault feature contamination, thereby establishing a baseline behavior pattern for healthy batteries.

[0039] S120. For each charging segment, determine the charging error corresponding to the charging segment based on the predicted current, predicted state of charge, actual current, and actual state of charge corresponding to the charging segment.

[0040] The actual current and actual state of charge (SOC) are the current and SOC corresponding to the time segment being charged. Charging error describes the difference between the predicted normal charging result and the actual measured charging result.

[0041] Specifically, for each charging segment, the corresponding charging error can be calculated to measure the degree of deviation between the actual data and the model prediction data, so as to reflect the degree of anomaly in the multiphysics coupling relationship. The predicted current corresponding to the charging segment can be compared with the actual current, and the predicted state of charge can be compared with the actual state of charge to obtain the error corresponding to the current and the error corresponding to the state of charge. Combining the errors of the two parts, the charging error of the charging segment can be obtained.

[0042] S130. For each vehicle battery to be tested, determine the average charging error of the vehicle battery to be tested based on the charging error corresponding to each charging segment of the vehicle battery to be tested and a preset first threshold.

[0043] The preset first threshold is a pre-defined threshold used to separate faulty charging segments from non-faulty charging segments; it can be a percentage, such as 20%. The average charging error is the mean of all charging errors within the first threshold.

[0044] Specifically, for each vehicle battery to be tested, the charging segments of the vehicle battery to be tested are sorted according to the magnitude of their corresponding charging errors, the charging errors within the first threshold are retained, and the average value is calculated as the average charging error of the vehicle battery to be tested.

[0045] Based on the above example, the average charging error of the vehicle battery under test can be determined by the following method, according to the charging error corresponding to each charging segment of the battery and a preset first threshold: The number of charging segments to be processed is determined based on a preset first threshold and the number of charging segments of the battery of the vehicle to be detected. Based on the charging error corresponding to each charging segment of the vehicle battery to be tested, they are sorted in a preset order, and the charging segments that meet the number requirements for the number of charging segments to be processed are taken as the charging segments to be processed. The average charging error of the vehicle battery under test is determined based on the charging error corresponding to each charging segment to be processed and the number of charging segments to be processed.

[0046] The number of charging segments to be processed is the product of a preset first threshold and the number of charging segments in the vehicle battery to be tested. The preset order is a pre-determined order based on requirements, which can be from largest to smallest or smallest to largest. The charging segments to be processed are those with the largest charging errors after sorting. It can be understood that the smallest charging error among the charging segments to be processed is greater than the largest charging error among the remaining charging segments. The remaining charging segments are the charging segments remaining after excluding the charging segments to be processed from the charging segments in the vehicle battery to be tested.

[0047] Specifically, the product of a preset first threshold and the number of charging segments of the vehicle battery under test is used as the number of charging segments to be processed. The charging errors corresponding to each charging segment of the vehicle battery under test are sorted according to a preset order, and the charging segments that meet the requirement for the number of charging segments to be processed are designated as the charging segments to be processed. The average charging error of the vehicle battery under test is calculated by averaging the charging errors corresponding to these charging segments and the number of charging segments to be processed.

[0048] For example, the average charging error of the vehicle battery under test can be determined by the following formula:

[0049] in, Let p be the average charging error of the v-th vehicle battery to be tested, and p be a preset first threshold. Let V be the number of charging segments of the battery of the v-th vehicle to be tested. This represents the charging error corresponding to the i-th charging segment.

[0050] Understandably, based on a preset first threshold, each charging segment sorted by charging error can be classified into two categories. The classification result identifies charging segments that may have faults, providing a basis for subsequent vehicle-level evaluation.

[0051] S140. Determine the faulty vehicle battery based on the average charging error of each vehicle battery to be tested and the preset fault threshold.

[0052] The preset fault threshold is a pre-set threshold used to determine whether the average charging error has reached a fault level. A faulty vehicle battery is a vehicle battery predicted to be faulty.

[0053] Specifically, for each vehicle battery under test, the average charging error of that battery can be compared with a preset fault threshold. If it exceeds the preset fault threshold, the battery is considered a faulty battery; otherwise, it is considered a normal battery. Based on this, the faulty battery can be identified from among the batteries tested.

[0054] In multiphysics coupling modeling, the pre-defined neural operator architecture employs time-frequency domain spectral convolution to process input data, effectively capturing the complex spatiotemporal dependence between voltage distribution and temperature gradient, overcoming the limitation of traditional methods in accurately characterizing electrochemical-thermodynamic coupling characteristics. The innovative strategy of training using only normal charging data completely solves the problem of existing technologies' reliance on large amounts of labeled fault data. Due to the scarcity and high cost of acquiring real fault data, traditional machine learning methods often require artificial simulation to generate training data, but these simulated data cannot fully reflect the complexity of actual fault modes and environmental changes. The above scheme transforms fault detection into an anomaly detection problem by learning the multiphysics coupling relationship under normal charging conditions, significantly reducing the difficulty of data acquisition and enhancing the model's generalization ability to unknown fault types. In practical applications, this method improves the detection sensitivity of key fault types such as internal short circuits and thermal runaway by 28%, while controlling the false alarm rate below 5%, significantly improving the reliability of battery safety management.

[0055] The vehicle battery fault diagnosis method provided in this application improves the accuracy of fault diagnosis by predicting the current and state of charge (SOC) of each charging segment for each vehicle battery under test based on the charging information of each charging segment and a pre-built neural operator architecture. This allows for accurate prediction of the charging current and SOC using the pre-built neural operator architecture. Furthermore, for each charging segment, the charging error is determined based on the predicted current, predicted SOC, actual current, and actual SOC, facilitating the assessment of the deviation of each charging segment. For each vehicle battery under test, the average charging error is determined based on the charging errors of each charging segment and a pre-set first threshold, providing a comprehensive evaluation standard for the vehicle battery. Finally, the faulty vehicle battery is identified based on the average charging error and a pre-set fault threshold, thus improving the accuracy of fault diagnosis.

[0056] Figure 2 This is a flowchart of another vehicle battery fault diagnosis method provided in an embodiment of this application. Based on the above embodiments, the process of calculating the average charging error of the vehicle battery under test is illustrated, and the method for determining the preset fault threshold is also illustrated. See [link to documentation]. Figure 2 The specific methods for diagnosing vehicle battery faults include: S210. For each vehicle battery to be tested, based on the charging information of each charging segment of the vehicle battery to be tested and the pre-built preset neural operator architecture, predict the predicted current and predicted state of charge corresponding to each charging segment.

[0057] S220. Determine the first error based on the predicted current, actual current and preset first normalization function corresponding to the charging segment.

[0058] The preset first normalization function is a pre-constructed function used to normalize the current error. The first error is the normalized result of the current error.

[0059] Specifically, for each charging segment, the difference between the corresponding predicted current and the actual current is calculated as the current error. The current error is then substituted into the preset first normalization function to obtain the first error.

[0060] S230. Determine the second error based on the predicted state of charge, the actual state of charge, and the preset second normalization function corresponding to the charging segment.

[0061] The preset second normalization function is a pre-constructed function used to normalize the state-of-charge error. The second error is the normalized result of the state-of-charge error.

[0062] Specifically, for each charging segment, the difference between the predicted state of charge and the actual state of charge is calculated as the state of charge error. The state of charge error is then substituted into a preset second normalization function to obtain the second error.

[0063] S240. Determine the charging error corresponding to the charging segment based on the first error, the second error, and the preset weight.

[0064] Among them, the preset weights are the weights pre-assigned to the current and the state of charge.

[0065] Specifically, the first error and the second error are weighted and summed according to preset weights to obtain the charging error corresponding to the charging segment.

[0066] S250. For each vehicle battery to be tested, determine the average charging error of the vehicle battery to be tested based on the charging error corresponding to each charging segment of the vehicle battery to be tested and a preset first threshold.

[0067] S260. Based on the average charging error of each vehicle battery to be tested and the preset fault threshold, determine the faulty vehicle battery.

[0068] Based on the above example, a preset failure threshold needs to be determined in advance based on minimizing the total expected cost. Specifically, it can be: Determine the threshold for each candidate fault based on the preset threshold range and preset step size; For each candidate fault threshold, the true positive rate and false positive rate are determined based on the average charging error of each known vehicle battery, the fault status of each known vehicle battery, the number of known normal vehicle batteries, the number of known abnormal vehicle batteries, and the candidate fault threshold. The preset fault thresholds are determined based on the true positive rate and false positive rate corresponding to each candidate fault threshold, the minimization of the total expected cost function, and each preset constraint condition.

[0069] The preset threshold range is a pre-defined range of thresholds for a preset fault threshold. The preset step size is the step size in the threshold search process. Candidate fault thresholds are multiple thresholds determined within the preset threshold range according to the preset step size. A known vehicle battery is a vehicle battery with a known fault state. Fault states can include normal and abnormal, i.e., non-fault and fault. The number of known normal vehicle batteries is the number of known vehicle batteries with a normal fault state. The number of known abnormal vehicle batteries is the number of known vehicle batteries with an abnormal fault state. The true positive rate reflects the ability to correctly identify abnormal vehicle batteries (faulty vehicle batteries). The false positive rate reflects the probability of misclassifying a normal vehicle battery as an abnormal vehicle battery. The function for minimizing the total expected cost is constructed based on the true positive rate, false positive rate, fault rate, cost of a single instance of not detecting a fault, and cost of a single inspection. The preset constraints include constraints corresponding to the fault rate, cost of a single instance of not detecting a fault, and cost of a single inspection. For example, the preset constraints for the failure rate are 0.038%-0.075%, the preset constraints for the cost of a single undetected failure are 1 million to 5 million yuan, and the preset constraints for the cost of a single inspection are 8,000 to 55,000 yuan.

[0070] Specifically, data is collected within a preset threshold range at a preset step size to obtain candidate fault thresholds. For each candidate fault threshold, fault identification is performed on the average charging error of each known vehicle battery according to that candidate fault threshold. Combining the actual fault states of each known vehicle battery, the number of known normal vehicle batteries, and the number of known abnormal vehicle batteries, the true positive rate and false positive rate corresponding to the candidate fault threshold can be calculated. Specifically, for each candidate fault threshold, the fault state of each known vehicle battery is determined according to that candidate fault threshold, i.e., the predicted normal vehicle batteries and predicted abnormal vehicle batteries are determined. The number of known abnormal vehicle batteries identified as predicted abnormal vehicle batteries divided by the total number of known abnormal vehicle batteries is used as the true positive rate, and the number of known normal vehicle batteries identified as predicted abnormal vehicle batteries divided by the total number of known normal vehicle batteries is used as the false positive rate. Under the constraints of each preset constraint, the true positive rate and false positive rate corresponding to each candidate fault threshold are substituted into the function of minimizing the total expected cost to obtain the preset fault threshold.

[0071] Building upon the example above, the function for minimizing the total expected cost is constructed as follows: The true positive rate and failure rate are used to determine the true positive probability, and the false positive rate and failure rate are used to determine the false positive probability. Determine the expected cost of detecting a fault based on the true positive probability, false positive probability, and cost per inspection. Based on the true positive rate, determine the probability of not detecting a fault, and based on the probability of not detecting a fault, the fault rate, and the cost of not detecting a fault per instance, determine the expected cost of not detecting a fault. Construct an economic cost function based on the expected cost of detecting a fault and the expected cost of not detecting a fault; A function to minimize the total expected cost is constructed with the objective of minimizing the total expected cost of each candidate fault threshold on the economic cost function.

[0072] The economic cost function is a function of the sum of the expected cost of not detecting a fault and the expected cost of detecting a fault. The expected cost of not detecting a fault is the product of the fault rate and the probability of not detecting a fault, multiplied by the cost of a single instance of not detecting a fault. The probability of not detecting a fault is 1 minus the true positive rate. The expected cost of detecting a fault is the sum of the true positive probability and the false positive probability, multiplied by the cost of a single inspection. The true positive probability is the product of the fault rate and the true positive rate, and the false positive probability is 1 minus the product of the difference between the fault rates and the false positive rate.

[0073] Specifically, the economic cost function is:

[0074] Where y represents the economic cost and p represents the failure rate. The true positive rate, The false positive rate, The cost of a single instance of a fault not being detected. Cost per inspection.

[0075] Understandably, the expected cost of not detecting a fault is... The probability of no fault being detected is The expected cost of detecting a fault is The probability of a true positive is The false positive probability is This economic cost function comprehensively considers the economic impact of missed fault detections and false alarms.

[0076] Based on the example above, the function that minimizes the total expected cost is:

[0077] in, To preset the fault threshold, Let p be the candidate fault threshold, and p be the fault rate. Candidate fault threshold The corresponding true positive rate, Candidate fault threshold The corresponding false positive rate, The cost of a single instance of a fault not being detected. Cost per inspection.

[0078] For each candidate fault threshold τ, calculate the true positive rate and false positive rate:

[0079]

[0080] in, and These represent the sets of batteries from abnormal vehicles and the sets of batteries from normal vehicles, respectively. and Given the known number of batteries in abnormal vehicles and the known number of batteries in normal vehicles. (·) is an indicator function used to determine whether the requirements are met; 1 indicates that the requirements are met, and 0 indicates that the requirements are not met. Let be the average charging error of the v-th vehicle battery under test. This calculation allows us to establish a mapping relationship between candidate fault thresholds and detection performance.

[0081] It is understandable that the optimization process of determining the preset fault threshold by minimizing the total expected cost is to find the operating point with the lowest economic cost (total expected cost) on the ROC curve (Receiver Operating Characteristic Curve), rather than simply pursuing the optimal technical indicators.

[0082] Building upon the above example, K-fold cross-validation can be introduced to improve the robustness of the preset fault threshold. Specifically, this can be achieved by: Divide the known vehicle batteries into a predetermined number of subsets; For each subset, the portion of the known vehicle batteries excluding the subset is determined as the training set corresponding to the subset; For each training set, based on minimizing the total expected cost function and each preset constraint, and according to the preset threshold range, preset step size, and the average charging error of each known vehicle battery, the fault state of each known vehicle battery, the number of known normal vehicle batteries, and the number of known abnormal vehicle batteries in the training set, the local optimal threshold corresponding to the training set is determined. The preset fault threshold is determined based on the local optimal threshold corresponding to each training set.

[0083] The preset number is the pre-defined number of folds for cross-validation. A subset is each set obtained by evenly distributing known vehicle batteries. The training set is the sum of all remaining subsets except for a given subset. The local optimum threshold is a threshold determined on a given training set.

[0084] Specifically, the known vehicle batteries are divided into multiple subsets based on a predetermined number. For each subset, the remaining subsets of known vehicle batteries are used as the training set. For each training set, based on minimizing the total expected cost function and various predetermined constraints, and considering the predetermined threshold range, predetermined step size, average charging error of each known vehicle battery in the training set, fault status of each known vehicle battery, number of known normal vehicle batteries, and number of known abnormal vehicle batteries, the threshold obtained is the local optimum threshold for that training set. This is the threshold calculation method based on the example above. The specific calculation method is not elaborated here, but can be referred to the calculation method in the example above. Thus, the local optimum thresholds for each training set can be obtained. Statistical analysis of these local optimum thresholds yields the global optimum threshold, which is the predetermined fault threshold. For example, the mean and median of each local optimum threshold can be calculated.

[0085] For example, the above example uses K-fold cross-validation to ensure the generalization ability of the preset fault threshold. That is, the dataset (known vehicle batteries) is divided into K subsets of equal size (preset number), and for each subset j, j=1,2,...,K; for each subset j, subset j is used as the validation set, and the remaining subsets are used as the training set; the local optimal threshold is calculated on the validation set / training set. Determine the globally optimal threshold: .

[0086] This strategy enhances the adaptability of preset fault thresholds to changes in data distribution, ensuring good results under different regional and market conditions. In other words, known vehicle batteries can be selected according to regional and market conditions to correspond to the battery of the vehicle being tested.

[0087] By constructing an economic cost function (total expected cost) that includes failure rate, failure cost, and inspection cost, this approach organically combines technical performance indicators with economic parameters, enabling dynamic calibration of preset failure thresholds and minimizing total expected costs. Practical application data shows that within typical parameter ranges—failure rate 0.038%-0.075%, cost of a single undetected failure ranging from RMB 1 million to 5 million, and inspection cost of RMB 8,000 to 55,000—this solution reduces operating costs by more than 20% compared to existing methods. This economy-oriented optimization strategy can adaptively adjust to different regional market conditions and manufacturer-specific cost structures, significantly improving the practicality and commercial value of the solution. Particularly in large-scale fleet management scenarios, this mechanism can save electric vehicle operators millions of RMB in maintenance costs annually while ensuring the safe operation of the battery system. By determining the global preset failure threshold through a K-fold cross-validation strategy, the optimal balance between diagnostic performance and economic cost is achieved under different regional market conditions. This innovation transforms battery fault diagnosis from a simple technical indicator evaluation to a comprehensive techno-economic optimization, providing a new decision-making paradigm for electric vehicle battery safety management.

[0088] A two-stage threshold mechanism based on residual analysis is employed to achieve high-precision anomaly identification. The first stage calculates the charging error for each charging segment, quantifying the deviation between predicted and actual values ​​through normalized error. The second stage uses a vehicle-level classification strategy to calculate the average charging error of each vehicle battery within a preset first threshold as a vehicle battery health indicator. This mechanism effectively filters transient anomalies while maintaining high sensitivity to persistent faults, significantly improving diagnostic reliability. Its core innovation lies in indirectly detecting faults by predicting abnormal changes in current and SOC trajectory. When battery faults (such as internal short circuits or thermal runaway) disrupt normal multiphysics coupling, the model generates significant residuals. For example, in the case of an internal short circuit, the current will show an abnormal surge; in the case of thermal runaway, the SOC will show an abnormal drift. These anomalies lead to a significant increase in normalized error (charging error), thereby enabling early fault detection. Furthermore, unlike traditional threshold setting methods, the preset fault threshold in this example is not a fixed value but is dynamically determined through economic optimization, ensuring optimal diagnostic performance in different application scenarios.

[0089] Optionally, a results processing and application module can be introduced later to implement intelligent decision-making, including both data storage and decision output functions. The data storage system can adopt a three-level architecture: the basic layer stores the charging error of the charging segment and the vehicle health score (average charging error); the metadata layer associates the vehicle identification number, mileage, battery type, and historical maintenance records; and the configuration layer records economic parameters and preset fault thresholds. Data output adopts standardized format specifications: vehicle health scores are encapsulated in JSON (JavaScript Object Notation) format for easy system integration, anomaly detection results are generated in CSV (Comma-Separated Values) format for easy manual analysis, and a RESTful API (Representational State Transfer Application Programming Interface) is provided to support real-time decision-making.

[0090] In practical applications, when a vehicle's health score exceeds a preset fault threshold, a three-tiered early warning mechanism is automatically triggered: Level 1 (80%-90% threshold) sends preventative maintenance recommendations; Level 2 (90%-100% threshold) arranges professional inspections; and Level 3 (exceeding 100% threshold) immediately restricts vehicle use and initiates an emergency response. This mechanism not only achieves high-precision fault detection at the technical level but also provides a complete decision support system, significantly improving the overall effectiveness of electric vehicle battery safety management.

[0091] The vehicle battery fault diagnosis method provided in this application determines a first error based on the predicted current, actual current, and a preset first normalization function corresponding to a charging segment; a second error based on the predicted state of charge, actual state of charge, and a preset second normalization function corresponding to the charging segment; and a charging error corresponding to the charging segment based on the first error, the second error, and preset weights. This method comprehensively considers the errors in charging current and state of charge. Furthermore, it determines candidate fault thresholds based on a preset threshold range and a preset step size. For each candidate fault threshold, it determines the true positive rate and false positive rate based on the average charging error of known vehicle batteries, the fault state of known vehicle batteries, the number of known normal vehicle batteries, the number of known abnormal vehicle batteries, and the candidate fault threshold. Finally, it determines a preset fault threshold based on the true positive rate and false positive rate of each candidate fault threshold, the minimization of the total expected cost function, and various preset constraints. This method significantly improves the accuracy and economy of battery fault diagnosis through an economic optimization decision-making mechanism.

[0092] Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. For example... Figure 3 As shown, the electronic device 300 includes one or more processors 301 and memory 302.

[0093] The processor 301 may be a central processing unit (CPU) or other form of processing unit with data processing and / or instruction execution capabilities, and may control other components in the electronic device 300 to perform desired functions.

[0094] The memory 302 may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. The volatile memory may include, for example, random access memory (RAM) and / or cache memory. The non-volatile memory may include, for example, read-only memory (ROM), hard disk, flash memory, etc. One or more computer program instructions may be stored on the computer-readable storage medium, and the processor 301 may execute the program instructions to implement the vehicle battery fault diagnosis method of any embodiment of this application described above and / or other desired functions. Various contents such as initial external parameters and thresholds may also be stored in the computer-readable storage medium.

[0095] In one example, the electronic device 300 may further include an input device 303 and an output device 304, these components being interconnected via a bus system and / or other forms of connection mechanisms (not shown). The input device 303 may include, for example, a keyboard, a mouse, etc. The output device 304 may output various information to the outside, including warning messages, braking force, etc. The output device 304 may include, for example, a display, a speaker, a printer, and a communication network and its connected remote output devices, etc.

[0096] Of course, for the sake of simplicity, Figure 3 Only some of the components of the electronic device 300 relevant to this application are shown in this illustration; components such as buses, input / output interfaces, etc., are omitted. In addition, the electronic device 300 may include any other suitable components depending on the specific application.

[0097] In addition to the methods and devices described above, embodiments of this application may also be computer program products, which include computer program instructions that, when executed by a processor, cause the processor to perform the steps of the vehicle battery fault diagnosis method provided in any embodiment of this application.

[0098] The computer program product can be written in any combination of one or more programming languages ​​to perform the operations of the embodiments of this application. The programming languages ​​include object-oriented programming languages ​​such as Java and C++, as well as conventional procedural programming languages ​​such as C or similar languages. The program code can be executed entirely on the user's computing device, partially on the user's computing device, as a standalone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server.

[0099] Furthermore, embodiments of this application may also be computer-readable storage media storing computer program instructions thereon, which, when executed by a processor, cause the processor to perform the steps of the vehicle battery fault diagnosis method provided in any embodiment of this application.

[0100] The computer-readable storage medium may be any combination of one or more readable media. A readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of readable storage media (a non-exhaustive list) include: an electrical connection having one or more wires, a portable disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof.

[0101] It should be noted that the terminology used in this application is for the purpose of describing specific embodiments only and is not intended to limit the scope of this application. As shown in the specification and claims of this application, unless the context clearly indicates otherwise, words such as "a," "an," "an," and / or "the" do not specifically refer to the singular and may also include the plural. The terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, or apparatus. Without further limitations, an element defined by the phrase "comprising an..." does not exclude the presence of other identical elements in the process, method, or apparatus that includes said element.

[0102] It should also be noted that the terms "center," "upper," "lower," "left," "right," "vertical," "horizontal," "inner," and "outer," etc., indicate the orientation or positional relationship 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 on this application. Unless otherwise expressly specified and limited, the terms "installed," "connected," "linked," etc., should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; they can refer to the internal communication between two elements. For those skilled in the art, the specific meaning of the above terms in this application can be understood according to the specific circumstances.

[0103] This document uses specific examples to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the methods and core ideas of this application. The above descriptions are only preferred embodiments of this application. It should be noted that due to the limitations of written expression, while there are objectively infinite specific structures, those skilled in the art can make several improvements, modifications, or changes without departing from the principles of this invention, and can also combine the above technical features in an appropriate manner. These improvements, modifications, changes, or combinations, or the direct application of the inventive concept and technical solution to other situations without modification, should all be considered within the scope of protection of this application.

Claims

1. A vehicle battery failure diagnosis method characterized by, The method comprises the following steps: For each vehicle battery to be detected, the charging information of each charging segment of the vehicle battery to be detected is used to predict the predicted current and the predicted state of charge corresponding to each charging segment according to a preset neural operator architecture. For each charging segment, the charging error corresponding to the charging segment is determined according to the predicted current, the predicted state of charge, the actual current and the actual state of charge corresponding to the charging segment. For each vehicle battery to be detected, the average charging error of the vehicle battery to be detected is determined according to the charging error corresponding to each charging segment of the vehicle battery to be detected and a preset first threshold value. According to the average charging error of each vehicle battery to be detected and a preset fault threshold value, each fault vehicle battery is determined.

2. The method of claim 1, wherein, The preset neural operator architecture comprises a spectral convolution layer and a model layer, and the preset neural operator architecture is constructed based on the following manner: In the spectral convolution layer, for each normal charging segment, the normal charging information of the normal charging segment is subjected to Fourier transform respectively to obtain the charging spectrum corresponding to each normal charging information. For each charging spectrum, the charging spectrum is split according to each preset low-frequency segment to obtain the low-frequency spectrum corresponding to the charging spectrum, and the low-frequency spectrum corresponding to the charging spectrum is subjected to convolution processing to obtain the target convolution value corresponding to the charging spectrum. In the model layer, the model layer is trained according to the target convolution value, the normal current and the normal state of charge corresponding to each normal charging segment.

3. The method of claim 2, wherein, The preset neural operator architecture further comprises a projection layer, and after the target convolution value corresponding to the charging spectrum is obtained, the following steps are further included: In the projection layer, for each normal charging segment, the target convolution value corresponding to the normal charging segment is projected into a preset space to obtain the target projection value corresponding to the normal charging segment. Correspondingly, the training of the model layer in the model layer according to the target convolution value, the normal current and the normal state of charge corresponding to each normal charging segment comprises the following steps: In the model layer, the model layer is trained according to the target projection value, the normal current and the normal state of charge corresponding to each normal charging segment.

4. The method of claim 1, wherein, The determination of the charging error corresponding to the charging segment according to the predicted current, the predicted state of charge, the actual current and the actual state of charge corresponding to the charging segment comprises the following steps: A first error is determined according to the predicted current, the actual current and a preset first normalization function corresponding to the charging segment. A second error is determined according to the predicted state of charge, the actual state of charge and a preset second normalization function corresponding to the charging segment. The charging error corresponding to the charging segment is determined according to the first error, the second error and a preset weight.

5. The method of claim 1, wherein, The determination of the average charging error of the vehicle battery to be detected according to the charging error corresponding to each charging segment of the vehicle battery to be detected and a preset first threshold value comprises the following steps: The number of charging segments to be processed is determined according to the first threshold value and the number of charging segments of the vehicle battery to be detected. According to the charging errors corresponding to each charging segment of the vehicle battery to be detected, the charging segments meeting the number requirement of the charging segments to be processed are sorted in a preset order as the charging segments to be processed; According to the charging errors corresponding to each charging segment to be processed and the number of the charging segments to be processed, the average charging error of the vehicle battery to be detected is determined.

6. The method of claim 1, wherein, Further comprising: According to the preset threshold range and the preset step length, each candidate fault threshold is determined; For each candidate fault threshold, according to the average charging error of each known vehicle battery, the fault state of each known vehicle battery, the number of known normal vehicle batteries, the number of known abnormal vehicle batteries and the candidate fault threshold, the true positive rate and the false positive rate corresponding to the candidate fault threshold are determined; According to the true positive rate and the false positive rate corresponding to each candidate fault threshold, the minimum total expected cost function and each preset constraint condition, the preset fault threshold is determined; Wherein, the minimum total expected cost function is constructed based on the true positive rate, the false positive rate, the fault rate, the cost of single undetected fault and the cost of single inspection, and the preset constraint condition includes the constraint condition corresponding to the fault rate, the cost of single undetected fault and the cost of single inspection respectively.

7. The method of claim 6, wherein, The minimum total expected cost function is constructed by the following way: According to the true positive rate and the fault rate, the true positive probability is determined, and according to the false positive rate and the fault rate, the false positive probability is determined; According to the true positive probability, the false positive probability and the cost of single inspection, the expected cost of detecting fault is determined; According to the true positive rate, the probability of undetected fault is determined, and according to the probability of undetected fault, the fault rate and the cost of single undetected fault, the expected cost of undetected fault is determined; According to the expected cost of detecting fault and the expected cost of undetected fault, the economic cost function is constructed; The minimum total expected cost function is constructed with the minimum total expected cost of each candidate fault threshold on the economic cost function as the target.

8. The method of claim 1, wherein, Further comprising: Each known vehicle battery is divided into a preset number of subsets; For each subset, the part of each known vehicle battery except the subset is determined as the training set corresponding to the subset; For each training set, based on the minimum total expected cost function and each preset constraint condition, according to the preset threshold range, the preset step length and the average charging error of each known vehicle battery in the training set, the fault state of each known vehicle battery, the number of known normal vehicle batteries and the number of known abnormal vehicle batteries, the local optimal threshold corresponding to the training set is determined; According to the local optimal threshold corresponding to each training set, the preset fault threshold is determined.

9. An electronic device, comprising: The electronic device comprises: A processor and a memory; The processor is configured to execute the steps of the vehicle battery fault diagnosis method according to any one of claims 1 to 8 by invoking the program or instructions stored in the memory.

10. A computer-readable storage medium, characterized in that, The computer readable storage medium stores programs or instructions, which make the computer execute the steps of the vehicle battery fault diagnosis method according to any one of claims 1 to 8.