Energy storage charging abnormity detection method and system based on user switching behavior
By using a user-based energy storage charging anomaly detection method based on user switching behavior, and by employing a reconstructed autoencoder model and contribution analysis, the problem of the inability to identify soft anomalies in energy storage systems in existing technologies is solved. This achieves accurate anomaly detection and root cause localization, thereby improving the intelligent monitoring capabilities of energy storage systems.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-02-28
- Publication Date
- 2026-03-31
AI Technical Summary
Existing technologies cannot effectively identify soft anomalies during the charging process of energy storage systems, and their reliance on anomaly labels and linear assumptions leads to a high false alarm rate. They also lack interpretable intelligent anomaly detection methods.
The energy storage charging anomaly detection method based on user switching behavior identifies charging segments through a dual-threshold hysteresis comparison mechanism, extracts basic state features, policy template compliance features, and behavioral profile compliance features, uses a reconstructed autoencoder model for unsupervised training, and combines contribution analysis and rule base to achieve anomaly root cause localization.
It enables comprehensive monitoring of the interaction between energy storage devices and the power grid, accurately detects various soft anomalies, reduces reliance on anomaly tags, and improves generalization capabilities and operation and maintenance efficiency.
Smart Images

Figure CN121765604A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of energy storage anomaly identification technology, specifically to a method and system for detecting energy storage charging anomalies based on user switching behavior. Background Technology
[0002] With the large-scale application of distributed energy storage in new power systems, the demand for refined anomaly monitoring of its charging process is becoming increasingly prominent. Currently, the technical solutions for anomaly detection in the charging process of energy storage systems mainly have the following limitations: (1) At the basic monitoring level, existing methods mostly focus on the physical health status of energy storage batteries, such as by evaluating internal parameters such as state of charge (SOC) and state of health (SOH). However, such methods cannot effectively identify behavioral anomalies caused by control strategy failure, communication interruption, etc., that is, the problem that the equipment is in normal physical condition but fails to correctly execute the grid dispatch instructions; (2) At the level of detection algorithms, although methods based on statistical process control (such as moving average) or signal processing (such as wavelet analysis) are applied, they are usually based on the assumption that the system is linear or stationary, which makes it difficult to adapt to the high nonlinearity and dynamism of energy storage in actual scheduling and market environment, resulting in a high false alarm and false alarm rate. (3) At the level of abnormal response mechanism, traditional threshold alarms are mainly designed to respond to hard anomalies such as voltage over-limit and current surge, but lack effective identification and coverage capabilities for "soft anomalies" such as insufficient charging power, intermittent charging, and strategy execution delay. (4) At the level of intelligent application, although the artificial intelligence method of supervised learning has certain potential, it relies heavily on a large number of accurately labeled abnormal samples. In the actual operating environment, especially various "soft abnormal" samples are extremely scarce and difficult to label, which makes the training cost of such models high and the generalization ability to unknown or new abnormal patterns insufficient.
[0003] In summary, existing technologies lack an intelligent anomaly detection method that can transcend the physical state of equipment, effectively monitor its interaction with the power grid, eliminate the need for anomaly tags, and possess high interpretability. Summary of the Invention
[0004] The purpose of this invention is to propose a method and system for detecting abnormalities in energy storage charging based on user switching behavior. This aims to overcome the technical problems of existing technologies that only focus on the physical state of the equipment, cannot cover soft anomalies, rely on anomaly labels, have weak generalization ability and lack interpretability, and achieve comprehensive monitoring, accurate anomaly detection and anomaly root cause localization of the interaction between energy storage equipment and the power grid.
[0005] In a first aspect, one technical solution provided in this embodiment of the invention is: a method for detecting abnormal energy storage charging based on user switching behavior, comprising the following steps: Acquire the power consumption time-series data of the target energy storage device within a preset analysis period, and identify the effective charging segments from the power consumption time-series data based on a dual threshold hysteresis comparison mechanism; Extract the basic state features that characterize the energy and power statistics of each effective charging segment, the strategy template conformity features that characterize the degree of conformity between the actual charging behavior and the grid dispatch strategy template in terms of time and energy, and the behavioral profile conformity features that characterize the degree of similarity between the current charging curve and the power curve template in terms of shape and time phase. The basic state features, policy template compliance features, and behavior profile compliance features are used as input vectors for the reconstruction autoencoder model, and the corresponding reconstruction vectors are output. The reconstruction autoencoder model is trained based on the features of the normal charging segment. The degree of anomaly is determined by the reconstruction residual between the reconstructed vector and the input vector, and the root cause of the anomaly is determined by an anomaly index based on the contribution of each feature factor in the input vector to the degree of anomaly.
[0006] As a preferred embodiment, the steps of acquiring the electricity consumption time-series data of the target energy storage device within a preset analysis period and identifying valid charging segments from the electricity consumption time-series data based on a dual-threshold hysteresis comparison mechanism are as follows: The missing values of the original power consumption time series data were filled by interpolation and the power values representing the discharge process were set to zero to obtain the power consumption time series data to be tested. Based on the rated power of the target energy storage device, a charging start power threshold and a charging stop power threshold are preset, wherein the charging start power threshold is greater than the charging stop power threshold; The power consumption time-series data under test is traversed using hysteresis comparison logic. When the active power value rises from below the charging stop power threshold and exceeds the charging start power threshold for the first time for a duration of t1, it is determined as the start point of a valid charging segment. When the active power value falls from above the charging start power threshold and falls below the charging stop power threshold for the first time for a duration of t2, it is determined as the end point of the current valid charging segment. Based on the start and end points of the effective charging segments, all effective charging segments are sequentially segmented from the power consumption timing data to be tested.
[0007] As a preferred approach, the steps for extracting the fundamental state features characterizing the energy and power statistics of each effective charging segment are as follows: The average charging power is obtained based on the arithmetic mean of the active power sequence within the effective charging segment. The total charging capacity is obtained by integrating the active power sequence over time. The standard deviation of charging power is obtained based on the standard deviation of the active power sequence; Extract the maximum value from the active power sequence as the highest load and the minimum value as the lowest load; The peak-valley difference rate is obtained based on the ratio of the highest load to the lowest load; The basic state characteristics are constructed by combining the average charging power, total charging capacity, standard deviation of charging power, highest load, lowest load, and peak-valley difference rate.
[0008] As a preferred approach, the steps for extracting the strategy template compliance feature, which characterizes the degree of compliance between the actual charging behavior and the grid dispatch strategy template in terms of time and energy, from each effective charging segment are as follows: A time window template sequence is generated based on a preset power grid dispatch strategy. The time window template sequence is a Boolean sequence, where the value of the time window template sequence is 1 when charging is allowed, and 0 otherwise. Based on the charging status of the effective charging segment in each time segment, a sequence of actual charging status of the device is generated. The sequence of actual charging status of the device is a Boolean sequence. When actual charging occurs, the corresponding charging status sequence value is 1; otherwise, the corresponding charging status sequence value is 0. Calculate the time window overlap between the time window template sequence and the actual charging state sequence of the device, wherein the time window overlap is equal to the ratio of the number of time slices in which the corresponding sequence values of the two sequences are all 1 to the number of time slices in which at least one corresponding sequence value of the two sequences is 1; Calculate the total charging energy of the effective charging segment within the time slice indicated as a time window template sequence where charging is prohibited, and obtain the out-of-window energy ratio based on the ratio of the total charging energy to the total charging energy of the effective charging segment; The policy template compliance feature is obtained based on the overlap of time windows and the proportion of energy outside the window.
[0009] As a preferred approach, the steps for extracting the behavioral profile conformity features representing the similarity in shape and time phase between the current charging curve and the power curve template in each effective charging segment are as follows: Select all charging days that are deemed compliant within a preset historical period, and take the median of the power values in the same time segment corresponding to the compliant charging days to construct the power shape template of the target energy storage device; Calculate the Pearson correlation coefficient between the current charging power curve corresponding to the effective charging segment and the power shape template, and use the optimal correlation coefficient that maximizes the Pearson correlation coefficient by sliding the power shape template within a certain time offset range as the morphological similarity. Record the time offset required for the power shape template to reach the optimal correlation coefficient as the time lag; The behavioral profile conformity feature is obtained by combining the morphological similarity with the time lag.
[0010] As a preferred embodiment, the steps of using basic state features, policy template compliance features, and behavior profile compliance features as input vectors to reconstruct the autoencoder model and outputting the corresponding reconstruction vectors are as follows: The basic state features, policy template compliance features, and behavior profile compliance features extracted for the same valid charging segment are combined to construct a high-dimensional feature vector; The high-dimensional feature vector is used as input and fed into a pre-trained reconstruction autoencoder model; the high-dimensional feature vector is encoded and compressed by the encoder part of the reconstruction autoencoder model to obtain a low-dimensional feature vector. The decoder part of the reconstructed autoencoder model decodes and reconstructs the low-dimensional feature vector, outputting a reconstructed feature vector with the same dimension as the high-dimensional feature vector.
[0011] As a preferred embodiment, the steps for training the reconstructed autoencoder model based on features from a normal charging segment are as follows: Filter out normal charging segments from valid charging segments where the policy template conformity is greater than the set threshold h1 and the behavior profile conformity is greater than the set threshold h2; Extract the basic state features, policy template compliance features, and behavior profile compliance features corresponding to the normal charging segment to construct a training feature set; Construct an autoencoder neural network with an encoder and a decoder structure; take minimizing the reconstruction error between the reconstructed vector obtained by inputting the feature vectors in the training feature set into the autoencoder neural network and the corresponding feature vector as the training objective, and perform iterative training on the autoencoder neural network; when the convergence condition is met, the reconstructed autoencoder model is obtained.
[0012] As a preferred approach, the degree of anomaly is determined based on the reconstruction residual between the reconstructed vector and the input vector. The steps for determining the root cause of the anomaly by using an anomaly index based on the contribution of each feature factor in the input vector to the degree of anomaly are as follows: The anomaly score, representing the degree of anomaly, is obtained by calculating the sum of squares of the differences between the input vector and the corresponding reconstructed vector in each feature dimension. Filter out all valid segments with anomaly scores higher than the preset anomaly judgment threshold to construct a charging anomaly segment sequence; The ratio of the squared difference of the feature factors in the input vector corresponding to each sequence in the abnormal charging segment sequence to the corresponding abnormal score is taken as the contribution of the current feature factor to the degree of abnormality. All feature factors whose contribution exceeds a preset contribution threshold are marked as abnormal feature factors and serialized to construct an abnormal dimension index set; The feature factors corresponding to each sequence segment in the abnormal dimension index set are combined and matched with a predefined rule base. Based on the matching result, the abnormal segment sequence number and abnormal type corresponding to the current charging abnormality are determined and output. The rule base stores the mapping relationship between different feature dimension combinations and abnormal types.
[0013] As a preferred embodiment, the implementation steps for storing the mapping relationship between different feature dimension combinations and anomaly types in the rule base include: When the feature dimensions are combined as average charging power and total charging capacity, the anomaly type is determined to be no charging or severely insufficient charging. When the feature dimensions are combined as the standard deviation of charging power and the peak-to-valley difference rate, the anomaly type is determined to be intermittent charging or drastic power fluctuations. When the feature dimensions are combined as time window overlap and out-of-window energy ratio, the anomaly type is determined to be a policy violation. When the feature dimensions are combined as morphological similarity and time lag, the anomaly type is determined to be behavioral pattern deviation.
[0014] Secondly, an embodiment of the present invention also provides a technical solution: an energy storage charging anomaly detection system, applicable to the energy storage charging anomaly detection method based on user switching behavior as described in the first aspect, comprising: The data preprocessing module is used to acquire and process the power consumption time series data, perform missing value filling and discharge power zeroing operations, and identify and segment all valid charging segments based on the dual threshold hysteresis comparison mechanism. The feature extraction module is used to extract the basic state features that characterize the energy and power statistics of the charging segment itself, the strategy template conformity feature that characterizes the degree of conformity between the actual charging behavior and the grid dispatch strategy template in terms of time and energy, and the behavior profile conformity feature that characterizes the degree of similarity between the current charging curve and the power curve template in terms of shape and time phase. The model computation module has a pre-trained reconstruction autoencoder model embedded in it, which is used to receive basic state features, policy template compliance features and behavior profile compliance features, and output the corresponding reconstruction vector based on the reconstruction autoencoder model. The intelligent diagnostic module determines anomaly scores that characterize the degree of anomaly based on the reconstruction residual between the reconstructed vector and the input vector. It then makes anomaly determinations based on the anomaly scores and performs contribution analysis and anomaly feature factor identification on the segments determined to be anomalous. Finally, it calls the rule base to map the identified anomaly feature factor combinations to specific anomaly root causes.
[0015] Thirdly, one technical solution provided in this embodiment of the invention is: an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor, when calling the computer program in the memory, implements the steps of the energy storage charging anomaly detection method based on user switching behavior as described in the first aspect.
[0016] Fourthly, one technical solution provided in this embodiment of the invention is: a storage medium storing computer-executable instructions, wherein when the computer-executable instructions are loaded and executed by a processor, the steps of the energy storage charging anomaly detection method based on user switching behavior as described in the first aspect are implemented.
[0017] The present invention has at least the following substantial beneficial effects: (1) In view of the problem that existing methods are difficult to effectively identify “soft anomalies” caused by policy failure, behavior deviation and other reasons, and the detection model relies heavily on linear assumptions, this application designs a feature engineering system that integrates three dimensions: basic state, policy template conformity and behavior profile conformity, and constructs a reconstruction autoencoder model based on unsupervised training of normal segments. This enables the synchronous and accurate detection of multiple soft anomalies such as insufficient charging power, intermittent charging, policy violation and behavior pattern deviation. The reconstruction autoencoder model uses the nonlinear fitting ability of deep neural networks to automatically learn complex behavior pattern associations from massive normal data, thereby generating significant reconstruction errors for abnormal patterns that deviate from normal distribution, overcoming the high false negative and false negative defects of traditional linear or stationary assumption methods in dynamic scheduling scenarios.
[0018] (2) To address the problem that the scarcity of abnormal samples in energy storage charging and the difficulty in labeling lead to a high application threshold and weak generalization ability of supervised learning methods, this application adopts an unsupervised learning reconstruction autoencoder architecture. It only needs to use the feature vectors extracted from historical normal charging segments for training, so that the model learns the potential distribution of normal behavior. During detection, it identifies anomalies by calculating the residual between the input features and the reconstruction output. This achieves effective detection of unknown or new abnormal patterns without any abnormal labels, greatly reducing the model's dependence on scarce labeled data and improving the generalization ability and feasibility of the algorithm in actual complex operating environments.
[0019] (3) In view of the problem that traditional anomaly detection methods can only output anomaly alarms but cannot provide interpretable root cause diagnosis, this application introduces an anomaly dimension indexing mechanism based on contribution analysis on the basis of reconstructing error calculation of anomaly segments, identifies the key feature dimensions that contribute the most to the total anomaly, and combines them with a pre-built rule base that integrates business knowledge to map specific feature dimension combinations to specific anomaly types (such as not charging, policy violation, etc.), realizing a closed loop from anomaly perception to intelligent attribution of anomaly root causes, providing precise technical support for targeted maintenance of energy storage systems and greatly improving operation and maintenance efficiency.
[0020] The above description of the invention is merely an overview of the technical solution of the present invention. In order to better understand the technical means of the present invention and to implement it in accordance with the contents of the specification, and to make the above and other objects, features and advantages of the present invention more apparent and understandable, specific embodiments of the present invention are described below. Attached Figure Description
[0021] Other features, objects, and advantages of the invention will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings. The drawings are for illustrative purposes only and are not intended to limit the invention. Furthermore, the same reference numerals denote the same parts throughout the drawings.
[0022] Figure 1 This is a flowchart of the energy storage charging anomaly detection method based on user switching behavior according to an embodiment of the present invention.
[0023] Figure 2 This is a block diagram of an energy storage charging anomaly detection system according to an embodiment of the present invention. Detailed Implementation
[0024] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only one preferred embodiment of this invention and are only used to explain this invention. They do not limit the scope of protection of this invention. All other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this invention.
[0025] Before discussing the exemplary embodiments in more detail, it should be mentioned that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although the flowcharts describe the operations (or steps) as sequential processes, many of the operations (or steps) can be performed in parallel, concurrently, or simultaneously. Furthermore, the order of the operations can be rearranged. The process can be terminated when its operation is completed, but it may also have additional steps not included in the figures; the process may correspond to a method, function, procedure, subroutine, subroutine, etc.
[0026] Example 1: As Figure 1 As shown, one technical solution provided in this embodiment of the invention is: an energy storage charging anomaly detection method based on user switching behavior, the implementation steps of which are shown in S100~S400.
[0027] S100: Obtain the power consumption time-series data of the target energy storage device within a preset analysis period, and identify the effective charging segment from the power consumption time-series data based on the dual threshold hysteresis comparison mechanism.
[0028] As an optional embodiment, the step of acquiring the electricity consumption time-series data of the target energy storage device within a preset analysis period and identifying valid charging segments from the electricity consumption time-series data based on a dual-threshold hysteresis comparison mechanism is as follows: S101. Use interpolation to fill in the missing values of the original power consumption time series data and set the power value representing the discharge process to zero to obtain the power consumption time series data to be tested. S102. Based on the rated power of the target energy storage device, preset the charging start power threshold and the charging stop power threshold, wherein the charging start power threshold is greater than the charging stop power threshold. S103. Use hysteresis comparison logic to traverse the power consumption timing data to be tested. When the active power value rises from below the charging stop power threshold and exceeds the charging start power threshold for the first time for a duration of t1, it is determined as the start point of a valid charging segment. When the active power value falls from above the charging start power threshold and falls below the charging stop power threshold for the first time for a duration of t2, it is determined as the end point of the current valid charging segment. S104. Based on the start and end points of the effective charging segments, all effective charging segments are sequentially segmented from the power consumption timing data to be tested.
[0029] Understandably, to address the issues of missing values, interference from discharge data, and inaccurate identification of charging segments in the original power consumption time-series data, this embodiment employs interpolation methods (such as Lagrange interpolation) to accurately fill in the missing values in the original power consumption time-series data (for example, if a 15-minute measurement point is missing, the value is filled in by interpolation calculations of the adjacent valid data before and after it). Continuous missing periods that cannot be interpolated are set to zero to mark invalid data. Simultaneously, negative power values representing the discharge process are set to zero, effectively eliminating irrelevant interference data and obtaining clean power consumption time-series data to be tested. Then, based on the rated power of the target energy storage device, a charging start-up power threshold is scientifically preset. With charging stop power threshold (For example, setting) 5% of the rated power (1% of rated power), and Subsequently, hysteresis comparison logic is used to traverse the power consumption time-series data under test. When the active power value rises from below and exceeds for the first time for a duration of t1 (e.g., 15 minutes in one measurement cycle), it is determined as the start point of a valid charging segment. When the active power value falls from above and falls below for the first time for a duration of t2 (e.g., 15 minutes in one measurement cycle), it is determined as the end point of the charging segment. This effectively avoids misjudgment of charging status caused by small power fluctuations. Finally, based on the identified start and end points, physically continuous and clearly defined valid charging event segments are accurately segmented from the continuous time-series data, providing an accurate and effective data foundation for the subsequent extraction of features in the three dimensions.
[0030] S200, extract the basic state features that characterize the energy and power statistics of each effective charging segment, the strategy template conformity feature that characterizes the degree of conformity between the actual charging behavior and the grid dispatch strategy template in terms of time and energy, and the behavior profile conformity feature that characterizes the degree of similarity between the current charging curve and the power curve template in terms of shape and time phase.
[0031] In this embodiment, by integrating quantitative information from three dimensions—device physical state, external policy constraints, and internal behavioral habits—a feature vector is constructed to comprehensively characterize the health of charging behavior. This provides a highly discriminative and interpretable input data foundation for subsequent unsupervised models to accurately distinguish between various normal and abnormal modes (including explicit non-charging and power fluctuations, as well as implicit policy violations and behavioral deviations).
[0032] For ease of analysis, this embodiment specifically defines the data analysis period: an "analysis day" is defined as 24 hours, from 21:00 on the current day to 21:00 on the following day, including 96 measurement points. This division method can more completely capture the entire business cycle from the start of off-peak charging at night, to daytime operation, and then to the end of the evening peak. Based on this "analysis day," starting from the basic charging strategy, and to further explore the differences in charging patterns at different times, such as charging in response to midday photovoltaic power consumption and charging during off-peak electricity prices at night, this embodiment further divides each analysis day into two main periods: midday and nighttime, and extracts and analyzes the charging behavior characteristics of these two periods separately.
[0033] As an optional embodiment, the basic state features characterizing the energy and power statistics of each effective charging segment are extracted as shown in steps S211~S216: S211. The average charging power is obtained based on the arithmetic mean of the active power sequence within the effective charging segment; S212. Obtain the total charging capacity based on the integration of the active power sequence over time; S213. Obtain the standard deviation of charging power based on the standard deviation of the active power sequence; S214. Extract the maximum value from the active power sequence as the highest load and the minimum value as the lowest load; S215. The peak-valley difference rate is obtained based on the ratio of the highest load to the lowest load; S216. The basic state characteristics are constructed by combining the average charging power, total charging capacity, standard deviation of charging power, highest load, lowest load and peak-valley difference rate.
[0034] Understandably, to accurately quantify the core energy and power characteristics of effective charging segments and provide basic data support for subsequent anomaly detection, this embodiment performs refined feature extraction on the active power sequence within the effective charging segment: The arithmetic mean of the power sequence is calculated to obtain the average charging power, which directly reflects the completion degree of the charging task and is the core basis for diagnosing no charging or insufficient charging; the active power sequence is integrated over time to obtain the total charging capacity (e.g., if the power sequence is P(t), the time interval is Δt, and the total charging capacity is...). It can help identify anomalies such as low power output; the standard deviation of the active power sequence is calculated to obtain the standard deviation of the charging power. ,in For a single power measurement, The average charging power is denoted by ; n is the number of measurement points in the active power sequence within the effective charging segment; the standard deviation of charging power is used to quantify power stability and determine whether intermittent charging exists; the maximum value in the active power sequence is extracted as the highest load, and the minimum value as the lowest load, which can identify instantaneous overload or charging interruption anomalies; the peak-valley difference rate is calculated based on the ratio of the highest load to the lowest load (formula is given). The above six features are used to quantify the relative amplitude of power fluctuations. Finally, the above six features are combined to construct basic state features. Each feature complements each other from different dimensions to characterize the energy and power statistics of the charging segment, realizing the comprehensive quantification of the core physical quantities of the charging process. This provides highly identifiable basic feature support for subsequent models to accurately identify anomalies such as insufficient charging and power fluctuations.
[0035] As an optional embodiment, the strategy template compliance feature, which characterizes the degree of compliance between the actual charging behavior and the grid dispatch strategy template in terms of time and energy, is extracted from each effective charging segment as shown in steps S221 to S225: S221. Generate a time window template sequence based on a preset power grid dispatch strategy. The time window template sequence is a Boolean sequence, wherein when charging is allowed, the time window template sequence value is 1, and otherwise the time window template sequence value is 0. S222. Generate a sequence of actual charging states of the device based on the charging states of the effective charging segments in each time segment. The sequence of actual charging states of the device is a Boolean sequence. When charging actually occurs, the corresponding charging state sequence value is 1; otherwise, the corresponding charging state sequence value is 0. S223. Calculate the time window overlap between the time window template sequence and the actual charging state sequence of the device, wherein the time window overlap is equal to the ratio of the number of time slices in which the corresponding sequence values of the two sequences are all 1 to the number of time slices in which at least one of the corresponding sequence values of the two sequences is 1. S224. Calculate the total charging energy of the effective charging segment within the time slice indicated as prohibited from charging in the time window template sequence, and obtain the out-of-window energy ratio based on the ratio of the total charging energy to the total charging energy of the effective charging segment. S225. Based on the overlap of time windows and the proportion of energy outside the window, the policy template conformity feature is obtained.
[0036] Understandably, in order to quantify the degree of fit between actual charging behavior and grid dispatching strategies, and to accurately identify strategy violation anomalies, this embodiment generates a time window template sequence based on a preset grid dispatching strategy (e.g., allowing charging during off-peak hours from 21:00 to 7:00 the next day). (For example, a certain analysis day contains 96 15-minute time slices, and the time window for allowing charging is defined according to the switching strategy.) This indicates that charging is permitted. (This indicates that charging is prohibited; the time window template provides data support for calculating the overlap of time windows and the proportion of energy outside the window), providing a rigid benchmark for determining the strategy fit. Then, based on the charging status of the effective charging segments in each time slice, a sequence of the actual charging state of the device is generated. (Actual charging time slices correspond to) The time slice that is not charged corresponds to For example, a valid charging segment covers 8 time slices, of which 5 time slices actually charge (corresponding to 5 "1"s and 3 "0"s), achieving precise mapping of the charging behavior in the time dimension; subsequently, the overlap of time windows is calculated using the Jaccard index. This feature directly reflects the degree of matching between charging time and the policy-allowed time; among which, This represents the set of time slices where "actual charging" and "policy allows charging"; This indicates the number of elements in the set (i.e., the number of time slices). This represents the set of time slices for either "actual charging" or "policy-allowed charging" (including the union of the two to avoid double counting); it also calculates the percentage of energy outside the window. Its formula is expressed as: , This feature is used to quantify the severity of illegal charging during non-switching strategy charging periods, where, In time slice The amount of charge, It is an indicator function, meaning: when the logical condition inside the parentheses is true, 1[condition] = 1; when the logical condition inside the parentheses is false, 1[condition] = 0. To prevent the denominator from being zero, the minimum value is set to... Finally, the overlap of the time windows was calculated. The proportion of energy outside the window The system integrates the conformity features of the strategy template. The former focuses on the time dimension of conformity, while the latter focuses on the degree of violation in the energy dimension. The two complement each other to achieve a comprehensive quantification of the strategy execution, providing accurate feature support for subsequent identification of anomalies such as "charging not within the specified time" and "charging in violation of the prohibited period".
[0037] As an optional embodiment, behavioral profile conformity features representing the similarity in shape and time phase between the current charging curve and the power curve template are extracted from each valid charging segment, as shown in steps S231-S234: S231. Select all charging days that are determined to be compliant within a preset historical period, and take the median of the power values in the same time segment corresponding to the compliant charging days to construct the power shape template of the target energy storage device. S232. Calculate the Pearson correlation coefficient between the current charging power curve corresponding to the effective charging segment and the power shape template. The optimal correlation coefficient that maximizes the Pearson correlation coefficient is found by sliding the power shape template within a certain time offset range and is used as the morphological similarity. S233. Record the time offset required for the power shape template to reach the optimal correlation coefficient as the time lag. S234. Combine the morphological similarity with the time lag to obtain the behavioral profile conformity feature.
[0038] Understandably, to quantify the degree of fit between current charging behavior and the device's historical normal charging patterns, and to accurately identify latent behavioral pattern deviations, this embodiment selects compliant charging days within a preset historical period (e.g., 14 days) where the compliance of all strategy templates and behavioral profiles meets the threshold requirements. The median power value is then taken within the same 15-minute time slice corresponding to each compliant charging day to construct a power shape template specific to the target energy storage device. ; A single compliant charging day refers to a specific day within a historical 14-day period that meets the preset compliant charging conditions. This is a set of compliant charging days, defined as a collection of charging activities occurring within a specified charging period within a 14-day historical period, excluding holidays. The power shape template accurately reflects the long-term, stable charging power variation pattern of the device, providing a personalized benchmark for determining the compliance of the behavior; then, the actual power curve for that day is calculated. Pearson correlation coefficient with the power shape template and its corresponding time offset These two features are used to quantify the similarity of power shape templates. A low value indicates abnormal charging behavior for the day, such as low power output or large fluctuations. The larger the value, the greater the deviation of the charging load curve. For example, charging earlier or later will cause this value to increase. Finally, the morphological similarity... With time lag The behavioral profile is constructed by combining relevant features. Specifically, the profile conformity formula is as follows: ; in, The maximum allowed offset is set to 4, or ±1 hour. Indicates the time offset. Indicates the maximum lag step count. It is a template time-shift operator. This is the Pearson correlation coefficient calculation function, where A corresponds to B corresponds to It is a constrained argmax optimization operator. Among them, ,in , It is the sequence mean. Both complement each other from the morphological and temporal dimensions to characterize the degree of fit between the current charging behavior and the historical normal pattern, realizing the dynamic tracking of the device's personalized charging habits, and providing highly identifiable feature support for subsequent identification of latent anomalies such as changes in power ramp-up rate and charging time deviation.
[0039] S300 uses the basic state features, policy template conformity features, and behavior profile conformity features as input vectors for the reconstruction autoencoder model and outputs the corresponding reconstruction vector; wherein, the reconstruction autoencoder model is trained based on the features of the normal charging segment.
[0040] As an optional embodiment, the basic state features, policy template compliance features, and behavior profile compliance features are used as input vectors to reconstruct the autoencoder model, and the corresponding reconstruction vectors are output as shown in steps S301~S303: S301. Combine the basic state features, policy template compliance features, and behavior profile compliance features extracted for the same valid charging segment to construct a high-dimensional feature vector. S302. The high-dimensional feature vector is used as input and fed into a pre-trained reconstruction autoencoder model; the high-dimensional feature vector is encoded and compressed by the encoder part of the reconstruction autoencoder model to obtain a low-dimensional feature vector. S303. The low-dimensional feature vector is decoded and reconstructed by the decoder part of the reconstructed autoencoder model, and a reconstructed feature vector with the same dimension as the high-dimensional feature vector is output.
[0041] Understandably, to address the issues that single-dimensional features are insufficient to comprehensively characterize energy storage charging behavior and that high-dimensional raw data can easily lead to model redundancy and inefficiency, this embodiment combines the basic state features, strategy template conformity features, and behavior profile conformity features of the same effective charging segment in a preset dimensional order to construct a model that includes average charging power. Total charging capacity Standard deviation of charging power Peak load Minimum load Peak-valley difference rate Time window overlap The proportion of energy outside the window Shape similarity and time lag The high-dimensional feature vector consists of ten features. This high-dimensional feature vector is then fed into a pre-trained reconstruction autoencoder model. The encoder's multi-layer neural network performs nonlinear mapping and dimensionality compression on the high-dimensional features, transforming the 10-dimensional high-dimensional vector into a 3-dimensional low-dimensional latent vector containing core feature information. This achieves data redundancy removal and key feature focusing. Finally, the low-dimensional vector is reverse-mapped and feature restored through a decoder neural network symmetrical to the encoder, outputting a reconstructed feature vector with the same dimensions as the input. The encoder's feature compression process retains the core pattern associations of normal charging behavior, while the decoder's reconstruction process accurately reproduces the normal feature distribution. This lays the foundation for subsequent anomaly identification through reconstruction errors, ensuring both the comprehensiveness of feature representation and improving model computational efficiency and feature extraction accuracy.
[0042] As an optional embodiment, the steps for training the reconstructed autoencoder model based on features of a normal charging segment are as follows: Filter out normal charging segments from valid charging segments where the policy template conformity is greater than the set threshold h1 and the behavior profile conformity is greater than the set threshold h2; Extract the basic state features, policy template compliance features, and behavior profile compliance features corresponding to the normal charging segment to construct a training feature set; Construct an autoencoder neural network with an encoder and a decoder structure; take minimizing the reconstruction error between the reconstructed vector obtained by inputting the feature vectors in the training feature set into the autoencoder neural network and the corresponding feature vector as the training objective, and perform iterative training on the autoencoder neural network; when the convergence condition is met, the reconstructed autoencoder model is obtained.
[0043] Understandably, to address the issue of insufficient anomaly detection accuracy due to model training relying on anomaly labels and inadequate learning of normal charging mode features, this embodiment selects normal charging segments from effective charging segments that have a policy template conformance greater than a set threshold h1 (e.g., 0.8) and a behavior profile conformance greater than a set threshold h2 (e.g., 0.85) to ensure the purity of training data and lay the foundation for the model to learn normal patterns. Then, it extracts the basic state features, policy template conformance features, and behavior profile conformance features of these normal charging segments and combines them to construct a training feature set covering multi-dimensional normal patterns. Subsequently, it constructs a symmetric autoencoder neural network containing an encoder and a decoder. The encoder uses three fully connected layers to compress the 10-dimensional input features into a 3-dimensional low-dimensional space, and the decoder uses three symmetric fully connected layers to restore the low-dimensional features to 10-dimensional reconstructed features, minimizing the mean square error between the input vector V and the reconstructed vector V' in the training feature set. Its formula is: Here, i represents the i-th feature dimension in the feature vector, and M represents the total number of dimensions of the feature vector V. The network parameters are iteratively optimized using the gradient descent algorithm. Training is stopped when the loss value after 100 consecutive training rounds falls below a preset convergence threshold, resulting in a fully trained reconstructed autoencoder model. This process requires no abnormal labels; it uses only normal data to allow the model to learn the normal feature distribution of charging behavior, ensuring accurate fitting of the model to normal patterns. This provides reliable model support for subsequent anomaly identification through reconstruction errors, while also improving the model's learning ability and generalization performance for complex normal patterns.
[0044] S400. Determine the degree of anomaly based on the reconstruction residual between the reconstructed vector and the input vector, and determine the root cause of the anomaly by performing an anomaly index based on the contribution of each feature factor in the input vector to the degree of anomaly.
[0045] As an optional embodiment, the degree of anomaly is determined based on the reconstruction residual between the reconstructed vector and the input vector, and the root cause of the anomaly is determined by an anomaly index based on the contribution of each feature factor in the input vector to the degree of anomaly, as shown in steps S401~S405: S401. Calculate the sum of squares of the differences between the input vector and the corresponding reconstructed vector in each feature dimension to obtain the anomaly score that represents the degree of anomaly. S402. Select all valid segments with abnormal scores higher than the preset abnormal judgment threshold to construct a charging abnormal segment sequence. S403. The ratio of the squared difference of the feature factors in the input vector corresponding to each sequence in the charging anomaly segment sequence to the corresponding anomaly score is taken as the contribution of the current feature factor to the degree of anomaly. S404. Mark all feature factors whose contribution exceeds the preset contribution threshold as abnormal feature factors and serialize them to construct an abnormal dimension index set; S405. Combine the feature factors corresponding to each sequence segment in the abnormal dimension index set and match them with a predefined rule base. Determine and output the abnormal segment sequence number and abnormal type corresponding to the current charging abnormality based on the matching result. The rule base stores the mapping relationship between different feature dimension combinations and abnormal types.
[0046] Understandably, to address the limitations of traditional anomaly detection methods, which can only determine whether an anomaly exists but cannot quantify its severity or pinpoint its root cause, this embodiment calculates the high-dimensional feature vector to be detected. With reconstructed vector The sum of the squares of the differences across each feature dimension yields the anomaly score, which characterizes the degree of anomaly. The formula is: This process achieves precise quantification of anomaly severity. A preset anomaly detection threshold is then set (e.g., the 99.5 percentile not used in the training / validation set is used as the threshold). Valid segments with anomaly scores higher than this threshold are selected to construct a charging anomaly segment sequence, ensuring accurate selection of anomaly segments. Subsequently, the ratio of the squared difference of each feature factor to its corresponding anomaly score is calculated to obtain the feature contribution. The calculation formula is: ;in, The process involves: defining the weight of each feature in relation to anomalies; setting a preset contribution threshold (e.g., 0.05) and marking feature factors with contributions exceeding this threshold as anomalous feature factors; serializing and constructing an anomaly dimension index set to focus on the core features of anomalies; finally, matching the anomaly dimension index set with a predefined rule base, which stores the mapping relationship between feature dimension combinations and anomaly types, outputting the anomaly fragment sequence number and specific anomaly type, thus completing the closed loop from anomaly identification to root cause diagnosis, significantly improving the interpretability and operational targeting of anomaly detection.
[0047] As an optional embodiment, the implementation steps for storing the mapping relationship between different feature dimension combinations and anomaly types in the rule base include: When the feature dimensions are combined as average charging power and total charging capacity, the anomaly type is determined to be no charging or severely insufficient charging. When the feature dimensions are combined as the standard deviation of charging power and the peak-to-valley difference rate, the anomaly type is determined to be intermittent charging or drastic power fluctuations. When the feature dimensions are combined as time window overlap and out-of-window energy ratio, the anomaly type is determined to be a policy violation. When the feature dimensions are combined as morphological similarity and time lag, the anomaly type is determined to be behavioral pattern deviation.
[0048] Understandably, to address the lack of clear mapping standards for the root causes of anomalies and the difficulty in directly guiding operations and maintenance with diagnostic results, this embodiment constructs a rule-based mapping system that integrates business logic and feature association. First, based on the strong correlation between the physical meaning of each feature dimension and the anomaly manifestation, a one-to-one correspondence rule is established between feature dimension combinations and anomaly types: when the anomaly dimension index set is a combination of average charging power and total charging capacity, it is determined as "not charging or severely undercharging," directly pointing to the core anomaly of incomplete charging tasks; when the index set is a combination of charging power standard deviation and peak-valley difference rate, it is determined as "intermittent charging or severe power fluctuations," accurately identifying anomaly patterns of unstable power; when the index set is a combination of time window overlap and out-of-window energy ratio, it is determined as "strategy violation," clearly indicating that the equipment has not followed the grid dispatch time rules; when the index set is a combination of morphological similarity and time lag, it is determined as "behavioral pattern deviation," capturing significant differences between charging habits and historical normal patterns. This rule base, by binding feature combinations to specific anomaly scenarios, achieves standardized and interpretable diagnosis of the root causes of anomalies, allowing operations and maintenance personnel to quickly locate problem types and significantly improve anomaly handling efficiency.
[0049] Example 2: Another embodiment provided in this invention is: an energy storage charging anomaly detection system, applicable to the energy storage charging anomaly detection method based on user switching behavior as described in Example 1, such as... Figure 2 As shown, it includes: The data preprocessing module 001 is used to acquire and process the power consumption time series data, perform missing value filling and discharge power zeroing operations, and identify and segment all valid charging segments based on the dual threshold hysteresis comparison mechanism. Feature extraction module 002 is used to extract basic state features that characterize the energy and power statistical characteristics of the charging segment itself, strategy template conformity features that characterize the degree of conformity between the actual charging behavior and the grid dispatch strategy template in terms of time and energy, and behavioral profile conformity features that characterize the degree of similarity between the current charging curve and the power curve template in terms of shape and time phase in each effective charging segment. Model computation module 003 has a pre-trained reconstruction autoencoder model embedded in it. It is used to receive basic state features, policy template compliance features and behavior profile compliance features, and output the corresponding reconstruction vector based on the reconstruction autoencoder model. The intelligent diagnostic module 004 determines anomaly scores that characterize the degree of anomaly based on the reconstruction residual between the reconstructed vector and the input vector. It then makes anomaly determinations based on the anomaly scores and performs contribution analysis and anomaly feature factor identification on the segments that are determined to be abnormal. Finally, it calls the rule base to map the identified anomaly feature factor combinations to specific anomaly root causes.
[0050] Example 3: One embodiment provided in this invention is an electronic device, including a memory and a processor. The memory stores a computer program, and when the processor calls the computer program in the memory, it implements the steps of the energy storage charging anomaly detection method based on user switching behavior as described in Example 1.
[0051] Example 4: One embodiment provided in this invention is: a storage medium storing computer-executable instructions, which, when loaded and executed by a processor, implement the steps of the energy storage charging anomaly detection method based on user switching behavior as described in Example 1.
[0052] Through the above description of the embodiments, those skilled in the art will understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the specific device can be divided into different functional modules to complete all or part of the functions described above.
[0053] In the embodiments provided in this application, it should be understood that the disclosed structures and methods can be implemented in other ways. For example, the structural embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another structure, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, or indirect coupling or communication connection between structures or units, and may be electrical, mechanical, or other forms.
[0054] The units described as separate components may or may not be physically separate. A component shown as a unit can be one or more physical units; that is, it can be located in one place or distributed in multiple different locations. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0055] Furthermore, in the embodiments of this application, the functional units can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0056] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, in essence, or the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0057] The specific embodiments described above are preferred embodiments of the energy storage charging anomaly detection method and system based on user switching behavior of the present invention, and are not intended to limit the specific scope of the present invention. The scope of the present invention includes but is not limited to the specific embodiments described above. All equivalent changes made in accordance with the shape and structure of the present invention are within the protection scope of the present invention.
Claims
1. A method for detecting abnormal energy storage charging based on user switching behavior, characterized in that: Includes the following steps: Acquire the power consumption time-series data of the target energy storage device within a preset analysis period, and identify the effective charging segments from the power consumption time-series data based on a dual threshold hysteresis comparison mechanism; Extract the basic state features that characterize the energy and power statistics of each effective charging segment, the strategy template conformity features that characterize the degree of conformity between the actual charging behavior and the grid dispatch strategy template in terms of time and energy, and the behavioral profile conformity features that characterize the degree of similarity between the current charging curve and the power curve template in terms of shape and time phase. The basic state features, policy template compliance features, and behavior profile compliance features are used as input vectors for the reconstruction autoencoder model, and the corresponding reconstruction vectors are output. The reconstruction autoencoder model is trained based on the features of the normal charging segment. The degree of anomaly is determined by the reconstruction residual between the reconstructed vector and the input vector, and the root cause of the anomaly is determined by an anomaly index based on the contribution of each feature factor in the input vector to the degree of anomaly.
2. The method for detecting energy storage charging anomalies based on user switching behavior according to claim 1, characterized in that: The steps for acquiring the power consumption time-series data of the target energy storage device within a preset analysis period and identifying valid charging segments from the power consumption time-series data based on a dual-threshold hysteresis comparison mechanism are as follows: The missing values of the original power consumption time series data were filled by interpolation and the power values representing the discharge process were set to zero to obtain the power consumption time series data to be tested. Based on the rated power of the target energy storage device, a charging start power threshold and a charging stop power threshold are preset, wherein the charging start power threshold is greater than the charging stop power threshold; The power consumption time-series data under test is traversed using hysteresis comparison logic. When the active power value rises from below the charging stop power threshold and exceeds the charging start power threshold for the first time for a duration of t1, it is determined as the start point of a valid charging segment. When the active power value falls from above the charging start power threshold and falls below the charging stop power threshold for the first time for a duration of t2, it is determined as the end point of the current valid charging segment. Based on the start and end points of the effective charging segments, all effective charging segments are sequentially segmented from the power consumption timing data to be tested.
3. The method for detecting energy storage charging anomalies based on user switching behavior according to claim 1, characterized in that: The steps for extracting the fundamental state features characterizing the energy and power statistics of each effective charging segment are as follows: The average charging power is obtained based on the arithmetic mean of the active power sequence within the effective charging segment. The total charging capacity is obtained by integrating the active power sequence over time. The standard deviation of charging power is obtained based on the standard deviation of the active power sequence; The maximum value in the active power sequence is extracted as the highest load, and the minimum value is extracted as the lowest load. The peak-valley difference rate is obtained based on the ratio of the highest load to the lowest load; The basic state characteristics are constructed by combining the average charging power, total charging capacity, standard deviation of charging power, highest load, lowest load, and peak-valley difference rate.
4. The method for detecting energy storage charging anomalies based on user switching behavior according to claim 1, characterized in that: The steps for extracting the policy template compliance feature, which characterizes the degree of compliance between the actual charging behavior and the grid dispatch policy template in terms of time and energy, from each effective charging segment are as follows: A time window template sequence is generated based on a preset power grid dispatch strategy. The time window template sequence is a Boolean sequence, where the value of the time window template sequence is 1 when charging is allowed, and 0 otherwise. Based on the charging status of the effective charging segment in each time segment, a sequence of actual charging status of the device is generated. The sequence of actual charging status of the device is a Boolean sequence. When actual charging occurs, the corresponding charging status sequence value is 1; otherwise, the corresponding charging status sequence value is 0. Calculate the time window overlap between the time window template sequence and the actual charging state sequence of the device, wherein the time window overlap is equal to the ratio of the number of time slices in which the corresponding sequence values of the two sequences are all 1 to the number of time slices in which at least one corresponding sequence value of the two sequences is 1; Calculate the total charging energy of the effective charging segment within the time slice indicated as a time window template sequence where charging is prohibited, and obtain the out-of-window energy ratio based on the ratio of the total charging energy to the total charging energy of the effective charging segment; The policy template compliance feature is obtained based on the overlap of time windows and the proportion of energy outside the window.
5. The method for detecting energy storage charging anomalies based on user switching behavior according to claim 1, characterized in that: The steps for extracting behavioral profile conformity features representing the similarity in shape and temporal phase between the current charging curve and the power curve template in each valid charging segment are as follows: Select all charging days that are deemed compliant within a preset historical period, and take the median of the power values in the same time segment corresponding to the compliant charging days to construct the power shape template of the target energy storage device; Calculate the Pearson correlation coefficient between the current charging power curve corresponding to the effective charging segment and the power shape template, and use the optimal correlation coefficient that maximizes the Pearson correlation coefficient by sliding the power shape template within a certain time offset range as the morphological similarity. Record the time offset required for the power shape template to reach the optimal correlation coefficient as the time lag; The behavioral profile conformity feature is obtained by combining the morphological similarity with the time lag.
6. The method for detecting energy storage charging anomalies based on user switching behavior according to claim 1, characterized in that: The steps for using basic state features, policy template compliance features, and behavior profile compliance features as input vectors to reconstruct the autoencoder model and outputting the corresponding reconstruction vectors are as follows: The basic state features, policy template compliance features, and behavior profile compliance features extracted for the same valid charging segment are combined to construct a high-dimensional feature vector; The high-dimensional feature vector is used as input and fed into a pre-trained reconstruction autoencoder model; the high-dimensional feature vector is encoded and compressed by the encoder part of the reconstruction autoencoder model to obtain a low-dimensional feature vector. The decoder part of the reconstructed autoencoder model decodes and reconstructs the low-dimensional feature vector, outputting a reconstructed feature vector with the same dimension as the high-dimensional feature vector.
7. The method for detecting abnormal energy storage charging based on user switching behavior according to claim 1 or 6, characterized in that: The steps for training the reconstructed autoencoder model based on features from a normal charging segment are as follows: Filter out normal charging segments from valid charging segments where the policy template conformity is greater than the set threshold h1 and the behavior profile conformity is greater than the set threshold h2; Extract the basic state features, policy template compliance features, and behavior profile compliance features corresponding to the normal charging segment to construct a training feature set; Construct an autoencoder neural network with an encoder and a decoder structure; take minimizing the reconstruction error between the reconstructed vector obtained by inputting the feature vectors in the training feature set into the autoencoder neural network and the corresponding feature vector as the training objective, and perform iterative training on the autoencoder neural network; when the convergence condition is met, the reconstructed autoencoder model is obtained.
8. The method for detecting abnormal energy storage charging based on user switching behavior according to claim 1, characterized in that: The steps for determining the degree of anomaly based on the reconstruction residual between the reconstructed vector and the input vector, and for determining the root cause of the anomaly by using an anomaly index based on the contribution of each feature factor in the input vector to the degree of anomaly, are as follows: The anomaly score, representing the degree of anomaly, is obtained by calculating the sum of squares of the differences between the input vector and the corresponding reconstructed vector in each feature dimension. Filter out all valid segments with anomaly scores higher than the preset anomaly judgment threshold to construct a charging anomaly segment sequence; The ratio of the squared difference of the feature factors in the input vector corresponding to each sequence in the abnormal charging segment sequence to the corresponding abnormal score is taken as the contribution of the current feature factor to the degree of abnormality. All feature factors whose contribution exceeds a preset contribution threshold are marked as abnormal feature factors and serialized to construct an abnormal dimension index set; The feature factors corresponding to each sequence segment in the abnormal dimension index set are combined and matched with a predefined rule base. Based on the matching result, the abnormal segment sequence number and abnormal type corresponding to the current charging abnormality are determined and output. The rule base stores the mapping relationship between different feature dimension combinations and abnormal types.
9. The energy storage charging anomaly detection method based on user switching behavior according to claim 8, characterized in that: The implementation steps for storing the mapping relationship between different feature dimension combinations and anomaly types in the rule base include: When the feature dimensions are combined as average charging power and total charging capacity, the anomaly type is determined to be no charging or severely insufficient charging. When the feature dimensions are combined as the standard deviation of charging power and the peak-to-valley difference rate, the anomaly type is determined to be intermittent charging or drastic power fluctuations. When the feature dimensions are combined as time window overlap and out-of-window energy ratio, the anomaly type is determined to be a policy violation. When the feature dimensions are combined as morphological similarity and time lag, the anomaly type is determined to be behavioral pattern deviation.
10. An energy storage charging anomaly detection system, applicable to the energy storage charging anomaly detection method based on user switching behavior as described in any one of claims 1 to 9, characterized in that: include: The data preprocessing module is used to acquire and process the power consumption time series data, perform missing value filling and discharge power zeroing operations, and identify and segment all valid charging segments based on the dual threshold hysteresis comparison mechanism. The feature extraction module is used to extract the basic state features that characterize the energy and power statistics of the charging segment itself, the strategy template conformity feature that characterizes the degree of conformity between the actual charging behavior and the grid dispatch strategy template in terms of time and energy, and the behavior profile conformity feature that characterizes the degree of similarity between the current charging curve and the power curve template in terms of shape and time phase. The model computation module has a pre-trained reconstruction autoencoder model embedded in it, which is used to receive basic state features, policy template compliance features and behavior profile compliance features, and output the corresponding reconstruction vector based on the reconstruction autoencoder model. The intelligent diagnostic module determines anomaly scores that characterize the degree of anomaly based on the reconstruction residual between the reconstructed vector and the input vector. It then makes anomaly determinations based on the anomaly scores and performs contribution analysis and anomaly feature factor identification on the segments determined to be anomalous. Finally, it calls the rule base to map the identified anomaly feature factor combinations to specific anomaly root causes.
11. An electronic device, characterized in that: The device includes a memory and a processor. The memory stores a computer program, and when the processor calls the computer program in the memory, it implements the steps of the energy storage charging anomaly detection method based on user switching behavior as described in any one of claims 1 to 9.
12. A storage medium, characterized in that: The storage medium stores computer-executable instructions, which, when loaded and executed by a processor, implement the steps of the energy storage charging anomaly detection method based on user switching behavior as described in any one of claims 1 to 9.
Citation Information
Patent Citations
Abnormality detection method and system for energy storage battery based on optical fiber sensor
CN120142984A
Frequency converter fault prediction method and system based on machine learning
CN120763808A
Abnormal data prediction and state evaluation method for battery
CN121114791A
Battery health detection method and system based on vehicle type-charging curve double-library mapping
CN121180062A
Shared power bank abnormal occupation identification method
CN121388931A