Residual electric quantity detection method, energy storage power supply and storage medium

By pruning and quantizing the deep learning model, a lightweight power detection model is generated. Combined with operating current and temperature parameters, it performs real-time detection, solving the problems of error accumulation and resource constraints in the ampere-hour integration method, and achieving high-precision and low-cost power detection.

CN121069220APending Publication Date: 2025-12-05SHENZHEN HELLO TECH ENERGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511103487.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-06
Publication Date
2025-12-05

AI Technical Summary

Technical Problem

In existing technologies, the ampere-hour integration method leads to the accumulation of errors in the measurement of remaining battery capacity, affecting measurement accuracy. Furthermore, deep learning models are difficult to deploy on resource-constrained energy storage power sources, resulting in excessive computational and storage burdens.

Method used

By pruning and quantizing the deep learning model, a lightweight first-level power detection model is generated and deployed on the processor of the energy storage power supply. It combines operating current and temperature parameters for real-time detection, reducing reliance on cloud servers.

Benefits of technology

It improves the accuracy and real-time performance of remaining power measurement, reduces hardware costs and energy consumption, adapts to embedded hardware environments, and enhances data security and privacy protection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121069220A_ABST
    Figure CN121069220A_ABST
Patent Text Reader

Abstract

The invention discloses a residual electric quantity detection method, an energy storage power supply and a storage medium, the energy storage power supply is provided with a first electric quantity detection model, the first electric quantity detection model is generated by pruning and quantifying a second electric quantity detection model, and the model volume of the first electric quantity detection model is smaller than that of the second electric quantity detection model. The method comprises the following steps: acquiring operation parameters of an energy storage power supply in a first preset duration, wherein the operation parameters comprise working current and working temperature; and based on the first electric quantity detection model, processing the operation parameters within the first preset duration to output the current remaining electric quantity of the energy storage power supply, thereby solving the problem that a deep learning model capable of detecting the current remaining electric quantity is difficult to deploy on the energy storage power supply with limited resources, reducing the dependence on a cloud server, and improving the user experience. The calculation and storage burden is reduced, so that the hardware cost and energy consumption are reduced, the current residual electric quantity of the energy storage power supply is calculated by using the model, and the calculation precision and accuracy of the residual electric quantity can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of energy storage power supply, and in particular to a remaining power detection method, an energy storage power supply and a nonvolatile computer readable storage medium containing a computer program. BACKGROUND

[0002] The state of charge (SOC) of a battery is an important indicator for measuring the current remaining energy of the battery or energy storage system. In related technologies, the SOC value of the battery is usually calculated by ampere-hour integration method. However, the ampere-hour integration method will cause measurement error accumulation due to long-time integration, thereby affecting the measurement accuracy. SUMMARY

[0003] The embodiments of the present application provide a remaining power detection method, an energy storage power supply and a storage medium to solve at least one of the above technical problems.

[0004] In a first aspect, the present application provides a remaining power detection method for an energy storage power supply, wherein the energy storage power supply is deployed with a first power detection model, the first power detection model is generated by pruning and quantizing a second power detection model, the model volume of the first power detection model is smaller than that of the second power detection model, and the method comprises:

[0005] Collecting running parameters of the energy storage power supply within a first preset time period, wherein the running parameters include working current and working temperature;

[0006] Processing the running parameters within the first preset time period based on the first power detection model to output the current remaining power of the energy storage power supply.

[0007] In a second aspect, the present application provides an energy storage power supply, comprising:

[0008] A processor, wherein the first power detection model is deployed on the processor, and the processor is configured to execute the remaining power detection method according to any one of the above embodiments.

[0009] In a third aspect, the present application provides a nonvolatile computer readable storage medium containing a computer program, wherein the computer program is executed by a processor to make the processor execute the remaining power detection method according to any one of the above embodiments.

[0010] The remaining power detection method, the energy storage power supply and the storage medium of the embodiment of the application, the energy storage power supply is deployed with a first power detection model, the first power detection model is generated by pruning and quantizing a second power detection model, the model volume of the first power detection model is smaller than that of the second power detection model, since the volume of the first power detection model is smaller, it is more suitable for the processor hardware environment of the energy storage power supply, and has relatively lower calculation complexity and storage requirement, solving the problem that the deep learning model capable of detecting the current remaining power is difficult to deploy on the resource-limited energy storage power supply, reducing the dependence on the cloud server, reducing the burden of calculation and storage, thereby reducing the hardware cost and energy consumption; then the running parameters of the energy storage power supply within a first preset time period are collected, the running parameters including working current and working temperature; based on the first power detection model, the running parameters within the first preset time period are processed to output the current remaining power of the energy storage power supply, the current remaining power of the energy storage power supply is calculated by using the excellent fitting effect of the model on the data with multiple characteristics, multiple factors and strong nonlinear relationship, improving the measurement accuracy and accuracy of the remaining power, and improving the real-time performance and response speed of the remaining power detection.

[0011] Additional aspects and advantages of the application will be set forth in part in the description which follows, and in part will become apparent to those skilled in the art upon examination of the following and / or can be learned by practice of the application. BRIEF DESCRIPTION OF DRAWINGS

[0012] The above and / or additional aspects and advantages of the application will become apparent and be readily appreciated from the following description, taken in conjunction with the accompanying drawings, in which:

[0013] Figure 1 is a schematic diagram of an application scenario of the remaining power detection method of one embodiment of the application;

