Current and power measurement method for ternary polymer lithium battery of shared charging equipment
Through multi-point sampling and preprocessing technology, combined with hierarchical clustering and model fusion, the problem that traditional measurement methods are difficult to capture the dynamic characteristics of shared lithium batteries is solved, and the accurate and stable measurement of current and power is achieved, adapting to different scenarios and conditions, and reducing the Operating costs.
Patent Information
- Application Number
- CN202411498323.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-25
- Publication Date
- 2025-01-03
- Estimated Expiration
- 2044-10-25
AI Technical Summary
Traditional battery current and power measurement methods are difficult to accurately capture the dynamic characteristics of shared lithium batteries in frequent use and complex environments, resulting in large deviations from the actual situation, and lack of adaptability, which affects the service quality and operation of shared charging equipment. cost.
Through multi-point sampling and preprocessing technology, comprehensive feature vectors are constructed and feature selection is performed, and the battery operating conditions and usage patterns are classified in combination with hierarchical clustering methods, multiple current and power measurement models are constructed, and temperature and usage frequency are compensated. Model fusion and adaptive calibration technology are used to achieve real-time measurement of current and power and long-term stability.
Significantly improve the accuracy of current and power measurement, adapt to different shared scenarios and usage conditions, eliminate the impact of environmental factors and usage frequency on measurement results, maintain long-term measurement stability, meet fast response needs, and provide reliable fault warning and equipment Management basis.
Smart Images

