A method, apparatus, device and medium for predicting remaining service life of a battery

CN121477015BActive Publication Date: 2026-09-08ZHEJIANG LEAPENERGY TECH CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202512034418.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-12-30
Publication Date
2026-09-08
Estimated Expiration
2045-12-30

AI Technical Summary

Technical Problem

[0004]本申请实施例提供一种电池剩余使用寿命的预测方法、装置、设备及介质,旨在解决在出现电池健康状态数据稀疏或缺失的情况下,难以准确预测电池剩余使用寿命的问题

Benefits of technology

[0017] This application determines the vehicle type by ensuring the integrity of battery data. Different prediction strategies are adopted for different types of vehicles. This allows data-rich vehicles to directly predict the remaining battery life based on battery data, while data-sparse vehicles can filter the nearest neighbor reference set in the knowledge base based on operating data, thus making up for the lack of data and improving the accuracy of battery life prediction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121477015B_ABST
    Figure CN121477015B_ABST
Patent Text Reader

Abstract

The application discloses a battery remaining service life prediction method, device, equipment and medium, and belongs to the technical field of battery capacity. The prediction method comprises the following steps: obtaining battery data and running data of a vehicle, determining the category of the vehicle according to the data integrity of the battery data, and the category of the vehicle comprises a data-rich type and a data-sparse type; in the case that the category of the vehicle is the data-rich type, a relationship between battery health state prediction data and time is predicted based on the battery data, in the case that the battery health state prediction data is lower than a preset failure threshold, the remaining service life of the battery is obtained; in the case that the category of the vehicle is the data-sparse type, a feature vector is extracted according to the running data, a near neighbor reference set of the feature vector is screened out in a preset knowledge base, and the remaining service life of the battery is obtained according to the near neighbor reference set. Different prediction strategies are used for different types of vehicles, and the accuracy of the prediction of the remaining service life of the battery is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of battery capacity calculation technology, specifically to a method, apparatus, device, and medium for predicting the remaining lifespan of a battery. Background Technology

[0002] Vehicle batteries undergo irreversible aging during cyclic use, primarily manifested as capacity decay and increased internal resistance. Remaining Useful Life (RUL) prediction is used to estimate the number of cycles or driving mileage a battery can still operate on before reaching its failure threshold, thus preventing safety accidents caused by sudden battery failure.

[0003] In related technologies, battery remaining life prediction adopts a data-driven approach, directly learning aging patterns from historical battery operating data. These methods typically require a large amount of complete historical health data to train a reliable prediction model. Therefore, it is necessary to ensure the richness of battery state of health (SoH) data. However, in real-world scenarios, the conditions for accurately calculating battery health are stringent, leading to problems such as sparse or missing battery health data, making it difficult to accurately predict the remaining battery life. Summary of the Invention

[0004] This application provides a method, apparatus, device, and medium for predicting the remaining lifespan of a battery, aiming to solve the problem that it is difficult to accurately predict the remaining lifespan of a battery when battery health status data is sparse or missing.

[0005] In a first aspect, embodiments of this application provide a method for predicting the remaining lifespan of a battery, the method comprising the following steps: Acquire vehicle battery data and operational data, and determine vehicle category based on the data integrity of the battery data. Vehicle categories include data-rich and data-sparse types. When the vehicle category is data-rich, the relationship between battery health status prediction data and time is obtained based on battery data prediction. When the battery health status prediction data is lower than the preset failure threshold, the remaining battery life is obtained. When the vehicle category is data sparse, feature vectors are extracted based on the operating data, and the nearest neighbor reference set of the feature vectors is selected from the preset knowledge base. The remaining battery life is then obtained based on the nearest neighbor reference set.

[0006] In some embodiments, battery data includes battery health status data; The steps for determining the vehicle category based on the integrity of the battery data include: If the quantity and time span of battery health status data can independently fit the degradation curve, the vehicle is classified as a data-rich type. When the amount or time span of battery health status data cannot independently fit the degradation curve, the vehicle is classified as a data-sparse type.

[0007] In some embodiments, the step of obtaining the relationship between battery health status prediction data and time based on battery data prediction, and determining the remaining battery life when the battery health status prediction data is less than a preset failure threshold, includes: An input window is constructed based on battery data, which includes multiple battery health status data points prior to the current time point. Input the pre-trained autoregressive model into the input window to predict the battery health status at the next time point; If the battery health status prediction data is greater than or equal to the failure threshold, the battery health status prediction data is merged into the input window, and the battery health status prediction data for the next time point is recalculated iteratively. If the predicted battery health status is less than the failure threshold, the remaining battery life is obtained from the time span from the time point corresponding to the predicted battery health status data that is less than the failure threshold to the current time point.

[0008] In some embodiments, the prediction method further includes: Obtain the first training dataset, which includes battery data of multiple vehicle categories with complete historical lifecycle data; An autoregressive model was trained based on the first training dataset.

[0009] In some embodiments, the prediction method further includes: A knowledge base is constructed, which stores the correspondence between standard feature vectors and standard battery remaining lifespan. The standard feature vectors and standard battery remaining lifespan are obtained from data-rich operating data with complete historical lifecycle data, based on the vehicle category.