[0014] Figure 2 is a schematic diagram of a module of the energy storage power supply of one embodiment of the application;

[0015] Figure 3 is a flowchart of the remaining power detection method of one embodiment of the application;

[0016] Figure 4 is a flowchart of the remaining power detection method of one embodiment of the application;

[0017] Figure 5 is a flowchart of the remaining power detection method of one embodiment of the application;

[0018] Figure 6 is a flowchart of the remaining power detection method of one embodiment of the application;

[0019] Figure 7is a flowchart of a method for detecting a remaining power level according to an embodiment of the present application;

[0020] Figure 8 is a module diagram of a device for detecting a remaining power level according to some embodiments of the present application;

[0021] Figure 9 is a connection state diagram of a non-volatile computer readable storage medium and a processor according to some embodiments of the present application. DETAILED DESCRIPTION

[0022] Embodiments of the present application are described in detail below with reference to the accompanying drawings, in which the same or similar components have the same or similar designations and functions throughout the various figures and embodiments. The embodiments described below are examples of the present application, and are not intended to limit the present application.

[0023] In the description of the present application, it is to be understood that the orientations or positional relationships indicated by the terms "center", "longitudinal", "lateral", "length", "width", "thickness", "upper", "lower", "front", "rear", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", "clockwise", "counterclockwise", and the like are based on the orientations or positional relationships shown in the drawings, and are only for the convenience of describing the present application and simplifying the description, and therefore cannot be understood as indicating or implying that the devices or elements referred to must have a particular orientation, be constructed and operated in a particular orientation, and therefore cannot be understood as limiting the present application. In the description of the present application, the meaning of "a plurality of" is two or more, unless otherwise explicitly specified and limited.

[0024] In the description of the present application, it should be noted that, unless otherwise explicitly specified and limited, the terms "mounting", "connecting", and "connecting" should be understood broadly, for example, they can be fixedly connected, or detachably connected, or integrally connected. It can be a mechanical connection, or an electrical connection. It can be directly connected, or indirectly connected through an intermediate medium. It can be the internal communication of two elements or the interaction relationship between two elements. For those skilled in the art, the specific meaning of the above terms in the present application can be understood according to the specific circumstances.

[0025] In the present application, unless otherwise explicitly specified and limited, "on" or "under" of a first feature to a second feature can include that the first and second features are in direct contact, or can include that the first and second features are not in direct contact but are in contact through another feature between them. Moreover, "on", "above" and "over" of a first feature to a second feature includes that the first feature is directly above and obliquely above the second feature, or only indicates that the first feature is higher than the second feature in horizontal height. "Under", "below" and "underneath" of a first feature to a second feature includes that the first feature is directly below and obliquely below the second feature, or only indicates that the first feature is lower than the second feature in horizontal height.

[0026] The disclosure herein provides many different embodiments or examples for implementing different structures of the present application. For the purpose of simplification of the present application, components and settings of specific examples are described herein. Of course, they are only examples, and the purpose is not to limit the present application. In addition, the present application can repeatedly refer to numbers and / or letters in different examples, and such repetition is for the purpose of simplification and clarity, which itself does not indicate the relationship between the various embodiments and / or settings discussed. In addition, the present application provides examples of various specific processes and materials, but those of ordinary skill in the art can realize the application of other processes and / or the use of other materials.

[0027] Before the embodiments of the present application are described in detail, the related art is further introduced.

[0028] The state of charge (SOC) of a battery is an important indicator to measure the current remaining energy of the battery or energy storage system. The battery management system (BMS) of the battery controls the use and charging and discharging process of the battery by obtaining the SOC value, thereby prolonging the service life of the battery. Therefore, the accurate acquisition and management of SOC is directly related to the use efficiency and safety of the battery.

[0029] In the related art, the SOC value of a battery is usually calculated by an open circuit voltage method and an ampere-hour integration method. The open circuit voltage method establishes an OCV-SOC fitting mapping curve of the battery in an open circuit state, and then infers the SOC value of the battery based on the curve and the voltage of the battery. However, the SOC value of the battery is influenced by multiple factors such as environmental temperature, initial open circuit voltage, discharge rate, battery capacity, etc. If the accuracy of the measurement is to be ensured, the OCV-SOC fitting mapping curve needs to cover as many working conditions as possible, which is difficult for a tester to test all working conditions, and due to the polarization effect of the battery, the test time is longer, resulting in high time cost and complex operation in the early stage of constructing the OCV-SOC fitting mapping curve, and the temperature and capacity decay in the test process also affect the SOC accuracy. When the SOC value of the battery is measured by the ampere-hour integration method, the measurement error is accumulated due to long-time integration, thereby affecting the accuracy of the measurement.

[0030] Therefore, the present application provides a remaining power detection method and an energy storage power supply. Figure 1 As shown in FIG. 1, the energy storage power supply 100 provided by the present application can be applied to the application scenario as shown in FIG. 2, and the energy storage power supply 10 includes a processor 10 including an edge processing chip and / or an embedded processing chip. Figure 1

[0031] The energy storage power supply 100 can be, for example, a photovoltaic energy storage device, an electric vehicle, etc.

[0032] Optionally, the edge processing chip can be a processing chip based on the RISC-V open source instruction set architecture (an open source instruction set architecture based on a reduced instruction set), which can quickly process data close to a data source or a user end, and integrates an artificial intelligence (AI) acceleration function.

