Battery fault detection method and device, electronic equipment and storage medium
By acquiring the target strain data of individual battery cells, performing median difference processing and converting it into a grayscale image, and combining it with a visual Transformer model to detect battery faults, the problem of low accuracy in battery fault detection in existing technologies is solved, achieving efficient and accurate battery fault detection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-06
- Publication Date
- 2026-03-27
AI Technical Summary
Existing battery fault detection methods rely solely on voltage data as a criterion, resulting in low accuracy and an inability to comprehensively detect battery faults.
By acquiring the target strain data of individual battery cells, median difference processing is performed to convert it into a grayscale image. The visual Transformer model is then used to capture global and local features of the image for fault detection.
It improves the accuracy of battery fault detection, can identify minor faults in individual battery cells, and realizes automation and high efficiency in battery fault detection.
Smart Images

Figure CN121069210B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] Embodiments of the present application relate to the technical field of power battery fault diagnosis, and in particular to a battery fault detection method and device, an electronic device, and a storage medium. BACKGROUND
[0002] As a core component of an electric vehicle, the health status of a power battery directly relates to the safety performance and service life of the vehicle. During long-term operation of the vehicle, the power battery will inevitably degrade or even fail, which may cause serious safety hazards, such as thermal runaway, fire, and the like. Therefore, detecting potential faults in the power battery is crucial to ensuring safe operation of the electric vehicle.
[0003] A related battery fault detection method generally uses the voltage of a normal battery as a reference group to determine whether the voltage of the battery deviates from the voltage of the reference group and whether the degree of deviation is greater than a preset threshold, as a standard for determining whether the battery has failed. However, this method only uses voltage as a standard for determining whether the battery has failed, which cannot comprehensively detect faults in the battery, and thus may result in low accuracy of battery fault detection. SUMMARY
[0004] In view of the above problems, a battery fault detection method, device, electronic device, and storage medium are provided to overcome the above problems or at least partially solve the above problems, comprising:
[0005] In a first aspect, embodiments of the present application provide a battery fault detection method applied to a vehicle, the vehicle comprising battery monomers, and the method comprising:
[0006] obtaining target strain data of any of the battery monomers, wherein the target strain data is a relative change in length, and the target strain data is a ratio of a change in length to an original length;
[0007] performing median difference processing on the target strain data to obtain median difference strain data;
[0008] converting the median difference strain data into a grayscale image;
[0009] inputting the grayscale image into a pre-generated battery monomer fault detection model to obtain a fault detection result label, wherein the pre-generated battery monomer fault detection model is a visual Transformer model, the visual Transformer model has the ability to capture global dependency information of an image, extracts global features of the grayscale image and local features of the grayscale image from the input grayscale image based on a self-attention mechanism, and determines the fault detection result label according to the global features of the grayscale image and the local features of the grayscale image.
[0010] If the fault detection result label is a preset first value, it is determined that the fault detection result of the battery monomer is that the battery monomer has a fault;
[0011] If the fault detection result label is a preset second value, it is determined that the fault detection result of the battery monomer is that the battery monomer has no fault.
[0012] Optionally, the target strain data of any of the battery monomers comprises:
[0013] Obtaining initial strain data of any of the battery monomers;
[0014] The initial strain data is down-sampled to obtain target strain data.
[0015] Optionally, the initial strain data is down-sampled to obtain target strain data, comprising:
[0016] For any preset time window, the length of the time window and the initial strain data in the time window are obtained;
[0017] According to the length of the time window and the initial strain data in the time window, the average value of the initial strain data is determined;
[0018] The average value of the initial strain data is taken as the target strain data.
[0019] Optionally, the target strain data is subjected to median difference processing to obtain median difference strain data, comprising:
[0020] For any of the time windows, the target strain data in the time window is obtained;
[0021] According to the target strain data, the median of the target strain data is determined;
[0022] For any of the target strain data, according to the target strain data and the median of the target strain data, the median difference strain data is determined.
[0023] Optionally, the median difference strain data is converted into a gray image, comprising:
[0024] The median difference strain data is normalized to obtain normalized median difference strain data;
[0025] The normalized median difference strain data is converted into polar coordinates, wherein the polar coordinates comprise a polar angle;
[0026] A target matrix is constructed according to the polar angle;
[0027] convert the target matrix into a gray image.
[0028] Optionally, the normalization processing on the median differential strain data comprises:
[0029] determining first target median differential strain data and second target median differential strain data according to the median differential strain data;
[0030] for any of the median differential strain data, determining the normalized median differential strain data according to the median differential strain data, the first target median differential strain data and the second target median differential strain data.
[0031] Optionally, the identification on the gray image comprises:
[0032] inputting the gray image into a pre-generated battery cell fault detection model to obtain a fault detection result label;
[0033] if the fault detection result label is a preset first value, determining that the fault detection result of the battery cell is that the battery cell has a fault;
[0034] if the fault detection result label is a preset second value, determining that the fault detection result of the battery cell is that the battery cell has no fault.
[0035] In a second aspect, an embodiment of the present application provides a battery fault detection device applied to a vehicle, the vehicle comprising a battery cell, and the device comprising:
[0036] a data acquisition module configured to acquire target strain data of any of the battery cells, wherein the target strain data is a relative change amount of length, and the target strain data is a ratio of a change amount of length to an original length;
[0037] a data processing module configured to perform median differential processing on the target strain data to obtain median differential strain data;
[0038] a data conversion module configured to convert the median differential strain data into a gray image;
[0039] The model processing module is configured to input the grayscale image into a pre-generated battery cell fault detection model to obtain a fault detection result label, wherein the pre-generated battery cell fault detection model is a visual Transformer model, the visual Transformer model has the ability to capture global dependency information of an image, extracts global features of the grayscale image and local features of the grayscale image from the input grayscale image based on a self-attention mechanism, and determines the fault detection result label according to the global features of the grayscale image and the local features of the grayscale image.
[0040] The first fault detection module is configured to determine that the fault detection result of the battery cell is that the battery cell has a fault if the fault detection result label is a preset first numerical value.
[0041] The second fault detection module is configured to determine that the fault detection result of the battery cell is that the battery cell does not have a fault if the fault detection result label is a preset second numerical value.
[0042] Optionally, the data acquisition module comprises:
[0043] The initial data acquisition submodule is configured to acquire initial strain data of any battery cell.
[0044] The down-sampling processing submodule is configured to perform down-sampling processing on the initial strain data to obtain target strain data.
[0045] Optionally, the down-sampling processing submodule comprises:
[0046] The initial strain data acquisition unit is configured to acquire, for any preset time window, a length of the time window and the initial strain data in the time window.
[0047] The average value operation unit is configured to determine an average value of the initial strain data according to the length of the time window and the initial strain data in the time window.
[0048] The target strain data determination unit is configured to take the average value of the initial strain data as target strain data.
[0049] Optionally, the data processing module comprises:
[0050] The target strain data acquisition unit is configured to acquire, for any preset time window, the target strain data in the time window.
[0051] The median processing unit is configured to determine a median value of the target strain data according to the target strain data.
[0052] a differential processing unit configured to determine, for any of the target strain data, median differential strain data according to the target strain data and a median value of the target strain data.
[0053] Optionally, the data conversion module comprises:
[0054] a normalization processing submodule configured to perform normalization processing on the median differential strain data to obtain normalized median differential strain data;
[0055] a polar coordinate conversion submodule configured to convert the normalized median differential strain data into polar coordinates, wherein the polar coordinates comprise a polar angle;
[0056] a matrix construction submodule configured to construct a target matrix according to the polar angle;
[0057] an image determination submodule configured to convert the target matrix into a grayscale image.
[0058] Optionally, the normalization processing submodule comprises:
[0059] a target median differential strain data determination unit configured to determine first target median differential strain data and second target median differential strain data according to the median differential strain data;
[0060] a normalization processing unit configured to determine, for any of the median differential strain data, normalized median differential strain data according to the median differential strain data, the first target median differential strain data, and the second target median differential strain data.
[0061] In a third aspect, an embodiment of the present application further provides an electronic device, comprising: a processor; and a memory for storing instructions executable by the processor, wherein the processor is configured to execute the instructions to implement the battery fault detection method according to any of the above.
[0062] In a fourth aspect, an embodiment of the present application further provides a storage medium, when instructions in the storage medium are executed by a processor of an electronic device, the electronic device is enabled to perform the battery fault detection method according to any of the above.
[0063] In the embodiment of the present application, the target strain data of any battery monomer is acquired, the target strain data is subjected to median difference processing to obtain median difference strain data, the median difference strain data is converted into a gray image, the gray image is recognized to obtain a fault detection result of the battery monomer. The present application introduces the target strain data of the battery monomer, which can capture the dynamic mechanical characteristics of the battery monomer in the running process. The target strain data is subjected to median difference processing, which can effectively remove the noise in the target strain data and highlight the change trend of the target strain data. The median difference strain data is converted into a gray image to improve the divisibility of the fault. Finally, the gray image is recognized to obtain the fault detection result of the battery monomer, which can identify the small fault of the battery monomer, thereby improving the accuracy of battery fault detection.
[0064] The above description is only a summary of the technical scheme of the present application. In order to more clearly understand the technical means of the present application, the content of the specification can be implemented, and in order to make the above and other purposes, characteristics and advantages of the present application more obvious and easy to understand, the following specific embodiments of the present application are described. BRIEF DESCRIPTION OF DRAWINGS
[0065] Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The accompanying drawings are included to provide a description of the preferred embodiments and are not meant to limit the present application. Moreover, the same reference numerals in the attached drawings refer to the same or similar components. In the drawings:
[0066] Figure 1 is a step flow chart of a battery fault detection method provided by an embodiment of the present application;
[0067] Figure 2 is a device block diagram of a battery fault detection device provided by an embodiment of the present application;
[0068] Figure 3 is a structure diagram of an electronic device provided by an embodiment of the present application;
[0069] Figure 4 is a schematic diagram of a gray image provided by an embodiment of the present application;
[0070] Figure 5 is one of the schematic diagrams of detecting a gray image provided by an embodiment of the present application;
[0071] Figure 6 is the second schematic diagram of detecting a gray image provided by an embodiment of the present application. DETAILED DESCRIPTION
[0072] Exemplary embodiments of the present application will be described in greater detail below with reference to the accompanying drawings. While exemplary embodiments of the present application are shown in the drawings, it is understood that the present application can be embodied in various forms and should not be limited by the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the application to those skilled in the art.
[0073] A battery fault detection method, device, electronic equipment and storage medium provided by an embodiment of the present application will be described in detail below with reference to the accompanying drawings in combination with a specific embodiment and its application scenario.
[0074] Figure 1 is a step flowchart of a battery fault detection method provided by an embodiment of the present application, as shown in the figure, the method comprises: Figure 1
[0075] Step 101, obtaining target strain data of any battery monomer, wherein the target strain data is a relative change amount of length, and the target strain data is a ratio of a change amount of length to an original length.
[0076] Step 102, performing median difference processing on the target strain data to obtain median difference strain data.
[0077] Step 103, converting the median difference strain data into a gray-scale image.
[0078] Step 104, inputting the gray-scale image into a pre-generated battery monomer fault detection model to obtain a fault detection result label, wherein the pre-generated battery monomer fault detection model is a visual Transformer model, the visual Transformer model has the ability to capture global dependency information of an image, extracts global features of the gray-scale image and local features of the gray-scale image from the input gray-scale image based on a self-attention mechanism, and determines the fault detection result label according to the global features of the gray-scale image and the local features of the gray-scale image.
[0079] Step 105, if the fault detection result label is a preset first numerical value, determining that the fault detection result of the battery monomer is that the battery monomer has failed.
[0080] Step 106, if the fault detection result label is a preset second numerical value, determining that the fault detection result of the battery monomer is that the battery monomer has not failed.
[0081] In some embodiments of the present application, the battery in the vehicle comprises a plurality of battery modules, and any battery module comprises a plurality of battery monomers. The strain data refers to a relative change amount of length, wherein strain data = change amount of length / original length.
[0082] The target strain data of the battery cell refers to data obtained by down-sampling the initial strain data of the battery cell.
[0083] The target strain data of the battery cell is obtained for any battery cell. In order to capture the dynamic mechanical properties of the battery cell, after obtaining the target strain data of the battery cell, the target strain data of the battery cell needs to be subjected to median difference processing to obtain median difference strain data.
[0084] In order to be able to detect the micro-failure of the battery cell, after obtaining the median difference strain data, the median difference strain data can be converted into a two-dimensional gray image.
[0085] The pre-generated battery cell failure detection model can be a visual Transformer model, which is a classification model. The visual Transformer model has the ability to capture global dependency information of an image, can perform deep feature extraction on the input gray image based on a self-attention mechanism, including extracting global features of the gray image and extracting local features of the gray image, and further obtains a classification output result corresponding to the gray image, that is, a failure detection result label.
[0086] After obtaining the gray image, the obtained gray image is input into the pre-generated battery cell failure detection model as an input of the battery cell failure detection model, and the battery cell failure detection model can automatically output the failure detection result label.
[0087] After obtaining the failure detection result label, whether the battery cell has failed is determined according to the failure detection result label, that is, the failure detection result of the battery cell is determined. The first preset value can be 1. If the failure detection result label is 1, it means that the battery cell has failed, and it is determined that the failure detection result of the battery cell is that the battery cell has failed. The second preset value can be 0. If the failure detection result label is 0, it means that the battery cell has not failed, and it is determined that the failure detection result of the battery cell is that the battery cell has not failed.
[0088] Each pixel point in the gray image represents the time sequence phase relationship between two time periods, that is, the dynamic change mode of the strain of the battery cell at different time intervals. The bright color area (high gray level) represents positive correlation (that is, similar change trend), and the dark color area (low gray level) represents negative correlation (that is, opposite change trend).
[0089] For example, Figure 5As shown, the original image img1 has a stable grayscale distribution and uniform texture, indicating that the temporal characteristics of the strain data of the battery cell are normal. Therefore, the original image img1 is a grayscale image obtained based on the target strain data of a normal battery cell, and is a normal grayscale image. The original image img1 is used as input to a pre-generated battery cell fault detection model. The model performs deep feature extraction on the input original image img1, including extracting global and local features. Gradients are extracted from these features, and the average is calculated based on the weighted gradient strength. The weights are then back-mapped back to the input original image img1 to obtain a heatmap corresponding to img1, i.e., the img1 heatmap. Since brighter colors (displayed as red or yellow) in the heatmap contribute more to the battery cell fault detection model's judgment of battery cell failure,... Since the heatmap of img1 is almost entirely blue, the battery cell fault detection model believes that there are no obvious fault features in the heatmap of img1. The original image of img1 is a normal grayscale image, and the battery cell is in a healthy state. Therefore, it will output the fault detection result label 0, indicating that the battery cell has not failed.
[0090] like Figure 6 As shown, the original image img2 exhibits obvious blocky and abrupt textures, indicating that the temporal characteristics of the strain data of the battery cell have undergone abnormal changes. Therefore, the original image img2 is a grayscale image obtained based on the target strain data of the faulty battery cell, and is an abnormal grayscale image. The original image img2 is used as input to a pre-generated battery cell fault detection model. The model performs deep feature extraction on the input original image img2, including extracting global and local features. Gradients are extracted from these features, and a weighted average is calculated based on the gradient strength. The weights are then back-mapped back to the input original image img2 to obtain a heatmap corresponding to the original image img2, i.e., the img2 heatmap. Since brighter colors (displayed as red or yellow) in the heatmap contribute more to the battery cell fault detection model's judgment of battery cell failure, the heatmap is more effective. The obvious red and yellow blocks in the upper right and lower left corners of the img2 heatmap indicate that the time-series characteristics of the strain data in these areas are the most abnormal. The battery cell fault detection model will judge that the original image of img2 is an abnormal grayscale image based on these characteristics. If the battery cell fails, it will output the fault detection result label 1, indicating that the battery cell has failed.
[0091] In addition, the specific implementation process of identifying the gray image to obtain the fault detection result of the battery monomer can further be: pre-processing the gray image to obtain a pre-processed gray image, wherein the pre-processing can include denoising, contrast enhancement, image segmentation, etc. Extracting image features related to the battery monomer fault from the pre-processed gray image, wherein the image features can be edge features of the image, texture features of the image, geometric features of the image, etc. Comparing the extracted image features with preset threshold values respectively. If the extracted image features exceed the preset threshold values, it is determined that the battery monomer has a fault; if the extracted image features are lower than the preset threshold values, it is determined that the battery monomer has no fault.
[0092] The application introduces target strain data of the battery monomer, which can capture the dynamic mechanical properties of the battery monomer during operation. The median difference processing of the target strain data can effectively remove noise in the target strain data and highlight the change trend of the target strain data. The median difference strain data is converted into a gray image to improve the divisibility of the fault. Finally, identifying the gray image to obtain the fault detection result of the battery monomer can identify the small fault of the battery monomer, thereby improving the accuracy of the battery fault detection. In addition, the application inputs the gray image into the pre-generated battery monomer fault detection model to realize the automation of the battery monomer fault detection, reduces the manual intervention, and improves the efficiency of the battery monomer fault detection. In addition, the first and second values are preset as the fault detection result labels, which clearly defines the judgment standard of the battery monomer fault and the battery monomer no fault, ensuring the definiteness and consistency of the battery monomer fault detection result.
[0093] Further, in some embodiments of the application, step 101 can further include the following steps:
[0094] Step 1011, obtaining initial strain data of any battery monomer.
[0095] Step 1012, performing down-sampling processing on the initial strain data to obtain target strain data.
[0096] In some embodiments of the application, a strain gauge is attached to each battery monomer in advance. For any battery monomer, the initial strain data of the battery monomer is obtained through the strain gauge. After obtaining the initial strain data of the battery monomer, the initial strain data of the battery monomer is subjected to down-sampling processing, and the initial strain data after down-sampling processing is the target strain data.
[0097] In addition, after obtaining the initial strain data of all battery monomers, a dynamic battery database can be established according to the initial strain data of all battery monomers.
[0098] The application can effectively reduce the data amount of the initial strain data, retain the main features of the initial strain data, make the subsequent strain data processing and analysis more efficient, and reduce the consumption of computing resources by downsampling the initial strain data of the battery cell.
[0099] Further, in some embodiments of the application, step 1012 can further include the following steps:
[0100] Sub-step 11: For any preset time window, the length of the time window and the initial strain data in the time window are obtained.
[0101] Sub-step 12: The average value of the initial strain data is determined according to the length of the time window and the initial strain data in the time window.
[0102] Sub-step 13: The average value of the initial strain data is taken as the target strain data.
[0103] In some embodiments of the application, the downsampling processing refers to reducing the sampling frequency, for example: originally w data are collected in a period of time, now 1 data is used to replace, and the 1 data is equal to the average value of the originally collected w data.
[0104] The specific implementation process of downsampling the initial strain data to obtain the target strain data is as follows: a time window is set in advance. For any preset time window, the length of the time window and the initial strain data in the time window are obtained. The average value of all initial strain data in the time window is calculated according to the length of the time window and the initial strain data in the time window, to obtain the average value of the initial strain data. After obtaining the average value of the initial strain data, the average value of the initial strain data is taken as the target strain data.
[0105] The formula of the downsampling processing is shown in formula (1):
[0106] Formula (1)
[0107] Wherein, is the time window, is the i-th time window, is the initial strain data, is the average value of the initial strain data in the i-th time window, is the length of the time window, is the i-th initial strain data in the i-th time window.
[0108] For example, if the length of the time window is 3, and the initial strain data is 1, 2, 3, 4, 5, 6, the average value of all initial strain data in the first time window can be calculated by using the above formula (1) as ; the average value of all initial strain data in the second time window is . In this way, one average value of initial strain data can replace the original three initial strain data, and the initial strain data is completed by the downsampling processing.
[0109] By taking the average value of the initial strain data as the target strain data, i.e., replacing the original multiple initial strain data in the time window with one average value of initial strain data, the application can effectively reduce the redundancy of the initial strain data, while retaining the overall trend and characteristics of the initial strain data, and improving the stability and reliability of the initial strain data.
[0110] Further, in some embodiments of the application, step 102 can further include the following steps:
[0111] Step 1021, for any time window, obtaining the target strain data in the time window.
[0112] Step 1022, determining the median value of the target strain data according to the target strain data.
[0113] Step 1023, for any target strain data, determining the median difference strain data according to the target strain data and the median value of the target strain data.
[0114] In some embodiments of the application, the specific implementation process of performing median difference processing on the target strain data to obtain the median difference strain data is as follows: for any time window, obtaining all target strain data in the time window. After obtaining all target strain data in the time window, all target strain data are sorted in ascending order (or in descending order). After sorting, the number of all target strain data is obtained. If the number of all target strain data is odd, the median value of the target strain data is the middle target strain data. If the number of all target strain data is even, the median value of the target strain data is the average value of the middle two target strain data. For any target strain data in the time window, the target strain data and the median value of the target strain data are difference operated, and the median difference strain data is obtained.
[0115] The formula of the median difference processing is shown in formula (2) and formula (3):
[0116] Formula (2)
[0117] Wherein, T is the time window, the first time window, the first time window, the first time window, the first time window,
[0118] Equation (3)
[0119] wherein U is any target strain data in the first time window, the first time window, the first time window, the first time window, a preset proportion parameter, a standard deviation of all target strain data, and CDP is a median differential strain data calculated for any target strain data in the first time window.
[0120] The application can remove abnormal values and noises in the target strain data by calculating the median of the target strain data, thereby enhancing the robustness of the target strain data. In addition, the application can quantify the deviation of each target strain data relative to the median of the target strain data by calculating the difference between the target strain data and the median of the target strain data, thereby facilitating the analysis of the volatility and abnormality of the target strain data.
[0121] Further, in some embodiments of the application, step 103 can further include the following steps:
[0122] Step 1031, performing normalization processing on the median differential strain data to obtain normalized median differential strain data.
[0123] Step 1032, converting the normalized median differential strain data into polar coordinates, wherein the polar coordinates include a polar angle.
[0124] Step 1033, constructing a target matrix according to the polar angle.
[0125] Step 1034, converting the target matrix into a gray-scale image.
[0126] In some embodiments of the application, the time series data is encoded into a two-dimensional image by the GADF (Gramian Angular Difference Field) method, which retains the time dependence and sequence structure of the original data. By analyzing the texture and pattern of the image, it is easier to identify the abnormalities and rules in the original time series data.
[0127] The specific implementation process of converting the median differential strain data into a gray image is: performing normalization processing on the median differential strain data to obtain normalized median differential strain data. The normalized median differential strain data is converted into a gray image by using GADF, wherein the normalized median differential strain data is converted into polar coordinates according to formula (4) as follows. A two-dimensional Gram matrix is constructed according to the polar angle in the polar coordinates, and the constructed two-dimensional Gram matrix is the target matrix, as shown in formula (5). The numerical value of any row and any column in the target matrix is converted into a gray value according to formula (6) as follows, and after all values in the target matrix are converted into gray values, a gray image is generated according to all the gray values.
[0128] Formula (4)
[0129] wherein, is the normalized median differential strain data, arccos is an inverse trigonometric cosine function, is the polar angle of the normalized median differential strain data in the polar coordinate system, and the value range is 0-π, is the normalized median differential strain data, arccos is an inverse trigonometric cosine function, is the polar angle of the normalized median differential strain data in the polar coordinate system, and the value range is 0-π, is the normalized median differential strain data, arccos is an inverse trigonometric cosine function, is the time stamp or index corresponding to the normalized median differential strain data, is the total length of the normalized median differential strain data, is the radial component in the polar coordinate system.
[0130] Formula (5)
[0131] wherein, GADF is a target matrix, is the polar angle of the normalized median differential strain data in the polar coordinate system, and the value range is 0-π.
[0132] Formula (6)
[0133] wherein, is the numerical value of the i-th row and the j-th column in the target matrix, int is a down rounding, and is used to convert a floating-point gray value into an image pixel gray value, is the numerical value of the i-th row and the j-th column in the target matrix, int is a down rounding, and is used to convert a floating-point gray value into an image pixel gray value, is the gray value corresponding to the numerical value of the i-th row and the j-th column in the target matrix.
[0134] The specific implementation process of converting the median differential strain data into a gray image can also be: normalizing the median differential strain data to the range of [0, 1] to obtain normalized median differential strain data. Mapping the normalized median differential strain data to the pixel value range (0-255) of the gray image. Filling the pixel value into the image matrix to generate a gray image.
[0135] In addition, steps 1031-1034 are exemplified as follows:
[0136] If the median differential strain data are 23.207, 27.228, 27.035, and 28.279, the normalized median differential strain data obtained by normalizing these median differential strain data are 0.14276, 0.167495, 0.166308, and 0.173961, respectively.
[0137] The normalized median differential strain data obtained are converted into polar coordinates respectively, and each polar coordinate includes a polar angle. The polar angles in these polar coordinates are 2.51185, 2.50209, 2.50256, and 2.49956, respectively.
[0138] The target matrix is constructed according to the polar angles in the polar coordinates, and the constructed target matrix is as follows:
[0139]
[0140] The target matrix constructed as described above is converted into a gray image, and the obtained gray image is as shown in Figure 4 .
[0141] The present application can eliminate the influence of the data dimension by normalizing the median differential strain data, and ensure that the data can maintain consistent scale in subsequent polar coordinate conversion. In addition, the present application converts the normalized median differential strain data into polar coordinates, constructs a target matrix according to the polar angles in the polar coordinates, and then converts the target matrix into a gray image, which realizes the conversion of one-dimensional normalized median differential strain data into a two-dimensional gray image, and facilitates subsequent fast and effective classification and recognition of the gray image.
[0142] Further, in some embodiments of the present application, step 1031 can further include the following steps:
[0143] Sub-step 21: determining first target median differential strain data and second target median differential strain data according to the median differential strain data.
[0144] In some embodiments of the present application, the first target median differential strain data can be the maximum median differential strain data among all the median differential strain data, and the second target median differential strain data can be the minimum median differential strain data among all the median differential strain data.
[0145] In some embodiments of the present application, the first target median differential strain data can be the maximum median differential strain data among all the median differential strain data, and the second target median differential strain data can be the minimum median differential strain data among all the median differential strain data.
[0146] The normalization processing refers to mapping the data into a specific interval range, which can be [-1, 1]. The specific implementation process of normalizing the median differential strain data to obtain the normalized median differential strain data is as follows: determining the first target median differential strain data and the second target median differential strain data according to all the median differential strain data. For any median differential strain data, the normalized median differential strain data can be determined according to the median differential strain data, the first target median differential strain data and the second target median differential strain data.
[0147] The formula of the normalization processing is shown in formula (7):
[0148] Formula (7)
[0149] wherein CDP is any median differential strain data, is a sequence composed of all the median differential strain data, is the minimum median differential strain data among all the median differential strain data, is the maximum median differential strain data among all the median differential strain data, is the normalized median differential strain data.
[0150] The present application specifies the input of the normalization processing by determining the first target median differential strain data and the second target median differential strain data according to the median differential strain data, ensuring the consistency and repeatability of the normalization processing procedure. In addition, the present application maps the value range of the median differential strain data to a specific interval by determining the normalized median differential strain data according to the median differential strain data, the first target median differential strain data and the second target median differential strain data, realizes the unification of the range of the median differential strain data, and facilitates subsequent analysis and processing.
[0151] In some embodiments of the present application, in order to illustrate the effectiveness of the embodiments of the present application, an overcharge experiment data of a battery module is prepared in advance, the battery module includes 6 battery monomers, and the 6 battery monomers are judged to have thermal runaway by the national standard thermal runaway judgment standard. Through testing, using the embodiments of the present application, the battery monomers that have thermal runaway can be diagnosed as having faults, a total of 6 battery monomers are predicted to have faults, no false negatives occur, and each battery monomer can be individually diagnosed as normal or faulty. Therefore, while detecting battery faults, the positioning of faulty battery monomers is realized.
[0152] Corresponding to the method provided by the battery fault detection method embodiments of the present application described above, referring to Figure 2 The present application also provides a device block diagram of a battery fault detection device, in the present embodiment, the device includes:
[0153] The data acquisition module 201 is configured to acquire target strain data of any battery monomer, wherein the target strain data is a relative change amount of length, and the target strain data is a ratio of a change amount of length to an original length;
[0154] The data processing module 202 is configured to perform median difference processing on the target strain data to obtain median difference strain data;
[0155] The data conversion module 203 is configured to convert the median difference strain data into a grayscale image;
[0156] The model processing module 204 is configured to input the grayscale image into a pre-generated battery monomer fault detection model to obtain a fault detection result label, wherein the pre-generated battery monomer fault detection model is a visual Transformer model, the visual Transformer model has the ability to capture global dependency information of an image, extracts global features of the grayscale image and local features of the grayscale image from the input grayscale image based on a self-attention mechanism, and determines the fault detection result label according to the global features of the grayscale image and the local features of the grayscale image;
[0157] The first fault detection module 205 is configured to determine that the fault detection result of the battery monomer is that the battery monomer has a fault if the fault detection result label is a preset first numerical value;
[0158] The second fault detection module 206 is configured to determine that the fault detection result of the battery monomer is that the battery monomer does not have a fault if the fault detection result label is a preset second numerical value.
[0159] Optionally, the data acquisition module 201 includes:
[0160] An initial data acquisition submodule is configured to acquire initial strain data of any battery monomer.
[0161] A downsampling processing submodule is configured to perform downsampling processing on the initial strain data to obtain target strain data.
[0162] Optionally, the downsampling processing submodule comprises:
[0163] An initial strain data acquisition unit is configured to, for any preset time window, acquire a length of the time window and initial strain data in the time window.
[0164] An average value operation unit is configured to determine an average value of the initial strain data according to the length of the time window and the initial strain data in the time window.
[0165] A target strain data determination unit is configured to take the average value of the initial strain data as the target strain data.
[0166] Optionally, the data processing module 202 comprises:
[0167] A target strain data acquisition unit is configured to, for any time window, acquire target strain data in the time window.
[0168] A median processing unit is configured to determine a median value of the target strain data according to the target strain data.
[0169] A difference processing unit is configured to, for any target strain data, determine median difference strain data according to the target strain data and the median value of the target strain data.
[0170] Optionally, the data conversion module 203 comprises:
[0171] A normalization processing submodule is configured to perform normalization processing on the median difference strain data to obtain normalized median difference strain data.
[0172] A polar coordinate conversion submodule is configured to convert the normalized median difference strain data into polar coordinates, wherein the polar coordinates comprise a polar angle.
[0173] A matrix construction submodule is configured to construct a target matrix according to the polar angle.
[0174] An image determination submodule is configured to convert the target matrix into a grayscale image.
[0175] Optionally, the normalization processing submodule comprises:
[0176] A target median difference strain data determination unit is configured to determine first target median difference strain data and second target median difference strain data according to the median difference strain data.
[0177] The normalization processing unit is configured to determine normalized median differential strain data according to the median differential strain data, the first target median differential strain data, and the second target median differential strain data for any median differential strain data.
[0178] Figure 3 is a structural diagram of an electronic device M00 provided by an embodiment of the present application. In the diagram, the electronic device M00 includes a processor M01 and a memory M02. The memory M02 stores a program or instructions that can run on the processor M01. The program or instructions are executed by the processor M01 to implement each step of the battery fault detection method embodiment described above and achieve the same technical effects. To avoid repetition, no further elaboration is provided here.
[0179] In an embodiment of the present application, the memory M02 can be used to store software programs and various data. The memory M02 can mainly include a first storage area storing programs or instructions and a second storage area storing data. The first storage area can store an operating system, application programs or instructions required by at least one function (such as a sound playing function, an image playing function, etc.), and the like. In addition, the memory M02 can include a volatile memory or a non-volatile memory, or the memory M02 can include both volatile and non-volatile memories. The non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory can be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDR SDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synch link dynamic random access memory (SLDRAM), and a direct memory bus random access memory (Direct Rambus RAM, DRRAM). The memory M02 in the embodiment of the present application includes but is not limited to these and any other suitable types of memories.
[0180] The processor M01 can include one or more processing units; optionally, the processor M01 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to operating systems, user interfaces, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It can be understood that the above-mentioned modem processor can also not be integrated into the processor M01.
[0181] The embodiments of the application further provide a storage medium, which has a program or instructions stored thereon, and the program or instructions are executed by a processor to implement each process of the above-mentioned battery fault detection method embodiments and achieve the same technical effects. To avoid repetition, details are not described herein.
[0182] The processor is the processor in the electronic device in the above-mentioned embodiments. The storage medium includes a computer readable storage medium, such as a computer readable only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0183] From the above description of the embodiments, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software and a general hardware platform, and of course, they can also be implemented by hardware, but in many cases, the former is a better embodiment. Based on this understanding, the technical solutions of the application can be embodied in the form of a computer software product, which is stored in a storage medium (such as a ROM / RAM, a magnetic disk, or an optical disk) and includes a plurality of instructions for causing a terminal (which can be a mobile phone, a computer, a server, or a network device) to execute the methods described in the embodiments of the application.
[0184] The embodiments of the application are described above in combination with the drawings, but the application is not limited to the above-mentioned specific embodiments, and the above-mentioned specific embodiments are only illustrative and not limiting. Those skilled in the art can make many forms under the inspiration of the application without departing from the scope of the application and the protection scope of the claims.
Claims
1. A battery fault detection method, characterized in that, Applied to a vehicle, the vehicle including a battery cell, the method includes: Obtain target strain data for any of the aforementioned battery cells, wherein the target strain data is the relative change in length, and the target strain data is the ratio of the change in length to the original length; The target strain data is subjected to median differencing to obtain median differencing strain data; The median differential strain data is converted into a grayscale image; The grayscale image is input into a pre-generated battery cell fault detection model to obtain fault detection result labels. The pre-generated battery cell fault detection model is a visual Transformer model, which has the ability to capture global dependency information of the image. Based on a self-attention mechanism, the global features and local features of the grayscale image are extracted from the input grayscale image. The fault detection result labels are determined based on the global features and local features of the grayscale image. If the fault detection result label is a preset first value, then the fault detection result of the battery cell is determined to be that the battery cell has failed. If the fault detection result label is a preset second value, then the fault detection result of the battery cell is determined to be that the battery cell has not failed. The step of performing median differencing on the target strain data to obtain median differencing strain data includes: For any given time window, acquire the target strain data within that time window; Determine the median value of the target strain data based on the target strain data; For any of the target strain data, the difference between the target strain data and the median of the target strain data is calculated to obtain the median differential strain data.
2. The method according to claim 1, characterized in that, The acquisition of target strain data for any of the battery cells includes: Obtain the initial strain data of any one of the battery cells; The initial strain data is downsampled to obtain the target strain data.
3. The method according to claim 2, characterized in that, The downsampling process of the initial strain data to obtain the target strain data includes: For any preset time window, obtain the length of the time window and the initial strain data within the time window; The average value of the initial strain data is determined based on the length of the time window and the initial strain data within the time window; The average value of the initial strain data is used as the target strain data.
4. The method according to claim 1, characterized in that, The step of converting the median difference strain data into a grayscale image includes: The median differential strain data is normalized to obtain the normalized median differential strain data. The normalized median difference strain data is converted into polar coordinates, wherein the polar coordinates include polar angles; Construct the target matrix based on the polar angle; The target matrix is converted into a grayscale image.
5. The method according to claim 4, characterized in that, The normalization process for the median differential strain data to obtain the normalized median differential strain data includes: The first target median differential strain data and the second target median differential strain data are determined based on the median differential strain data. For any of the aforementioned median differential strain data, the normalized median differential strain data is determined based on the median differential strain data, the first target median differential strain data, and the second target median differential strain data.
6. A battery fault detection device, characterized in that, Applied to a vehicle, the vehicle including a battery cell, the device includes: The data acquisition module is configured to acquire target strain data of any of the battery cells, wherein the target strain data is the relative change in length and the target strain data is the ratio of the change in length to the original length. The data processing module is configured to perform median difference processing on the target strain data to obtain median difference strain data; The data conversion module is configured to convert the median differential strain data into a grayscale image; The model processing module is configured to input the grayscale image into a pre-generated battery cell fault detection model to obtain a fault detection result label. The pre-generated battery cell fault detection model is a visual Transformer model, which has the ability to capture global dependency information of the image. Based on a self-attention mechanism, it extracts the global features and local features of the grayscale image from the input grayscale image, and determines the fault detection result label based on the global features and local features of the grayscale image. The first fault detection module is configured to determine that the fault detection result of the battery cell is a fault if the fault detection result label is a preset first value. The second fault detection module is configured to determine that the fault detection result of the battery cell is that the battery cell has not failed if the fault detection result label is a preset second value. The data processing module includes: The target strain data acquisition unit is configured to acquire the target strain data within any given time window. A median processing unit is configured to determine the median of the target strain data based on the target strain data. The differential processing unit is configured to perform a difference operation on the target strain data and the median of the target strain data for any of the target strain data to obtain median differential strain data.
7. An electronic device, characterized in that, include: processor; Memory used to store the processor's executable instructions; The processor is configured to execute the instructions to implement the battery fault detection method as described in any one of claims 1 to 5.
8. A storage medium, characterized in that, When the instructions in the storage medium are executed by the processor of the electronic device, the electronic device is able to perform the battery fault detection method as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Lithium ion battery health state estimation and life prediction method considering mechanical strain
CN113504482A
Battery fault detection model construction method and device and battery fault detection method and device
CN117849627A