[0010] In some embodiments, the steps of extracting feature vectors based on operational data, filtering a nearest neighbor reference set of the feature vectors from a preset knowledge base, and obtaining the remaining battery life based on the nearest neighbor reference set include: Based on the operational data, operational features are extracted and converted into feature vectors, wherein the operational features include at least one of behavioral habit features, environmental features, and battery attribute features; Based on the encoder model, the feature vector is mapped to the latent space to obtain the low-dimensional vector corresponding to the feature vector in the latent space. Calculate the similarity between the low-dimensional vector and the standard feature vector in the knowledge base in the latent space, and select several standard feature vectors based on the similarity to obtain the nearest neighbor reference set; The remaining battery life is obtained by considering the standard remaining battery life corresponding to several standard feature vectors in the nearest neighbor reference set.

[0011] In some embodiments, the steps of calculating the similarity between a low-dimensional vector in the latent space and a standard feature vector in the knowledge base, and then selecting several standard feature vectors based on the similarity to obtain a nearest neighbor reference set include: Calculate the Mahalanobis distance between the low-dimensional vector and the standard feature vector in the latent space, and use the Mahalanobis distance as the similarity. The standard feature vectors are sorted according to similarity, and the highest number of similar standard feature vectors are selected to obtain the nearest neighbor reference set.

[0012] In some embodiments, the step of obtaining the remaining battery life based on the standard remaining battery life corresponding to several standard feature vectors in the nearest neighbor reference set includes: The remaining battery life is obtained by distance-weighted fusion of the standard battery life corresponding to several standard feature vectors in the nearest neighbor reference set.

[0013] In some embodiments, the prediction method further includes: Obtain a second training dataset, which includes multiple standard feature vectors; The standard feature vector is input into the attention encoder. After calculating the weight of the feature vector in each dimension, the standard feature vector is mapped to the latent space to obtain the standard low-dimensional vector corresponding to the standard feature vector in the latent space. The standard low-dimensional vector is input into the decoder and reconstructed into a reconstructed feature vector with the same dimension as the standard feature vector. The error between the standard feature vector and the reconstructed feature vector is calculated using a loss function. The attention encoder is iteratively updated based on the error until the loss function converges, thus obtaining the encoder model.

[0014] Secondly, embodiments of this application also provide a device for predicting the remaining lifespan of a battery, the device comprising: The data acquisition module is used to acquire vehicle battery data and operating data, and to determine the vehicle category based on the data integrity of the battery data. The vehicle category includes data-rich and data-sparse types. The first prediction module is used to predict the relationship between battery health status prediction data and time points based on battery data when the vehicle category is data rich, and to obtain the remaining battery life when the battery health status prediction data is lower than the preset failure threshold. The second prediction module is used to extract feature vectors from operating data when the vehicle category is sparse, filter out the nearest neighbor reference set of the feature vectors in a preset knowledge base, and obtain the remaining battery life based on the nearest neighbor reference set.

[0015] Thirdly, embodiments of this application also provide an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the computer program, when executed by the processor, implements the prediction method as described in the first aspect.

[0016] Fourthly, embodiments of this application also provide a computer-readable storage medium having a computer program stored thereon, the computer program being loaded by a processor to perform the steps as described in the first aspect.

[0017] This application determines the vehicle type by ensuring the integrity of battery data. Different prediction strategies are adopted for different types of vehicles. This allows data-rich vehicles to directly predict the remaining battery life based on battery data, while data-sparse vehicles can filter the nearest neighbor reference set in the knowledge base based on operating data, thus making up for the lack of data and improving the accuracy of battery life prediction. Attached Figure Description

[0018] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0019] Figure 1 This is a flowchart illustrating a method for predicting the remaining lifespan of a battery according to an exemplary embodiment of this disclosure. Figure 2 This is another flowchart illustrating a method for predicting the remaining lifespan of a battery provided by an exemplary embodiment of this disclosure; Figure 3 This is a flowchart illustrating step S203 of a method for predicting the remaining lifespan of a battery provided in an exemplary embodiment of this disclosure. Figure 4 This is a flowchart illustrating step S205 of a method for predicting the remaining lifespan of a battery provided in an exemplary embodiment of this disclosure. Figure 5 This is a flowchart illustrating the training of an autoregressive model for a method of predicting the remaining lifespan of a battery provided by an exemplary embodiment of this disclosure. Figure 6This is a flowchart illustrating the construction of a knowledge base for a method for predicting the remaining lifespan of a battery, provided by an exemplary embodiment of this disclosure. Figure 7 This is a flowchart illustrating the training encoder model for a method for predicting the remaining battery life provided in an exemplary embodiment of this disclosure. Figure 8 This is a schematic diagram of the structure of a battery remaining life prediction device provided by an exemplary embodiment of this disclosure; Figure 9 This is a schematic diagram of the structure of an electronic device provided by an exemplary embodiment of this disclosure.

[0020] Explanation of icon numbers: 101. Data acquisition module; 102. First prediction module; 103. Second prediction module; 200. Electronic device; 201. Memory; 202. Processor; 203. Communication component; 204. Bus. Detailed Implementation