[0033] Optionally, the embedded processing chip can be a processing chip supporting a lightweight machine learning framework (TensorFlow Lite) embedded platform, and the embedded processing chip has certain computing power and resources (such as computing power, memory, etc.), and can run a first power detection model to realize data processing and SOC value prediction without relying on cloud computing.

[0034] Optionally, the processor 10 can be, for example, a microcontroller unit (MCU) (a microcomputer chip integrating a central processing unit (CPU), memory, input / output (I / O) interface, etc.), a digital signal processor (DSP) (a processor for digital signal processing), etc.

[0035] ​The energy storage power supply 100 further comprises a current sensor 20, which can include a Hall sensor and an analog-to-digital converter (ADC). The Hall sensor can collect the current of the energy storage power supply 100 during charging and discharging and output a corresponding current signal. The analog-to-digital converter can convert the current signal into a digital signal to obtain the working current of the energy storage power supply 100.

[0036] It can be understood that the working current can be assigned positive and negative values according to the flow direction of the working current to distinguish the charging and discharging conditions of the energy storage power supply 100. For example, it is specified that when the working current is negative, the energy storage power supply 100 is in a discharging condition, and when the working current is positive, the energy storage power supply 100 is in a charging condition.

[0037] Optionally, the energy storage power supply 100 comprises a battery module, and the charging and discharging of the energy storage power supply 100 is realized through the charging and discharging of the battery module.

[0038] Optionally, the energy storage power supply 100 further comprises a temperature sensor 30, which is arranged on the battery module and is used to collect the temperature of the battery module to obtain the working temperature of the energy storage power supply 100. For example, the temperature sensor 30 can be a negative temperature coefficient thermistor (NTC).

[0039] Optionally, the energy storage power supply 100 further comprises a voltage sensor 40, through which the working voltage of the energy storage power supply 100 can be collected.

[0040] It can be understood that after the energy storage power supply 100 collects the working current through the Hall sensor, the working temperature through the temperature sensor 30, and the working voltage through the voltage sensor 40, these operating parameters can be transmitted to the first electric quantity detection model through an application program interface (API), so as to realize the inference prediction of the current remaining electric quantity of the energy storage power supply 100, and the inference prediction time can be controlled within 30 milliseconds (ms), meeting the real-time requirement.

[0041] Optionally, the energy storage power supply 100 comprises a display screen 50, which can be used to display the current remaining electric quantity of the energy storage power supply 100, the working current, the working temperature, and the like of the energy storage power supply 100. For example, please refer to Figure 1 The energy storage power supply 100 displays the current remaining electric quantity as 50% through the display screen 50, so that the user can obtain the current remaining electric quantity information.

[0042] Please refer to Figure 2Optionally, the energy storage power supply 100 can include a plurality of modules, which can be hardware modules and / or software modules. For example, the energy storage power supply 100 can include a sensing acquisition module 101, an edge AI module 102, a storage module 103, and a display and control module 104, wherein the sensing acquisition module 101 can be used to acquire operating parameter data of the energy storage power supply 100, the storage module 103 can be used to store operating parameters and historical current residual capacity values (for example, the storage module 103 can include a local log module, and the energy storage power supply 100 can store the current residual capacity output each time into the local log module for subsequent model adjustment, etc.), the edge AI module 102 can receive the operating parameters acquired by the sensing acquisition module 101 and detect the current residual capacity through a first capacity detection model; the display and control module 104 can be used to control the display content of the energy storage power supply 100 on the display screen 50, the charge and discharge control of the energy storage power supply 100, etc.

[0043] Next, the residual capacity detection method of the present application will be described in detail. Please refer to Figures 1 to 3 The residual capacity detection method of the present embodiment is used for an energy storage power supply, which is deployed with a first capacity detection model generated by pruning and quantizing a second capacity detection model, the model of the first capacity detection model is smaller than that of the second capacity detection model, and the residual capacity detection method comprises:

[0044] Step 011: Acquire operating parameters of the energy storage power supply within a first preset time period, the operating parameters including working current and working temperature.

[0045] The first capacity detection model is a lightweight model generated by pruning and quantizing the second capacity detection model, and has a smaller volume than the second capacity detection model. The first capacity detection model is deployed on a processor of the energy storage power supply and used to detect the current residual capacity (SOC value) of the energy storage power supply.

[0046] The second capacity detection model has a larger and more complex model, higher accuracy, but also greater demand for calculation and storage, compared with the first capacity detection model.

[0047] The pruning can be an operation of deleting redundant connections or calculation units (such as neurons, convolution kernels, etc. that have little effect on the output SOC value) in the second capacity detection model, simplifying the model structure and reducing the model complexity.

[0048] The quantization can be an operation of reducing the numerical precision of parameters in the second capacity detection model to reduce the model storage volume and calculation amount.

[0049] The operating parameters can be parameters reflecting the current working state of the energy storage power supply.

[0050] Optionally, the operation parameters include working current, working temperature, working voltage, and a timestamp of collecting the operation parameters.

[0051] The working current can be a current under a current working condition of the energy storage power supply, and can include a charging current or a discharging current. The working current can include a positive current and a negative current, which can be used to distinguish the charging and discharging state of the energy storage power supply. The working voltage can be a voltage under a current working condition of the energy storage power supply. The working temperature can be a temperature at a current moment of the energy storage power supply, and can reflect an environmental parameter affecting the charging and discharging performance of the energy storage power supply. For example, in a case where the energy storage power supply includes a plurality of battery modules, the working temperature can be an average temperature of the plurality of battery modules. The energy storage power supply can further record the collection time of the working current, the working voltage, and the working temperature by setting a real-time clock (RTC), to ensure the time correlation and accuracy of the data.

