Battery charge state detection method, device, equipment, storage medium and product
By constructing a detection model for changing battery operation characteristics over time and iteratively optimizing the battery state of charge detection model, the problem of low accuracy of battery state of charge detection in the prior art under complex operating conditions is solved, and higher detection accuracy is achieved sex.
Patent Information
- Application Number
- CN202411587253.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-07
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2044-11-07
AI Technical Summary
The existing battery state of charge detection methods are difficult to accurately reflect the external characteristics of the battery cell under complex operating conditions, and the number of label samples used in the neural network model is difficult to cover all operating conditions, resulting in low detection accuracy.
By constructing a detection model for the changes in battery operation characteristics over time, using the full amount of battery historical operation data to generate the first sample data without the battery state of charge label, combining the feature encoder to construct the second battery state of charge detection model, and iterate through Optimize the target battery state of charge detection model.
The detection accuracy of battery state of charge detection is improved, and the external characteristics of the battery cell can be accurately reflected under complex operating conditions, and the problem of low detection accuracy in the prior art is overcome.
Smart Images

Figure CN119104932B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of energy storage battery testing, and in particular to a battery state of charge detection method, device, computer equipment, computer-readable storage medium and computer program product. Background Art
[0002] The battery state of charge (SOC), also known as the remaining power, is used to reflect the remaining capacity of the battery. It is numerically defined as the ratio of the remaining capacity to the battery capacity, and is often expressed as a percentage. Accurate detection of the battery state of charge is an important factor in ensuring battery reliability. With the continuous development of science and technology, more and more means of battery state of charge detection are emerging.
[0003] At present, the ampere-hour integration method, equivalent circuit method or neural network model are usually used to detect the battery state of charge. However, due to the complex operating conditions of the battery during use, the ampere-hour integration method and the equivalent circuit method cannot truly reflect the external characteristics of the battery cell under complex conditions, and the number of label samples used by the neural network model is also difficult to cover the data under all operating conditions, which makes it easy for the detected battery state of charge to be inconsistent with the actual state of charge. Therefore, the current battery state of charge detection has low detection accuracy. Summary of the invention
[0004] Based on this, it is necessary to provide a battery state of charge detection method, device, computer equipment, computer readable storage medium and computer program product to improve the detection accuracy of battery state of charge detection in response to the above technical problems.
[0005] In a first aspect, the present application provides a battery state of charge detection method, comprising:
[0006] Using first sample data without a battery state of charge label as a first training data set, a first battery state of charge detection model in which battery operation characteristics change over time is constructed, wherein the first sample data is generated according to the full amount of historical battery operation data, the full amount of historical battery operation data refers to all operation data of the battery in a charging stage, a discharging stage, and a static stage during the historical operation process, and the first battery state of charge detection model includes a feature encoder;
[0007] constructing a second battery state of charge detection model according to the feature encoder;
[0008] constructing second sample data carrying the battery state of charge tag according to the battery history operation sampling data extracted from the battery history operation full data, and extracting features from the second sample data by the feature encoder to obtain sample feature data;
[0009] Taking the sample feature data as a second training data set, iteratively optimizing the feature predictor of the second battery state of charge detection model, and taking the iteratively optimized second battery state of charge detection model as a target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize the relationship between the battery state of charge and the battery operation characteristics;
[0010] The battery state of charge is detected on the battery to be detected according to the target battery state of charge detection model.
[0011] In one embodiment, the first sample data without a battery state of charge label is used as a first training data set to construct a first battery state of charge detection model in which battery operation characteristics change over time, including:
[0012] Splitting the first training data set into first training data of a first time step and second training data of a second time step, wherein the first time step is smaller than the second time step;
[0013] Performing feature reconstruction on the first training data to obtain training reconstructed data;
[0014] The first battery state of charge detection model is constructed using a target training data set composed of the second training data and the training reconstruction data.
[0015] In one embodiment, constructing the second sample data carrying the battery state of charge tag according to the battery historical operation sampling data extracted from the battery historical operation full data includes:
[0016] Extracting the battery historical operation sampling data from the battery historical operation full data according to a plurality of battery operating conditions to which the battery historical operation full data belongs;
[0017] Determining the historical battery state of charge corresponding to the battery historical operation sampling data according to a preset ampere-hour integral ratio;
[0018] The battery historical operation sampling data and the historical battery state of charge are concatenated into the second sample data.
[0019] In one embodiment, extracting the battery historical operation sampling data from the battery historical operation full data according to the multiple battery operating conditions to which the battery historical operation full data belongs includes:
[0020] Extracting the battery historical operating condition data under each of the battery operating conditions from the battery historical operating full data;
[0021] According to the working condition sample weights corresponding to the respective battery working conditions, sampling the historical working condition data of the respective batteries to obtain a plurality of battery working condition sampling data;
[0022] The sampling data of each battery operation condition are integrated into the battery historical operation sampling data.
[0023] In one embodiment, the feature encoder includes a plurality of local feature encoders, each of which is trained by local sample data according to the placement position of the battery cell in the battery module; the feature encoder extracts features from the second sample data to obtain sample feature data, including:
[0024] Performing multi-scale feature extraction on the second sample data according to the placement positions of the battery cells in the battery module by each of the local feature encoders to obtain a plurality of sample spatial scale features, wherein the second sample data includes operating characteristics of different battery cells, and one spatial scale corresponds to one battery cell;
[0025] The spatial scale features of each sample are weighted and fused to obtain the sample feature data.
[0026] In one embodiment, before using the first sample data without the battery state of charge label as the first training data set to construct a first battery state of charge detection model in which the battery operation characteristics change over time, the method further includes:
[0027] Extracting the historical operating current, historical operating voltage and historical operating temperature of each battery cell from the full amount of historical operating data of the battery;
[0028] Generating a historical sample operating temperature of each of the battery cells according to each of the historical operating temperatures;
[0029] For any of the battery cells, the historical operating current of the battery cell, the historical operating voltage of the battery cell and the historical sample operating temperature are concatenated together into single-cell sample data of the battery cell;
[0030] The individual sample data are integrated into the first sample data.
[0031] In a second aspect, the present application also provides a battery charge state detection device, comprising:
[0032] A first building module, configured to build a first battery state of charge detection model in which the battery operation characteristics change over time by using first sample data without a battery state of charge label as a first training data set, wherein the first sample data is generated according to the full amount of historical operation data of the battery, the full amount of historical operation data of the battery refers to all operation data of the battery in a charging stage, a discharging stage and a static stage during the historical operation process, and the first battery state of charge detection model includes a feature encoder;
[0033] A second building module, used to build a second battery state of charge detection model according to the feature encoder;
[0034] an extraction module, configured to construct second sample data carrying the battery state of charge tag according to the battery history operation sampling data extracted from the battery history operation full data, and extract features from the second sample data through the feature encoder to obtain sample feature data;
[0035] an optimization module, configured to iteratively optimize a feature predictor of the second battery state of charge detection model using the sample feature data as a second training data set, and use the iteratively optimized second battery state of charge detection model as a target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize a relationship between a battery state of charge and a battery operation characteristic;
[0036] The detection module is used to perform battery charge state detection on the battery to be detected according to the target battery charge state detection model.
[0037] In a third aspect, the present application further provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:
[0038] A first battery state of charge detection model in which battery operation characteristics change over time is constructed using first sample data without a battery state of charge label as a first training data set, wherein the first sample data is generated based on the full amount of battery historical operation data, the full amount of battery historical operation data refers to all operation data of the battery in a charging stage, a discharging stage and a static stage during the historical operation process, and the first battery state of charge detection model includes a feature encoder; a second battery state of charge detection model is constructed based on the feature encoder; second sample data carrying the battery state of charge label is constructed based on the battery historical operation sampling data extracted from the full amount of battery historical operation data, and features are extracted from the second sample data by the feature encoder to obtain sample feature data; the sample feature data is used as a second training data set, a feature predictor of the second battery state of charge detection model is iteratively optimized, and the iteratively optimized second battery state of charge detection model is used as a target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize the relationship between the battery state of charge and the battery operation characteristics; and a battery state of charge detection is performed on the battery to be detected based on the target battery state of charge detection model.
[0039] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the following steps are implemented:
[0040] A first battery state of charge detection model in which battery operation characteristics change over time is constructed using first sample data without a battery state of charge label as a first training data set, wherein the first sample data is generated based on the full amount of battery historical operation data, the full amount of battery historical operation data refers to all operation data of the battery in a charging stage, a discharging stage and a static stage during the historical operation process, and the first battery state of charge detection model includes a feature encoder; a second battery state of charge detection model is constructed based on the feature encoder; second sample data carrying the battery state of charge label is constructed based on the battery historical operation sampling data extracted from the full amount of battery historical operation data, and features are extracted from the second sample data by the feature encoder to obtain sample feature data; the sample feature data is used as a second training data set, a feature predictor of the second battery state of charge detection model is iteratively optimized, and the iteratively optimized second battery state of charge detection model is used as a target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize the relationship between the battery state of charge and the battery operation characteristics; and a battery state of charge detection is performed on the battery to be detected based on the target battery state of charge detection model.
[0041] In a fifth aspect, the present application further provides a computer program product, including a computer program, which implements the following steps when executed by a processor:
[0042] A first battery state of charge detection model in which battery operation characteristics change over time is constructed using first sample data without a battery state of charge label as a first training data set, wherein the first sample data is generated based on the full amount of battery historical operation data, the full amount of battery historical operation data refers to all operation data of the battery in a charging stage, a discharging stage and a static stage during the historical operation process, and the first battery state of charge detection model includes a feature encoder; a second battery state of charge detection model is constructed based on the feature encoder; second sample data carrying the battery state of charge label is constructed based on the battery historical operation sampling data extracted from the full amount of battery historical operation data, and features are extracted from the second sample data by the feature encoder to obtain sample feature data; the sample feature data is used as a second training data set, a feature predictor of the second battery state of charge detection model is iteratively optimized, and the iteratively optimized second battery state of charge detection model is used as a target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize the relationship between the battery state of charge and the battery operation characteristics; and a battery state of charge detection is performed on the battery to be detected based on the target battery state of charge detection model.
[0043] The above-mentioned battery state of charge detection method, device, computer equipment, computer-readable storage medium and computer program product first generate first sample data without a battery state of charge label based on the full amount of battery historical operation data, and use the first sample data as the first training data set to construct a first battery state of charge detection model in which the battery operation characteristics change over time, so as to realize relying on the full amount of battery historical operation data to construct a first battery state of charge prediction model reflecting the operation characteristics of the battery cell under time changes, and then construct a second battery state of charge detection model through a trained feature encoder, and extract battery historical operation sampling data from the full amount of battery historical operation data, and construct the second sample data carrying the battery state of charge label through the battery historical operation sampling data, that is, the purpose of extracting part of the battery historical operation sampling data from the full amount of battery historical operation data to construct the second sample data is achieved, and then the feature encoder is used to extract features of the second sample data to obtain sample feature data. Since the sample feature data carries the battery state of charge label, the sample feature data can characterize the correlation between the battery state of charge and the operation characteristics of the battery cell. Therefore, by using the sample feature data The second training data set is used as the second training data set, and the feature predictor of the second battery state of charge detection model can be iteratively optimized, and the iteratively optimized second battery state of charge detection model is used as the target battery state of charge detection model. Finally, the battery state of charge detection is performed on the battery to be detected through the target battery state of charge detection model. Since the full amount of battery historical operation data can fully reflect the external characteristics of the battery under full working conditions, the first battery state of charge detection model can fully capture the operating characteristics of the battery to be detected, and the target battery state of charge detection model accurately feedbacks the correlation between the battery state of charge and the battery operating characteristics, so that the battery state of charge of the battery to be detected can be accurately detected in the subsequent actual operating conditions of the battery to be detected. Therefore, the complex operating conditions of the battery during use, which leads to the inability of the ampere-hour integration method and the equivalent circuit method to truly reflect the external characteristics of the battery cell under complex conditions, and the number of label samples used by the neural network model is difficult to cover the data under all operating conditions, which makes it easy to detect the technical defects of the situation that the detected battery state of charge and the actual state of charge are inconsistent, so the detection accuracy of the battery state of charge detection is improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the related technologies, the drawings required for use in the embodiments or the related technical descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0045] Figure 1 is a schematic flow chart of a method for detecting a battery state of charge in one embodiment;
[0046] Figure 2 A schematic diagram of the architecture of a first battery state of charge detection model of a battery state of charge detection method in an embodiment;
[0047] Figure 3 A schematic diagram of the architecture of a target battery state of charge detection model of a battery state of charge detection method in an embodiment;
[0048] Figure 4 is a flow chart of a battery state of charge detection method in another embodiment;
[0049] Figure 5 is a structural block diagram of a battery charge state detection device in one embodiment;
[0050] Figure 6 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0051] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0052] First of all, it should be understood that the state of charge detection of lithium batteries is usually carried out using methods such as the ampere-hour integration method, the equivalent circuit method or the neural network model. For example, the battery state of charge correction is performed based on special working conditions such as static or full charge, or the model simulation and parameter estimation are performed based on the equivalent circuit model, or the model learning is performed based on supervised or self-supervised deep learning networks. However, the above-mentioned battery state of charge detection methods all have their own shortcomings. The former involves limited working conditions, and in the process of model simulation and parameter estimation, only a small amount of edge data of a few cells can be used, which makes it difficult to establish a deep learning model. The generalization ability of the model is limited. In addition, the defect of relying on supervised or self-supervised deep learning networks for model learning is that the full amount of data is not used for pre-training, which ultimately leads to low detection accuracy of battery state of charge detection. It can be seen that the above-mentioned battery state of charge detection method cannot adapt to the detection needs of the battery under complex operating conditions, resulting in the inability to truly reflect the external characteristics of the battery cell under complex conditions, which makes it easy for the detected battery state of charge to be inconsistent with the actual state of charge. Therefore, there is an urgent need for a battery state of charge detection method that improves the detection accuracy of battery state of charge detection.
[0053] In one embodiment, Figure 1As shown, a battery state of charge detection method is provided. This embodiment takes the method applied to a terminal as an example. The terminal includes but is not limited to a personal computer, a laptop computer, a smart phone, and a tablet computer. The terminal includes a first building module, a second building module, an extraction module, an optimization module, and a detection module. The first building module is used to use first sample data that does not carry a battery state of charge label as a first training data set to construct a first battery state of charge detection model in which the battery operation characteristics change over time, wherein the first sample data is generated according to the full amount of historical battery operation data, and the full amount of historical battery operation data is data of all operation stages of the battery during the historical operation process. The first battery state of charge detection model includes a feature encoder, and the second building module is used to According to the feature encoder, a second battery state of charge detection model is constructed. The extraction module is used to construct second sample data carrying a battery state of charge label according to the battery history operation sampling data extracted from the full battery history operation data, and to extract features from the second sample data through the feature encoder to obtain sample feature data. The optimization module is used to iteratively optimize the feature predictor of the second battery state of charge detection model using the sample feature data as the second training data set, and use the iteratively optimized second battery state of charge detection model as the target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize the relationship between the battery state of charge and the battery operation characteristics. The detection module is used to perform, according to the target battery state of charge detection model, The battery to be detected performs battery state of charge detection. In the process of performing battery state of charge detection on the battery to be detected, the present embodiment first constructs a first battery state of charge detection model of battery operation characteristics changing with time by using first sample data carrying a battery state of charge label, so as to realize a first battery state of charge prediction model reflecting the operation characteristics of the battery cell changing with time by relying on the full amount of battery historical operation data, and constructs a second sample data by extracting part of the battery historical operation data from the full amount of battery historical operation data. Since the sample feature data carries the battery state of charge label, the sample feature data can characterize the correlation between the battery state of charge and the operation characteristics of the battery cell. Therefore, by using the sample feature data as The second training data set can iteratively optimize the feature predictor of the second battery state of charge detection model, and use the iteratively optimized second battery state of charge detection model as the target battery state of charge detection model, and finally use the target battery state of charge detection model to perform battery state of charge detection on the battery to be detected, that is, the external characteristics of the battery under full working conditions are fully reflected through the full amount of historical battery operation data, and the operating characteristics of the battery to be detected are fully captured through the first battery state of charge detection model. The target battery state of charge detection model accurately feedbacks the correlation between the battery state of charge and the battery operating characteristics, so that the battery state of charge of the battery to be detected can be accurately detected in the subsequent operation of the battery to be detected based on the actual operation of the battery to be detected.This solves the technical problem that the detected battery state of charge is inconsistent with the actual state of charge when using the traditional battery state of charge detection method. Therefore, the detection accuracy of the battery state of charge detection is improved. It can be understood that the method can also be applied to the server, and can also be applied to the system including the terminal and the server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps 202 to 210. Among them:
[0054] Step 202, using first sample data without a battery state of charge label as a first training data set, constructing a first battery state of charge detection model in which battery operation characteristics change over time, wherein the first sample data is generated based on the full amount of historical battery operation data, the full amount of historical battery operation data refers to all operation data of the battery in a charging stage, a discharging stage, and a static stage during the historical operation process, and the first battery state of charge detection model includes a feature encoder.
[0055] It should be noted that the terminal and the cloud server are communicatively connected, and the cloud server stores the full amount of historical operation data of the battery. The full amount of historical operation data of the battery refers to all operation data of the battery in the charging stage, discharging stage and static stage during the historical operation process, which may specifically include data in the charging stage, data in the discharging stage, and data in the static stage (non-charging or discharging stage), etc. For example, the full amount of historical operation data of the battery specifically includes the charging start time, charging end time, charging current and voltage, temperature during charging, discharge start time, discharge end time, discharge current and voltage, discharge depth, and voltage and current during static period, etc. For example, in one feasible method, before model training, the edge uploads signals such as the highest cell voltage, cell voltage, current, highest cell temperature and lowest cell temperature to the cloud, so that the subsequent terminal can obtain the above-mentioned first sample data from the cloud to train the first battery state of charge detection model.
[0056] It should be noted that, in the process of implementing the first battery state of charge detection model, unlabeled sample data (first sample data) generated by the full amount of historical battery operation data is used as the first training data set, that is, the full amount of operation characteristics of the battery cell are collected through the first sample data, and then the first battery state of charge detection model is constructed with the full amount of operation characteristics, so that the first battery state of charge detection model can accurately capture the external characteristics of the battery. For example, in an implementable manner, the terminal accesses the full operating condition data in the cloud database. It is assumed that each battery cluster has n battery cells connected in series, then the battery cell single cell voltage is a data table list with n elements; the current is the common value of all battery cells; the average temperature is the average value between the highest single cell temperature and the lowest single cell temperature of the battery cell, that is, all batteries The common value of the battery cells; if the single cell voltage is separated, each frame of each battery cell can obtain a list with three elements = [single cell voltage, current, average temperature], so the first sample data generated according to the full amount of historical operation data of the battery can be expressed as "single cell voltage of the battery cell, current of the battery cell, average temperature of the battery cell", that is, the first sample data can be the single cell voltage, current of the battery cell and average temperature of the battery cell in different historical time frames, wherein the battery state of charge label is used to identify the battery state of charge, which can be 70%, 80% or 90%, etc., that is, the essence of constructing the first battery state of charge detection model is to use the unlabeled full amount of sample data for unsupervised learning to obtain a battery state of charge detection model that can accurately capture the battery operation characteristics. For example, in one feasible method, refer to Figure 2 , Figure 2 : is a schematic diagram of the architecture of a first battery state of charge detection model, wherein the first battery state of charge detection model is formed by superposition of two layers of convolutional layers, BatchNormalization layers and relu activation functions. Specifically, the first battery state of charge detection model may include a feature encoder encoder and a feature decoder decoder, the feature encoder and the feature decoder are both two-layer LSTM (Long Short-Term Memory, long short-term memory network), the fully connected layer 1 and the fully connected layer 2 can be represented as MLP1 and MLP2 respectively, and the preset battery state of charge detection model is trained by the first training data set to obtain the first battery state of charge detection model, wherein T represents Tensor, and B represents Batch Size. For example, "T (b×3×20)" indicates that the tensor T is a three-dimensional tensor, the first dimension b represents the batch size, which is used to represent the number of samples processed in each iteration, the second dimension 3 represents the number of sample features, and the third dimension 20 represents the time step of each sample.
[0057] As an example, step 202 includes: obtaining the full amount of historical operation data of the battery, generating first sample data without a battery state of charge label based on the full amount of historical operation data, and using the first sample data as a first training data set, and iteratively optimizing a preset battery state of charge detection model in which the battery operation characteristics change over time based on the first training data set to obtain a first battery state of charge detection model, wherein the first battery state of charge detection model includes a feature encoder.
[0058] Step 204: construct a second battery state of charge detection model according to the feature encoder.
[0059] It should be noted that, since the first battery state of charge detection model is a neural network model that has been trained by the first training data set, and the feature encoder of the first battery state of charge detection model is a trained feature encoder, the feature encoder can accurately capture the external characteristics of the battery operation. It can be understood that the second battery state of charge detection model can be composed of the feature encoder of the first battery state of charge detection model and an untrained feature predictor.
[0060] As an example, step 204 includes: constructing a feature encoder and an untrained feature predictor together into a second state of charge detection model.
[0061] Step 206 , constructing second sample data carrying a battery state of charge tag based on the battery history operation sampling data extracted from the battery history operation full data, and extracting features from the second sample data through a feature encoder to obtain sample feature data.
[0062] It should be noted that the battery historical operation sampling data refers to the battery historical operation sampling data extracted from the battery historical operation full data, and then the feature encoder is used to extract features from the second sample data carrying the battery state of charge label constructed based on the battery historical operation sampling data, so as to obtain sample feature data characterizing the relationship between the battery state of charge and the battery operation characteristics. For example, in an implementable manner, assuming that in the battery cells of the same battery cluster, the highest node is fully charged, then the three signal data of the battery cell single voltage, the battery cell current and the battery cell average temperature = (highest single cell temperature + lowest single cell temperature) / 2 of the corresponding node number are taken out, and then each frame of the highest node battery cell can obtain a data table list of three elements, and since the highest node battery cell is fully charged, the battery state of charge label of the highest node battery cell is defined as "100%", that is, for the sampled battery historical operation sampling data, the corresponding battery state of charge label is defined, thereby forming labeled sample data (second sample data). Since the feature encoder has been trained through the unlabeled sample data, the feature encoder is used to extract features from the second sample data, and finally the sample feature data is extracted.
[0063] As an example, step 206 includes: randomly extracting battery historical operation sampling data from the full battery historical operation data, matching the battery state of charge label for the historical operation sampling data, assigning the battery state of charge label to the battery historical operation sampling data to obtain second sample data, and inputting the second sample data into a feature encoder for feature extraction to obtain sample feature data.
[0064] Step 208, using the sample feature data as a second training data set, iteratively optimizing the feature predictor of the second battery state of charge detection model, and using the iteratively optimized second battery state of charge detection model as a target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize the relationship between the battery state of charge and the battery operation characteristics.
[0065] It should be noted that the second battery state of charge model refers to a battery state of charge model in which the feature encoder is trained but the feature predictor is not trained. If the second battery state of charge detection model is to be able to accurately perform battery state of charge detection, the feature predictor needs to be trained, so that the second battery state of charge detection model in which both the feature encoder and the feature predictor are trained is used as the target battery state of charge detection model. For example, in one practicable manner, referring to Figure 3 , Figure 3 Schematic diagram of the architecture of the target battery state of charge detection model, wherein the encoder part (feature encoder) of the trained autoencoder MODEL1 is taken, and the downstream network MLP3 is added to form a new model MODEL2 (a second battery state of charge detection model), wherein the autoencoder part is frozen, and only the sample feature data is used to train the downstream network, the fully connected layer 3 can be represented as the downstream network MLP3, the second battery state of charge detection model is iteratively optimized through the second training data set, and the iteratively optimized second battery state of charge detection model is used as the target battery state of charge detection model and saved.
[0066] As an example, step 208 includes: using the sample feature data as a second training data set, and iteratively optimizing the feature predictor of the second battery state of charge detection model through the second training data set until the feature predictor training of the second battery state of charge detection model is completed, determining that the iterative optimization of the second battery state of charge detection model is completed, and using the iteratively optimized second battery state of charge detection model as a target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize the relationship between the battery state of charge and the battery operation characteristics.
[0067] Step 210 , performing a battery state of charge detection on the battery to be detected according to the target battery state of charge detection model.
[0068] It should be noted that since the target battery state of charge detection model is used to characterize the changing relationship between the battery state of charge and the battery operation characteristics, the battery state of charge can be predicted by deploying the target battery state of charge detection model to the edge.
[0069] As an example, step 210 includes: according to the target battery state of charge detection model, feature extraction is performed on the real-time operation data of the battery to be detected to obtain the real-time battery operation characteristics of the battery to be detected, and the battery state of charge of the battery to be detected is detected based on the real-time battery operation characteristics.
[0070] In the above-mentioned battery state of charge detection method, firstly, by using unlabeled sample data generated according to the full amount of historical battery operation data as the first training data set, the preset battery state of charge detection model that characterizes the change of battery operation characteristics over time is iteratively optimized to obtain a trained first battery state of charge detection model, wherein the first battery state of charge detection model includes a feature encoder, and then a second battery state of charge detection model is constructed by the trained feature encoder, and by using the labeled sample data as the second training data set, the feature predictor of the second battery state of charge detection model constructed based on the feature encoder is trained to obtain a target battery state of charge detection model in which both the feature encoder and the feature predictor are trained. Since the target battery state of charge detection model is used to characterize the relationship between the change of the battery state of charge and the battery operation characteristics, the target battery state of charge detection model can be used to detect the state of the battery to be detected. Battery state of charge, since the full amount of historical battery operation data can fully reflect the external characteristics of the battery under all operating conditions, the first battery state of charge detection model can fully capture the operating characteristics of the battery to be detected, and the target battery state of charge detection model can accurately feedback the correlation between the battery state of charge and the battery operating characteristics, so that the battery state of charge of the battery to be detected can be accurately detected based on the actual operating conditions of the battery to be detected in the future. Therefore, the complex operating conditions of the battery during use make the ampere-hour integration method and the equivalent circuit method unable to truly reflect the external characteristics of the battery cell under complex conditions, and the number of label samples used by the neural network model is difficult to cover the data under all operating conditions, which makes it easy for the detected battery state of charge to be inconsistent with the actual state of charge. Therefore, the detection accuracy of the battery state of charge detection is improved.
[0071] In one embodiment, Figure 4 As shown, the first sample data without a battery state of charge label is used as the first training data set to construct a first battery state of charge detection model in which the battery operation characteristics change over time, including:
[0072] Step 302: split the first training data set into first training data of a first time step and second training data of a second time step, wherein the first time step is smaller than the second time step.
[0073] It should be noted that when using the full amount of historical battery operation data to perform self-supervised pre-training on the preset battery state of charge detection model, in order to avoid the trap of data self-duplication due to a single training task, and to avoid the defect of lack of insight into the changes in the model in a longer time dimension due to lack of self-prediction, in order to extract more effective information from the training data, thereby improving the generalization ability of the model, after generating the first training data set based on the full amount of historical operation data, the first data set is split to obtain the first training data and the second training data. It can be understood that the time steps of the first training data and the second training data are different. Among them, in order to facilitate the subsequent prediction tasks and self-prediction tasks, the first time step is guaranteed to be smaller than the second time step.
[0074] As an example, step 302 includes: according to a data time identifier of the first training data set, splitting the first training data set into first training data of a first time step and second training data of a second time step, wherein the first time step is smaller than the second time step.
[0075] Step 304, reconstructing features of the first training data to obtain training reconstructed data;
[0076] It should be noted that the data volumes of the first training data and the second training data may be the same or different. To increase the accuracy and stability of model prediction, the first training data is the earlier training data in the first training data set.
[0077] As an example, step 304 includes: reconstructing the first training data into training reconstructed data.
[0078] Step 306: construct a first battery state of charge detection model using a target training data set composed of the second training data and the training reconstruction data.
[0079] As an example, step 306 includes: combining the second training data and the training reconstruction data to form a target training data set, iteratively optimizing a preset battery state of charge detection model according to the target training data set, and using the optimized preset battery state of charge detection model as the first battery state of charge detection model.
[0080] In this embodiment, in the process of constructing the first battery state of charge detection model, the first training data set is firstly split into first training data and second training data of different time steps, wherein the time step of the first training data is smaller than the time step of the second training data, and then the first training data with an earlier time point is used for self-reconstruction to obtain training reconstructed data, and finally the preset battery state of charge detection model is iteratively optimized through the target training data set composed of the second training data and the training reconstructed data to obtain the first battery state of charge detection model. Since the process of iteratively optimizing the preset battery state of charge detection model includes self-prediction tasks and prediction tasks, more effective information can be used for model training in the process of self-supervised learning, thereby improving the generalization ability of the first battery state of charge detection model.
[0081] In one embodiment, constructing second sample data carrying a battery state of charge tag based on battery historical operation sampling data extracted from the battery historical operation full data includes:
[0082] According to multiple battery operating conditions to which the full battery historical operation data belongs, battery historical operation sampling data is extracted from the full battery historical operation data; according to a preset ampere-hour integral ratio, the historical battery state of charge corresponding to the battery historical operation sampling data is determined; and the battery historical operation sampling data and the historical battery state of charge are spliced into the second sample data.
[0083] It should be noted that in the process of constructing the second sample data carrying the battery state of charge label, due to the data size of the battery historical operation sampling data and the changes in the battery state of charge of the battery historical operation sampling data in different time frames, the traditional method can be used to assign battery state of charge labels to the battery historical operation sampling data in different time frames. For example, in one feasible method, the battery state of charge corresponding to the historical operation sampling data of the highest battery cell that is fully charged can be defined as 100%, and the historical operation sampling data of different battery cells can be reversed using the ampere-hour integration method to obtain the historical battery state of charge corresponding to different historical operation sampling data.
[0084] It should be noted that the battery state of charge predicted under different operating conditions is different, and the operating conditions applied to different batteries are also different. In order to improve the scenario adaptability of the target battery state of charge detection model, the battery historical operation full data can be fixedly extracted based on the battery operating conditions to which the battery historical operation full data belongs, so that the battery historical operation sampling data can comprehensively and evenly characterize the operating characteristics of the battery under various historical operating conditions, wherein the battery operating conditions may specifically be battery charging conditions, battery static conditions, and battery discharging conditions, etc. The second sample data may specifically be battery historical operation sampling data spliced with historical battery states of charge. For example, in an implementable manner, the second sample data may specifically be "cell voltage of the battery cell, battery current, battery cell average temperature, and battery state of charge of 80%".
[0085] As an example, multiple battery operating conditions to which the full battery historical operating data belongs are counted, and historical operating data under different battery historical operating conditions are extracted from the battery historical operating conditions according to a fixed ratio as battery historical operation sampling data; the battery historical operation sampling data is configured with a corresponding historical battery state of charge according to a preset ampere-hour integral ratio; the battery historical operation sampling data and the historical battery state of charge corresponding to the battery historical operation sampling data are concatenated together into a second sample data.
[0086] In this embodiment, after counting multiple battery operating conditions to which the full amount of battery historical operating data belongs, historical operating data under different battery historical operating conditions are extracted as battery historical operating sampling data, and a preset ampere-hour integral ratio is used to configure corresponding historical battery states of charge for different battery historical operating sampling data. Thus, through targeted splicing of the battery historical operating sampling data and the historical battery states of charge, second sample data is constructed, thereby achieving the purpose of quickly configuring historical battery states of charge for different battery historical operating sampling data. At the same time, the battery operating characteristics carried by the second sample data can be more suitable for the actual battery operating scenario. Therefore, while laying the foundation for improving the detection accuracy of battery state of charge detection, it also lays the foundation for improving the scenario adaptability of the constructed first battery state of charge detection model.
[0087] In one embodiment, according to a plurality of battery operating conditions to which the full amount of battery historical operating data belongs, extracting battery historical operating sampling data from the full amount of battery historical operating data includes:
[0088] The battery historical operating condition data under each battery operating condition is extracted from the battery historical operating full data; a plurality of battery operating condition sampling data are obtained by sampling each battery historical operating condition data according to the condition sample weights corresponding to each battery operating condition; and the sampling data of each battery operating condition are integrated into the battery historical operation sampling data.
[0089] It should be noted that different battery operating conditions appear with different frequencies in actual applications. In order to reflect the differences between different battery operating conditions, different condition sample weights can be matched to the battery historical operating condition data corresponding to different battery operating conditions, and then the battery historical operating condition data are sampled with different condition sample weights to obtain battery historical operation sampling data, wherein the amount of historical operating condition data under different battery historical operating conditions in the battery historical operation sampling data is different. For example, in one feasible method, assuming that the condition sample weight of battery operating condition A is 0.7, the condition sample weight of battery operating condition B is 0.2, and the condition sample weight of battery operating condition C is 0.1, then the ratios of the battery historical operating condition data corresponding to battery operating condition A, battery operating condition B and battery operating condition C presented in the integrated battery historical operation sampling data are 7:2:1, respectively.
[0090] As an example, the full amount of historical battery operation data is divided into battery historical operating condition data under each battery operating condition; a corresponding condition sample weight is matched to each battery operating condition, and based on the condition sample weight, a plurality of battery operating condition sampling data are sampled from the battery historical operating condition corresponding to each battery operating condition; and the plurality of battery operating condition sampling data under each battery historical operating condition are integrated together into the battery historical operation sampling data.
[0091] In the present embodiment, in the process of extracting battery historical operation sampling data from the full battery historical operation data, the full battery historical operation data is first divided according to the battery operating conditions to obtain battery historical operating condition data under different battery operating conditions, and then the battery historical operating condition data under different battery operating conditions are sampled through the condition sample weights corresponding to different battery operating conditions to obtain battery operating condition sampling data under multiple battery operating conditions, and the battery operating condition sampling data under different battery operating conditions are integrated into the battery historical operation sampling data, so as to achieve the purpose of obtaining the battery historical operation sampling data by weighted extraction from the full battery historical operation data based on the frequency of different battery operating conditions in actual applications. Therefore, the foundation is further laid for improving the scenario adaptability of the constructed first battery state of charge detection model.
[0092] In one embodiment, the feature encoder includes a plurality of local feature encoders, each of which is trained by local sample data according to the placement position of the battery cell in the battery module; the feature encoder extracts features from the second sample data to obtain sample feature data, including:
[0093] Multi-scale feature extraction is performed on the second sample data according to the placement position of the battery cells in the battery module through each local feature encoder to obtain multiple sample spatial scale features, wherein the second sample data includes operation characteristics of different battery cells, and one spatial scale corresponds to one battery cell; weighted fusion is performed on each sample spatial scale feature to obtain sample feature data.
[0094] It should be noted that, in the process of feature extraction of the second sample data, since the battery cells in the battery module will generate different operating data due to different placement positions, in order to fully reflect the external characteristics of the battery cells under historical operating conditions, local sample data of the battery cells at different placement positions can be extracted, and multiple local feature encoders are set in the feature encoder. After the training of multiple local feature encoders is completed relying on local sample data, the sample space scale features of the battery cells at different placement positions in the battery module can be extracted through multiple local feature encoders. Finally, the sample feature data obtained by fusing multiple sample space scales can fully reflect the operating characteristics of the battery cells, thereby improving the richness of the sample features, so that the target battery state of charge detection model obtained by subsequent iterative training has stronger generalization ability.
[0095] As an example, multi-scale feature extraction is performed on the second sample data according to the placement position of the battery cells in the battery module through multiple local feature encoders to obtain multiple sample spatial scale features, wherein the second sample data includes operating characteristics of different battery cells, one spatial scale corresponds to one battery cell, and the multiple local feature encoders are trained by local sample data according to the placement position of the battery cells in the battery module; according to the feature weights of each sample spatial scale feature, each sample spatial scale feature is fused together into sample feature data.
[0096] In this embodiment, in the process of extracting features from the second sample data using the feature encoder, multi-scale feature extraction is performed on the second sample data according to the placement position of the battery cell in the battery module through the deployed multiple local feature encoders, so that sample spatial scale features at different spatial scales are extracted from the operating characteristics of different battery cells, and finally sample feature data is obtained by weighted fusion of different sample spatial scale features, that is, the obtained sample feature data can fully reflect the spatial characteristics of the battery cell under the operating conditions, and then in the process of iteratively optimizing the second battery state of charge detection model based on the sample feature data, the richness of the sample features can be improved, thereby laying a foundation for improving the detection accuracy of the constructed target battery state of charge detection model.
[0097] In one embodiment, before constructing a first battery state of charge detection model in which the battery operation characteristic changes over time by using the first sample data without the battery state of charge label as the first training data set, the method further includes:
[0098] The historical operating current, historical operating voltage and historical operating temperature of each battery cell are extracted from the full amount of historical operating data of the battery; the historical sample operating temperature of each battery cell is generated according to each historical operating temperature; for any battery cell, the historical operating current, historical operating voltage and historical sample operating temperature of the battery cell are concatenated together into single cell sample data of the battery cell; and each single cell sample data is integrated into the first sample data.
[0099] It should be noted that the conventional battery state of charge detection method does not use full data, which will result in the inability to adapt to the complex external characteristics of iron-lithium batteries under various operating conditions. In this embodiment, although the full amount of battery historical operation data used can avoid the above-mentioned defects, due to the huge amount of battery historical operation data, in order to improve the detection efficiency of the battery state of charge, the full amount of battery historical operation data can be preprocessed, and the preprocessed full amount of battery historical operation data can be integrated to obtain the first sample data for iterative training of the preset battery state of charge detection model.
[0100] As an example, the historical operating current, historical operating voltage and historical operating temperature of each battery cell are extracted from the full amount of historical operating data of the battery; the historical highest operating temperature and the historical lowest operating temperature are selected from each historical operating temperature, and the average value of the historical highest operating temperature and the historical lowest operating temperature is used as the historical sample operating temperature of the battery cell; for any battery cell, the historical operating current, historical operating voltage and historical sample operating temperature of the battery cell are concatenated together into single cell sample data of the battery cell; and each single cell sample data is integrated into the first sample data.
[0101] In this embodiment, current, voltage and temperature are extracted from the full amount of historical operation data of the battery as characteristic data reflecting the operating condition of the battery under operating conditions, and the current, voltage and temperature of different battery cells are integrated to obtain first sample data for iterative training of a preset battery state of charge detection model. This reduces the redundancy of sample data while adapting to the complex external characteristics of battery cells under various operating conditions. Therefore, while laying a foundation for improving the detection accuracy of battery state of charge detection, it also lays a foundation for improving the detection efficiency of battery state of charge detection.
[0102] In an practicable manner, the specific process of the above-mentioned battery state of charge detection method can be as follows: 1) First, extract the highest cell voltage, cell voltage, current, highest cell temperature and lowest cell temperature and other data from the full amount of battery historical operation data in the cloud, and after preprocessing the data, obtain the first sample data without the battery state of charge label, that is, each frame of each battery cell can obtain a list with 3 elements = [cell voltage, current, average temperature]; 2) Slice and split the time series to form a data set, as follows: Assume that m is the slice length, move frame by frame, if the forward 2m consecutive frames of historical data, including the cell voltage , current and average temperature are all effective values, then the time series forward is intercepted, the dimension is 3×(2m), where the time series of the first m frames is recorded as A1, and the time series of the last m frames is recorded as A2, then the input of the deep learning model MODEL1 of the autoencoder architecture is A1, the dimension is 3×m; the output labels are A1 and A2, the dimensions are both 3×m; because all effective data, regardless of charging, discharging or static, can be sliced as the input and output of model MODEL1, the data volume is large, and the data set is divided as follows: 98% for training set, 1% for validation set, and 1% for test set; the data set is recorded as D1 (the first training data set), and the data set is used to Iteratively train the preset battery state of charge detection model based on data set D1 to obtain the first battery state of charge detection model; 3) Access the charging data in the database and mark the battery cells as follows: if the highest node in the battery cells of the same battery cluster is fully charged, take out the three signals of the battery cell voltage, current, and average temperature = (highest cell temperature + lowest cell temperature) / 2 of the corresponding node number, then each frame of the highest node battery cell can obtain a list of 3 elements; The real SOC label of each frame of the highest node battery cell is defined as: reversely inferring from the full charge point using ampere-hour integration, where the full charge point is defined as 100% SOC, that is, using the ampere-hour integration method to determine the historical operation sampling data of different batteries The historical battery state of charge is obtained, and the battery historical operation sampling data and the historical battery state of charge are spliced into the second sample data; 4) The above-mentioned highest energy-saving cell full charge time series is sliced and split to form a data set, and the method is as follows: move frame by frame, if the forward continuous m frames of historical data, including voltage, current and average temperature are all valid values, then intercept the forward time series, the dimension is 3×(m), recorded as A3, then the input of the SOC intelligent prediction model MODEL2 is A3, dimension 3×m; the output label is the actual SOC at the current moment; the data set is divided into the following proportions: 70% for training set, 20% for validation set, and 10% for test set;The data set is recorded as D2 (sample feature data), and the second battery state of charge detection model is trained by the sample feature data to obtain the target battery state of charge detection model, that is, the sample feature data is used as the second training data set, the feature predictor of the second battery state of charge detection model is iteratively optimized, and the iteratively optimized second battery state of charge detection model is used as the target battery state of charge detection model; 5) The trained deep learning model MODEL2 (target battery state of charge detection model) is deployed to the edge for intelligent SOC estimation. ;
[0103] Since the full amount of historical battery operation data can fully reflect the external characteristics of the battery under all operating conditions, the first battery state of charge detection model can fully capture the operating characteristics of the battery to be detected, and the target battery state of charge detection model can accurately feedback the correlation between the battery state of charge and the battery operating characteristics, so that the battery state of charge of the battery to be detected can be accurately detected based on the actual operating conditions of the battery to be detected in the future. Therefore, the problem of the ampere-hour integration method and the equivalent circuit method being unable to truly reflect the external characteristics of the battery cell under complex operating conditions due to the complex operating conditions of the battery during use is overcome, and the number of label samples used by the neural network model is difficult to cover the data under all operating conditions, which makes it easy for the detected battery state of charge to be inconsistent with the actual state of charge. Therefore, the detection accuracy of the battery state of charge detection is improved.
[0104] It should be understood that, although the steps in the flowcharts involved in the above embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above embodiments may include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0105] Based on the same inventive concept, the embodiment of the present application also provides a battery state of charge detection device for implementing the battery state of charge detection method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more embodiments of the battery state of charge detection device provided below can refer to the limitations of the battery state of charge detection method above, and will not be repeated here.
[0106] In an exemplary embodiment, Figure 5 As shown, a battery state of charge detection device is provided, including: a first construction module 401, a second construction module 402, an extraction module 403, an optimization module 404 and a detection module 405, wherein:
[0107] A first construction module 401 is used to construct a first battery state of charge detection model in which the battery operation characteristics change over time by using first sample data without a battery state of charge label as a first training data set, wherein the first sample data is generated according to the full amount of historical operation data of the battery, the full amount of historical operation data of the battery refers to all operation data of the battery in the charging stage, the discharging stage and the static stage during the historical operation process, and the first battery state of charge detection model includes a feature encoder;
[0108] A second construction module 402 is used to construct a second battery state of charge detection model according to the feature encoder;
[0109] An extraction module 403 is used to construct second sample data carrying the battery state of charge tag according to the battery historical operation sampling data extracted from the battery historical operation full data, and extract features from the second sample data through the feature encoder to obtain sample feature data;
[0110] an optimization module 404, configured to iteratively optimize a feature predictor of the second battery state of charge detection model using the sample feature data as a second training data set, and use the iteratively optimized second battery state of charge detection model as a target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize a relationship between a battery state of charge and a battery operation characteristic;
[0111] The detection module 405 is used to perform a battery state of charge detection on the battery to be detected according to the target battery state of charge detection model.
[0112] In one embodiment, the first building module 401 is further used for:
[0113] The first training data set is split into first training data of a first time step and second training data of a second time step, wherein the first time step is smaller than the second time step; feature reconstruction is performed on the first training data to obtain training reconstructed data; and the first battery state of charge detection model is constructed using a target training data set composed of the second training data and the training reconstructed data.
[0114] In one embodiment, the extraction module 403 is further used for:
[0115] According to a plurality of battery operating conditions to which the full battery historical operating data belongs, the battery historical operating sampling data is extracted from the full battery historical operating data; according to a preset ampere-hour integral ratio, the historical battery state of charge corresponding to the battery historical operating sampling data is determined; and the battery historical operating sampling data and the historical battery state of charge are spliced into the second sample data.
[0116] In one embodiment, the extraction module 403 is further used for:
[0117] The battery historical operating condition data under each of the battery operating conditions is extracted from the battery historical operating full data; a plurality of battery operating condition sampling data are obtained by sampling each of the battery historical operating condition data according to the condition sample weights corresponding to each of the battery operating conditions; and the battery operating condition sampling data are integrated into the battery historical operation sampling data.
[0118] In one embodiment, the feature encoder includes a plurality of local feature encoders, each of which is trained by local sample data according to the placement position of the battery cell in the battery module; the extraction module 403 is further used for:
[0119] The second sample data is subjected to multi-scale feature extraction by each of the local feature encoders according to the placement position of the battery cell in the battery module to obtain a plurality of sample spatial scale features, wherein the second sample data includes operating characteristics of different battery cells, and one spatial scale corresponds to one battery cell; each of the sample spatial scale features is subjected to weighted fusion to obtain the sample feature data.
[0120] In one embodiment, the battery charge state detection device is further used for:
[0121] The historical operating current, historical operating voltage and historical operating temperature of each battery cell are extracted from the full historical operating data of the battery; the historical sample operating temperature of each battery cell is generated according to each historical operating temperature; for any battery cell, the historical operating current of the battery cell, the historical operating voltage of the battery cell and the historical sample operating temperature are concatenated together into single cell sample data of the battery cell; and each single cell sample data is integrated into the first sample data.
[0122] Each module in the above-mentioned battery charge state detection device can be implemented in whole or in part by software, hardware and a combination thereof. Each of the above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the corresponding operations of each of the above modules.
[0123] In an exemplary embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as shown in FIG. Figure 6 As shown. The computer device includes a processor, a memory, an input / output interface, a communication interface, a display unit and an input device. The processor, the memory and the input / output interface are connected via a system bus, and the communication interface, the display unit and the input device are connected to the system bus via the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be implemented through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a battery state of charge detection method is implemented. Those skilled in the art can understand that Figure 6 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0124] In one embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above method embodiments when executing the computer program.
[0125] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.
[0126] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.
[0127] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0128] The technical features of the above embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0129] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A method for detecting a battery state of charge, characterized in that: The method comprises: Using first sample data without a battery state of charge label as a first training data set, a first battery state of charge detection model in which battery operation characteristics change over time is constructed, wherein the first sample data is generated according to the full amount of historical battery operation data, the full amount of historical battery operation data refers to all operation data of the battery in a charging stage, a discharging stage, and a static stage during the historical operation process, and the first battery state of charge detection model includes a feature encoder; constructing a second battery state of charge detection model according to the feature encoder; constructing second sample data carrying the battery state of charge tag according to the battery history operation sampling data extracted from the battery history operation full data, and extracting features from the second sample data by the feature encoder to obtain sample feature data; Taking the sample feature data as a second training data set, iteratively optimizing the feature predictor of the second battery state of charge detection model, and taking the iteratively optimized second battery state of charge detection model as a target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize the relationship between the battery state of charge and the battery operation characteristics; According to the target battery state of charge detection model, a battery state of charge detection is performed on the battery to be detected, wherein the first sample data without a battery state of charge label is used as a first training data set to construct a first battery state of charge detection model in which the battery operation characteristics change over time, including: Splitting the first training data set into first training data of a first time step and second training data of a second time step, wherein the first time step is smaller than the second time step; Performing feature reconstruction on the first training data to obtain training reconstructed data; The first battery state of charge detection model is constructed using a target training data set composed of the second training data and the training reconstruction data, wherein the second sample data carrying the battery state of charge label is constructed based on the battery historical operation sampling data extracted from the battery historical operation full data, including: Extracting the battery historical operation sampling data from the battery historical operation full data according to a plurality of battery operating conditions to which the battery historical operation full data belongs; Determining the historical battery state of charge corresponding to the battery historical operation sampling data according to a preset ampere-hour integral ratio; The battery historical operation sampling data and the historical battery state of charge are spliced into the second sample data, wherein the feature encoder includes a plurality of local feature encoders, each of which is trained by local sample data according to the placement position of the battery cell in the battery module; the feature encoder extracts features from the second sample data to obtain sample feature data, including: Performing multi-scale feature extraction on the second sample data according to the placement positions of the battery cells in the battery module by each of the local feature encoders to obtain a plurality of sample spatial scale features, wherein the second sample data includes operating characteristics of different battery cells, and one spatial scale corresponds to one battery cell; The spatial scale features of each sample are weighted and fused to obtain the sample feature data.
2. The method according to claim 1, characterized in that: The extracting the battery historical operation sampling data from the battery historical operation full data according to the multiple battery operating conditions to which the battery historical operation full data belongs includes: Extracting the battery historical operating condition data under each of the battery operating conditions from the battery historical operating full data; According to the working condition sample weights corresponding to the respective battery working conditions, sampling the historical working condition data of the respective batteries to obtain a plurality of battery working condition sampling data; The sampling data of each battery operation condition are integrated into the battery historical operation sampling data.
3. The method according to claim 1, characterized in that Before constructing a first battery state of charge detection model in which the battery operation characteristics vary over time by using the first sample data without the battery state of charge label as the first training data set, the method further includes: Extracting the historical operating current, historical operating voltage and historical operating temperature of each battery cell from the full amount of historical operating data of the battery; Generating a historical sample operating temperature of each of the battery cells according to each of the historical operating temperatures; For any of the battery cells, the historical operating current of the battery cell, the historical operating voltage of the battery cell and the historical sample operating temperature are concatenated together into single-cell sample data of the battery cell; The individual sample data are integrated into the first sample data.
4. A battery state of charge detection device, characterized in that: The device comprises: A first building module, configured to build a first battery state of charge detection model in which the battery operation characteristics change over time by using first sample data without a battery state of charge label as a first training data set, wherein the first sample data is generated according to the full amount of historical operation data of the battery, the full amount of historical operation data of the battery refers to all operation data of the battery in a charging stage, a discharging stage and a static stage during the historical operation process, and the first battery state of charge detection model includes a feature encoder; A second building module, used to build a second battery state of charge detection model according to the feature encoder; an extraction module, configured to construct second sample data carrying the battery state of charge tag according to the battery history operation sampling data extracted from the battery history operation full data, and extract features from the second sample data through the feature encoder to obtain sample feature data; an optimization module, configured to iteratively optimize a feature predictor of the second battery state of charge detection model using the sample feature data as a second training data set, and use the iteratively optimized second battery state of charge detection model as a target battery state of charge detection model, wherein the target battery state of charge detection model is used to characterize a relationship between a battery state of charge and a battery operation characteristic; A detection module is used to perform a battery state of charge detection on the battery to be detected according to the target battery state of charge detection model, wherein the first building module is also used to: The first training data set is split into first training data of a first time step and second training data of a second time step, wherein the first time step is smaller than the second time step; feature reconstruction is performed on the first training data to obtain training reconstruction data; and the first battery state of charge detection model is constructed with a target training data set composed of the second training data and the training reconstruction data, wherein the extraction module is further used for: According to a plurality of battery operating conditions to which the full amount of battery historical operating data belongs, the battery historical operating sampling data is extracted from the full amount of battery historical operating data; according to a preset ampere-hour integral ratio, the historical battery state of charge corresponding to the battery historical operating sampling data is determined; the battery historical operating sampling data and the historical battery state of charge are spliced into the second sample data, wherein the feature encoder includes a plurality of local feature encoders, each of which is trained by local sample data according to the placement position of the battery cell in the battery module; the extraction module is also used for: The second sample data is subjected to multi-scale feature extraction by each of the local feature encoders according to the placement position of the battery cell in the battery module to obtain a plurality of sample spatial scale features, wherein the second sample data includes operating characteristics of different battery cells, and one spatial scale corresponds to one battery cell; each of the sample spatial scale features is subjected to weighted fusion to obtain the sample feature data.
5. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 3 are implemented.
6. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 3 are implemented.
7. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 3 are implemented.
Citation Information
Patent Citations
Passive state-of-charge prediction model training method, passive state-of-charge prediction method, passive state-of-charge prediction equipment and medium
CN115728645A
Battery anomaly detection method, device and system and electronic device
CN116184210A