[0021] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0022] In the description of this application, it should be understood that the terms "center," "longitudinal," "lateral," "length," "width," "thickness," "upper," "lower," "front," "rear," "left," "right," "vertical," "horizontal," "top," "bottom," "inner," and "outer," etc., indicating orientation or positional relationships based on the orientation or positional relationships shown in the accompanying drawings, are used 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. Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include one or more of the stated features. In the description of this application, "a plurality of" means two or more, unless otherwise explicitly specified.

[0023] "A and / or B" includes the following three combinations: A only, B only, and a combination of A and B.

[0024] The use of "applies to" or "configured to" in this application implies open and inclusive language, which does not exclude the applicability to or configuration to devices performing additional tasks or steps. Additionally, the use of "based on" implies openness and inclusivity, because processes, steps, calculations, or other actions "based on" one or more of the stated conditions or values ​​may in practice be based on additional conditions or values ​​beyond those stated.

[0025] In this application, the term "exemplary" is used to mean "used as an example, illustration, or description." Any embodiment described as "exemplary" in this application is not necessarily to be construed as being more preferred or advantageous than other embodiments. The following description is provided to enable any person skilled in the art to make and use this application. Details are set forth in the following description for purposes of explanation. It should be understood that those skilled in the art will recognize that this application can be made without using these specific details. In other instances, well-known structures and processes are not described in detail to avoid obscuring the description of this application with unnecessary detail. Therefore, this application is not intended to be limited to the embodiments shown, but is consistent with the broadest scope of the principles and features disclosed in this application.

[0026] Firstly, embodiments of this application provide a method for predicting the remaining lifespan of a battery, such as... Figure 1 As shown, the prediction method includes the following steps: S101. Obtain the vehicle's battery data and operating data, and determine the vehicle's category based on the data integrity of the battery data.

[0027] Battery data includes State of Health (SoH) data, which reflects the degree of battery aging and is typically expressed as a percentage of the current battery capacity to the factory-rated battery capacity. Battery data may also include battery voltage, internal resistance, and other battery-related data to predict the remaining battery life.

[0028] Operational data includes data on vehicle driving and battery operation, such as charging mode, driving speed, ambient temperature, and depth of charge / discharge.

[0029] The completeness of battery data is determined based on the quantity and time span of battery health status data to classify the current vehicle. Vehicles are categorized as either data-rich or data-sparse. If the quantity and time span of battery health status data are sufficient, the vehicle is classified as data-rich; if they are insufficient, the vehicle is classified as data-sparse.

[0030] By classifying vehicles, a foundation is laid for subsequent differentiated prediction strategies. This avoids using the same prediction model for vehicles with abundant data and those with sparse data, which can lead to an imbalance in accuracy, affecting detection accuracy and improving overall detection efficiency.

[0031] S102. When the vehicle category is data-rich, the relationship between battery health status prediction data and time is obtained based on battery data prediction. When the battery health status prediction data is lower than the preset failure threshold, the remaining battery life is obtained.

[0032] The relationship between battery health status prediction data and time is the predicted change in battery health status over a future period. The failure threshold is the critical value of battery health status at which battery failure occurs; below this threshold, the battery is considered to have failed. Remaining battery life is the time span from the current time point to the point when the battery health status first falls below the failure threshold.

[0033] Data-rich vehicles have relatively complete battery data, which can be used to directly predict future battery health status through autoregressive models, resulting in high detection accuracy.

[0034] S103. When the vehicle category is data sparse, extract feature vectors based on the operating data, select the nearest neighbor reference set of the feature vectors in the preset knowledge base, and obtain the remaining battery life based on the nearest neighbor reference set.

[0035] Feature vectors are multi-dimensional data combinations extracted from operational data to reflect factors affecting battery aging. The knowledge base stores the correspondence between standard feature vectors and standard remaining battery life. By comparing the vehicle's feature vectors with the standard feature vectors in the knowledge base, the closest standard feature vectors are selected as the nearest neighbor reference set to determine the vehicle's remaining battery life.

[0036] By extracting feature vectors from operational data, and matching these feature vectors with standard feature vectors already stored in the knowledge base when the vehicle does not have complete battery health status data, the vehicle's remaining battery life can be predicted based on the operating conditions closest to the current vehicle and the standard remaining battery life corresponding to the standard feature vector.

[0037] This application determines the vehicle type by ensuring the integrity of battery data. Different prediction strategies are adopted for different types of vehicles. This allows data-rich vehicles to directly predict the remaining battery life based on battery data, while data-sparse vehicles can filter the nearest neighbor reference set in the knowledge base based on operating data, thus making up for the lack of data and improving the accuracy of battery life prediction.

[0038] This application also provides another method for predicting the remaining battery life, such as... Figure 2 As shown, the prediction method includes the following steps: S201. Obtain vehicle battery data and operating data.

[0039] Battery data includes battery health status data, which reflects the degree of battery aging, and is generally expressed as a percentage of the current battery capacity to the factory rated battery capacity. Battery data may also include battery voltage, internal resistance, and other battery-related data to predict the remaining battery life.

[0040] Operational data includes data on vehicle driving and battery operation, such as charging mode, driving speed, ambient temperature, and depth of charge / discharge.

[0041] S202. Determine the vehicle category based on the data integrity of the battery data.

[0042] Vehicles are categorized into data-rich and data-sparse types.

[0043] If the quantity and time span of battery health status data can independently fit the degradation curve, the vehicle is classified as a data-rich type.