[0052] The first preset time length can be a time length of collecting the operation parameters, for example, 30 seconds (s), 40 s, 50 s, 55 s, 60 s, 65 s, 70 s, etc. The operation parameters of the first preset time length can reflect the working state of the energy storage power supply. For example, taking 60 s as the first preset time length, the energy storage power supply can record a set of data of the working current, the working temperature, the working voltage, and the timestamp every second, and continuously collect the data of the past 60 s by using a sliding window mechanism, to obtain the operation parameters in the first preset time length.

[0053] Step 012: based on the first power detection model, processing the operation parameters in the first preset time length to output the current residual power of the energy storage power supply.

[0054] Specifically, the energy storage power supply can collect the operation parameters in the first preset time length through sensors (for example, a Hall sensor detects the working current, a temperature sensor detects the working temperature, etc.), and the operation parameters can reflect the working condition of the energy storage power supply. Then, the collected operation parameters are input into the deployed first power detection model, and the first power detection model performs feature extraction and calculation on the operation parameters, and outputs the current residual power of the energy storage power supply.

[0055] For example, in a deep learning-based lithium battery SOC estimation method for electric vehicles, an optimized model deployed in the cloud receives the working parameters of the lithium battery through network communication, performs calculations to obtain the SOC estimation value, and sends the SOC estimation value to the energy storage device through network communication. Due to the insufficient AI computing power of the single-chip microcomputer of the energy storage device, it cannot simultaneously collect data, analyze data, and predict results in real time. Most of the collection and calculation processes rely on cloud computing, and the results are transmitted to the energy storage device after cloud computing. With the increase in the number of energy storage devices, the cloud server load becomes heavy, and the real-time estimation is affected.

[0056] That is, although the deep learning-based lithium battery SOC estimation method for electric vehicles can calculate the SOC value, due to the limitations of the single-chip microcomputer of the energy storage device, it is not possible to deploy a trained optimized model on the energy storage device. Cloud computing based on the optimized model deployed in the cloud introduces latency and heavy load, resulting in application limitations.

[0057] The present application first optimizes the original second power detection model through pruning and quantization, generates a smaller first power detection model while retaining the detection capability of the model to detect the SOC value, and finally outputs the current remaining power of the energy storage device by analyzing and processing the operating parameters within the first preset time period through the first power detection model. Due to the relatively small size of the first power detection model, it can be directly deployed on the energy storage power supply, reducing the dependence on the cloud server, alleviating network load, enhancing data security and privacy protection, achieving high-precision SOC prediction under edge computing, and improving real-time performance and response speed.

[0058] In this way, the energy storage power supply is deployed with the first power detection model, which is generated by pruning and quantizing the second power detection model. The model size of the first power detection model is smaller than that of the second power detection model. Due to the smaller size of the first power detection model, it is more suitable for the processor hardware environment of the energy storage power supply, has relatively lower computational complexity and storage requirements, solves the problem of deep learning models that can detect the current remaining power but cannot be deployed on resource-constrained energy storage power supplies, reduces the dependence on the cloud server, and reduces the burden of computation and storage, thereby reducing hardware costs and energy consumption; by collecting the operating parameters of the energy storage power supply within the first preset time period, the operating parameters include working current and working temperature; based on the first power detection model, the operating parameters within the first preset time period are processed to output the current remaining power of the energy storage power supply. The model has excellent fitting effect on data with multiple characteristics, multiple factors, and strong non-linear relationships to calculate the current remaining power of the energy storage power supply, improve the calculation accuracy and precision of the remaining power, and improve the real-time performance and response speed of the remaining power detection.

[0059] Referring to Figure 4 In some embodiments, the method for detecting the residual power further comprises:

[0060] Step 013: obtaining a plurality of operating parameters and first residual powers corresponding to the operating parameters;

[0061] Step 014: generating a training sample based on the plurality of operating parameters and the corresponding first residual powers in the first preset time length, and taking the first residual power as the label information of the training sample;

[0062] Step 015: training the second power detection model based on the plurality of training samples until convergence.

[0063] The first residual power can be an actual residual power value corresponding to the operating parameter, the first residual power can be used as a training label, and the first residual power can be a calculation target value for indicating the calculation of the second power detection model based on the operating parameter.

[0064] Optionally, step 015: training the second power detection model based on the training sample until convergence, comprises:

[0065] Step 0151: inputting the training sample into the second power detection model to obtain a training residual power;

[0066] Step 0152: determining a loss value based on the training residual power, the first residual power corresponding to the training sample, and a preset loss function;

[0067] Step 0153: adjusting the second power detection model based on the loss value corresponding to each training sample until the second power detection model converges.

[0068] The preset loss function can be a mean square error (MSE) function.

[0069] Specifically, taking the collection of the working temperature, the working current, the working voltage and the timestamp once per second as an example. The plurality of operating parameters of the energy storage power supply under different working conditions can be collected, and the first residual power corresponding to each operating parameter can be calculated and recorded by, for example, the open circuit voltage method or the ampere-hour integral method, the first residual power is the training label, a training sample is generated according to the operating parameters and the corresponding first residual power in the first preset time length (60s for example), then the above process is repeated to generate a plurality of training samples with a time window of 60s, and finally the plurality of training samples are input into the second power detection model to train the second power detection model to convergence.