Figure CN119001512B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of lithium battery measurement, and in particular to a method for measuring current and power of a ternary polymer lithium battery of a shared charging device. Background Art
[0002] The performance and life of ternary polymer lithium batteries, the core components of shared charging equipment, have become key factors affecting user experience and operating costs. Traditional battery current and power measurement methods are inadequate in shared scenarios and it is difficult to accurately capture the dynamic characteristics of batteries under frequent use and complex environments.
[0003] In addition, the usage patterns of shared charging equipment are highly diverse and uncertain, which poses a huge challenge to the battery management system. Different users' charging habits, usage frequency, and environmental factors will have a significant impact on the performance of the battery, and the existing measurement methods often ignore these shared factors, resulting in a large deviation between the measurement results and the actual situation. At the same time, the aging process and performance degradation of the battery are also a problem that needs to be solved urgently. With the increase in the number of uses, the changes in the internal resistance and capacity attenuation of the battery will have a negative impact on the accuracy of current and power measurements. However, the existing measurement technology lacks the ability to adapt to these dynamic changes, and it is difficult to maintain a high-precision measurement level throughout the battery life cycle. These problems not only affect the service quality of shared charging equipment, but also increase the maintenance costs and safety risks of operators. Summary of the invention
[0004] The present invention provides a method for measuring current and power of a ternary polymer lithium battery of a shared charging device. The present invention improves the service quality of the shared charging device and reduces the maintenance cost and safety risk of the operator.
[0005] In a first aspect, the present invention provides a method for measuring current and power of a ternary polymer lithium battery of a shared charging device, the method comprising:
[0006] The current, voltage, temperature of the ternary polymer lithium batteries in multiple shared charging devices and the usage frequency of the charging devices are multi-point sampled and preprocessed to obtain a preprocessed data set;
[0007] Constructing a comprehensive feature vector based on the preprocessed data set and performing feature selection to obtain multiple target feature subsets;
[0008] Performing multi-dimensional analysis and hierarchical clustering on the battery operating conditions and shared charging equipment usage patterns according to the multiple target feature subsets to obtain multiple operating condition and usage pattern category results;
[0009] constructing a plurality of current and power measurement models based on the plurality of operating condition and usage mode category results and the plurality of target feature subsets;
[0010] Perform temperature compensation and shared frequency compensation based on the measurement circuit topology to obtain temperature and frequency compensation matrices;
[0011] Based on the classification results of the multiple operating conditions and usage modes and the temperature and usage frequency compensation matrix, the multiple current and power measurement models are subjected to model fusion and adaptive calibration to obtain a current and power measurement model set.
[0012] In a second aspect, the present invention provides a ternary polymer lithium battery current and power measurement device for a shared charging device, the ternary polymer lithium battery current and power measurement device for a shared charging device comprising:
[0013] The sampling module is used to perform multi-point sampling and preprocessing on the current, voltage, temperature of the ternary polymer lithium batteries in multiple shared charging devices and the use frequency of the charging devices to obtain a preprocessed data set;
[0014] A selection module, used for constructing a comprehensive feature vector based on the preprocessed data set and performing feature selection to obtain multiple target feature subsets;
[0015] An analysis module, configured to perform multi-dimensional analysis and hierarchical clustering on the battery operating conditions and the shared charging device usage patterns according to the multiple target feature subsets, to obtain multiple operating condition and usage pattern category results;
[0016] A construction module, configured to construct a plurality of current and power measurement models based on the plurality of operating condition and usage mode category results and the plurality of target feature subsets;
[0017] A compensation module, used for performing temperature compensation and shared use frequency compensation based on a measurement circuit topology structure, and obtaining a temperature and use frequency compensation matrix;
[0018] A fusion module is used to perform model fusion and adaptive calibration on the multiple current and power measurement models based on the multiple operating conditions and usage mode classification results and the temperature and usage frequency compensation matrix to obtain a current and power measurement model set.
[0019] The third aspect of the present invention provides a computer device, comprising: a memory and at least one processor, wherein the memory stores instructions; the at least one processor calls the instructions in the memory so that the computer device executes the above-mentioned method for measuring current and power of a ternary polymer lithium battery of a shared charging device.
[0020] A fourth aspect of the present invention provides a computer-readable storage medium, in which instructions are stored. When the computer-readable storage medium is run on a computer, the computer executes the above-mentioned method for measuring current and power of a ternary polymer lithium battery of a shared charging device.
[0021] In the technical solution provided by the present invention, by multi-point sampling and preprocessing technology, combined with dynamic weight adjustment algorithm for feature selection, the key features of the battery can be effectively extracted, and the accuracy of current and power measurement can be significantly improved. The battery operating conditions and usage modes are classified by hierarchical clustering method, and multiple current and power measurement models are constructed, which can adapt to different sharing scenarios and usage conditions. By equivalently decoupling the measurement circuit and introducing temperature and usage frequency compensation matrix, the measurement parameters can be adjusted in real time, and the influence of environmental factors and usage frequency on the measurement results can be effectively eliminated. Model fusion and adaptive calibration technology are adopted, combined with Bayesian model averaging method, so that the measurement system can automatically adjust with the change of battery performance and maintain long-term measurement stability. By constructing an efficient neural network model and an optimized data processing flow, real-time measurement of current and power can be achieved to meet the rapid response requirements of shared charging equipment. Through the uncertainty estimation layer and probabilistic measurement results, the credibility of the measurement can be evaluated, providing a reliable basis for equipment management and fault warning. Based on the mechanism of operating condition identification and model selection, the most suitable model can be called for different situations, the use of computing resources can be optimized, and the overall efficiency of the system can be improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative work.
[0023] Figure 1 A schematic diagram of the steps of a method for measuring current and power of a ternary polymer lithium battery of a shared charging device in an embodiment of the present invention;
[0024] Figure 2 It is a schematic diagram of the structure of a ternary polymer lithium battery current and power measurement device of a shared charging device in an embodiment of the present invention. DETAILED DESCRIPTION
[0025] An embodiment of the present invention provides a method for measuring current and power of a ternary polymer lithium battery of a shared charging device. The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including" or "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0026] For ease of understanding, the specific process of the embodiment of the present invention is described below. Figure 1 , an embodiment of a method for measuring current and power of a ternary polymer lithium battery of a shared charging device in an embodiment of the present invention includes:
[0027] Step S1, performing multi-point sampling and preprocessing on the current, voltage, temperature of the ternary polymer lithium batteries in multiple shared charging devices and the use frequency of the charging devices to obtain a preprocessed data set;
[0028] It is understandable that the execution subject of the present invention can be a ternary polymer lithium battery current and power measurement device of a shared charging device, or a terminal or a server, which is not limited here. The embodiment of the present invention is described by taking a server as the execution subject as an example.
[0029] Specifically, high-frequency sampling is performed on ternary polymer lithium batteries in multiple shared charging devices to collect current, voltage and temperature data to obtain raw sampling data. The raw data is timestamped and associated with the device identification to form a raw data set with spatiotemporal information. The device usage characteristic data is generated by calculating the usage frequency and the number of charge and discharge cycles of each charging device. Multi-scale analysis of the raw data set with spatiotemporal information is performed by wavelet transform, and the raw data is denoised. The wavelet transform can effectively separate useful signals and noise through multi-scale analysis, retain the core features of the data, and obtain the denoised signal data. The denoised signal data is amplitude normalized and time scale standardized. Amplitude normalization can eliminate the amplitude differences between different devices and sampling processes, making the data comparable between different devices; time scale standardization ensures that the time characteristics of the data are unified, so that data from different time periods can be compared and analyzed at the same time scale to obtain a standardized data set. Based on the standardized data set, the dynamic time warping algorithm is used to identify and segment the charging cycle. The identification of the charging cycle is one of the key steps in the whole process, because the performance and service life of the battery depend largely on the regularity of the charge and discharge cycle. The dynamic time warping algorithm can accurately identify the start and end points of the charging cycle by dynamically matching data from different time periods, and reasonably segment the original data to obtain cycle segmented data, which reflects the working status of the battery in different charging cycles. Time series alignment and feature fusion are performed on the cycle segmented data and the device usage feature data. Time series alignment ensures the time consistency between different data sources, while feature fusion integrates multiple feature information (such as current, voltage, temperature, and device usage frequency) into a unified feature vector to obtain a multi-dimensional feature data set. Sliding window segmentation and overlapping sampling are performed on the multi-dimensional feature data set. Sliding window segmentation sets a sliding window on the time axis and segments the data with a fixed step size, so that each segment of data can reflect the working status of the battery within a certain time range; overlapping sampling is to increase the redundancy of the data, and a certain proportion of overlapping between adjacent windows is performed to ensure the continuity between the data and the integrity of the information. Through sliding window segmentation and overlapping sampling, a preprocessed data set for the construction of the current and power measurement model is generated.
[0030] Step S2: constructing a comprehensive feature vector based on the preprocessed data set and performing feature selection to obtain multiple target feature subsets;
[0031] Specifically, the preprocessed data set is analyzed in the time domain and frequency domain to obtain the initial feature set. In the time domain analysis, the time series changes of parameters such as current, voltage, and temperature can reveal the trends and laws of battery performance, while the frequency domain analysis captures the periodic components and hidden patterns in the data by transforming to the frequency space. Based on the initial feature set, the change rate of key parameters in the charging and discharging process is calculated, and the dynamic change features are extracted to capture the fluctuation of key performance parameters of the battery under different working conditions. For example, the sharp changes in current and voltage may indicate abnormal working conditions or battery aging. By combining the initial feature set and the dynamic change features, a comprehensive feature vector is constructed. Based on the comprehensive feature vector, the degree of influence of each feature on the battery performance is calculated to obtain the importance ranking of the features. The correlation between each feature and the battery performance is evaluated, and the features with greater influence are assigned a higher importance level. The sorting process not only helps to identify the features that are important to the battery health and performance, but also excludes and screens irrelevant or redundant features to improve the efficiency of subsequent modeling. According to the feature importance ranking, multiple importance thresholds are set, and the features are divided into multiple levels to obtain a hierarchical feature set. Each level corresponds to a different importance threshold, which is arranged from high to low. Perform correlation analysis on the features in the hierarchical feature set to reduce the problem of multicollinearity. Through correlation analysis, streamline the feature set, retain the most representative features, and obtain a streamlined feature set. Based on the streamlined feature set, build a dynamic weight adjustment model, initialize the feature weights, and form an initial weight distribution scheme. Dynamically adjust the feature weights according to the usage pattern of the shared charging device. In actual use, the load condition, battery health status, and frequency of use of shared charging devices will change. Dynamically adjusting feature weights helps the model adaptively respond to various working conditions and ultimately form multiple target feature subsets.
[0032] Step S3: performing multi-dimensional analysis and hierarchical clustering on the battery operating conditions and shared charging device usage patterns according to multiple target feature subsets to obtain multiple operating condition and usage pattern category results;
[0033] Specifically, multiple target feature subsets are normalized to eliminate the differences in dimensions and scales of different features, ensuring that different features are comparable in cluster analysis. Through normalization, a standardized feature matrix is obtained, which unifies the numerical range of each feature to avoid excessive influence of some features with large values on the clustering results. Based on the standardized feature matrix, the Euclidean distance between features is calculated to measure the similarity between features. Euclidean distance is a commonly used distance measurement method. By calculating the distance between different features, a distance matrix between features is constructed. Based on the distance matrix, the minimum distance method is used for initial clustering. The minimum distance method is a basic method of hierarchical clustering. By continuously merging the features or data points with the closest distance, a clustering structure is gradually formed to obtain the initial clustering results. The initial clustering results are hierarchically merged to construct a clustering tree structure. The clustering tree is a multi-level structure that can show the whole process from individual data points to large-scale aggregation. Through this structure, the clustering of data at different levels can be clearly observed. The inter-class and intra-class distance ratios are calculated based on the multi-level clustering model to determine the optimal number of clusters. The inter-class distance represents the difference between different classes, while the intra-class distance represents the similarity within the same class. By calculating the ratio of inter-class and intra-class distances, an optimal number of clusters is found so that the difference between different classes is maximized and the difference between the same class is minimized, and the optimized clustering result is obtained. Feature analysis is performed on each class in the optimized clustering result, and the feature vector of the class is extracted to form a working condition feature set. The feature vector of each class can reflect the specific working state and characteristics of the battery under the class, such as charging and discharging speed, temperature change law, etc. At the same time, based on the working condition feature set, combined with the time and space usage data of the shared charging device, the usage mode descriptor is constructed. The usage mode of the shared charging device depends not only on the physical characteristics of the battery, but also on factors such as the frequency of use of the device and the geographical location. By analyzing the time and space data, the usage mode feature set is obtained. The working condition feature set and the usage mode feature set are combined and analyzed to generate the joint distribution of the working condition and the usage mode. Through the joint analysis, the association between the battery working condition and the device usage mode is captured, and the results of multiple working condition and usage mode categories are obtained, which reveals the performance of the battery under different working conditions and can also provide the operating characteristics of the shared charging device under different usage scenarios.
[0034] Step S4: construct multiple current and power measurement models based on multiple operating conditions and usage mode category results and multiple target feature subsets;
[0035] Specifically, the results of multiple working conditions and usage mode categories are encoded with unique hot vectors, and the category information is converted into feature vectors to avoid sequential deviations between categories. After encoding, the category feature vector can accurately express the category information of different working conditions and usage modes. The category feature vector is spliced with multiple target feature subsets, and the multi-head self-attention mechanism is used for feature interaction. The multi-head self-attention mechanism captures the long-distance dependencies between features, realizes deep interaction between features, and generates enhanced feature vectors. A shared factor encoder is constructed, which contains three parallel sub-networks to process shared factors such as charging frequency, usage time, and ambient temperature respectively. Each sub-network consists of three fully connected layers and uses the GELU activation function, which can improve the nonlinear expression ability of the model, so that the encoder can extract more refined shared factor features and obtain the shared factor features after training encoding. The enhanced feature vector and the encoded shared factor features are input into the feature fusion layer. The feature fusion layer adopts the gated linear unit (GLU) structure, which automatically adjusts the information fusion method according to the different input features, realizes adaptive fusion of features, and obtains the training fusion features. A dynamic graph convolution layer is constructed based on the training fusion features. The dynamic graph convolution layer dynamically constructs the graph structure by learning the similarity matrix between samples, and applies the graph convolution operation to extract high-order features. Graph convolution can effectively capture the local relationship between data and the dependency of high-order features, improve the quality of feature representation, and obtain the training graph convolution features. The graph convolution features are input into the multi-scale temporal convolution network. The network contains three parallel one-dimensional convolution branches, and the sizes of the convolution kernels are set to 3, 5, and 7 respectively. Each branch is followed by a maximum pooling layer. The change characteristics of battery current and power data at different time scales are extracted through convolution operations of different scales. An attention-enhanced bidirectional long short-term memory network layer (Bi-LSTM) is constructed. By taking the multi-scale temporal features as input and applying the self-attention mechanism on the output of the LSTM unit, the most important parts of the data can be highlighted while capturing the long-term dependency of the sequence data, thus obtaining the training context-aware features. The training context-aware features are input into the self-calibrated residual network. The network consists of 5 residual blocks, each of which uses layer normalization and ELU activation function to ensure the stability of the gradient during training and the nonlinear expression ability of the network. A self-calibration gating mechanism is added to the residual connection, so that the network can adaptively adjust the information transfer process according to the different input features, thereby improving the performance of the model and obtaining self-calibration features. Based on the self-calibration features, an uncertainty estimation layer is constructed. This layer adopts a multi-task learning framework to simultaneously predict the mean and variance of current and power and generate measurement results with probabilistic properties. During the entire training process, the negative log-likelihood loss function is used for optimization, combined with L1 regularization to prevent the model from overfitting, and a learning rate decay strategy is adopted to ensure the convergence of the model.End-to-end training is performed using the Adam optimizer to generate multiple current and power measurement models that are suitable for different sharing scenarios. These models can accurately measure and predict the current and power of the battery under different operating conditions and usage modes.
[0036] Step S5, performing temperature compensation and shared frequency compensation based on the measurement circuit topology to obtain a temperature and frequency compensation matrix;
[0037] Specifically, the measurement circuit topology of the shared charging device is analyzed to construct an initial equivalent circuit model. The equivalent circuit model can reflect the connection relationship and electrical characteristics of each component in the circuit. Based on the initial equivalent circuit, the node voltage method and the mesh current method are used to establish the mathematical model of the circuit. The node voltage method can reflect the potential difference between different nodes by solving the voltage of each node in the circuit, while the mesh current law is used to analyze the current distribution in each mesh, thereby comprehensively describing the operation state of the circuit. The mathematical model of the circuit is transformed into a symbolic matrix and algebraically simplified to obtain a set of decoupled subcircuit equations. By decoupling the complex circuit, the overall circuit is decomposed into multiple independent subcircuits. Based on the decoupled subcircuit equation set, a nonlinear characteristic model of the temperature sensitive element is constructed to form a temperature correlation coefficient matrix. The electrical characteristics of the temperature sensitive element will be different at different temperatures, and the nonlinear characteristic model is used to quantify the influence of temperature on the circuit performance. The temperature correlation coefficient matrix is thermodynamically analyzed to establish the heat conduction equation. The heat conduction equation describes the transfer and diffusion process of temperature in the circuit, which helps to understand the temperature changes in different parts of the circuit. In order to solve the heat conduction equation, the finite difference method is used as a numerical solution. The finite difference method can accurately obtain the spatial distribution function of the temperature by discretizing the continuous temperature field into a finite number of calculation points. Based on the temperature distribution function, the decoupled subcircuit is temperature compensated to correct the deviation of parameters such as resistance and inductance caused by temperature changes in the circuit, and the circuit parameters after temperature compensation are obtained. The circuit parameters after temperature compensation are analyzed in the frequency domain to study the response characteristics of the circuit at different frequencies. Especially in shared charging devices, the fluctuation of charging frequency and device usage frequency will have a great impact on the circuit. Through frequency domain analysis, a shared usage frequency impact model is constructed, and the corresponding frequency response function is calculated to quantify the specific impact of device usage frequency on circuit performance. Based on the frequency response function, the circuit parameters are compensated for shared usage frequency. Frequency compensation is to compensate for the performance loss caused by frequency changes by adjusting the frequency-related parameters in the circuit. In this process, the temperature compensation results are combined with the frequency compensation results to form a temperature and usage frequency compensation matrix.
[0038] Step S6: Based on the classification results of multiple working conditions and usage modes and the temperature and usage frequency compensation matrix, multiple current and power measurement models are fused and adaptively calibrated to obtain a current and power measurement model set.
[0039] Specifically, feature encoding is performed on the classification results of multiple working conditions and usage modes to obtain a working condition mode feature vector, which effectively characterizes the operating state of the battery under different working conditions. Based on the feature vector, multiple existing current and power measurement models are screened, and the model that can perform best under specific working conditions and usage modes is selected to form a candidate model subset. A temperature and usage frequency compensation matrix is applied to each model in the candidate model subset. The temperature compensation and usage frequency compensation can effectively correct the errors caused by ambient temperature changes and shared device usage frequency fluctuations to the current and power measurement model. By applying the compensated model parameters to each model, it is ensured that these models can maintain high accuracy under different temperature and frequency conditions. Based on the compensated model parameters, a dynamic weight coefficient is assigned to each model according to the contribution of different models to the measurement results to form a weighted model set. The weight coefficient is dynamically adjusted according to the performance of the model under different working conditions and usage modes, ensuring that the weighted model set can combine the advantages of multiple models and improve the overall performance. The weighted model set is integrated and learned. Through the integrated learning method, the output results of multiple weighted models are fused to generate an initial integrated model. A self-calibration layer containing multiple residual units and an attention mechanism is constructed on the basis of the initial integrated model. The residual unit can effectively capture the error between the model output and the true value, while the attention mechanism is used to highlight the most important features under different working conditions and usage modes. Through adaptive adjustment, the calibrated integrated model can more accurately reflect the actual current and power measurement results of the battery. For the calibrated integrated model, the posterior distribution of the model prediction is calculated to provide uncertainty estimates for the prediction results and improve the robustness of the model under different working conditions. On this basis, an adaptive threshold selector is constructed. The adaptive threshold selector dynamically adjusts the predicted threshold according to different working conditions and usage modes, so that the model can automatically select the optimal threshold to predict current and power in different situations, ensuring the accuracy and adaptability of the measurement results, and obtaining a set of current and power measurement models.
[0040] Among them, real-time data collection is performed on the ternary polymer lithium battery in the shared charging device to obtain key physical parameters such as current, voltage, and temperature. The collected data is preprocessed to remove noise, smooth the data, and normalize it to ensure that different features are analyzed under the same dimension to obtain a standardized real-time feature vector. Based on the standardized real-time feature vector, the current working condition category is determined by a pre-trained working condition classification model, such as whether the battery is in a high load, low load, or normal load state. The working condition classification model assigns a working condition identifier to each working state. After determining the working condition, the activation model corresponding to the current working condition is called from the current and power measurement model set. This model is designed and optimized according to the specific working condition and can ensure high-precision measurement results under different working conditions. The standardized real-time feature vector is input into the shared factor encoder in the activation model. The shared factor encoder encodes the input features and extracts important factors related to the use of the device, such as frequency of use, duration of use, ambient temperature, etc. The encoder is usually composed of a multi-layer neural network, and a more abstract shared factor feature is generated through a nonlinear activation function (such as GELU). In this way, the key usage features of the device can be fully extracted and encoded to form shared factor features after real-time encoding. The shared factor features after real-time encoding are input into the feature fusion layer and fused with the standardized real-time feature vector. The feature fusion layer weights and combines data from different sources to ensure that the fused features can simultaneously reflect the physical state and usage environment of the battery. Through the fusion operation, real-time fused features are generated. The real-time fused features are input into the dynamic graph convolution layer to extract high-order features. The dynamic graph convolution layer can extract the complex relationship between features by dynamically constructing the association graph between features, and capture the high-order dependency of the battery state. The real-time graph convolution features are generated through convolution operations. The real-time graph convolution features are input into the multi-scale temporal convolution network and the attention-enhanced bidirectional long short-term memory network (Bi-LSTM). The multi-scale temporal convolution network captures the changes of features in different time spans through multiple convolution kernels of different scales, while the Bi-LSTM can model the temporal dependency of features and identify the temporal information that is most critical to the current state through the attention mechanism. Bi-LSTM outputs real-time context-aware features that reflect the time-dependent characteristics and important contextual information of the battery under the current operating conditions. The real-time context-aware features are processed by a self-calibrated residual network to reduce the bias in the model prediction and generate preliminary raw measurement results in combination with uncertainty estimation. The self-calibrated residual network can enhance the model's ability to correct measurement errors by introducing residual connections and self-calibration mechanisms. The raw measurement results are corrected by combining the temperature and usage frequency compensation matrix to obtain real-time current and power measurement results. The compensation matrix adjusts the output of the battery measurement model according to the current environment temperature and the device usage frequency to ensure the accuracy and reliability of current and power measurements under complex conditions.
[0041] Further, the standardized real-time feature vector is decomposed to extract the charging frequency feature, the usage time feature and the ambient temperature feature. The charging frequency feature is input into the first fully connected layer of the charging frequency encoder, which maps the input feature to a new feature space through linear transformation to obtain the intermediate feature representation. The intermediate feature is processed by the GELU activation function. GELU is a nonlinear activation function that can improve the nonlinear representation ability of the model by introducing the smoothness of the Gaussian distribution, so that the model can better capture the complex patterns in the charging frequency feature. After this activation process, the activation output of the first layer is obtained. The activation output is input into the second fully connected layer of the charging frequency encoder to reduce the dimension and compress the information of the feature. Through the dimension reduction operation, the key information in the charging frequency feature is retained while reducing the influence of redundant features. The reduced dimension feature is processed by the GELU activation function again to obtain the activation output of the second layer. The activation output of the second layer is input into the third fully connected layer for feature mapping and semantic extraction. Through deep feature transformation, higher-level semantic information related to the charging frequency is extracted to form the encoding result of the charging frequency. Similar to the processing of charging frequency features, usage time features and ambient temperature features are processed through their respective fully connected layers. Each feature is processed by three layers of fully connected layers, and linear transformation, dimensionality reduction and semantic extraction are completed in turn to generate usage time encoding results and ambient temperature encoding results. The charging frequency encoding results, usage time encoding results and ambient temperature encoding results are feature fused. Through the feature fusion operation, features from different dimensions can be effectively integrated to form a comprehensive real-time encoded shared factor feature, which comprehensively reflects the real-time status of shared charging devices.
[0042] In the embodiment of the present invention, by multi-point sampling and preprocessing technology, combined with dynamic weight adjustment algorithm for feature selection, the key features of the battery can be effectively extracted, and the accuracy of current and power measurement can be significantly improved. The battery operating conditions and usage modes are classified by hierarchical clustering method, and multiple current and power measurement models are constructed, which can adapt to different sharing scenarios and usage conditions. By equivalently decoupling the measurement circuit and introducing temperature and usage frequency compensation matrix, the measurement parameters can be adjusted in real time, and the influence of environmental factors and usage frequency on the measurement results can be effectively eliminated. Model fusion and adaptive calibration technology are adopted, combined with Bayesian model averaging method, so that the measurement system can automatically adjust with the change of battery performance and maintain long-term measurement stability. By constructing an efficient neural network model and an optimized data processing flow, real-time measurement of current and power can be achieved to meet the rapid response requirements of shared charging equipment. Through the uncertainty estimation layer and probabilistic measurement results, the credibility of the measurement can be evaluated, providing a reliable basis for equipment management and fault warning. Based on the mechanism of operating condition identification and model selection, the most suitable model can be called for different situations, the use of computing resources can be optimized, and the overall efficiency of the system can be improved.
[0043] In a specific embodiment, the process of executing step S1 may specifically include the following steps:
[0044] Perform high-frequency sampling on ternary polymer lithium batteries in multiple shared charging devices, collect current, voltage, and temperature data, and obtain original sampling data;
[0045] The original sampling data is timestamped and associated with the device identification to obtain an original data set with spatiotemporal information, and based on the original data set with spatiotemporal information, the usage frequency and the number of charge and discharge cycles of each charging device are calculated to obtain the device usage characteristic data;
[0046] Perform multi-scale analysis of wavelet transform on the original data set with spatiotemporal information to obtain denoised signal data, and perform amplitude normalization and time scale normalization on the denoised signal data to obtain a standardized data set;
[0047] Based on the standardized data set, the dynamic time warping algorithm is used to identify and segment the charging cycle to obtain the cycle segmentation data;
[0048] Time series alignment and feature fusion are performed on the period segmentation data and the equipment usage feature data to obtain a multi-dimensional feature data set, and sliding window segmentation and overlapping sampling are performed on the multi-dimensional feature data set to generate a preprocessed data set.
[0049] Specifically, current, voltage, and temperature data are collected at high frequency through high-precision sensors. Assuming the sampling frequency is 1000 Hz, 1000 current, voltage, and temperature data points are obtained per second to form a high-precision raw data set. In order to mark these data, a timestamp is added to each data point to indicate the time series of the collection. At the same time, the associated device identifier , so that each data point With time and device information. The labeled original data set can be expressed as:
[0050] ;
[0051] in, is the total number of sampling points, is the timestamp, Is the device identifier. Based on the original data set with spatiotemporal information, the usage frequency and charge-discharge cycle number of each charging device are calculated. Usage frequency It can be calculated by the following formula:
[0052] ;
[0053] in, Is the device in the time interval The number of charge and discharge cycles can be measured by monitoring the voltage Count the number of complete cycles of voltage from low to high (charging) and then from high to low (discharging) over time , expressed as:
[0054] ;
[0055] in, Represents the change in voltage, is the time interval. After obtaining the device usage characteristic data, the wavelet transform is used to perform multi-scale analysis on the original data set with time and space information. The wavelet transform can separate the noise and useful signal in the signal and obtain the denoised signal data. , its wavelet transform It can be calculated by the following formula:
[0056] ;
[0057] in, is the scale parameter, is the translation parameter, is the wavelet function, is its conjugate complex number. After denoising, the signal data is amplitude normalized and time scale normalized. Amplitude normalization normalizes all data to the interval of 0 to 1, and time scale normalization ensures the consistency of data on different time scales by standardizing the time interval. Based on the standardized data set, the dynamic time warping algorithm is used to identify and segment the charging cycle. Dynamic time warping is an algorithm used to compare time series of different lengths. It can match two time series on a nonlinear time scale and identify periodic behavior. For two time series and , its dynamic time warping distance can be expressed as:
[0058] ;
[0059] Dynamic time warping finds the best matching path between two time series. Even if different devices have different charging speeds, the algorithm can still identify similar charging cycles. Dynamic time warping obtains cycle segmentation data to ensure accurate segmentation of charging behavior. Time series alignment and feature fusion are performed on the cycle segmentation data and the device usage feature data. Time series alignment is to synchronize different feature data according to the time sequence to ensure the matching relationship between multi-dimensional data. For example, feature data such as the frequency of use of the device and the number of charge and discharge cycles need to be compared with the corresponding cycle segmentation data on the same time axis. Through this operation, a multi-dimensional feature data set is generated, including dynamic information of current, voltage, and temperature data, as well as statistical features such as device usage frequency and charge and discharge cycles. In order to improve the availability of data, sliding window segmentation and overlapping sampling are performed on the multi-dimensional feature data set. Sliding window technology segments data on the time axis by setting a fixed-length window (such as 5 seconds or 10 seconds), and overlapping sampling sets partial overlapping areas between adjacent windows to ensure data continuity and feature integrity. For example, if the window length is 10 seconds and the overlap time is 2 seconds, the data of the first window is 0-10 seconds, and the data of the second window is 8-18 seconds. Through the sliding window segmentation and overlapping sampling technology, the continuity between the data in different time periods is guaranteed, and a richer preprocessed data set is generated.
[0060] In a specific embodiment, the process of executing step S2 may specifically include the following steps:
[0061] Perform time domain and frequency domain analysis on the preprocessed data set to obtain an initial feature set, and based on the initial feature set, calculate the change rate of key parameters in the charging and discharging process to obtain dynamic change characteristics;
[0062] The initial feature set and the dynamically changing features are combined to construct a comprehensive feature vector, and based on the comprehensive feature vector, the influence of each feature on the battery performance is calculated to obtain the feature importance ranking;
[0063] According to the feature importance sorting, multiple importance thresholds are set to divide the features into multiple levels to obtain a hierarchical feature set, and the features in the hierarchical feature set are subjected to correlation analysis to obtain a streamlined feature set;
[0064] Based on the streamlined feature set, a dynamic weight adjustment model is constructed to initialize the feature weights to obtain an initial weight allocation scheme. According to the initial weight allocation scheme and combined with the usage pattern of shared charging devices, the feature weights are dynamically adjusted to obtain multiple target feature subsets.
[0065] Specifically, the time series of signals such as current, voltage, and temperature are extracted from the original data set. Time domain analysis mainly examines the characteristics of signal changes over time, such as whether the battery voltage has an obvious upward or downward trend during the charging and discharging process, whether there is a peak in the current, etc. In time domain analysis, common statistics include mean, variance, peak, skewness, and kurtosis. Through time domain statistics, we can preliminarily understand the change pattern of voltage during battery charging and discharging. Frequency domain analysis converts time domain signals into frequency domain signals by performing Fourier transform on the signal, and analyzes the frequency components of the signal. Through fast Fourier transform, the voltage or current signal is converted into a frequency domain signal. Convert to frequency domain representation , the formula is:
[0066] ;
[0067] In the frequency domain, the amplitude and phase information of specific frequency components can reveal the response characteristics of the battery in different frequency ranges, especially whether there is noise or abnormal vibration in different frequency bands during the charging and discharging process. The time domain and frequency domain analysis results are combined to obtain the initial feature set. Based on the initial feature set, the change rate of key parameters during the charging and discharging process is calculated to extract dynamic change features. Dynamic change features reflect the rate of change of the battery state over time. For example, the voltage change rate Able to describe how quickly the voltage changes when a battery is charging or discharging:
[0068] ;
[0069] in, and The time and The voltage value at the time of charging and discharging. The dynamic change characteristics help predict the health status of the battery. Similarly, the rate of change of current and temperature can be calculated in the same way to obtain a complete feature set that reflects the dynamic changes of different parameters during battery charging and discharging. Based on the initial feature set and the dynamic change characteristics, these features are combined to construct a comprehensive feature vector. The comprehensive feature vector can comprehensively characterize the state of the battery under different working conditions, including time domain characteristics, frequency domain characteristics, and dynamic change characteristics. Assume that features, the comprehensive feature vector can be expressed as:
[0070] ;
[0071] in, Indicates Features. Based on the comprehensive feature vector, the feature importance is calculated by the degree of influence of the feature on the battery performance. Feature importance ranking can usually be achieved through regression analysis or decision tree model. The importance score of each feature is obtained by calculating the contribution of each feature to the target variable (such as battery health status or performance). For a feature , its feature importance It can be calculated by the correlation between the feature and the target variable or the contribution rate in the model. According to different feature importance scores, multiple importance thresholds are set to divide the features into multiple levels. For example, the features are divided into three levels: high importance, medium importance, and low importance. The stratified feature set can better focus on the features that have the greatest impact on battery performance, while weakly correlated features can be appropriately filtered out. Perform correlation analysis on the features in the stratified feature set to remove redundant information. Correlation analysis is completed by calculating the correlation coefficient between two features, and the formula is:
[0072] ;
[0073] in, It is a feature and The correlation coefficient between is their covariance, and is their standard deviation. If If it is close to 1, it means that the two features are highly correlated, and one of them can be retained to obtain a streamlined feature set. Based on the streamlined feature set, a dynamic weight adjustment model is constructed to assign a dynamically adjusted weight to each feature. The initial weight allocation scheme is determined based on the feature importance ranking. Assume that each feature The initial weight is , then the weight initialization scheme can be expressed as:
[0074] ;
[0075] in, It is a feature The importance score of are the initially assigned weights. The weights of these features are dynamically adjusted according to the usage pattern of the shared charging device. For example, when the battery is under high load, the weight of the current feature may need to be increased; while in a low temperature environment, the weight of the temperature feature should be appropriately increased. By dynamically adjusting the feature weights, it is ensured that the model can capture the most critical features under different working conditions and usage patterns. Through these steps, multiple target feature subsets can be obtained, each of which reflects the feature performance under different working conditions.
[0076] In a specific embodiment, the process of executing step S3 may specifically include the following steps:
[0077] Normalize multiple target feature subsets to obtain a standardized feature matrix, and calculate the Euclidean distance between features based on the standardized feature matrix to construct a distance matrix;
[0078] According to the distance matrix, the minimum distance method is used to perform initial clustering on the features to obtain the initial clustering results, and the initial clustering results are hierarchically merged to construct a clustering tree structure to obtain a multi-level clustering model;
[0079] Based on the multi-level clustering model, the distance ratio between classes and within classes is calculated to determine the optimal number of clusters to obtain the optimized clustering results. The characteristics of each category in the optimized clustering results are analyzed, and the category feature vector is extracted to obtain the working condition feature set.
[0080] According to the working condition feature set, combined with the time and space usage data of the shared charging equipment, a usage mode descriptor is constructed to obtain a usage mode feature set;
[0081] The operating condition feature set and the usage pattern feature set are combined and analyzed to generate the joint distribution of the operating condition and the usage pattern, and obtain multiple operating condition and usage pattern category results.
[0082] Specifically, each feature is standardized so that in the subsequent clustering process, each feature can be compared at the same scale. The purpose of normalization is to eliminate the dimensional differences of different features. For example, current and temperature may have different numerical ranges, and normalization can map them to the same range (usually between 0 and 1), so that the influence of different features is relatively balanced, and a standardized feature matrix is obtained, in which each row represents a feature and each column represents a different sample point. The Euclidean distance between features is calculated based on the standardized feature matrix to quantify the similarity of different features in multidimensional space. Features with smaller distances mean that they are closer in data distribution. The calculation formula for Euclidean distance is:
[0083] ;
[0084] in, and Characteristics and Features The vector of is the number of samples, and It is The eigenvalues corresponding to the samples. Through this formula, we can get the distance matrix between the features , where each element Representation characteristics and Features The Euclidean distance between them. According to the distance matrix, the minimum distance method is used to perform initial clustering of the features. The minimum distance method is a basic method of hierarchical clustering. By continuously merging the two features with the closest distance into one cluster, multiple clusters are gradually formed. In the initial clustering stage, each feature is treated as an independent cluster, and then gradually merged according to the minimum value in the distance matrix. The initial clustering results will reflect the similarity between different features, and this process gradually establishes the connection between the features. The initial clustering results are hierarchically merged to construct a clustering tree structure. The hierarchical clustering tree (also called a dendrogram) can show the aggregation process between features from individuals to the whole. By continuously merging the closest feature clusters, a multi-level clustering model is generated. In this model, low-level clusters represent strong correlations between features, while high-level clusters reflect feature similarities in a larger range. Based on this multi-level clustering model, the ratio of inter-class and intra-class distances is calculated to determine the optimal number of clusters. The intra-class distance represents the similarity between features in the same class, while the inter-class distance reflects the difference between different classes. By calculating the ratio of the distance between classes and within classes, we can find a cluster number that can maximize the difference between classes and minimize the difference within classes. and intra-class distance The ratio can be expressed by the following formula:
[0085] ;
[0086] By maximizing the ratio , determine the optimal number of clusters. When the ratio reaches the maximum value, the clustering effect is the best. According to the optimal number of clusters, feature analysis is performed on each category, and the feature vector of each category is extracted. The main mode of each type of feature is comprehensively reflected to form a working condition feature set. Based on the working condition feature set, the usage mode descriptor is constructed in combination with the time and space usage data of the shared charging device. The usage mode of the shared charging device depends not only on the physical state of the battery (such as current and voltage), but also on the frequency of use of the device, time period and geographical location. Time and space data can help identify the usage scenarios of the device. For example, some devices may be frequently used during peak hours, while other devices may be used less in low temperature environments. By analyzing these data, a usage mode descriptor is constructed for each device to form a usage mode feature set. The working condition feature set and the usage mode feature set are combined and analyzed to generate a joint distribution of working conditions and usage patterns, revealing the working state of the battery in different usage scenarios. The working condition feature set describes the physical state of the battery, while the usage mode feature set provides contextual information related to the use of the device. By combining the two, the working condition exhibited by the battery under a specific usage mode is identified. For example, some devices may show a significant voltage drop in a long-term high-load usage mode, but perform stably in a light-load usage mode. Through combined analysis, a joint distribution of operating conditions and usage modes is generated to reflect the correlation between different operating conditions and usage modes. Based on the joint distribution, the classification results of multiple operating conditions and usage modes are obtained to help predict the performance of batteries in different usage environments.
[0087] In a specific embodiment, the process of executing step S4 may specifically include the following steps:
[0088] Perform one-hot vector encoding on multiple working condition and usage mode category results to obtain category feature vectors;
[0089] The category feature vector is concatenated with multiple target feature subsets, and feature interaction is performed through a multi-head self-attention mechanism to obtain an enhanced feature vector;
[0090] Construct a shared factor encoder, which includes three parallel sub-networks: charging frequency encoder, usage time encoder, and ambient temperature encoder. Each sub-network consists of three fully connected layers and uses the GELU activation function to obtain the shared factor features after training encoding.
[0091] The enhanced feature vector and the encoded shared factor features are input into the feature fusion layer. The feature fusion layer adopts a gated linear unit structure to achieve adaptive fusion of features and obtain training fusion features.
[0092] A dynamic graph convolution layer is constructed based on the training fusion features. The dynamic graph convolution layer dynamically constructs the graph structure by learning the similarity matrix between samples, and applies the graph convolution operation to extract high-order features to obtain the training graph convolution features.
[0093] The graph convolution features are input into the multi-scale temporal convolutional network. The multi-scale temporal convolutional network contains three parallel one-dimensional convolution branches with convolution kernel sizes of 3, 5, and 7 respectively. Each branch is followed by a maximum pooling layer to obtain multi-scale temporal features.
[0094] Construct an attention-enhanced bidirectional long short-term memory network layer, which uses multi-scale temporal features as input and applies a self-attention mechanism on the output of the LSTM unit to obtain training context-aware features;
[0095] The trained context-aware features are input into the self-calibrated residual network, which contains five residual blocks. Layer normalization and ELU activation function are used inside each residual block, and a self-calibrated gating mechanism is added to the residual connection to obtain self-calibrated features.
[0096] An uncertainty estimation layer is constructed based on the self-calibration features. The uncertainty estimation layer adopts a multi-task learning framework to simultaneously predict the mean and variance of current and power to obtain probabilistic measurement results.
[0097] The negative log-likelihood loss function is used, combined with L1 regularization and learning rate decay strategy, and the Adam optimizer is used for end-to-end training to obtain multiple current and power measurement models that are suitable for different sharing scenarios.
[0098] Specifically, one-hot vector encoding is performed on multiple working conditions and usage mode category results. One-hot encoding is a commonly used classification feature encoding method that converts category information into a binary vector. For example, assuming there are three usage mode categories (A, B, C), the one-hot vector encodes category A as [1, 0, 0], category B as [0, 1, 0], and category C as [0, 0, 1]. Through encoding, a category feature vector is obtained, which can effectively represent the state of each device in different usage modes. The category feature vector is concatenated with multiple target feature subsets. The target feature subset may include physical features such as battery current, voltage, temperature, and device usage frequency, time, and space features. By concatenating the category features with these target features, a more comprehensive feature vector is formed, which can simultaneously reflect the physical state and usage mode of the battery. In order to mine the complex relationship between features, a multi-head self-attention mechanism is used for feature interaction. The multi-head self-attention mechanism captures the interdependence between features through multiple attention heads, and can generate enhanced feature vectors in different contexts. The core formula of the self-attention mechanism is as follows:
[0099] ;
[0100] in, is the query matrix, is the key matrix, is the value matrix, is the feature dimension. Through the formula, the similarity between feature vectors is quantified, so as to better learn the relationship between features. A shared factor encoder is constructed to capture the shared features of the equipment under different working conditions. It consists of three parallel sub-networks: charging frequency encoder, usage time encoder, and ambient temperature encoder. Each sub-network consists of three fully connected layers, and the GELU activation function is used to enhance the nonlinear expression ability. The GELU activation function is more advantageous than the ReLU function because it combines randomness and nonlinearity and can process small value inputs more smoothly. The formula is:
[0101] ;
[0102] Through the encoder, the encoding features of the shared factors are generated to reflect the impact of the device's usage frequency, usage time and ambient temperature in different scenarios. The enhanced feature vector and shared factor features are input into the feature fusion layer for fusion. The feature fusion layer adopts the gated linear unit (GLU) structure to achieve adaptive fusion of features. The GLU structure can effectively filter out irrelevant information by performing gating operations on different input features, retaining only features that are useful for the current working conditions and usage patterns. The fused features can better reflect the overall status of the device and generate training fusion features. Based on the training fusion features, a dynamic graph convolution layer is constructed. The dynamic graph convolution layer can dynamically construct a graph structure based on the similarity between samples and capture high-order dependencies between features. Dynamic graph convolution not only considers the direct relationship between local features, but also extracts deeper feature representations through graph convolution operations. Its core formula is:
[0103] ;
[0104] in, is the adjacency matrix of the graph, is the degree matrix, It is The feature matrix of the layer, is the weight matrix, is the activation function. Through dynamic graph convolution operations, higher-order training graph convolution features are extracted. The graph convolution features are input into a multi-scale temporal convolutional network. The network consists of three parallel one-dimensional convolution kernels with kernel sizes of 3, 5, and 7 to capture feature changes at different time scales. Each convolution branch is followed by a maximum pooling layer to extract key temporal features. Through multi-scale convolution operations, it can effectively cope with complex temporal data with changes such as battery charging time and usage frequency. An attention-enhanced bidirectional long short-term memory network layer is constructed to capture the forward and backward dependencies of temporal data, while the self-attention mechanism further strengthens the focus on important temporal fragments. By taking multi-scale temporal features as input, the bidirectional long short-term memory network can generate training context-aware features that reflect the temporal and contextual information in the data. The training context-aware features are input into a self-calibrated residual network. The self-calibrated residual network consists of 5 residual blocks, each of which uses layer normalization and ELU activation functions to ensure the stability of gradients and the nonlinear expression ability of the model in deep networks. Adding a self-calibration gating mechanism to the residual connection can dynamically adjust the residual path according to the changes in the input features, thereby improving the flexibility and accuracy of the model. Through the residual block, the self-calibration feature is finally generated. Based on the self-calibration feature, an uncertainty estimation layer is constructed. This layer uses a multi-task learning framework to simultaneously predict the mean and variance of current and power to generate probabilistic measurement results. Uncertainty estimation can provide confidence intervals for the results predicted by the model, thereby improving the robustness of the model. For current and power The mean and variance prediction of can be expressed by the following loss function:
[0105] ;
[0106] in, and are the predicted values of current and power respectively, and is the standard deviation of the uncertainty estimate. In order to optimize the model training process, the negative log-likelihood loss function is used, combined with L1 regularization to prevent overfitting. At the same time, the learning rate decay strategy is adopted to ensure that the model can gradually converge during the training process. The entire model is trained end-to-end through the Adam optimizer, and the model parameters are gradually adjusted to enable it to adapt to current and power measurement in different sharing scenarios.
[0107] In a specific embodiment, the process of executing step S5 may specifically include the following steps:
[0108] The measurement circuit topology of the shared charging device is analyzed to obtain the initial equivalent circuit. Based on the initial equivalent circuit, the node voltage method and mesh current method are applied to establish the circuit mathematical model.
[0109] The circuit mathematical model is transformed into a symbolic matrix and algebraically simplified to obtain a set of decoupled subcircuit equations, and based on the decoupled subcircuit equations, a nonlinear characteristic model of the temperature sensitive element is constructed to obtain a temperature correlation coefficient matrix;
[0110] Perform thermodynamic analysis on the temperature correlation coefficient matrix, establish the heat conduction equation, and use the finite difference method to solve it to obtain the temperature distribution function. Based on the temperature distribution function, perform temperature compensation on the decoupled sub-circuit to obtain the circuit parameters after temperature compensation.
[0111] Perform frequency domain analysis on the circuit parameters after temperature compensation, build the impact model of shared frequency, and obtain the frequency response function;
[0112] Based on the frequency response function, the circuit parameters are shared using frequency compensation, and combined with the temperature compensation result, the temperature and using frequency compensation matrix is obtained.
[0113] Specifically, the measurement circuit topology of the shared charging device is analyzed to obtain the initial equivalent circuit. The measurement circuit is usually composed of basic components such as resistors, inductors, capacitors, and some temperature-sensitive components. The equivalent circuit model converts the complex circuit topology into a mathematically tractable form by simplifying the actual structure of the circuit. In this process, the voltage and current of each circuit node are accurately described. After obtaining the initial equivalent circuit, the node voltage method and the mesh current method are used to establish the mathematical model of the circuit. The node voltage method establishes equations by analyzing the voltages of each node in the circuit, while the mesh current law establishes equations by analyzing the flow of current in each loop. The basic principle of the node voltage method is Kirchhoff's current law, that is, the principle of "inflow current equals outflow current" is applied to each node. For a with The voltage equation of a circuit with nodes can be expressed in matrix form as:
[0114] ;
[0115] in, It is the admittance matrix, which contains information about all resistors, capacitors, and other components in the circuit; is the node voltage vector, representing the voltage at each node; is the current vector, which represents the injected current of each node. By solving this set of equations, the voltage distribution of each node is obtained. At the same time, the mesh current method is based on Kirchhoff's voltage law, the core of which is that for each loop, the voltage drop in the loop is equal to the power supply voltage in the loop. The current equation of a mesh can be expressed as:
[0116] ;
[0117] in, is the resistance matrix, representing the impedance in each loop, is the mesh current vector, is the power supply voltage vector. By solving this equation, the current distribution in each mesh is obtained. The mathematical model of the circuit is transformed into a symbolic matrix and algebraically simplified. The symbolic matrix transformation is to standardize the complex circuit equations, and in the process of algebraic simplification, some redundant variables are eliminated to obtain a set of decoupled sub-circuit equations. The decoupled equations enable each sub-circuit to be analyzed and calculated independently of other circuits. Based on the decoupled sub-circuit equation set, a nonlinear characteristic model of the temperature-sensitive element is constructed. The resistance of temperature-sensitive elements (such as thermistors) will change at different temperatures, and their nonlinear characteristics can be described by empirical formulas or experimental data. For example, for a temperature-sensitive resistor , the relationship between resistance and temperature can be expressed as:
[0118] ;
[0119] in, is the reference temperature The resistance value below is the temperature coefficient, which indicates the effect of temperature change on resistance. In this way, the temperature correlation coefficient matrix is obtained: , each element of which reflects the characteristics of circuit components at different temperatures. Thermodynamic analysis is performed on the temperature correlation coefficient matrix to establish the heat conduction equation to describe the conduction and diffusion of temperature in the circuit. The basic form of the heat conduction equation is:
[0120] ;
[0121] in, is the temperature distribution function, is the thermal conductivity, is the Laplace operator, which represents the spatial variation of temperature. In order to solve this equation, the finite difference method is used. The finite difference method discretizes the continuous temperature variation into a finite number of calculation points to obtain the distribution of temperature at each time and spatial point. By solving the heat conduction equation, the temperature distribution function is obtained. , which describes the change of temperature with time and space. Based on the temperature distribution function, the decoupled sub-circuit is temperature compensated and the circuit parameters are adjusted so that the circuit can maintain a stable working state at different temperatures. By performing temperature compensation on the resistance, capacitance and other parameters of the circuit, the circuit performance fluctuations caused by temperature changes can be avoided, and the circuit parameters after temperature compensation are obtained. The temperature-compensated circuit parameters are analyzed in the frequency domain. The frequency domain analysis converts the time response of the circuit into the frequency response to understand the behavioral characteristics of the circuit at different frequencies. Through Fourier transform, the time domain equation of the circuit is converted into the frequency domain equation, and a shared frequency impact model is constructed. For the voltage in the circuit , its frequency domain representation for
[0122] ;
[0123] Through frequency domain analysis, the frequency response function of the circuit at different frequencies is obtained , which describes the response characteristics of the circuit to different frequency signals. Based on the frequency response function , and share the use frequency compensation of the circuit parameters. The use frequency of the shared charging device will affect the working state of the circuit, especially at high frequencies, the parasitic inductance and capacitance in the circuit may cause instability. Through frequency compensation, adjust the circuit parameters to keep it stable at different use frequencies. Combine the temperature compensation results with the frequency compensation results to get the temperature and use frequency compensation matrix , each element of which represents the correction value of the circuit parameter at a specific temperature and operating frequency.
[0124] In a specific embodiment, the process of executing step S6 may specifically include the following steps:
[0125] Feature encoding is performed on the classification results of multiple working conditions and usage modes to obtain a working condition mode feature vector, and model selection is performed on multiple current and power measurement models based on the working condition mode feature vector to obtain a candidate model subset;
[0126] Applying temperature and usage frequency compensation matrices to each model in the candidate model subset to obtain compensated model parameters, and assigning dynamic weight coefficients to each model based on the compensated model parameters to obtain a weighted model set;
[0127] Perform ensemble learning on the weighted model set to obtain an initial ensemble model, and build a self-calibration layer containing multiple residual units and attention mechanisms based on the initial ensemble model, adaptively adjust the model output, and obtain a calibrated ensemble model;
[0128] For the calibrated integrated model, the posterior distribution of the model prediction is calculated, and an adaptive threshold selector is constructed to dynamically adjust the prediction threshold according to different working conditions and usage patterns to obtain the current and power measurement model set.
[0129] Specifically, feature encoding is performed for different working conditions and usage modes, and the classification results are converted into numerical vector representations that can be directly input into the model. One-hot encoding is used to map each category into a unique binary vector. For example, if there are three different working conditions (such as "high load", "medium load" and "low load"), the corresponding codes are [1, 0, 0], [0, 1, 0] and [0, 0, 1] respectively. In this way, different working conditions and usage modes are converted into numerical features to construct a complete working condition mode feature vector. Based on the working condition mode feature vector, multiple current and power measurement models are selected. According to the current working condition mode characteristics, suitable current and power measurement models are screened out. Each model may be optimized for different working conditions and usage scenarios. Model selection can be matched to the most suitable model set based on the working condition characteristics of the current device. This process can be completed by calculating the fitness of the working condition mode feature vector and each model. For example, if a model is designed for the "high load" working condition, then the priority of the model will be higher in the high load mode. The screened models form a candidate model subset. For each model in the candidate model subset, apply the temperature and use frequency compensation matrix to correct the deviation of the model caused by temperature changes and frequency fluctuations in actual operation. Temperature and use frequency compensation matrix By adjusting the circuit parameters (such as resistance and capacitance), the model can be kept stable under different environmental conditions. The compensated model parameters can be expressed as:
[0130] ;
[0131] in, represents the original model parameters, is the compensated parameter, is the compensation matrix. By applying the compensation matrix, the model can automatically adapt to different temperatures and usage frequencies to ensure the accuracy of the prediction results. Based on the compensated model parameters, a dynamic weight coefficient is assigned to each model to generate a weighted model set. The dynamic weight dynamically adjusts the contribution of the model in the weighted model set according to the performance and compensation effect of the model under the current working conditions. Weight coefficient The distribution can be based on the performance indicators of the model (such as error or accuracy), the formula is:
[0132] ;
[0133] in, It is a model The smaller the error, the greater the weight of the model, and vice versa. By weighting, a weighted model set is obtained so that the output of each model is combined according to its importance. The weighted model set is integrated and learned to obtain the initial integrated model. The goal of integrated learning is to fuse the prediction results of multiple models to obtain a comprehensive model that performs better than a single model. The initial integrated model is obtained by weighted averaging the prediction results of the weighted model set or by voting. In order to improve the accuracy and adaptability of the integrated model, a self-calibration layer containing multiple residual units and attention mechanisms is constructed based on the initial integrated model. The residual unit can help the model capture deep features, while the attention mechanism enables the model to focus on the most critical information. The basic form of the residual unit is:
[0134] ;
[0135] in, are input features, is a function that performs nonlinear transformation on features (such as convolutional layer), is the weight parameter. By making a residual connection between the input and output, the model can avoid the gradient vanishing problem and effectively capture the deep relationships in the data. The attention mechanism focuses on the features that have the greatest impact on the output by assigning different weights to different parts of the input features. The calculation formula for attention is:
[0136] ;
[0137] in, is the query matrix, is the key matrix, is the value matrix, is the feature dimension. Through this mechanism, the self-calibration layer can adaptively adjust the model output and improve the accuracy of the model. On the calibrated integrated model, the posterior distribution of the model prediction is calculated to better evaluate the uncertainty of the prediction results. The posterior distribution can provide a confidence interval for each predicted value to help understand the reliability of the prediction. For the prediction of current and power, the posterior distribution can be calculated using the Bayesian formula, and the uncertainty of the prediction is represented by the variance of the model. Construct an adaptive threshold selector. The goal of the adaptive threshold selector is to dynamically adjust the prediction threshold according to different working conditions and usage patterns. The prediction accuracy of current and power may vary under different usage modes, so different thresholds need to be set according to the working condition characteristics. For example, in high load mode, a higher threshold may be required to cope with power fluctuations, while in low load mode, the threshold can be relatively low. The setting of the adaptive threshold can be achieved by analyzing the error distribution in historical data, and dynamically adjusting the threshold can ensure the accuracy of the model in different scenarios.
[0138] In a specific embodiment, the current and power measurement method of the ternary polymer lithium battery of the shared charging device further includes the following steps:
[0139] Real-time data collection and preprocessing of ternary polymer lithium batteries in shared charging equipment are performed to obtain standardized real-time feature vectors;
[0140] Determine the current operating condition category based on the standardized real-time feature vector, obtain the operating condition identifier, and call the corresponding activation model from the current and power measurement model set according to the operating condition identifier;
[0141] Input the standardized real-time feature vector into the shared factor encoder of the activation model to obtain the shared factor features after real-time encoding;
[0142] The shared factor features after real-time encoding are input into the feature fusion layer and fused with the standardized real-time feature vector to obtain the real-time fusion feature;
[0143] Input the real-time fusion features into the dynamic graph convolution layer for high-order feature extraction to obtain real-time graph convolution features;
[0144] The real-time graph convolution features are input into the multi-scale temporal convolutional network and the attention-enhanced bidirectional long short-term memory network layer to obtain real-time context-aware features;
[0145] The real-time context-aware features are self-calibrated for residual and uncertainty estimation to obtain raw measurements, which are then combined with temperature and frequency compensation matrices to obtain real-time current and power measurements.
[0146] Specifically, important physical parameters such as current, voltage, and temperature are collected from the device through high-precision sensors. The collected raw data is preprocessed, including denoising, data smoothing, and normalization operations, so as to eliminate measurement noise, outliers, and scale differences between different features, and obtain a standardized real-time feature vector. Based on the standardized real-time feature vector, the current battery operating condition category is determined. The operating condition category can be predicted by a pre-trained classification model. The classification model can classify the current state into different operating condition categories, such as "high load", "normal operation", or "low load", based on the battery's current, voltage, temperature, and other characteristics. Assuming that a K-nearest neighbor classifier is used, the model determines the nearest operating condition category by calculating the distance between the real-time feature vector and each operating condition in the training set. The operating condition identifier is the identifier of the category, which determines what working state the current battery is in. Based on the determined operating condition identifier, the corresponding activation model is called from the pre-trained current and power measurement model set. Each model is optimized for different operating conditions. For example, assuming that the current operating condition of the battery is "high load", the system will activate a model designed specifically for high load conditions from the model set. The standardized real-time feature vector is input into the shared factor encoder in the activation model. The role of the shared factor encoder is to extract key features based on specific usage factors of the device (such as frequency of use, duration of use, and temperature) to improve the expressiveness of the model. The encoder can contain multiple layers of fully connected neural networks, which are processed by nonlinear activation functions (such as ReLU or GELU) to generate real-time encoded shared factor features. The real-time encoded shared factor features are input into the feature fusion layer. The shared factor features are fused with the original standardized real-time feature vector. A commonly used fusion method is the gated linear unit, which controls the weights of different features so that important features are given greater weights, while the influence of irrelevant or redundant features is weakened. The formula for feature fusion can be expressed as:
[0147] ;
[0148] in, and is a trainable weight matrix, is the activation function, is the fused feature. The obtained real-time fused feature can comprehensively reflect the current state of the battery and the influence of shared factors. The real-time fused feature is input into the dynamic graph convolution layer for high-order feature extraction. The dynamic graph convolution layer dynamically builds the graph structure by learning the similarity between features, and applies convolution operations in the graph to extract high-order features of the battery state. The formula for dynamic graph convolution is:
[0149] ;
[0150] in, It is The feature matrix of the layer, is the adjacency matrix of the graph, which represents the connection relationship between features. is the degree matrix, is a trainable weight matrix, is the activation function. Through dynamic graph convolution, high-order correlation features under battery status can be extracted and real-time graph convolution features can be generated. The extracted real-time graph convolution features are input into the multi-scale temporal convolutional network and the attention-enhanced bidirectional long short-term memory network layer. The multi-scale temporal convolutional network contains convolution kernels of different sizes to capture feature changes at different time scales in the data. The formula is:
[0151] ;
[0152] in, , , It is a convolution operation with different kernel sizes. Concat means concatenating the convolution results of different scales. The bidirectional long short-term memory network is used to capture the temporal dependencies in the data. It can process the bidirectional temporal relationship of the input features. At the same time, it focuses on the temporal information that has an important impact on the current battery status through the self-attention mechanism, generating real-time context-aware features. . The real-time context-aware features are processed with self-calibrated residual networks and uncertainty estimation. The self-calibrated residual network can correct errors in deep features. The formula of the residual unit is:
[0153] ;
[0154] in, is a nonlinear transformation, are input features, is the output feature. The self-calibration network combines the current input and the calibration results of the model to ensure that the model can maintain high accuracy under complex working conditions. The uncertainty estimation estimates the uncertainty of the measurement results by predicting the mean and variance. The formula is:
[0155] ;
[0156] in, is the predicted mean, is the standard deviation, is a random variable used to capture the uncertainty of the prediction. Combined with the uncertainty estimate, the raw measurement result is obtained. Combined with the temperature and use frequency compensation matrix, the raw measurement result is corrected to obtain the final real-time current and power measurement result. The compensation matrix The measurement deviation caused by temperature and frequency changes is corrected by the formula:
[0157] ;
[0158] in, is the original measurement result, It is the result after compensation. Through real-time measurement and compensation, the system can accurately measure current and power under complex working conditions.
[0159] In a specific embodiment, the process of executing the step of inputting the standardized real-time feature vector into the shared factor encoder of the activation model to obtain the shared factor feature after real-time encoding may specifically include the following steps:
[0160] Perform feature decomposition on the standardized real-time feature vector to obtain charging frequency features, usage time features, and ambient temperature features;
[0161] Input the charging frequency feature into the first fully connected layer of the charging frequency encoder, perform linear transformation on the input feature to obtain an intermediate feature representation, and apply the GELU activation function to the intermediate feature representation to introduce nonlinear transformation to obtain the first layer activation output;
[0162] The activation output of the first layer is input into the second fully connected layer of the charging frequency encoder to perform feature dimension reduction and information compression to obtain the reduced dimension features, and the GELU activation function is applied to the reduced dimension features to obtain the activation output of the second layer;
[0163] The activation output of the second layer is input into the third fully connected layer of the charging frequency encoder for feature mapping and semantic extraction to obtain the charging frequency encoding result;
[0164] According to the usage time characteristics and the ambient temperature characteristics, the usage time encoding result and the ambient temperature encoding result are obtained respectively;
[0165] The encoding results of charging frequency, usage duration and ambient temperature are fused to obtain the shared factor features after real-time encoding.
[0166] Specifically, the standardized real-time feature vector is decomposed into three key sub-features: charging frequency feature, usage time feature, and ambient temperature feature. The standardized real-time feature vector usually contains multi-dimensional data, such as battery voltage, current, temperature, usage time, etc. Through indexing or feature selection algorithms, feature subsets directly related to charging frequency, usage time, and ambient temperature are extracted. For example, assuming the standardized feature vector ,in Represents the charging frequency, Represents the usage time, Represents the ambient temperature. Three independent feature subsets are obtained through feature decomposition: charging frequency feature , Usage duration characteristics and ambient temperature characteristics .Charge frequency characteristics Input to the first fully connected layer of the charging frequency encoder. The fully connected layer is a linear transformation operation, which is used to linearly combine the input charging frequency features to generate an intermediate feature representation. This process can be expressed by the following formula:
[0167] ;
[0168] in, is the output of the first fully connected layer, is the weight matrix of the first layer, is the input charging frequency characteristic, is the bias term. Through linear transformation, an intermediate feature representation is obtained. In order to introduce nonlinear characteristics and avoid the model being too simple, the GELU activation function is applied to the intermediate feature representation. GELU is a nonlinear activation function that can introduce randomness and smoothness through Gaussian distribution. The formula is as follows:
[0169] ;
[0170] Through the GELU activation function, the activation output of the first layer is obtained . Output the first layer activation As input, the second fully connected layer of the charging frequency encoder is input. The main function of the second fully connected layer is to reduce the dimension and compress the input features. Through the dimensionality reduction operation, the most representative information is retained and the feature dimension is reduced to prevent overfitting problems. The linear transformation of the second layer can be expressed as:
[0171] ;
[0172] in, is the output of the second layer, is the weight matrix of the second layer, is the bias term. The reduced features are processed by the GELU activation function to obtain the activation output of the second layer. . Output the second layer activation Input to the third fully connected layer of the charging frequency encoder. In the third layer, feature mapping and semantic extraction are mainly performed, so that the features have higher-level semantic information, which facilitates the model to understand the impact of charging frequency on overall current and power measurement. The linear transformation formula of the third layer is:
[0173] ;
[0174] Through the feature mapping process, the encoding result of the charging frequency is obtained The encoding result is used for subsequent feature fusion and model prediction. Similar to the charging frequency feature, the usage duration feature and ambient temperature characteristics They are also input into the corresponding encoders. Each encoder contains three fully connected layers, and the GELU activation function is also used for nonlinear transformation. After feature dimensionality reduction and semantic extraction, the encoding result of the usage time is obtained. and ambient temperature encoding results The encoding results of charging frequency, usage time and ambient temperature are fused to obtain the shared factor features after real-time encoding. The three feature encoding results are spliced together using the splicing method to generate a comprehensive shared feature vector
[0175] ;
[0176] Among them, Concat is a concatenation operation. is the final shared factor feature. The shared feature vector contains information about charging frequency, usage time, and ambient temperature, which can more comprehensively reflect the status of the device.
[0177] The above describes the current and power measurement method of the ternary polymer lithium battery of the shared charging device in the embodiment of the present invention. The following describes the current and power measurement device of the ternary polymer lithium battery of the shared charging device in the embodiment of the present invention. Figure 2 , an embodiment of a ternary polymer lithium battery current and power measurement device of a shared charging device in an embodiment of the present invention includes:
[0178] The sampling module is used to perform multi-point sampling and preprocessing on the current, voltage, temperature of the ternary polymer lithium batteries in multiple shared charging devices and the use frequency of the charging devices to obtain a preprocessed data set;
[0179] A selection module is used to construct a comprehensive feature vector based on the preprocessed data set and perform feature selection to obtain multiple target feature subsets;
[0180] An analysis module is used to perform multi-dimensional analysis and hierarchical clustering on battery operating conditions and shared charging equipment usage patterns according to multiple target feature subsets to obtain multiple operating condition and usage pattern category results;
[0181] A building module for building multiple current and power measurement models based on multiple operating condition and usage mode category results and multiple target feature subsets;
[0182] A compensation module, used for performing temperature compensation and shared use frequency compensation based on a measurement circuit topology structure, and obtaining a temperature and use frequency compensation matrix;
[0183] The fusion module is used to perform model fusion and adaptive calibration on multiple current and power measurement models based on multiple working conditions and usage mode classification results and temperature and usage frequency compensation matrices to obtain a current and power measurement model set.
[0184] Through the cooperation of the above components, multi-point sampling and preprocessing technology, combined with dynamic weight adjustment algorithm for feature selection, the key features of the battery can be effectively extracted, and the accuracy of current and power measurement can be significantly improved. The battery working conditions and usage modes are classified by hierarchical clustering method, and multiple current and power measurement models are constructed to adapt to different sharing scenarios and usage conditions. By equivalently decoupling the measurement circuit and introducing temperature and usage frequency compensation matrix, the measurement parameters can be adjusted in real time to effectively eliminate the influence of environmental factors and usage frequency on the measurement results. The model fusion and adaptive calibration technology, combined with the Bayesian model averaging method, enable the measurement system to automatically adjust as the battery performance changes and maintain long-term measurement stability. By building an efficient neural network model and an optimized data processing flow, real-time measurement of current and power can be achieved to meet the rapid response requirements of shared charging equipment. Through the uncertainty estimation layer and probabilistic measurement results, the credibility of the measurement can be evaluated, providing a reliable basis for equipment management and fault warning. Based on the mechanism of working condition identification and model selection, the most suitable model can be called for different situations, the use of computing resources can be optimized, and the overall efficiency of the system can be improved.
[0185] The present invention also provides a computer device, which includes a memory and a processor, wherein the memory stores computer-readable instructions. When the computer-readable instructions are executed by the processor, the processor executes the steps of the method for measuring current and power of a ternary polymer lithium battery of a shared charging device in the above-mentioned embodiments.
[0186] The present invention also provides a computer-readable storage medium, which may be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium. Instructions are stored in the computer-readable storage medium. When the instructions are executed on a computer, the computer executes the steps of the method for measuring the current and power of the ternary polymer lithium battery of the shared charging device.
[0187] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described systems, systems and units can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0188] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or the whole or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program code.
[0189] As described above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for measuring current and power of a ternary polymer lithium battery of a shared charging device, characterized in that: The method comprises: The current, voltage, temperature of the ternary polymer lithium batteries in multiple shared charging devices and the usage frequency of the charging devices are multi-point sampled and preprocessed to obtain a preprocessed data set; Constructing a comprehensive feature vector based on the preprocessed data set and performing feature selection to obtain multiple target feature subsets; Performing multi-dimensional analysis and hierarchical clustering on the battery operating conditions and shared charging equipment usage patterns according to the multiple target feature subsets to obtain multiple operating condition and usage pattern category results; constructing a plurality of current and power measurement models based on the plurality of operating condition and usage mode category results and the plurality of target feature subsets; Perform temperature compensation and shared frequency compensation based on the measurement circuit topology to obtain temperature and frequency compensation matrices; Based on the classification results of the multiple operating conditions and usage modes and the temperature and usage frequency compensation matrix, the multiple current and power measurement models are subjected to model fusion and adaptive calibration to obtain a current and power measurement model set.
2. The method for measuring current and power of a ternary polymer lithium battery of a shared charging device according to claim 1, characterized in that: The current, voltage, temperature of the ternary polymer lithium batteries in the multiple shared charging devices and the use frequency of the charging devices are multi-point sampled and preprocessed to obtain a preprocessed data set, including: Perform high-frequency sampling on ternary polymer lithium batteries in multiple shared charging devices, collect current, voltage, and temperature data, and obtain original sampling data; Performing timestamp tagging and device identification association on the original sampling data to obtain an original data set with spatiotemporal information, and calculating the usage frequency and the number of charge and discharge cycles of each charging device based on the original data set with spatiotemporal information to obtain device usage characteristic data; Performing multi-scale analysis of wavelet transform on the original data set with spatiotemporal information to obtain denoised signal data, and performing amplitude normalization and time scale normalization processing on the denoised signal data to obtain a standardized data set; Based on the standardized data set, a dynamic time warping algorithm is used to identify and segment the charging cycle to obtain cycle segmentation data; The period segmented data and the device usage feature data are time-series aligned and feature fused to obtain a multi-dimensional feature data set, and the multi-dimensional feature data set is subjected to sliding window segmentation and overlapping sampling to generate a preprocessed data set.
3. The method for measuring current and power of a ternary polymer lithium battery of a shared charging device according to claim 1, characterized in that: The method of constructing a comprehensive feature vector based on the preprocessed data set and performing feature selection to obtain multiple target feature subsets includes: Performing time domain and frequency domain analysis on the preprocessed data set to obtain an initial feature set, and based on the initial feature set, calculating the change rate of key parameters in the charging and discharging process to obtain dynamic change characteristics; Combining the initial feature set and the dynamically changing feature to construct a comprehensive feature vector, and based on the comprehensive feature vector, calculating the influence of each feature on battery performance to obtain a feature importance ranking; According to the feature importance ranking, multiple importance thresholds are set to divide the features into multiple levels to obtain a hierarchical feature set, and correlation analysis is performed on the features in the hierarchical feature set to obtain a streamlined feature set; Based on the streamlined feature set, a dynamic weight adjustment model is constructed, the feature weights are initialized to obtain an initial weight allocation scheme, and according to the initial weight allocation scheme, combined with the usage pattern of the shared charging device, the feature weights are dynamically adjusted to obtain multiple target feature subsets.
4. The method for measuring current and power of a ternary polymer lithium battery of a shared charging device according to claim 1, characterized in that: The multi-dimensional analysis and hierarchical clustering of the battery operating conditions and the shared charging device usage patterns are performed according to the multiple target feature subsets to obtain multiple operating condition and usage pattern category results, including: Normalizing the multiple target feature subsets to obtain a standardized feature matrix, and calculating the Euclidean distance between features based on the standardized feature matrix to construct a distance matrix; According to the distance matrix, the features are initially clustered using the minimum distance method to obtain initial clustering results, and the initial clustering results are hierarchically merged to construct a clustering tree structure to obtain a multi-level clustering model; Based on the multi-level clustering model, the distance ratio between classes and within classes is calculated, the optimal number of clusters is determined, and an optimized clustering result is obtained; and feature analysis is performed on each class in the optimized clustering result, and a class feature vector is extracted to obtain a working condition feature set; According to the working condition feature set, combined with the time and space usage data of the shared charging device, a usage mode descriptor is constructed to obtain a usage mode feature set; The operating condition feature set and the usage mode feature set are combined and analyzed to generate a joint distribution of operating conditions and usage modes, and obtain multiple operating condition and usage mode category results.
5. The method for measuring current and power of a ternary polymer lithium battery of a shared charging device according to claim 1, characterized in that: The constructing a plurality of current and power measurement models based on the plurality of operating conditions and usage mode category results and the plurality of target feature subsets comprises: Performing one-hot vector encoding on the multiple operating condition and usage mode category results to obtain a category feature vector; The category feature vector is concatenated with the multiple target feature subsets, and feature interaction is performed through a multi-head self-attention mechanism to obtain an enhanced feature vector; Construct a shared factor encoder, which includes three parallel sub-networks: charging frequency encoder, usage time encoder, and ambient temperature encoder. Each sub-network consists of three fully connected layers and uses the GELU activation function to obtain the shared factor features after training encoding. The enhanced feature vector and the encoded shared factor feature are input into a feature fusion layer, the feature fusion layer adopts a gated linear unit structure to achieve adaptive fusion of features, and obtain training fusion features; A dynamic graph convolution layer is constructed based on the training fusion features, the dynamic graph convolution layer dynamically constructs a graph structure by learning a similarity matrix between samples, and applies a graph convolution operation to extract high-order features to obtain training graph convolution features; The graph convolutional features are input into a multi-scale temporal convolutional network, which includes three parallel one-dimensional convolutional branches with convolution kernel sizes of 3, 5, and 7 respectively. Each branch is followed by a maximum pooling layer to obtain multi-scale temporal features; Constructing an attention-enhanced bidirectional long short-term memory network layer, which uses the multi-scale temporal features as input and applies a self-attention mechanism on the output of the LSTM unit to obtain training context-aware features; Inputting the training context-aware features into a self-calibrated residual network, the self-calibrated residual network comprises five residual blocks, each residual block uses layer normalization and ELU activation function, and a self-calibrated gating mechanism is added to the residual connection to obtain self-calibrated features; An uncertainty estimation layer is constructed based on the self-calibration feature. The uncertainty estimation layer adopts a multi-task learning framework to simultaneously predict the mean and variance of current and power to obtain a probabilistic measurement result. The negative log-likelihood loss function is used, combined with L1 regularization and learning rate decay strategy, and the Adam optimizer is used for end-to-end training to obtain multiple current and power measurement models that are suitable for different sharing scenarios.
6. The method for measuring current and power of a ternary polymer lithium battery of a shared charging device according to claim 1, characterized in that: The temperature compensation and shared frequency compensation are performed based on the measurement circuit topology structure to obtain a temperature and frequency compensation matrix, including: Analyze the measurement circuit topology of the shared charging device to obtain an initial equivalent circuit, and establish a circuit mathematical model based on the initial equivalent circuit by applying a node voltage method and a mesh current method; Performing symbolic matrix transformation and algebraic simplification on the circuit mathematical model to obtain a decoupled sub-circuit equation set, and constructing a nonlinear characteristic model of the temperature sensitive element based on the decoupled sub-circuit equation set to obtain a temperature correlation coefficient matrix; Performing thermodynamic analysis on the temperature correlation coefficient matrix, establishing a heat conduction equation, and solving it using a finite difference method to obtain a temperature distribution function, and based on the temperature distribution function, performing temperature compensation on the decoupled subcircuit to obtain circuit parameters after temperature compensation; Performing frequency domain analysis on the temperature compensated circuit parameters, building an impact model of shared use frequency, and obtaining a frequency response function; Based on the frequency response function, the circuit parameters are compensated for the shared use frequency, and combined with the temperature compensation result, a temperature and use frequency compensation matrix is obtained.
7. The method for measuring current and power of a ternary polymer lithium battery of a shared charging device according to claim 1, characterized in that: The method of performing model fusion and adaptive calibration on the multiple current and power measurement models based on the multiple operating conditions and usage mode classification results and the temperature and usage frequency compensation matrix to obtain a current and power measurement model set includes: Performing feature encoding on the classification results of the multiple operating conditions and usage modes to obtain an operating condition mode feature vector, and performing model selection on the multiple current and power measurement models based on the operating condition mode feature vector to obtain a candidate model subset; Applying the temperature and usage frequency compensation matrix to each model in the candidate model subset to obtain compensated model parameters, and assigning a dynamic weight coefficient to each model based on the compensated model parameters to obtain a weighted model set; Performing ensemble learning on the weighted model set to obtain an initial ensemble model, and constructing a self-calibration layer including multiple residual units and an attention mechanism based on the initial ensemble model, and adaptively adjusting the model output to obtain a calibrated ensemble model; For the calibrated integrated model, the posterior distribution of the model prediction is calculated, and an adaptive threshold selector is constructed to dynamically adjust the prediction threshold according to different working conditions and usage modes to obtain a current and power measurement model set.
8. The method for measuring current and power of a ternary polymer lithium battery of a shared charging device according to claim 7, characterized in that: The method further comprises: Real-time data collection and preprocessing of ternary polymer lithium batteries in shared charging equipment are performed to obtain standardized real-time feature vectors; Determine the current operating condition category based on the standardized real-time feature vector, obtain an operating condition identifier, and call a corresponding activation model from the current and power measurement model set according to the operating condition identifier; Inputting the standardized real-time feature vector into the shared factor encoder of the activation model to obtain the shared factor feature after real-time encoding; Inputting the shared factor features after real-time encoding into a feature fusion layer, and fusing them with the standardized real-time feature vector to obtain real-time fused features; Inputting the real-time fusion features into the dynamic graph convolution layer to extract high-order features to obtain real-time graph convolution features; Inputting the real-time graph convolutional features into a multi-scale temporal convolutional network and an attention-enhanced bidirectional long short-term memory network layer to obtain real-time context-aware features; The real-time context-aware feature is subjected to self-calibration residual and uncertainty estimation to obtain the original measurement result, and the real-time current and power measurement result is obtained by combining the temperature and the use frequency compensation matrix.
9. The method for measuring current and power of a ternary polymer lithium battery of a shared charging device according to claim 8, characterized in that: The step of inputting the standardized real-time feature vector into the shared factor encoder of the activation model to obtain the shared factor feature after real-time encoding includes: Performing feature decomposition on the standardized real-time feature vector to obtain charging frequency features, usage duration features, and ambient temperature features; Input the charging frequency feature into the first fully connected layer of the charging frequency encoder, perform linear transformation on the input feature to obtain an intermediate feature representation, and apply a GELU activation function to the intermediate feature representation to introduce a nonlinear transformation to obtain a first layer activation output; Inputting the first layer activation output into the second fully connected layer of the charging frequency encoder, performing feature dimension reduction and information compression to obtain reduced dimension features, and applying the GELU activation function to the reduced dimension features to obtain the second layer activation output; Inputting the activation output of the second layer into the third fully connected layer of the charging frequency encoder for feature mapping and semantic extraction to obtain a charging frequency encoding result; According to the usage time characteristics and the ambient temperature characteristics, respectively obtaining a usage time encoding result and an ambient temperature encoding result; The charging frequency encoding result, the usage time encoding result and the ambient temperature encoding result are feature fused to obtain the shared factor features after real-time encoding.
10. A ternary polymer lithium battery current and power measurement device for a shared charging device, characterized in that: A method for measuring current and power of a ternary polymer lithium battery of a shared charging device according to any one of claims 1 to 9, the device comprising: The sampling module is used to perform multi-point sampling and preprocessing on the current, voltage, temperature of the ternary polymer lithium batteries in multiple shared charging devices and the usage frequency of the charging devices to obtain a preprocessed data set; A selection module, used for constructing a comprehensive feature vector based on the preprocessed data set and performing feature selection to obtain multiple target feature subsets; An analysis module, configured to perform multi-dimensional analysis and hierarchical clustering on the battery operating conditions and the shared charging device usage patterns according to the multiple target feature subsets, to obtain multiple operating condition and usage pattern category results; A construction module, configured to construct a plurality of current and power measurement models based on the plurality of operating condition and usage mode category results and the plurality of target feature subsets; A compensation module, used for performing temperature compensation and shared use frequency compensation based on a measurement circuit topology structure, and obtaining a temperature and use frequency compensation matrix; A fusion module is used to perform model fusion and adaptive calibration on the multiple current and power measurement models based on the multiple operating conditions and usage mode classification results and the temperature and usage frequency compensation matrix to obtain a current and power measurement model set.