[0044] When the amount or time span of battery health status data cannot independently fit the degradation curve, the vehicle is classified as a data-sparse type.

[0045] The degradation curve is a trend curve of the battery health state changing over time. It is used to reflect the law of irreversible degradation of battery capacity and is the basis for calculating the remaining battery life. Only when the degradation curve can be fitted can the failure time of the battery health state be predicted and the remaining battery life be calculated.

[0046] Based on the data integrity of the battery data, vehicles are divided into two categories: data-rich and data-sparse. Different prediction strategies are adopted for different categories, which provides a basis for predicting the remaining battery life in subsequent steps.

[0047] S203. When the vehicle category is data-rich, the relationship between battery health status prediction data and time is obtained based on battery data prediction; when the battery health status prediction data is lower than the preset failure threshold, the remaining battery life is obtained.

[0048] like Figure 3 As shown, step S203 includes S2031-S2034.

[0049] S2031. Construct an input window based on battery data.

[0050] The input window is a fixed-length sequence containing multiple battery health status data points prior to the current time point. The number of battery health status data points in the input window remains constant; when new data is added to the input window, the oldest data point is deleted to ensure a fixed number of battery health status data points in the input window.

[0051] After preprocessing, the battery health status data is sequentially placed into the input window in chronological order until the last data point represents the battery health status at the current time. The number of battery health status data points in the input window can be selected from 5 to 20, depending on the battery characteristics and data density. For example, if the battery has a short charge / discharge cycle and dense data records, 5 to 8 data points can be selected; if the cycle is long and the data is sparse, 15 to 20 data points can be selected.

[0052] By selecting only core time series data near the current moment through the input window, and removing data from the early stages without decay or irrelevant fluctuations, computational efficiency is improved and interference with prediction results is reduced.

[0053] S2032. Input the pre-trained autoregressive model into the input window to predict the battery health status at the next time point.

[0054] The autoregressive model is a predictive model that is pre-trained using complete battery data from data-rich vehicles. It can predict the battery health status data at the next time point using multiple battery health status data.

[0055] Each iteration only predicts the battery health status at the next time point, reducing prediction errors and improving the overall reliability of the prediction.

[0056] S2033. If the battery health status prediction data is greater than or equal to the failure threshold, merge the battery health status prediction data into the input window and re-iterate to calculate the battery health status prediction data for the next time point.

[0057] The failure threshold is the critical value for the battery's health status at which it fails; a battery is considered to have failed if it falls below this threshold. The failure threshold can be 70%-80% of the factory-rated battery capacity and can be adjusted according to battery type, vehicle model, or application scenario.

[0058] If the predicted battery health status data is greater than or equal to the failure threshold, the latest predicted battery health status data is merged into the input window, and the earliest battery health status data in the input window is deleted. The new input window is then used as input to re-execute step S2032 to continue predicting the predicted battery health status data for the next time point.

[0059] S2034. If the predicted battery health status data is less than the failure threshold, the remaining battery life is obtained based on the time span from the time point corresponding to the predicted battery health status data that is less than the failure threshold to the current time point.

[0060] The battery fails at the time point when the predicted battery health status data first falls below the failure threshold. The remaining battery life can be obtained from the time span between the predicted battery health status data point below the failure threshold and the current time point. The specific representation of the remaining battery life can be selected according to the actual application scenario, such as the remaining number of cycles, the remaining calendar days, or the remaining driving range.

[0061] In one embodiment, the battery health status data for a vehicle categorized as data-rich is: Where t is the current time, and the input window of size L is constructed based on the battery health status data. , to input window As the initial input, the battery health status prediction data for the first future time point is obtained through an autoregressive model. .

[0062] Battery health status prediction data If the failure threshold is exceeded, Merge into input window And input window The earliest data Delete, and you will get the input window. Re-enter the input window into the autoregressive model to obtain the battery health status prediction data for the second future time point. .

[0063] Battery health status prediction data If the value exceeds the failure threshold, the iteration continues, generating a sequence of battery health status prediction data sequentially until the first occurrence of battery health status prediction data in the sequence. Less than or equal to the failure threshold Then, from the current time t, until the first occurrence in the predicted sequence... The remaining battery lifespan is the time span k up to the future moment t+k.

[0064] S204. When the vehicle category is data sparse, extract feature vectors based on the operation data.

[0065] Operational features are extracted from operational data and converted into feature vectors. The operational features are key information extracted from the operational data to reflect factors affecting battery aging, including at least one of behavioral habit features, environmental features, and battery attribute features.

[0066] Behavioral habit features are used to characterize user behavior habits. They are quantified using percentages to eliminate biases caused by absolute values ​​and to more universally represent user usage patterns. Specific features include, but are not limited to: charging behavior distribution, such as the percentage of fast charging and full charging times out of total charging times; driving intensity distribution, such as the percentage of mileage driven in different average speed ranges out of total mileage; and charge / discharge depth distribution, such as the percentage of time spent operating in different SoC ranges.

[0067] Environmental characteristics are used to describe the external stress conditions under which the battery operates. These include, but are not limited to, the average temperature, temperature fluctuation variance, and the percentage of time the battery pack operates within different temperature ranges based on historical operating data.