[0070] More specifically, the training process of the second electric quantity detection model is as follows: by obtaining a plurality of training samples, the training samples including running parameters within a first preset time length and label information corresponding to each running parameter, the label information being a first residual electric quantity corresponding to the running parameter, the running parameters within the same training sample having time sequence continuity; then inputting the training samples into the second electric quantity detection model for training to obtain a training residual electric quantity; then calculating a loss value between the training residual electric quantity and the first residual electric quantity according to a loss function, and adjusting the second electric quantity detection model according to the loss value (for example, by setting an Adam optimizer, adjusting the model parameters of the second electric quantity detection model according to the loss value, etc.), and training the second electric quantity detection model by inputting a plurality of training samples, until the loss value is less than a preset loss threshold, then considering that the generalization ability and prediction accuracy of the second electric quantity detection model at this time reach the expected level, completing convergence, and obtaining the trained second electric quantity detection model.

[0071] It should be noted that the plurality of training samples for training the second electric quantity detection model includes data sets of the energy storage power supply under different temperature conditions, different rate discharges, and different aging periods, and the plurality of training samples cover residual electric quantity data of the energy storage power supply under different environmental conditions and in different working conditions.

[0072] It can be understood that in the process of training the second electric quantity detection model, the initial SOC value of the second electric quantity detection model at the first time of running can also be obtained as a reference for subsequent electric quantity detection and calculation, and by combining the initial SOC value and different training samples, the residual electric quantity at the subsequent time can be more accurately calculated, the prediction error in the initial stage of the model is reduced, and the electric quantity detection is ensured to start from a reliable reference point.

[0073] In this way, by collecting the running parameters and the corresponding first residual electric quantity of the energy storage power supply in actual operation, and constructing the training samples by using the running parameters within the first preset time length and the corresponding first residual electric quantity, the model can learn the potential law between the running parameters and the residual electric quantity when training the second electric quantity detection model by using the training samples.

[0074] That is to say, since the training samples are derived from continuous running parameters within the first preset time length, the change law of the running parameters over time can be captured, and the learning ability of the model for time sequence characteristics is enhanced, and by covering training samples under different working conditions, the second electric quantity detection model can learn the electric quantity change law under various conditions, and the adaptability to complex scenes is improved.

[0075] Optionally, the running parameters further include a working voltage and a timestamp of collecting the running parameters, and step 014: generating a training sample based on a plurality of running parameters that are continuous within the first preset time length, including:

[0076] Step 0141: generating an initial operation parameter matrix based on the plurality of working currents, working voltages, working temperatures and time stamps in the preset time length, each row of the initial operation parameter matrix including one working current, one working voltage, one working temperature and one time stamp (past 60 seconds of data collected through the sliding window mechanism, forming a 60x4-dimensional data input matrix);

[0077] Step 0142: normalizing and filtering the initial operation parameter matrix to obtain an input operation parameter matrix;

[0078] Step 0143: generating a training sample based on the input operation parameter matrix and the first remaining power.

[0079] The initial operation parameter matrix includes a matrix composed of a plurality of working currents, working voltages, working temperatures and time stamps in the first preset time length, and each row of the matrix includes one working current, one working voltage, one working temperature and one corresponding time stamp when the data is collected. Taking an example of collecting operation parameters once a second for 60 seconds as the first preset time length, the operation parameter matrix includes a 60x4-dimensional matrix.

[0080] The normalization processing can be a processing of unifying the magnitude of the data in the initial operation parameter matrix.

[0081] The filtering processing can be a processing of filtering or smoothing the noise data (e.g., abnormal working current, abnormal working temperature, etc.) in the initial operation parameter matrix to reduce data interference and improve data accuracy.

[0082] Specifically, the initial operation parameter matrix can be generated by collecting the continuous operation parameters in the past first preset time length through the sliding window mechanism, and the working current, working voltage, working temperature and time stamp data in the initial operation parameter matrix can be unified in magnitude (e.g., mapped to the same interval through the maximum and minimum value method, etc.) to eliminate the influence of different operation parameter units and ranges, and abnormal data can be removed through filtering processing to obtain the input operation parameter matrix (in the form of a four-dimensional feature vector). Finally, the input operation parameter matrix and the corresponding first remaining power are combined to form a set of training samples. The initial operation parameter matrix is generated based on the operation parameters in the first preset time length, which retains the time sequence correlation (e.g., the trend of the working current) of the operation parameters in the first preset time length, so that the second power detection model can learn the time-dependent law of power change. The normalization processing can eliminate the magnitude difference of the operation parameters, and the filtering processing can reduce noise interference, ensuring that the data input into the second power detection model is more reliable and providing a high-quality basis for model training.

[0083] Please refer to Figure 5In some embodiments, the method for detecting the residual power further comprises:

[0084] Step 016: calculating the weight of the connection between any two calculation units of the second power detection model, and deleting the connection if the weight is less than a preset weight threshold, to obtain a third power detection model;

[0085] Step 017: calculating the output results of each calculation unit of the third power detection model under different operating parameters, and deleting the calculation unit if the change value of the output results is less than a preset change threshold, to obtain a fourth power detection model;

[0086] Step 018: mapping the data bit number of the fourth power detection model to a preset bit number based on a preset proportional relationship, to obtain the first power detection model, the preset bit number being less than the data bit number before mapping of the second power detection model.

[0087] Among them, the calculation unit can be a basic component for feature extraction and operation in the second power detection model, such as a neuron, a convolution kernel, etc.