[0068] Battery property characteristics are used to characterize the inherent properties of a battery. These include, but are not limited to, the battery's chemical type and rated capacity.

[0069] S205. Select the nearest neighbor reference set of the feature vector from the preset knowledge base, and obtain the remaining battery life based on the nearest neighbor reference set.

[0070] like Figure 4 As shown, step S205 includes S2051-S2053.

[0071] S2051. Based on the encoder model, the feature vector is mapped to the latent space to obtain the low-dimensional vector corresponding to the feature vector in the latent space.

[0072] The encoder model is used to map high-dimensional feature vectors to low-dimensional latent space. The encoder model is pre-trained using feature vectors extracted from battery data of data-rich vehicles with complete historical life cycle data, and has the ability to learn battery aging feature patterns.

[0073] The feature vector is input into the encoder model, which uses a perceptron attention mechanism to evaluate the global importance of each dimension of the high-dimensional feature. The weight of each feature dimension is calculated through a fully connected layer and a softmax function. The weights of features strongly correlated with aging, such as charging behavior distribution and average temperature, are automatically enhanced, while the influence of irrelevant features is weakened, resulting in a weighted feature representation. Then, through linear or nonlinear transformation, the weighted high-dimensional features are compressed and mapped to a low-dimensional latent space, outputting a low-dimensional vector.

[0074] The process of mapping the encoder model to the low-dimensional latent space follows the feature mapping rules of data-rich vehicles and ensures that the low-dimensional vector and the low-dimensional vector in the knowledge base are in the same feature space, which facilitates the subsequent similarity calculation.

[0075] S2052. Calculate the similarity between the low-dimensional vector and the standard feature vector in the knowledge base in the latent space, and select several standard feature vectors based on the similarity to obtain the nearest neighbor reference set.

[0076] In the latent space, the Mahalanobis distance between the low-dimensional vector and the standard feature vector is calculated, and the Mahalanobis distance is used as the similarity. The standard feature vectors are sorted according to the similarity, and the highest number of standard feature vectors with the highest similarity are selected to obtain the nearest neighbor reference set.

[0077] The knowledge base stores the correspondence between standard feature vectors and standard remaining battery life. For vehicles with abundant standard feature vector data, the feature vectors are mapped using the same encoder model to obtain low-dimensional vectors, which serve as the benchmark for similarity matching. Each standard feature vector corresponds to a standard remaining battery life.

[0078] The nearest neighbor reference set is a collection of standard feature vectors selected from the knowledge base that are most similar to the aging pattern of the target vehicle.

[0079] The formula for calculating the Mahalanobis distance between a low-dimensional vector and a standard eigenvector is: ; in It is a low-dimensional vector. A standard feature vector in the nearest neighbor reference set. Let be the covariance matrix of the latent space representation of all vehicles in the knowledge base.

[0080] Traditional cosine similarity only considers vector direction, Euclidean distance ignores the correlation of dimensions, while Mahalanobis distance is corrected by the covariance matrix, which not only eliminates the difference in dimensions but also considers the intrinsic correlation between feature dimensions, making the similarity assessment more in line with the distribution pattern of battery aging.

[0081] S2053. Obtain the remaining battery life based on the standard battery life corresponding to several standard feature vectors in the nearest neighbor reference set.

[0082] The remaining battery life is obtained by distance-weighted fusion of the standard battery life corresponding to several standard feature vectors in the nearest neighbor reference set.

[0083] The formula for weighted fusion of remaining lifespan of standard batteries is shown below: ; Among them, weight This indicates that vehicles with higher similarity have greater weight. The remaining lifespan of a standard battery in the nearest neighbor reference set.

[0084] By assigning greater weight to vehicles with higher similarity, the reference vehicle that best matches the aging pattern of the target vehicle plays a dominant role, making the prediction results closer to the actual aging trajectory of the target vehicle and avoiding the accuracy dilution caused by simple averaging. Distance-weighted fusion can effectively suppress the impact of single sample errors in the nearest neighbor reference set on the results, improving the detection accuracy.

[0085] In some embodiments, the prediction method further includes the step of training an autoregressive model, such as Figure 5 As shown, it includes the following steps: S301. Obtain the first training dataset.

[0086] The first training dataset is used to train the autoregressive model. It includes rich battery data with complete historical lifecycle data for multiple vehicle categories, enabling the autoregressive model to learn battery aging patterns. The complete historical lifecycle data is time-series data from the moment the vehicle is put into use until the battery's health status falls below the failure threshold, reflecting the battery's aging trajectory from health to failure.

[0087] The battery data in the first training set is data-rich battery data extracted from the power battery big data cloud platform, ensuring that the data covers different user habits, environmental adjustments and battery types, thereby improving the model's generalization ability.

[0088] The first training set preprocesses the extracted battery data by filling in missing values, removing outliers, and standardizing the data to facilitate subsequent model training.

[0089] S302. An autoregressive model is trained based on the first training dataset.

[0090] Autoregressive models are models focused on time-series data prediction. They use time-series data from multiple past time points to predict data for the next time point, accurately capturing the dependencies between battery health status data.

[0091] The architecture of an autoregressive model can be a gated recurrent unit (GRU), a long short-term memory (LSTM), or a transformer.