[0088] Among them, the weight can be used to measure the influence degree of the connection between two calculation units on the current residual power output by the second power detection model, the greater the weight, the more significant the influence on the current residual power output.

[0089] Among them, the preset weight threshold can be used to judge whether the connection is redundant, if the weight of the connection is less than the preset weight threshold, it can be considered that the connection has less influence on the current residual power output, and the connection is redundant.

[0090] Among them, the preset change threshold can be a change value, or a change slope threshold, etc. In the case that the change value of the output result is less than the preset change value, it can be considered that the calculation function of the calculation unit is redundant, and has less influence on the current residual power output.

[0091] Among them, the data bit number can be the data storage bit number of the model (for example, 32-bit floating point number, 16-bit integer, etc.), the higher the bit number, the higher the precision of the model, and the larger the model storage and calculation amount. The preset bit number can be, for example, 16 bits, 8 bits, etc.

[0092] Specifically, by calculating the weights of the connections between the calculation units in the second power detection model, the influence degree of each connection on the current remaining power of the output is evaluated, each weight is compared with a preset weight threshold, and the connections with weights less than the preset weight threshold are deleted to obtain a third power detection model with a simplified structure; different operating parameters are input to the third power detection model, the output results of each calculation unit are recorded, and the change values (for example, the difference between the maximum value and the minimum value, for example, the slope of the fitting curve corresponding to the output result, etc.) of the output results of the same calculation unit under different inputs are calculated, each change value is compared with a preset change threshold, and the calculation units with change values less than the preset change threshold are deleted to obtain a fourth power detection model that is further simplified, and finally, the data bit number of the fourth power detection model is converted based on a preset proportional relationship through a linear transformation formula to convert the data bit number of the parameters in the fourth power detection model to a preset bit number (the preset bit number is less than the bit number before quantization), further reducing the model storage and calculation amount, for example, mapping the original 32-bit floating point number value range of the fourth power model to an 8-bit integer range, thereby obtaining a first power detection model with a smaller volume. By pruning and optimizing the second power detection model, the original 8 megabyte (MB) second power detection model can be compressed to a first power detection model of less than 1 MB, which is suitable for the embedded hardware environment of the energy storage power supply.

[0093] In this way, by deleting redundant connections and functionally redundant calculation units that have a small influence on the current remaining power of the output, unnecessary structures in the second power detection model are removed, the pruning of the second power detection model is completed, and the model complexity is simplified; then by reducing the storage bit number of the model data of the second power detection model, the storage space and calculation resources occupied by the parameters are reduced, the model volume is further compressed, the quantization of the second power detection model is completed, and the first power detection model is obtained, which further minimizes the accuracy loss while significantly reducing the volume and calculation demand of the model, making it suitable for the embedded hardware environment of the energy storage power supply. After removing redundant structures and reducing the data bit number, the calculation amount of the first power detection model is reduced, the running speed is increased, and the response demand of the real-time power detection of the energy storage power supply can be met.

[0094] Please refer to Figure 6 In some embodiments, step 012: based on the first power detection model, processing the operating parameters within a preset time period to output the current remaining power of the energy storage power supply, includes:

[0095] Step 0121: generating a collection operating parameter matrix based on the operating parameters within a first preset time period, and performing normalization processing and filtering processing on the collection operating parameter matrix;

[0096] Step 0122: input the normalized and filtered acquisition operation parameter matrix into the first electric quantity detection model to obtain the current residual electric quantity.

[0097] The acquisition operation parameter matrix can be a matrix composed of operation parameters in the first preset time length, and has the same structure as the input operation parameter matrix in the training phase (for example, both are 60x4 dimensions). The acquisition operation parameter matrix can be used as the input of the first electric quantity detection model.

[0098] Specifically, the real-time operation parameters of the energy storage power supply in the first preset time length are collected and arranged in time sequence to generate an acquisition operation parameter matrix. The matrix is preprocessed by normalization and filtering to eliminate noise interference and reduce detection error. The preprocessed acquisition operation parameter matrix is input into the first electric quantity detection model to obtain the current residual electric quantity. Through standardized data processing and efficient calculation of the lightweight model, the real-time and detection accuracy of the current residual electric quantity of the energy storage power supply are realized.

[0099] Optionally, the second electric quantity detection model includes a one-dimensional convolutional neural network and / or a long short-term memory network.

[0100] For example, the second electric quantity detection model includes a one-dimensional convolutional neural network; or the second electric quantity detection model includes a long short-term memory network; or the second electric quantity detection model includes a one-dimensional convolutional neural network and a long short-term memory network.

[0101] The one-dimensional convolutional neural network (1D-CNN) is a deep learning network for processing sequence data, which realizes efficient analysis of time series, audio signals and other data through local feature extraction and hierarchical compression, and has advantages such as local feature extraction, parameter sharing, translation invariance and scalability.

[0102] The long short-term memory network (Long Short-Term Memory, LSTM) is a subtype of recurrent neural network (Recurrent Neural Networks, RNN). The LSTM can solve the problem of gradient vanishing or explosion in traditional RNN when processing long sequence data, and can capture long-distance dependency.

[0103] Optionally, the second electric quantity detection model can include an input layer, a one-dimensional convolution layer (1D-CNN), a long short-term memory network layer (LSTM), a full connection layer, the input layer can be used to collect the running parameter matrix, the one-dimensional convolution layer can be used to extract the time sequence features of the running parameters within the first preset time length, the long short-term memory network layer can be used to process the influence features of the historical output on the current output electric quantity, the full connection layer can be used to integrate the two features of the one-dimensional convolution layer and the long short-term memory network layer, and the output layer is used to generate and output the current residual electric quantity based on the integration result of the full connection layer.

[0104] Referring to Figure 7 In some embodiments, the method for detecting the residual electric quantity further includes:

[0105] Step 019: obtaining the calibrated residual electric quantity of the energy storage power supply based on the working condition of the energy storage power supply;

[0106] Step 020: correcting the first electric quantity detection model based on the current running parameters of the energy storage power supply and the calibrated residual electric quantity.

[0107] Optionally, step 019: obtaining the calibrated residual electric quantity of the energy storage power supply based on the working condition of the energy storage power supply, includes:

[0108] Step 0191: determining that the energy storage power supply is in a static state and obtaining the current voltage of the energy storage power supply in the case that the energy storage power supply is in a shutdown working condition or the output current of the energy storage power supply is less than a preset current value for a duration reaching a second preset time length.

[0109] Step 0192: determining the calibrated residual electric quantity of the energy storage power supply based on the preset open circuit voltage table and the current voltage, wherein the open circuit voltage table includes the mapping relationship between the voltage and the residual electric quantity of the energy storage power supply in the static state.

[0110] The calibrated residual electric quantity can be a reference residual electric quantity value determined based on the parameters (such as the open circuit voltage) of the energy storage power supply in a specific working condition, which is used to correct the prediction result of the first electric quantity detection model and improve the detection accuracy.

[0111] The second preset time length can be, for example, 250s, 270s, 290s, 300s, 310s, etc.

[0112] The preset current value can be used to determine whether the energy storage power supply is in a low load (or no load) state. For example, in the case that the output current of the energy storage power supply is less than the preset current value, it can be considered that the energy storage power supply is in a low load (or no load) state, and in the case that the duration of the output current of the energy storage power supply being less than the preset current value reaches the second preset time length, it can be considered that the energy storage power supply is in a static state.

[0113] The open-circuit voltage can be the voltage of the energy storage power supply in a static state (for example, no charging and discharging behavior, or a small output current, etc.), in which the internal chemical reaction of the battery of the energy storage power supply reaches equilibrium, the voltage is stable and is not affected by the charging and discharging current, and the remaining power of the battery can be relatively accurately reflected.

[0114] The open-circuit voltage table can represent the mapping relationship between the voltage and the remaining power of the energy storage power supply in the static state.

[0115] Specifically, the working current of the energy storage power supply can be monitored (for example, in the case of a working current of 0, it is determined that the energy storage power supply is powered off, etc.), and in the case that the energy storage power supply is powered off or the duration of the output current being less than a preset current value reaches a second preset duration, it is determined that the energy storage power supply is in a static state and the current voltage of the energy storage power supply is obtained. At this time, the current voltage is approximately the open-circuit voltage. Then, by querying the preset open-circuit voltage table, the corresponding remaining power value is found according to the current voltage, which is the calibrated remaining power. Then, according to the current operating parameters (such as working current, working voltage, etc.) and the calibrated remaining power, the first power detection model is periodically dynamically corrected by a preset algorithm (for example, an error feedback adjustment model parameter, a correction prediction offset algorithm, etc.), so that the remaining power output by the model is consistent with the calibrated remaining power, and the cumulative error is eliminated.

[0116] It can be understood that, since the voltage of the energy storage power supply is stable and the mapping relationship between the voltage and the remaining power is clear in the static state, the accuracy and reliability of the calibrated remaining power are high. In addition, since the open-circuit voltage table only includes the mapping relationship between the open-circuit voltage and the remaining power, the influence of the discharge rate, the battery capacity, etc. does not need to be considered when constructing the mapping relationship, and the testing process is relatively simple and efficient.

[0117] In this way, by correcting the first power detection model when the energy storage power supply is in a static state, the detection error can be reduced, the problem of accuracy decline caused by long-term operation of the model can be avoided, and the detection reliability can be ensured.

[0118] Please refer to Figure 8To facilitate better implementation of the remaining power detection method of the embodiments of the present application, the embodiments of the present application further provide a remaining power detection device 300 for an energy storage power supply, the energy storage power supply being deployed with a first power detection model, the first power detection model being generated by pruning and quantizing a second power detection model, the model volume of the first power detection model being smaller than that of the second power detection model, the remaining power detection device 300 comprising a collection module 301 and an output module 302, the collection module 301 being configured to collect operating parameters of the energy storage power supply within a first preset time period, the operating parameters comprising working current and working temperature; and the output module 302 being configured to process the operating parameters within the first preset time period based on the first power detection model, so as to output the current remaining power of the energy storage power supply.

[0119] In the foregoing, the device is described from the perspective of functional modules, which can be implemented by hardware, or by instructions of software, or by a combination of hardware and software modules. Specifically, each step of the method embodiments in the embodiments of the present application can be completed by integrated logic circuits of hardware in a processor and / or instructions of software. The steps of the method disclosed in the embodiments of the present application can be directly embodied as hardware coding processors to execute, or be executed by a combination of hardware and software modules in the coding processor. Alternatively, the software module can be located in a mature storage medium in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, register, etc. The storage medium is located in the storage, and the processor reads information in the storage, and combines the hardware to complete the steps in the method embodiments.

[0120] The embodiments of the present application further provide a computer program product comprising a computer program, the computer program comprising instructions of the remaining power detection method of any of the above-mentioned embodiments. For brevity, details are not repeated here.