[0092] Autoregressive models can effectively learn the dependencies between battery health status data, allowing the model's predictions to closely match the actual aging trend of the battery, thereby improving the accuracy of predicting the remaining battery life of data-rich vehicles.

[0093] In some embodiments, the prediction method further includes the step of constructing a knowledge base, such as Figure 6 As shown, it includes the following steps: S401. Obtain battery data and operational data for vehicles with a data-rich category and complete historical lifecycle data.

[0094] Battery data and operational data are synchronized from the power battery big data cloud platform with full data of data-rich vehicles. The battery data and operational data of the vehicles with complete historical life cycle data are selected to ensure that the battery data and operational data are correlated.

[0095] S402. Extract standard feature vectors based on the running data.

[0096] Operational features are extracted from the operational data, and the operational features are preprocessed to fill missing values. The data of each dimension column is normalized to a standard normal distribution, and the operational features are converted into standard feature vectors. The operational features are key information extracted from the operational data to reflect the factors affecting battery aging, including at least one of behavioral habit features, environmental features, and battery attribute features.

[0097] Behavioral habit features are used to characterize user behavior habits. They are quantified using percentages to eliminate biases caused by absolute values ​​and to more universally represent user usage patterns. Specific features include, but are not limited to: charging behavior distribution, such as the percentage of fast charging and full charging times out of total charging times; driving intensity distribution, such as the percentage of mileage driven in different average speed ranges out of total mileage; and charge / discharge depth distribution, such as the percentage of time spent operating in different SoC ranges.

[0098] Environmental characteristics are used to describe the external stress conditions under which the battery operates. These include, but are not limited to, the average temperature, temperature fluctuation variance, and the percentage of time the battery pack operates within different temperature ranges based on historical operating data.

[0099] Battery property characteristics are used to characterize the inherent properties of a battery. These include, but are not limited to, the battery's chemical type and rated capacity.

[0100] S403. Construct a knowledge base based on the standard feature vector and the standard battery remaining life corresponding to the standard feature vector.

[0101] Each standard feature vector is associated with the standard remaining battery life corresponding to the standard feature vector to construct a structured knowledge base. The knowledge base can be stored and managed in the form of a database or matrix, where each row represents a data-rich vehicle and each column corresponds to the standard feature vector and the standard remaining battery life, respectively.

[0102] In some embodiments, the prediction method further includes the step of training an encoder model, such as... Figure 7 As shown, it includes the following steps: S501. Obtain the second training dataset.

[0103] The second training dataset is used to train the encoder model and includes multiple standard feature vectors extracted from the knowledge base. Let there be N data-rich vehicles in the second training dataset, and each vehicle's feature vector be d-dimensional. Then the training set can be represented as a matrix. ,in Let represent the feature vector of the i-th vehicle.

[0104] S502. Input the standard feature vector into the attention encoder, calculate the weight of the feature vector in each dimension, and then map the standard feature vector to the latent space to obtain the standard low-dimensional vector corresponding to the standard feature vector in the latent space.

[0105] standard feature vectors Input to attention encoder The attention encoder first adaptively calculates the weights of each feature dimension through an attention mechanism to enhance features critically related to battery aging, thus obtaining a weighted feature representation. Subsequently, the encoder maps the weighted features to a low-dimensional latent space to obtain a standard low-dimensional vector. .

[0106] The choice of attention mechanism is based on considerations of model efficiency and task adaptability. This embodiment uses perceptron attention instead of scaled dot product attention, primarily because the input features are static multi-dimensional vectors rather than long sequence data. Perceptron attention works by connecting fully connected layers to… Directly evaluating the global importance of features allows for more direct feature selection, avoiding the query-key projection required for scaling dot product attention, thus making it more suitable for feature-level optimization in this scenario.

[0107] S503. Input the standard low-dimensional vector into the decoder and reconstruct it into a reconstructed feature vector with the same dimension as the standard feature vector.

[0108] Standard low-dimensional vector The input is to the decoder, which then reconstructs a feature vector with the same dimensions as the original feature vector through a reverse decoding operation. .

[0109] S504. Calculate the error between the standard feature vector and the reconstructed feature vector using the loss function.

[0110] The goal of this exercise is to minimize the reconstruction loss. The loss function is defined as the mean squared error between the original features and the reconstructed features, as shown below: ; Where N is the number of training samples, that is, the total number of data-rich vehicles. For standard feature vectors, To reconstruct the feature vector.

[0111] S505. Iteratively update the attention encoder based on the error until the loss function converges to obtain the encoder model.

[0112] The parameters of the attention encoder are updated and optimized, and multiple rounds of iterative calculations are performed. When the global loss value remains stable within the preset threshold range for multiple rounds during training, and there is no obvious decreasing or increasing trend, it indicates that the model has learned stable feature mapping rules and there is no need to continue training, thus obtaining the encoder model.

[0113] Secondly, embodiments of this application also provide a device for predicting the remaining lifespan of a battery, such as... Figure 8 As shown, the prediction device includes a data acquisition module 101, a first prediction module 102, and a second prediction module 103.

[0114] The data acquisition module 101 acquires vehicle battery data and operational data. Based on the completeness of the battery data, it determines the vehicle category, which includes data-rich and data-sparse vehicles. This vehicle category classification lays the foundation for subsequent differentiated prediction strategies, avoiding the use of the same prediction model for both data-rich and data-sparse vehicles, which could lead to an imbalance in accuracy and affect detection accuracy, thus improving overall detection efficiency.

[0115] The first prediction module 102 is used to predict the relationship between battery health status prediction data and time points based on battery data when the vehicle category is data-rich. If the battery health status prediction data is lower than a preset failure threshold, the remaining battery lifespan is obtained. Data-rich vehicles have relatively complete battery data, and future battery health status can be directly predicted through an autoregressive model, resulting in high detection accuracy.

[0116] The second prediction module 103 is used to extract feature vectors from operating data when the vehicle category is data sparse, filter the nearest neighbor reference set of the feature vectors in a preset knowledge base, and obtain the remaining battery life based on the nearest neighbor reference set. By extracting feature vectors from operating data, in the absence of complete battery health status data for the vehicle, the feature vectors are matched with standard feature vectors already stored in the knowledge base to find the operating condition closest to the current vehicle, thereby predicting the vehicle's remaining battery life based on the standard remaining battery life corresponding to the standard feature vector.

[0117] This application determines the vehicle type by ensuring the integrity of battery data. Different prediction strategies are adopted for different types of vehicles. This allows data-rich vehicles to directly predict the remaining battery life based on battery data, while data-sparse vehicles can filter the nearest neighbor reference set in the knowledge base based on operating data, thus making up for the lack of data and improving the accuracy of battery life prediction.

[0118] Thirdly, such as Figure 9 As shown, an electronic device 200 is provided, including: a memory 201 and a processor 202; The memory 201 stores computer-executed instructions; The processor 202 executes the computer execution instructions stored in the memory 201, causing the processor 202 to perform the above-described method.

[0119] In one embodiment, the electronic device 200 includes at least one processor 202 and a memory 201. Optionally, the electronic device 200 further includes a communication component 203. The processor 202, memory 201, and communication component 203 are connected via a bus 204.

[0120] In a specific implementation, at least one processor 202 executes computer execution instructions stored in memory 201, causing at least one processor 202 to perform the above-described method.

[0121] The specific implementation process of processor 202 can be found in the above method embodiments, and its implementation principle and technical effect are similar. It will not be repeated here.

[0122] In the above embodiments, it should be understood that the processor 202 can be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in this invention can be directly manifested as execution by the hardware processor 202, or execution by a combination of hardware and software modules in the processor 202.

[0123] Memory 201 may include random access memory (RAM) and may also include non-volatile memory. Volatile memory (NVM), such as at least one disk storage 201.

[0124] Bus 204 can be an industry standard architecture (ISA) bus, a peripheral component (PCI) bus, or an extended industry standard architecture (EISA) bus, etc. Bus 204 can be divided into address bus, data bus, control bus, etc. For ease of illustration, the bus 204 in the accompanying drawings of this application is not limited to only one bus or one type of bus.

[0125] Fourthly, this application also provides a computer-readable storage medium storing a computer program thereon, which is loaded by a processor to execute the autonomous driving target detection method as described in the above embodiments, which will not be repeated here.

[0126] The aforementioned computer-readable storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The readable storage medium can be any available medium accessible to a general-purpose or special-purpose computer.

[0127] An exemplary computer-readable storage medium is coupled to a processor, enabling the processor to read information from and write information to the storage medium. Alternatively, the storage medium can be an integral part of the processor. Both the processor and the storage medium can reside in application-specific integrated circuits (ASICs). Alternatively, the processor and the storage medium can exist as discrete components within the device.

[0128] The division of units is merely a logical functional division; 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 indirect coupling or communication connection through some interfaces, devices, or units, and may be electrical, mechanical, or other forms.

[0129] 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.

[0130] In addition, the functional units in the various embodiments of the present invention 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.