[0121] Please refer to Figure 1 The embodiments of the present application further provide an energy storage power supply comprising a processor, a first power detection model being deployed on the processor, the processor being configured to execute the steps of the remaining power detection method of any of the above-mentioned embodiments. For brevity, details are not repeated here.

[0122] In some embodiments, the processor comprises an edge processing chip and / or an embedded processing chip.

[0123] Please refer to Figure 9The embodiment of the present application further provides a computer readable storage medium 600, which stores a computer program 610. When the computer program 610 is executed by a processor 620, the steps of the remaining power detection method of any one of the above embodiments are realized. For brevity, details are not repeated herein.

[0124] In the description of the present specification, the description of the terms "one embodiment", "some embodiments", "exemplary embodiment", "example", "specific example", or "some examples" and the like means that the specific features, structures, materials or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present application. In the present specification, the exemplary description of the above terms does not necessarily mean the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.

[0125] Although the embodiments of the present application have been shown and described, those of ordinary skill in the art can understand that various changes, modifications, replacements and variations can be made to the embodiments without departing from the principles and spirit of the present application, and the scope of the present application is defined by the claims and their equivalents.

Claims

1. A method of detecting a remaining electric quantity, characterized by, The application relates to a method for an energy storage power supply, wherein a first power detection model is deployed, the first power detection model is generated by pruning and quantizing a second power detection model, the model volume of the first power detection model is smaller than that of the second power detection model, and the method comprises the following steps: acquiring operation parameters of the energy storage power supply within a first preset time period, wherein the operation parameters comprise working current and working temperature; processing the operation parameters within the first preset time period based on the first power detection model to output the current residual power of the energy storage power supply.

2. The method of claim 1, wherein The method further comprises the following steps: obtaining a plurality of operation parameters and corresponding first residual power; generating training samples based on a plurality of continuous operation parameters and corresponding first residual power within the first preset time period, and taking the first residual power as label information of the training samples; training the second power detection model based on a plurality of training samples until convergence.

3. The method of claim 2, wherein The operation parameters further comprise working voltage and a timestamp of acquiring the operation parameters, and the step of generating training samples based on a plurality of continuous operation parameters within the first preset time period comprises the following steps: generating an initial operation parameter matrix based on a plurality of continuous working current, working voltage, working temperature and timestamp within a preset time period, wherein each row of the initial operation parameter matrix comprises one working current, one working voltage, one working temperature and one timestamp; performing normalization processing and filtering processing on the initial operation parameter matrix to obtain an input operation parameter matrix; generating the training samples based on the input operation parameter matrix and the first residual power.

4. The method of claim 2 or 3, wherein The step of training the second power detection model based on the training samples until convergence comprises the following steps: inputting the training samples into the second power detection model to obtain training residual power; determining a loss value based on the training residual power, the first residual power corresponding to the training samples and a preset loss function; adjusting the second power detection model based on the loss value corresponding to each training sample until the second power detection model converges.

5. The method of claim 4, wherein The method further comprises the following steps: calculating the weight of a connection between any two calculation units of the second power detection model, and deleting the connection when the weight is less than a preset weight threshold to obtain a third power detection model; calculating the output results of each calculation unit of the third power detection model under different operation parameters, and deleting the calculation unit when the change value of the output result is less than a preset change threshold to obtain a fourth power detection model; mapping the data bit number of the fourth power detection model to a preset bit number based on a preset proportional relationship to obtain the first power detection model, wherein the preset bit number is smaller than the data bit number of the second power detection model before mapping.

6. The method of claim 1-5, wherein, The second power detection model comprises a one-dimensional convolutional neural network and / or a long short-term memory network.

7. The method of claim 1 or 5, wherein The first electric quantity detection model is used to process the operation parameters in the first preset time length to output the current residual electric quantity of the energy storage power supply, including: generating a collection operation parameter matrix based on the operation parameters in the first preset time length, and performing normalization processing and filtering processing on the collection operation parameter matrix; inputting the normalized and filtered collection operation parameter matrix into the first electric quantity detection model to obtain the current residual electric quantity.

8. The method of claim 1, wherein Further comprising: obtaining a calibrated residual electric quantity of the energy storage power supply based on the working condition of the energy storage power supply; correcting the first electric quantity detection model based on the current operation parameters of the energy storage power supply and the calibrated residual electric quantity.

9. The method of claim 8, wherein The calibrated residual electric quantity of the energy storage power supply is obtained based on the working condition of the energy storage power supply, including: determining that the energy storage power supply is in a stationary state and obtaining the current voltage of the energy storage power supply when the energy storage power supply is in a shutdown working condition or the output current of the energy storage power supply is less than a preset current value for a duration reaching a second preset time length; determining the calibrated residual electric quantity of the energy storage power supply based on a preset open-circuit voltage table and the current voltage, wherein the open-circuit voltage table includes a mapping relationship between the voltage and the residual electric quantity of the energy storage power supply in the stationary state.

10. An energy storage power supply, characterized by, including: a processor, the first electric quantity detection model is deployed on the processor, and the processor is used to execute the residual electric quantity detection method in any one of claims 1-9.

11. The energy storage power supply of claim 10, wherein, The processor includes an edge processing chip and / or an embedded processing chip.

12. A non-volatile computer readable storage medium containing a computer program, which is executed by a processor to make the processor execute the residual electric quantity detection method in any one of claims 1-9.