[0131] If the functionality 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 invention, essentially, or the part that contributes to the prior art, or a 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 several instructions to cause an electronic device 200 (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 invention. The aforementioned storage medium includes: a USB flash drive, a portable hard drive, and a read-only memory (ROM). Various media that can store program code, such as only memory, random access memory (RAM), magnetic disks, or optical disks.

[0132] Those skilled in the art will understand that all or part of the steps of the above-described method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When executed, the program performs the steps of the above-described method embodiments; and the aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks.

[0133] In the above embodiments, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions in other embodiments.

[0134] The foregoing has provided a detailed description of a method, apparatus, device, and medium for predicting the remaining lifespan of a battery, as provided in the embodiments of this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the embodiments above are only for the purpose of helping to understand the method and core ideas of this application. At the same time, those skilled in the art will recognize that there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.

Claims

1. A method for predicting the remaining lifespan of a battery, characterized in that, The prediction method includes the following steps: Obtain vehicle battery data and operating data, and determine the vehicle category based on the data integrity of the battery data. The vehicle category includes data-rich and data-sparse types. When the vehicle category is the data-rich type, the relationship between battery health status prediction data and time is obtained based on the battery data prediction. When the battery health status prediction data is lower than a preset failure threshold, the remaining battery life is obtained. When the vehicle category is the data sparse type, feature vectors are extracted based on the operating data, and a nearest neighbor reference set of the feature vectors is selected in a preset knowledge base. The remaining battery life is then obtained based on the nearest neighbor reference set.

2. The prediction method according to claim 1, characterized in that, The battery data includes battery health status data; The steps for determining the vehicle category based on the data integrity of the battery data include: If the quantity and time span of the battery health status data can independently fit the degradation curve, the vehicle is classified as the data-rich type. If the quantity or time span of the battery health status data cannot independently fit the degradation curve, the vehicle is classified as a data-sparse type.

3. The prediction method according to claim 2, characterized in that, Based on the battery data prediction, the relationship between battery health status prediction data and time is obtained. If the battery health status prediction data is less than a preset failure threshold, the step of determining the remaining battery life includes: An input window is constructed based on the battery data, and the input window includes multiple battery health status data points prior to the current time point; Input the pre-trained autoregressive model into the input window to predict the battery health status at the next time point; If the predicted battery health status data is greater than or equal to the failure threshold, the predicted battery health status data is merged into the input window, and the predicted battery health status data for the next time point is recalculated iteratively. If the predicted battery health status data is less than the failure threshold, the remaining battery lifespan is obtained based on the time span from the time point corresponding to the predicted battery health status data that is less than the failure threshold to the current time point.

4. The prediction method according to claim 3, characterized in that, The prediction method further includes: Obtain a first training dataset, which includes battery data of multiple vehicles that are classified as data-rich and have complete historical lifecycle data; The autoregressive model is trained based on the first training dataset.

5. The prediction method according to claim 1, characterized in that, The prediction method further includes: The knowledge base is constructed, wherein the knowledge base stores the correspondence between standard feature vectors and standard battery remaining lifespan, and the standard feature vectors and standard battery remaining lifespan are obtained based on the vehicle category and the running data with complete historical life cycle data.

6. The prediction method according to claim 5, characterized in that, The steps of extracting feature vectors from the operational data, selecting a nearest neighbor reference set from a preset knowledge base, and obtaining the remaining battery life based on the nearest neighbor reference set include: Based on the operational data, operational features are extracted and converted into the feature vector, wherein the operational features include at least one of behavioral habit features, environmental features, and battery attribute features; Based on the encoder model, the feature vector is mapped to the latent space to obtain the low-dimensional vector corresponding to the feature vector in the latent space. The similarity between the low-dimensional vector and the standard feature vector in the knowledge base is calculated in the latent space. Based on the similarity, several standard feature vectors are selected to obtain the nearest neighbor reference set. The remaining battery life is obtained based on the remaining standard battery life corresponding to several standard feature vectors in the nearest neighbor reference set.

7. The prediction method according to claim 6, characterized in that, The steps of calculating the similarity between the low-dimensional vector in the latent space and the standard feature vector in the knowledge base, and then selecting several standard feature vectors based on the similarity to obtain the nearest neighbor reference set include: The Mahalanobis distance between the low-dimensional vector and the standard feature vector is calculated in the latent space, and the Mahalanobis distance is used as the similarity. The standard feature vectors are sorted according to the similarity, and the standard feature vectors with the highest similarity are selected to obtain the nearest neighbor reference set.

8. The prediction method according to claim 6, characterized in that, The steps for obtaining the remaining battery life based on the standard battery life corresponding to several standard feature vectors in the nearest neighbor reference set include: The remaining battery life is obtained by performing distance-weighted fusion on the standard battery remaining life corresponding to several standard feature vectors in the nearest neighbor reference set.

9. The prediction method according to claim 6, characterized in that, The prediction method further includes: Obtain a second training dataset, which includes multiple of the aforementioned standard feature vectors; The standard feature vector is input into the attention encoder. After calculating the weight of the feature vector in each dimension, the standard feature vector is mapped to the latent space to obtain the standard low-dimensional vector corresponding to the standard feature vector in the latent space. The standard low-dimensional vector is input into the decoder and reconstructed into a reconstructed feature vector with the same dimension as the standard feature vector. The error between the standard feature vector and the reconstructed feature vector is calculated using a loss function; The attention encoder is iteratively updated based on the error until the loss function converges, thus obtaining the encoder model.

10. A device for predicting the remaining lifespan of a battery, characterized in that, The prediction device includes: The data acquisition module is used to acquire vehicle battery data and operating data, and determine the vehicle category based on the data integrity of the battery data. The vehicle category includes data-rich and data-sparse types. The first prediction module is used to predict the relationship between battery health status prediction data and time points based on the battery data when the vehicle category is the data-rich type, and to obtain the remaining battery life when the battery health status prediction data is lower than a preset failure threshold. The second prediction module is used to extract feature vectors from the operating data when the vehicle category is the data sparse type, filter out the nearest neighbor reference set of the feature vectors in a preset knowledge base, and obtain the remaining battery life based on the nearest neighbor reference set.

11. An electronic device, characterized in that, It includes a memory and a processor, wherein the memory stores a computer program that, when executed by the processor, implements the prediction method as described in any one of claims 1-9.

12. A computer-readable storage medium, characterized in that, It stores a computer program, which is loaded by a processor to perform the steps in the prediction method as described in any one of claims 1-9.

Citation Information

Patent Citations

  • Lithium battery aging state calculation method and device, electronic equipment and storage medium

    CN117406118A

  • Battery life prediction method and device, vehicle and storage medium

    CN119667529A