Electricity consumption trend analysis and early warning method and system for electric vehicle charging station

By constructing a spatiotemporal joint representation model and dynamically adjusting the detection threshold, the problem of balancing model sensitivity and stability in the monitoring of electric vehicle charging station power load is solved, achieving high-precision identification of abnormal fluctuations and adaptive adjustment, thereby improving the robustness and operation and maintenance efficiency of the system.

CN121921049APending Publication Date: 2026-04-24GUANGZHOU RISEN INFORMATION TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
GUANGZHOU RISEN INFORMATION TECHNOLOGY CO LTD
Filing Date
2025-12-24
Publication Date
2026-04-24

AI Technical Summary

Technical Problem

Existing methods for monitoring the power load of electric vehicle charging stations suffer from several problems when dealing with complex spatiotemporal scenarios, sudden large-scale fluctuations, and the influence of external factors. These problems include difficulty in balancing model sensitivity and stability, lack of spatial context modeling, and high false alarm and false negative rates due to static abnormal threshold parameters.

Method used

High-frequency collection of electric vehicle charging station power load data is adopted, and graph neural network is used to model the topological relationship between stations to construct a spatiotemporal joint representation model. A lightweight Transformer architecture and an improved isolated forest algorithm are used for dual-channel trend analysis. Causal matching analysis is performed by combining meteorological and emergency event databases, and detection thresholds are dynamically adjusted to generate an adaptive anomaly detection parameter set.

Benefits of technology

It significantly improves the accuracy and adaptability of abnormal fluctuation identification, reduces false alarm rate and missed detection rate, improves the intelligence level and operation and maintenance efficiency of the system, and is suitable for the stable operation and management of large-scale urban charging networks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121921049A_ABST
    Figure CN121921049A_ABST
Patent Text Reader

Abstract

The invention discloses an electric vehicle charging station power consumption trend analysis early warning method and system, and the method comprises the steps: carrying out the time sequence collection, quality verification and structural processing of the high-frequency power consumption load data of a charging station, extracting multi-dimensional statistical features, and constructing a space-time joint representation through combining a graph neural network; a dual-channel trend analysis structure is adopted, a main channel captures a periodic trend by using a lightweight Transform, an auxiliary channel detects short-time deviation based on an improved isolated forest, and a response is dynamically adjusted through a gating fusion weight; according to the method, causal judgment of abnormal fluctuation is achieved by combining external factor correlation analysis, sensitivity parameters are dynamically adjusted to optimize a detection threshold value, efficient and accurate detection, classification and dynamic cause tracing of charging load fluctuation abnormity can be achieved, and the adaptability and early warning capacity of a system to environment changes are enhanced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of spatiotemporal modeling and anomaly detection technology for the power load of electric vehicle charging stations, and in particular to a method and system for trend analysis and early warning of power consumption of electric vehicle charging stations. Background Technology

[0002] Electric vehicle charging stations, as a new type of energy infrastructure, have developed rapidly in urban transportation and new energy deployments in recent years. With the increasingly diverse and complex spatiotemporal distribution of charging demand, the electricity load at charging stations exhibits nonlinear fluctuations and multi-source heterogeneous characteristics. Current mainstream solutions generally employ static statistical methods and periodic trend modeling for load monitoring and anomaly detection. The main technical approaches include: time-series-based threshold judgment methods, periodic fitting and residual analysis algorithms, and machine learning anomaly detection models such as isolated forests. These methods can effectively analyze long-term trends or regular periodic variations and identify abnormal changes in electricity load within a certain range. The above solutions are applicable to setting the charging station load baseline and identifying small daily fluctuations, but they often face the following technical bottlenecks when dealing with complex spatiotemporal scenarios, sudden large-scale fluctuations, or load anomalies caused by external factors: (1) It is difficult to balance model sensitivity and stability. Traditional anomaly detection methods, after improving the model's response sensitivity to short-term fluctuations, are prone to increase false alarm rate and disordered trend judgment signals, resulting in frequent operation and maintenance interventions; while if the model's stability to load patterns is enhanced, it may lead to missed detection of real sudden anomalies and failure to provide timely warning of key energy security risks; (2) Existing methods mainly rely on single time series parameters or static spatial distributions, lacking in-depth modeling of spatial context factors such as charging station area attributes, traffic flow, and load propagation mechanisms between adjacent nodes. For complex fluctuations driven by multiple factors, such as regional power consumption trends affected by weather changes, holiday peaks, or sudden events, traditional methods cannot effectively distinguish between "atypical anomalies" caused by reasonable external factors and "sudden anomalies" that require timely response, resulting in a single handling strategy and insufficient system robustness; (3) The abnormal threshold parameter is set statically and relies on manual subjective judgment or experience range adjustment for a long time. It lacks adaptive ability and is difficult to cope with the dynamic needs of different environments and diverse operating scenarios. As a result, the detection results are significantly affected by scene changes, and the overall false alarm rate and false alarm rate of the system remain high. Summary of the Invention

[0003] In order to solve the above-mentioned technical problems, the present invention provides a method for analyzing and warning of electricity consumption trends in electric vehicle charging stations.

[0004] The technical solution of this invention is implemented as follows: A method for analyzing and warning of electricity consumption trends at electric vehicle charging stations, comprising: S1: Collect high-frequency power load data sequences of electric vehicle charging stations and record the timestamp information of each sampling point to form raw load data with time sequence markings; S2: Divide the original load data into sliding windows, extract the statistical features within each time window, including mean, variance, rate of change and periodicity, and generate a basic time series feature vector; S3: Based on the geographical attributes of the area where the charging station is located and the real-time load status of adjacent charging nodes, a graph neural network is used to model the topological relationship between stations, calculate the contextual influence weight of each node, and integrate local dynamics and global situation to generate a spatiotemporal joint representation vector. S4: Input the basic time series feature vector and the spatiotemporal joint representation vector into the dual-channel trend analysis structure. The main channel uses a lightweight Transformer architecture to capture long-term periodic patterns, while the auxiliary channel integrates an improved isolated forest algorithm to identify short-term deviation points and outputs trend estimation results separated by the two channels. S5: Based on the context stability index calculated in real time, gating fusion is performed on the trend estimation results of the dual-channel separation. When the context environment is stable, the weight of the main channel is enhanced, and when it is unstable, the response priority of the auxiliary channel is increased to generate a fused dynamic trend baseline. S6: Input the detected potential abnormal fluctuations into the online verification module, combine them with external factor databases such as meteorology, holidays and emergencies to perform causal matching analysis, determine whether there are explanatory external causes for the fluctuations, and output the fluctuation interpretability determination result. S7: Trigger a dynamic sensitivity adjustment mechanism based on confidence feedback based on the fluctuation interpretability determination result: if there are interpretable factors, lower the detection threshold sensitivity in the corresponding scenario; if there is no clear cause and the deviation continues, increase the local sensitivity parameter and generate an adaptively adjusted abnormal detection parameter set. S8: Based on the adaptively adjusted anomaly detection parameter set update trend analysis strategy, output a structured load fluctuation identification report containing fluctuation type classification, occurrence location, duration and confidence level for use in the early warning and control process.

[0005] The present invention also provides an electric vehicle charging station power consumption trend analysis and early warning system, which uses the above-mentioned electric vehicle charging station power consumption trend analysis and early warning method to perform electric vehicle charging station power consumption trend analysis and early warning.

[0006] The present invention provides a method and system for analyzing and warning the electricity consumption trend of electric vehicle charging stations, which has the following beneficial effects: (1) This invention significantly improves the accuracy and adaptability of abnormal fluctuation identification by constructing a spatiotemporal joint representation model that integrates time series features and spatial topological relationships. It introduces graph neural networks to model the topological associations between charging stations and constructs a dual context feature space by combining regional geographical attributes and the load status of neighboring nodes, thus realizing the transformation from "single-point monitoring" to "network collaborative perception". On this basis, it uses a sliding window to extract multidimensional statistical features and captures long-term trend patterns and short-term mutation signals through a main and auxiliary dual-channel structure. The gating fusion mechanism dynamically adjusts the weight allocation based on the real-time context stability index, strengthens the periodic modeling capability during the stable operation of the power grid, and enhances the abnormal response sensitivity during periods of frequent disturbances. Thus, it can maintain excellent detection consistency under different operating conditions and effectively overcome the technical bottlenecks of poor robustness and weak generalization ability of traditional methods in dynamic environments. (2) This invention innovatively proposes a dynamic sensitivity adjustment mechanism based on confidence feedback, combining causal matching analysis and online reinforcement learning strategies to construct a closed-loop optimization system with continuous evolution capabilities. When the system identifies potential abnormal fluctuations, it automatically accesses multi-source external factor databases such as meteorology, traffic, and public events to trace the causes: if the fluctuation can be explained by reasonable external factors, it is classified as "atypical abnormality," and the detection sensitivity threshold for this type of scenario is reduced accordingly to avoid repeated false triggers; otherwise, the local sensitivity parameter is increased and the early warning process is initiated to ensure that the real risks are not missed. At the same time, the system continuously records each judgment result and its confidence level, and uses reinforcement learning to continuously update the sensitivity adjustment rule base, enabling the model to autonomously accumulate discrimination experience in long-term operation and gradually form an adaptive adjustment capability for diverse operating environments. This mechanism effectively balances the contradiction between false alarm rate and false negative rate in the detection process, significantly reduces the need for manual intervention, and significantly improves the intelligence level and operation and maintenance efficiency of the system, especially suitable for the long-term stable operation and management of large-scale urban charging networks; (3) This invention integrates a lightweight Transformer architecture and an improved isolated forest algorithm into a dual-channel analysis framework. While ensuring high-precision trend prediction and anomaly identification, it also considers computational resource consumption and real-time response performance, demonstrating good engineering feasibility. The main channel adopts a Transformer structure with simplified parameters and optimized attention mechanism to efficiently capture long-period dependency characteristics in load data and avoid the gradient vanishing problem of traditional RNN-type models. The auxiliary channel uses an improved isolated forest algorithm to enhance the detection capability of sparse anomalies, which is particularly suitable for the rapid location of short-term pulse-like load mutations under high-frequency sampling. The outputs of the two channels are fused through a gating mechanism, and the overall model can complete a complete inference round in a few hundred milliseconds, meeting the stringent real-time requirements of actual systems. In addition, the entire analysis process does not require a complex manual parameter tuning process. The model can autonomously adapt to the data distribution characteristics of new regions and new time periods through online learning, demonstrating excellent scalability and deployment flexibility. Attached Figure Description

[0007] Figure 1 A flowchart of a method for analyzing and warning the electricity consumption trend of electric vehicle charging stations according to the present invention; Figure 2 This is a sub-flowchart of a method for analyzing and warning the electricity consumption trend of electric vehicle charging stations according to the present invention. Figure 3 This is another sub-flowchart of the electric vehicle charging station power consumption trend analysis and early warning method of the present invention. Detailed Implementation

[0008] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as limiting the present invention.

[0009] The following disclosure provides many different embodiments or examples for implementing different structures of the invention. To simplify the disclosure, specific examples of components and arrangements are described below. Of course, these are merely examples and are not intended to limit the invention. Furthermore, reference numerals and / or letters may be repeated in different examples; such repetition is for simplification and clarity and does not in itself indicate a relationship between the various embodiments and / or arrangements discussed.

[0010] like Figure 1 As shown, this invention provides a method for analyzing and warning of electricity consumption trends at electric vehicle charging stations, specifically including: S1: Collect high-frequency power load data sequences of electric vehicle charging stations and record the timestamp information of each sampling point to form raw load data with time sequence markings; S2: Divide the original load data into sliding windows, extract the statistical features within each time window, including mean, variance, rate of change and periodicity, and generate a basic time series feature vector; S3: Based on the geographical attributes of the area where the charging station is located and the real-time load status of adjacent charging nodes, a graph neural network is used to model the topological relationship between stations, calculate the contextual influence weight of each node, and integrate local dynamics and global situation to generate a spatiotemporal joint representation vector. S4: Input the basic time series feature vector and the spatiotemporal joint representation vector into the dual-channel trend analysis structure. The main channel uses a lightweight Transformer architecture to capture long-term periodic patterns, while the auxiliary channel integrates an improved isolated forest algorithm to identify short-term deviation points and outputs trend estimation results separated by the two channels. S5: Based on the context stability index calculated in real time, gating fusion is performed on the trend estimation results of the dual-channel separation. When the context environment is stable, the weight of the main channel is enhanced, and when it is unstable, the response priority of the auxiliary channel is increased to generate a fused dynamic trend baseline. S6: Input the detected potential abnormal fluctuations into the online verification module, combine them with external factor databases such as meteorology, holidays and emergencies to perform causal matching analysis, determine whether there are explanatory external causes for the fluctuations, and output the fluctuation interpretability determination result. S7: Trigger a dynamic sensitivity adjustment mechanism based on confidence feedback based on the fluctuation interpretability determination result: if there are interpretable factors, lower the detection threshold sensitivity in the corresponding scenario; if there is no clear cause and the deviation continues, increase the local sensitivity parameter and generate an adaptively adjusted abnormal detection parameter set. S8: Based on the adaptively adjusted anomaly detection parameter set update trend analysis strategy, output a structured load fluctuation identification report containing fluctuation type classification, occurrence location, duration and confidence level for use in the early warning and control process.

[0011] Step S1: Collect high-frequency power load data sequences of electric vehicle charging stations and record the timestamp information of each sampling point to form raw load data with time-series markings. Specifically, this includes: S1.1: Obtain the raw current, voltage and power signals output by the power metering device in the electric vehicle charging station, and perform digital sampling of the analog signals based on the analog-to-digital conversion module to generate a discrete high-frequency power load data stream as the initial input data for subsequent processing; For the power metering device connected to the electric vehicle charging station, a three-phase synchronous sampling method (parameters: sampling frequency ≥ 10kHz, sampling bit width 16bit) is adopted to obtain the instantaneous value of the original current signal of each phase and ensure that the time deviation of the current sampling between each phase channel is controlled within the microsecond level. Furthermore, by using a high-precision voltage sampling module (parameters: input range 0~500V, sampling accuracy 0.1V), the instantaneous amplitude of each phase voltage signal is acquired, and the current signal and voltage signal are locked and aligned at the hardware timing level to ensure phasor matching for subsequent power calculations; Furthermore, using a real-time power calculation algorithm (parameter: sliding window length = one power frequency cycle), the instantaneous active power value is calculated according to the following formula. :

[0012] in, Instantaneous voltage For instantaneous current, The active power is accurately calculated by integrating within each sampling period, given the power frequency cycle duration. Furthermore, a high linearity analog-to-digital converter module (ADC parameters: ENOB≥14bit, sampling frequency≥100kS / s) is used to digitally sample the current, voltage and power signals after analog front-end conditioning, generate discretized three-channel signal sequences, and package each signal sample into a data frame structure according to a unified sampling time. Furthermore, by utilizing the data frame sequence buffering mechanism, the sampled data is sequentially cached and assigned sequence numbers to achieve full traceability of sampling points and packet loss detection. Through the above algorithm and sampling processing method, the physical signal of the previous step is transformed into a high-frequency discrete data stream of electricity load that is consistent in time, uniform in frequency, and standardized in format, so as to achieve the expected technical effect of providing high-quality input for subsequent timestamp marking and trend analysis. For example, for an electric vehicle charging station equipped with dual-gun DC fast charging piles, high-frequency sampling is performed between 08:00 and 08:05 on a certain operating day. The three-phase current sampling frequency is set to 12kHz, the sampling bit width is 16bit, the three-phase voltage sampling input range is 0~500V, the accuracy is 0.1V, and the analog-to-digital conversion module selected is an ENOB 14.2bit module. The ADC was used with a sampling frequency set to 120 kS / s. The peak values ​​of the sampled three-phase current waveforms were 112A, 109A, and 111A, respectively, and the effective voltage values ​​were 392V, 391V, and 393V, respectively. According to the instantaneous power calculation formula, the average active power obtained by integration within each power frequency cycle was 43.5kW. The data frames generated by the ADC sampling contained time sequence numbers from 00001 to 03600 (corresponding to 5 minutes × 60 seconds × 12 frames / second), and no frame loss was verified. This discretized data stream is input into the subsequent time sequence marking module, which can significantly improve the synchronization accuracy of cross-site trend analysis and the ability to capture load dynamics. S1.2: Apply a UTC standard timestamp to each sampling point in the high-frequency power load data stream based on the system synchronization clock source, and use the Network Time Protocol (NTP) to achieve microsecond-level time synchronization between multiple sites, generating an original load data sequence with a unified time sequence mark to ensure the time consistency of cross-regional data; Based on the digital sampling results of the high-frequency power load data stream of electric vehicle charging stations, a system synchronization clock source is adopted (parameter: clock stability < The timekeeping signal type is either atomic clock or GPS time synchronization. A UTC standard timestamp is applied to each sampling point in the data stream to achieve unified time marking across nodes. Furthermore, the system clocks of the edge computing nodes of each charging station are aligned and calibrated using the Network Time Protocol (NTP) (parameters: polling period = 1s, maximum allowable offset <50μs) to achieve microsecond-level time synchronization between distributed stations and generate a unified time reference for multiple nodes; Furthermore, using a timestamp appending algorithm (parameters: time format is ISO 8601 extended type, precision bits are at the millisecond level or higher), the aligned clock information is bound to each load data sampling point to generate a structured timestamp field, ensuring that any load data point has a globally unique and traceable time attribute; Furthermore, the UTC offset between multiple nodes at the current time is calculated using the time synchronization error estimation formula:

[0013] in, For the first Node sampling point timestamp, For reference node timestamp, The total number of nodes participating in the comparison. This represents the root mean square value of the time synchronization error; Furthermore, through the output of the formula The system automatically determines whether a second NTP synchronization calibration is needed by comparing the data with a preset threshold, and updates the timestamp dictionary for all sites after calibration is completed. The above algorithm is used to process the high-frequency load data stream from the previous step into a raw load data sequence with a unified time sequence label, achieving microsecond-level time consistency across regions. For example, in an electric vehicle charging network in a certain city, edge nodes use temperature-compensated crystal oscillator timekeeping modules with a maximum daily drift of less than 2μs. The system synchronization clock source is a GNSS receiver with a timing accuracy better than 5ns. The NTP alignment calibration polling period is configured to 0.5s, and the error threshold is set to 10μs. During a peak data collection period, real-time load data sampling points from 15 charging stations were extracted and bound to UTC time using a timestamp appending algorithm, with the time format being YYYY-MM-DDThh:mm:ss.sssZ. The root mean square error of time synchronization between multiple nodes was calculated. = μs, below the set threshold, no secondary calibration is required. The output raw load data sequence with uniform time-series labeling can be directly compared across sites in the subsequent quality verification step S1.3, significantly improving data consistency and the stability of subsequent feature extraction; S1.3: Perform preliminary quality checks on the raw load data sequence with timestamps, identify abnormal values ​​that exceed the rated range of the equipment based on the threshold comparison algorithm, mark suspected bad points and trigger the retransmission mechanism. If the data cannot be repaired, use linear interpolation to fill in the missing values ​​and generate the checked time series dataset. S1.4: The verified time-series dataset is structured and categorized according to charging station ID, charging pile number and phase type. Local caching and compression storage are performed using edge computing nodes to generate distributed raw load data packets with spatial identification attributes, providing an indexable data access interface for subsequent sliding window partitioning. S1.5: Upload distributed raw load data packets to the central data lake through a secure communication link, realize low-latency batch push based on Message Queuing Telemetry Transport Protocol (MQTT), and register the time range, geographical location and sampling frequency information of the data packets in the cloud metadata directory to form a standardized raw load data resource pool that can be called by global scheduling.

[0014] Step S2: Divide the original load data into a sliding window, extract statistical features within each time window, including mean, variance, rate of change, and periodicity, to generate a basic time-series feature vector. Specifically, this includes: S2.1: Obtain the original load data sequence with time-series markers, define the width and step size of the sliding window based on the preset time granularity, and perform equal-width sliding slice processing on the original load data to generate a series of continuous and partially overlapping time window segments, each segment corresponding to a local time-series observation segment; Obtain the raw load data sequence with time-series markers, and use the sliding window segmentation method (parameters: window width W, step size Δ) to achieve local slicing of the continuous data stream; Furthermore, by employing an equal-width slicing strategy (which determines the ratio between W and Δ based on a preset time granularity τ), sequential segmentation of the data stream is achieved, and a set of partially overlapping time windows is generated. Furthermore, through the index mapping algorithm (parameters: window start index i, end index i+W) 1) Implement synchronous extraction of timestamps and sampled values, and combine the extraction results into a local time series observation segment matrix, where the matrix columns correspond to sampled values ​​and the rows correspond to time window sequences; Furthermore, the window coverage verification method (parameter: overlap rate) is used. To achieve quantitative evaluation of window overlap and ensure the continuity of local temporal features under the condition that R ≥ preset threshold; Furthermore, through index iteration and batch slicing, all observation segments that meet the preset parameters are combined into a continuous sequence to form a windowed dataset for subsequent statistical feature extraction. By using the sliding window segmentation algorithm, the raw load data sequence generated in the previous step is transformed into a structured local time series observation segment containing timestamps, sample values ​​and window number identifiers, thereby standardizing the input data for statistical feature calculation. For example, in a load data sequence of an electric vehicle charging station (sampling frequency of 1Hz, sequence length of 3600 seconds), the window width W is set to... seconds, step size Δ is Seconds, with a time granularity τ corresponding to minute-level resolution. First, the timestamp range covered by each window is determined based on an equal-width slicing strategy; for example, the first window covers t0 to t... 59 The second window covers t 30 To t 89 This process continues until 118 partially overlapping window segments are formed. Then, an index mapping algorithm is used to synchronously extract the 60 load sample values ​​corresponding to each window and their timestamps, combining them into a single window. The matrix consists of columns and rows, with a total of 118 rows. Next, the window overlap ratio R is calculated using the formula... Substitute parameter W = Δ = We get R = Satisfying the preset threshold R≥ The conditions ensured the continuity of features. The final windowed dataset was standardized into structured data containing timestamp sequences, load matrices, and window numbers, for subsequent analysis of mean, variance, rate of change, and periodicity intensity. In actual verification, this processing method significantly improved the stability of periodic feature extraction while preserving the sensitivity of short-term fluctuation detection. S2.2: For the load sampling values ​​within each sliding window segment, the mean and variance are calculated using statistical methods. The mean reflects the average load level of the charging station during that period, and the variance characterizes the degree of load fluctuation dispersion, generating primary statistical characteristic parameters that include central tendency and dispersion characteristics. S2.3: Based on the changing relationship of the mean sequence between adjacent windows, the numerical differential algorithm is used to calculate the rate of change, that is, the growth slope of the average load within a unit time window, in order to capture the direction of short-term dynamic trends, and the rate of change is output as a dynamic response characteristic parameter. S2.4: Perform periodic intensity analysis on the load data within the current window, extract the energy amplitude of the dominant spectral component through Fourier transform, combine it with the peak height of the autocorrelation function at the main period delay point, and calculate the periodic intensity index to quantify the regularity and repeatability of load behavior during this period. S2.5: The statistical characteristic parameters of the four dimensions of mean, variance, rate of change and periodic intensity obtained above are vectorized and concatenated to generate a structured basic time series characteristic vector, which serves as the unified input for the next stage of dual-channel trend analysis structure, ensuring that the model can simultaneously perceive static distribution characteristics and dynamic evolution patterns.

[0015] like Figure 2 As shown, step S3 involves: based on the geographical attributes of the charging station's location and the real-time load status of adjacent charging nodes, using a graph neural network to model the topological relationships between stations, calculating the contextual influence weights of each node, and fusing local dynamics and global situational awareness to generate a spatiotemporal joint representation vector. Specifically, this includes: S3.1: Obtain the geographic attribute data of the electric vehicle charging station and the real-time load status sequence of adjacent charging nodes. The geographic attributes include the urban functional area category, traffic density index and surrounding facility type code. The real-time load status includes active power sampling value and equipment online rate. Based on the multi-source heterogeneous data, perform semantic alignment processing, use the embedding layer to map discrete geographic labels into low-dimensional dense vectors, and at the same time perform normalization transformation on the continuous load sequence to generate a unified dimension spatial attribute embedding vector to support subsequent topological relationship modeling. The system acquires geographic attribute data from electric vehicle charging stations and real-time load status sequences of adjacent charging nodes. The input objects include urban functional area categories provided by the urban planning database, traffic density index output by the traffic flow monitoring system, and surrounding facility type codes coded by the geographic information system. It also includes active power sampling values ​​and equipment online rate collected by the charging equipment sensors. A semantic alignment processing algorithm (parameters: word embedding dimension 64, category dictionary mapping table) is adopted to realize the low-dimensional dense vectorized representation of discrete geographic tags from different sources in a unified semantic space; Furthermore, through the embedding layer mapping process (parameter: the embedding matrix initialization method is uniform distribution), the urban functional area category labels are converted into vectors of length 64, the traffic density index level codes are converted into vectors of length 64, and the surrounding facility type codes are converted into vectors of length 64, forming a unified embedding vector set of discrete labels; Furthermore, a normalization transformation method (parameters: zero mean standardization, standard deviation calculation window of 24 hours) is used to scale the continuous active power sampling sequence and equipment online rate, so that the numerical distribution of different charging nodes is within the normalized interval of zero mean and unit variance. Furthermore, a spatial attribute embedding vector fusion model is constructed (parameters: fusion method is vector concatenation, output dimension 256). The discrete geographic attribute vector after embedding is combined with the normalized continuous load status vector in terms of dimension to generate a unified dimension spatial attribute embedding vector containing spatial location semantics and real-time operating status. Through the above fusion process, the multi-source heterogeneous raw data is transformed into node feature vectors with unified structure, consistent dimensions, and spatial semantic expression capabilities, thus realizing a spatial attribute base dataset that supports subsequent graph neural network topological relationship modeling. For example, in an electric vehicle charging network in a city center, the urban functional area is classified as a commercial area (code 3), the traffic density index is high (code 5), and the surrounding facility type is a large shopping mall (code 7). After discrete label embedding, these are transformed into dense vectors Va, Vb, and Vc of length 64, respectively. The active power sampling value of a charging station in this area has an average value of 16.2kW and a standard deviation of 4.1kW over the past 24 hours, and the average online rate of the equipment in the same period is 0.92 with a standard deviation of 0.06. The normalized power sequence is... The formula yields:

[0016] in These are the original sampled values. The mean, The standard deviation is converted into a sequence with a mean of 0 and a standard deviation of 1. The equipment online rate sequence is also normalized in the same way to obtain the sequence Ar. Va, Vb, Vc and Ar are concatenated to form a spatial attribute embedding vector of length 256, which is used as the input to the node feature matrix in the subsequent S3.2 step. This effectively improves the feature expression ability of the graph neural network in node spatial relationship modeling and shows a significant recognition effect on the propagation path of abnormal load fluctuations in the topology calculation experiment. S3.2: Based on the geographical distance threshold between charging stations and the grid connection relationship, a weighted undirected graph structure is constructed as the input topology of the graph neural network. The nodes represent charging stations, and the edge weights are jointly determined by geographical proximity and historical load correlation coefficient. The spatial attribute embedding vectors generated in the previous step are organized using this graph structure to form a graph data object with spatial association constraints. It contains a node feature matrix and an adjacency matrix, which serve as the basic input for the message passing mechanism of the graph neural network. Based on the spatial attribute embedding vectors generated in the previous steps and the geographical distance and power grid connection data between charging stations, a weighted graph construction method is adopted (parameter: geographical distance threshold). Power grid connection matrix The charging stations are represented as nodes in a set, thus achieving the initial formation of the network structure. Furthermore, the edge weight calculation function (parameter: geographic proximity index) is used. Historical load correlation coefficient The following weighted formula is used to fuse information from two dimensions to generate the edge weights between each pair of nodes. :

[0017] in and The fusion weighting coefficient is used to balance the effects of spatial proximity and load association; Furthermore, a weighted undirected graph topology is constructed based on the above edge weight set. An adjacency matrix generation algorithm (parameters: node ID list, edge weight mapping table) is used to generate an adjacency matrix of dimension N×N, where N is the total number of charging station nodes and the matrix elements represent the weight relationship between node pairs. Furthermore, through the feature matrix mapping method (parameter: spatial attribute embedding vector set) The embedding vector of each node is mapped to a node feature matrix of size N×d according to the node ID, where d is the spatial embedding dimension, so as to realize the ordered arrangement of features in the graph structure. By encapsulating graph data objects, the adjacency matrix and node feature matrix are combined into a unified Graph object structure, which serves as the basic input for the message passing mechanism of the graph neural network, thus achieving the synchronous supply of node features and topology. For example, in a scenario where electric vehicle charging station topology is constructed in a certain area, the geographical distance threshold is... Grid connection matrix set at 5km Provided by the operator, this record shows the direct cable connections between various sites. Geographic Proximity Index From the formula Calculate, where d is the measured distance between stations; historical load correlation coefficient Calculated using the Pearson correlation formula. The fusion weighting coefficient is set to... , The generated adjacency matrix has 0 on the main diagonal and the off-diagonal elements are the calculated edge weights. The spatial attribute embedding dimension d is set to 32, and the node feature matrix size is 50×32 (50 charging station nodes). The Graph object obtained by this method is input into the subsequent GAT model, which can realize the priority transfer of features between nodes with high proximity and similar load change trends, significantly improving the ability to model the propagation of abnormal fluctuations in the spatial dimension. S3.3: Deploy a message propagation algorithm based on graph attention mechanism (GAT) on the constructed graph data object, and perform weighted aggregation on the feature information received by each node from its first-order neighbors. The attention coefficient is calculated based on the dynamic consistency between the neighbor nodes and the central node in the load change trend. The node representation is iteratively updated through a multi-layer graph attention network to generate a local context feature vector that integrates high-order neighborhood information, reflecting the degree to which the current node is affected by the operating status of the surrounding charging facilities. S3.4: Based on the generated local context feature vector, calculate the context influence weight of each charging node. This weight reflects the strength of the influence of the node on the potential fluctuation propagation of other nodes in the network at the current moment. Use global average pooling operation to summarize the influence weights of all nodes and extract the global context feature vector that represents the operating status of the entire charging network, which is used to characterize the overall evolution trend of regional load fluctuation. S3.5: The local context feature vector and the global context feature vector are concatenated and fused, and compressed into a fixed-length spatiotemporal joint representation vector through a nonlinear projection layer. This vector simultaneously encodes the local dynamic response characteristics of the current charging station and the macroscopic situation information of its network environment, serving as the spatial context input in the subsequent dual-channel trend analysis structure, thereby achieving refined identification of abnormal fluctuation patterns in the spatiotemporal dimension.

[0018] like Figure 3As shown, step S4 involves inputting the basic time-series feature vector and the spatiotemporal joint representation vector into a dual-channel trend analysis structure. The main channel employs a lightweight Transformer architecture to capture long-term periodic patterns, while the auxiliary channel integrates an improved isolated forest algorithm to identify short-term deviations, outputting the trend estimation results separated by the two channels. Specifically, this includes: S4.1: Based on the basic temporal feature vector and spatiotemporal joint representation vector generated in the previous steps, they are concatenated into a joint input feature matrix to retain local statistical properties and global contextual information, and a multidimensional input tensor shared by the two channels is generated as the common input source for the main channel and the auxiliary channel. Based on the basic temporal feature vector and spatiotemporal joint representation vector generated in the preceding steps, a vector concatenation method is adopted (parameter: concatenation dimension is the sum of the feature lengths of the two, concatenation order is basic temporal features first, spatiotemporal joint representation second) to achieve linear connection between the two types of features in order to preserve static statistics and spatial context information. Furthermore, by using a feature dimension alignment algorithm (parameter: the target dimension adopts the same dimension length as the input channels of the main channel Transformer encoder and the auxiliary channel isolated forest detector), the consistency of the concatenated features in terms of numerical scale and dimensionality is achieved, and a joint input feature matrix with a unified numerical range is obtained; Furthermore, a normalization method is adopted (parameters: zero mean standard deviation normalization, mean μ comes from the average value of the basic time series feature components, standard deviation σ comes from the square root of the variance of the spatiotemporal joint representation components) to standardize the distribution of features from different sources and generate a normalized joint feature matrix to ensure the stability of the subsequent multi-channel model during gradient updates. Furthermore, the normalized joint feature matrix is ​​transformed into a four-dimensional tensor structure using a batch tensor quantization method (parameters: fixed batch size B, time step length T determined by the sliding window width). , where F is the total dimension of the concatenated features, realizing the input form of time series batch processing; By using a caching optimization strategy (parameters: pre-allocated GPU memory block size is consistent with batch tensor, asynchronous data loading is enabled), the result of the previous step is transformed into a multi-dimensional input tensor shared by the main channel and auxiliary channel, achieving the expected technical effect of easy parallel computing in dual channels; For example, in a load fluctuation detection application scenario for an electric vehicle charging network, the basic temporal feature vector is 64 in length, derived from the concatenation of mean, variance, rate of change, and periodicity intensity features. The spatiotemporal joint representation vector is 128 in length, derived from the fusion of local and global contexts encoded by GNN. A joint feature matrix of length 192 is obtained using a vector concatenation method. The input dimension F of the target main channel Transformer is set to 192, and the input dimension of the auxiliary channel isolated forest detector remains consistent. Zero-mean standard deviation normalization is performed, where the mean... The mean of all characteristic components is 3.27, and the standard deviation is... A value of 1.15 yields a balanced joint matrix. Let the batch size be... Time step length The shape of the tensor is The input tensor serves as the common input source for both the main and auxiliary channels, and is actually fed into the main and auxiliary channel calculation modules. In this scenario, the processed input tensor ensures the synchronous execution of the main channel periodic trend analysis and the auxiliary channel abnormal deviation detection, achieving parallel maintenance of trend stability and transient sensitivity, and significantly improving throughput and computation speed when operating on the GPU. S4.2: Perform main channel processing on the multidimensional input tensor, use the self-attention mechanism in the lightweight Transformer architecture to calculate the dependency weights between temporal positions, extract the periodic and trend patterns across time windows, generate the main channel trend encoding sequence, and decode the output long-term load trend estimate through a feedforward neural network to form a stable and dominant trend benchmark output. Based on the dual-channel shared multidimensional input tensor, a lightweight Transformer architecture with a self-attention mechanism in the main channel (parameters: time window length, number of attention heads, dimension scaling factor) is adopted to realize the dependency weight calculation between feature positions across time windows, so as to characterize the global correlation structure of periodic repetition patterns and trend change signals. Furthermore, an explicit embedding representation of time position is achieved through a position encoding generation module (parameter: frequency coefficients of sine / cosine encoding function), and this position encoding vector is added to the input feature matrix to improve the sensitivity of the self-attention mechanism to time series ordinal information and its ability to maintain long-term trend structure. Furthermore, the input feature matrix is ​​parallelized for attention weight calculation using a multi-head self-attention operation unit, employing a scaled dot product attention formula:

[0019] in, For attention score matrix, For querying the matrix, The key matrix, For value matrices, The square root of the key vector dimension is used to scale the weights to prevent gradient vanishing and to generate an attention output tensor that captures long sequence dependencies across the window. Furthermore, the multi-head attention output is processed through a residual connection and a layer normalization module (parameter: normalization ε smoothing coefficient) to enhance gradient stability and maintain feature scale consistency. The output is then fed to a position feedforward neural network (parameter: hidden layer size, activation function type ReLU) to perform nonlinear feature mapping and extract high-order pattern information of the long-term trend encoding sequence. Furthermore, the long-term trend encoding sequence is mapped to numerical periodic trend estimates through the decoding layer, and the hidden feature dimension is compressed to a single trend output dimension using a linear projection matrix to obtain a long-term load trend prediction sequence on a continuous time scale, which serves as a stable and dominant trend benchmark output. By using a lightweight Transformer main channel's self-attention and feedforward network processing method, the multidimensional input tensor from the previous step is transformed into long-term load trend estimation data, enabling the main channel to accurately capture and stably output periodic and trend patterns. For example, in an application scenario where main channel processing is performed on the joint input feature matrix, the input tensor dimension is 128×64, where 128 represents the number of sampling points within the time window, and 64 represents the feature dimension that integrates basic temporal statistical properties and spatial context. The number of attention heads is set to 8, and the dimension scaling factor is... The value is 8, and the frequency coefficient of the sine / cosine hybrid positional encoding is 0.05. In the multi-head self-attention calculation, the query, key, and value matrices are all generated from the input feature matrix through different linear mapping matrices, each with a dimension of 64×8. In the scaled dot product attention operation, the following is used: The attention score matrix is ​​calculated, and the weight distribution is obtained through softmax normalization, resulting in an output dimension of 128×8. After residual and layer normalization, it is fed into a feedforward network with a hidden layer dimension of 256 and ReLU activation function. The decoding linear projection matrix has a dimension of 256×1, mapping the encoded sequence to a trend value sequence of length 128. In this scenario, the final output trend curve exhibits a smooth periodic structure in the time domain. In validation on datasets with strong seasonal load fluctuations, the stability of trend prediction and the ability to fit long-term patterns are significantly improved. S4.3: Perform auxiliary channel processing on the multidimensional input tensor in parallel, construct an anomaly scoring function based on the improved isolated forest algorithm, perform random segmentation path modeling on the sample subset in the input feature space, calculate the anomaly score of each sampling point, identify short-term fluctuation points that significantly deviate from the normal distribution, and generate a short-term deviation intensity sequence as a highly sensitive anomaly response output. The multidimensional input tensor is processed in parallel using auxiliary channels, and an improved isolated forest algorithm (parameters: adjusted subsampling ratio, dynamic node partitioning threshold) is used to achieve high-sensitivity anomaly detection of feature space samples. Furthermore, a subset of feature vectors is extracted from the multidimensional input tensor using a random subsampling method (parameters: sample subset ratio p, random seed setting), and then passed to the tree model building module to ensure the model's generalization ability under different operating conditions. Furthermore, using a random segmentation path modeling method (parameters: segmentation attribute selection strategy, maximum tree depth setting), the feature space is randomly divided in each isolated tree according to the feature values, and the path length from each sampling point to the leaf node is recorded to form a path length sequence as the basis for scoring. Furthermore, the path length is quantified using an anomaly scoring function, and the anomaly score for each sampling point is calculated using the following formula. :

[0020] in, The average path length of the sample across all trees. In a sample size of The expected path length can be determined by comparing the actual path length with the expected value, which can quantify the degree of abnormal deviation. Furthermore, a threshold segmentation is performed on the above abnormal score sequences using a set significance threshold to screen out sampling points that are significantly higher than the normal distribution range and mark them as short-term fluctuation points, ensuring that the detection results maintain a high responsiveness to sudden changes; By using anomaly scoring functions and threshold segmentation methods, the random segmentation path results from the previous step are transformed into a short-term deviation intensity sequence, thereby enabling a quantitative characterization of transient abnormal fluctuations. For example, in a scenario where the multidimensional input tensor is a spatiotemporal joint representation vector containing four statistical features—time mean, variance, rate of change, and periodicity intensity—the subsampling ratio p is set to 0.6, the maximum tree depth to 15, and the random seed to 12345 to ensure repeatability. During the construction of 100 isolated trees, each tree uses a random feature partitioning method, randomly selecting split points based on the range of input feature values; for example, a sampling point has a path length of 8 in the 25th tree, and the average path length across all trees is calculated. The value is 7.5. Based on the sample size t=256, the expected path length is calculated. An anomaly score of approximately 7.2 is considered an anomaly score. =1.041, and sampling points exceeding the set threshold of 1.02 are marked as transient fluctuation events. The short-time deviation intensity sequence output by this process can significantly improve the system's recognition accuracy for aperiodic load impacts and provide highly sensitive and stable anomaly detection input for subsequent gating fusion; S4.4: The long-term load trend estimate of the main channel output and the short-term deviation intensity sequence of the auxiliary channel output are time-series aligned and normalized to generate a dual-channel separation trend vector group with consistent structure, ensuring that the two are comparable in terms of time granularity and numerical scale, and providing compatible input for subsequent gating fusion. Based on the long-term load trend estimate from the main channel output and the short-term deviation intensity sequence from the auxiliary channel output, a timestamp index matching algorithm (parameters: window width and sliding step size are consistent with the previous input) is used to achieve precise alignment of the two time series data on the sampling scale. Furthermore, by using a linear interpolation resampling method (parameter: interpolation order is first), missing sampling points are filled in and the time scale is smoothed, generating an aligned sequence output without time gaps; Furthermore, a normalization algorithm (parameters: standardization method is Z-score, mean and standard deviation are calculated independently based on their respective channels) is used to achieve consistency in the numerical scale of the two sequences, and the normalized trend sequence matrix is ​​obtained. Furthermore, by using a scale-matching correction method (parameter: the correction coefficient is determined by the ratio of the long-term trend mean of the main channel to the deviation intensity mean of the auxiliary channel), the proportion of the two data in absolute magnitude is coordinated, generating a trend vector group with a unified dimension; Furthermore, by utilizing the dimension arrangement and index mapping function (parameter: the index mapping table consists of channel identifiers and time indices), the structural consistency of the dual-channel separated trend data in terms of matrix dimensions and index order is achieved, thereby forming a dual-channel separated trend vector group; Through the above normalization and structural consistency processing, the trend estimate from the previous step is transformed into a dual-channel trend vector that is comparable in terms of time granularity and numerical scale, thereby achieving full compatibility and computational stability of the input in the subsequent gating fusion stage. For example, in a certain electric vehicle charging station network operation scenario, the long-term trend estimation sequence output by the main channel has a sampling frequency of 1Hz and a total of 3600 sampling points; the short-time deviation intensity sequence output by the auxiliary channel has a time offset of approximately 2% due to the internal calculation delay of the algorithm. A timestamp index matching algorithm is used, with a sliding window width of 60 seconds and a step size of 10 seconds, to strictly align the two data streams on the time scale, and linear interpolation is used to fill in the 72 missing sampling points generated during the offset process. During the normalization calculation, the main channel trend mean... The value is 35.4, with a standard deviation of 100%. The mean is 5.2; the auxiliary channel mean is 0.84, and the standard deviation is 0.17. After normalization, the mean of both data approaches zero, and the variance approaches 1. During proportional correction, the correction coefficient is calculated as follows: The deviation intensity sequence after the auxiliary channel is normalized is scaled by approximately 42.14 to match the dimensions of the main channel. The resulting dual-channel trend vector groups are all 3600×1 in matrix dimension and have the same index order, ensuring that no additional resynchronization processing is required when the gating fusion algorithm is called in subsequent calls, thus achieving a significant improvement in the compatibility and accuracy of dual-channel data. S4.5: Output the trend estimation results of the dual channels, including the periodic trend curve provided by the main channel and the transient deviation event markers detected by the auxiliary channel. The two are logically independent and complementary in information, and together they form the input basis for the next stage of gating fusion, realizing the decoupled expression of trend stability and fluctuation sensitivity.

[0021] Step S5: Based on the real-time calculated context stability index, gated fusion is performed on the trend estimation results of the dual-channel separation. When the context environment is stable, the weight of the main channel is increased; when it is unstable, the response priority of the auxiliary channel is increased, generating a fused dynamic trend baseline. Specifically, this includes: S5.1: Based on the spatiotemporal joint representation vector and basic temporal feature vector generated in the preceding steps, calculate the context stability index of the current running segment. Use the statistical dispersion (standard deviation / mean) and periodic consistency deviation (root mean square of the residual between the actual value and the historical predicted value) of the load sequence within the sliding time window as input variables, and generate a quantitative index through weighted normalization to characterize the stability of the external environment in which the current system is located. The output is the context stability index value. S5.2: Based on the context stability index value, a gating weight adjustment function is set to construct a piecewise linear mapping relationship: when the context stability index is higher than the preset high threshold, the environment is determined to be stable, the output main channel weight coefficient approaches 1 and the auxiliary channel weight approaches 0; when the index is lower than the preset low threshold, the environment disturbance is determined to be significant, the output main channel weight decreases to the minimum allowable value and the auxiliary channel weight increases to approach 1; the intermediate interval uses linear interpolation to achieve a smooth transition and generate a dynamic gating weight vector; The input is the context stability index value calculated according to step S5.1, and the execution object is the gating fusion weight adjustment process of the long-term trend estimation result and the short-term deviation intensity result of the dual-channel trend analysis structure output. A piecewise linear mapping function is used to construct the method (parameter: preset high threshold). Preset low threshold Smooth interval interpolation coefficients ), to implement the context stability index Mapping the weighting coefficients of the primary and secondary channels; Furthermore, through the interval determination algorithm (parameter: , , To classify stability conditions, a set of interval identifiers C = {stable interval, unstable interval, transition interval} is obtained. Furthermore, for the stable interval, the constant weighting function is called (parameter: target weight value). Generate static weight vectors This ensures that the main channel trend output is fully retained; Furthermore, for the unstable interval, the constant value transposition function is called (parameter: target weight value). , Generate static weight vectors This ensures the high responsiveness of the auxiliary channel and reduces the stability of the main channel output. Furthermore, for the transition interval, a linear interpolation function (parameter: To achieve a smooth transition of weights, the interpolation formula is as follows: ,in For the current context stability index, and These are the high and low thresholds, respectively, and the auxiliary channel weights are determined by... The calculation yields a dynamically gated weight vector that continuously varies within a smooth interval. By using the above piecewise linear mapping and interpolation processing method, the context stability index result of the previous step is transformed into the main and auxiliary channel weight coefficients corresponding to the time point, thereby achieving the adaptive weight allocation effect of the gating fusion process. For example, within a certain runtime period, let the context stability index ξ = 0.72, and the high threshold... =0.8, low threshold =0.3, minimum weight of the main channel =0.2, maximum weight of auxiliary channel =0.8. The interval determination algorithm outputs that the time period is in the transition interval, and linear interpolation is used to calculate the main channel weight coefficient. ,Right now Auxiliary channel weight coefficient = Within the smooth interval, the weights continue to change. Adjusting as values ​​change, the stability gradually approaches the target value. When the weight of the main channel increases significantly and the weight of the auxiliary channel decreases, the proportion of trend stability is ensured; when near As the transition occurs, the weight of the auxiliary channel gradually increases, enhancing its responsiveness to abnormal fluctuations. The results of this example demonstrate that the method can achieve continuous dynamic adjustment of the primary and auxiliary weights during the transition period, effectively balancing stability and sensitivity in the overall trend analysis. S5.3: Perform point-by-point multiplication operations on the long-term trend estimation sequence output by the main channel and the short-term deviation intensity sequence output by the auxiliary channel with the dynamic gating weight vector respectively, and perform weighted fusion processing on the two trend estimation results to obtain the comprehensive trend response value at each time point, ensuring that the periodic regularity is preserved under steady-state conditions and the transient sensitivity is preserved in sudden change scenarios. S5.4: Perform smoothing correction on the weighted and fused comprehensive trend response sequence, use an adaptive Kalman filter algorithm to suppress local oscillation artifacts caused by weight switching, dynamically update the process noise covariance parameter based on the current observation residual, optimize the filter gain, and generate an intermediate fused trend curve with time-varying smoothing characteristics. S5.5: Perform trend continuity verification and extreme value correction on the intermediate fusion trend curve, detect whether there are non-physical jumps or platform drift phenomena. If an anomaly is found, perform local reconstruction based on the trend slope and confidence feedback information of the adjacent window, and finally output a continuous, robust and context-aware dynamic trend baseline for subsequent abnormal fluctuation judgment and sensitivity adjustment.

[0022] Step S6: The detected potential abnormal fluctuations are input into the online verification module. Causal matching analysis is performed using a database of external factors such as meteorology, holidays, and emergencies to determine whether there are any explainable external causes for the fluctuation, and the fluctuation interpretability determination result is output. Specifically, this includes: S6.1: Obtain a set of potential abnormal fluctuation events output by the dual-channel trend analysis structure, where each event includes an occurrence timestamp, spatial location identifier, load deviation magnitude, and duration, and trigger an external factor correlation query request based on the time-space coordinates of the event to initiate the causal matching analysis process; S6.2: Based on the time-space coordinates, relevant environmental variable data for the corresponding time period are retrieved in parallel from the pre-constructed multi-source external factor database, including regional meteorological data (such as sudden temperature changes and heavy rainfall), public calendar information (such as statutory holidays and large-scale events), and emergency event records released by transportation and emergency management departments (such as road closures and power grid maintenance), to generate a candidate set of external factors that match the current abnormal event in time and space. Based on the timestamps and spatial location identifiers of the abnormal fluctuation events output by step S6.1, a time-space index query method (parameters: event timestamp, spatial location code) is used to locate multi-source environmental variable data segments that are consistent with the spatiotemporal range of the events from the external factor database. Furthermore, a regional meteorological data extraction algorithm (parameters: geographic coordinates, time range, meteorological data resolution) is used to obtain weather observation and forecast values ​​for the target area from the meteorological database, including temperature, humidity, precipitation, wind speed, etc., and additionally extract extreme event labels such as sudden temperature changes or heavy rainfall occurrence markers to generate a meteorological impact feature set. Furthermore, a public calendar association algorithm (parameters: date code, administrative region identifier) ​​is used to match the schedules of statutory holidays, commemorative days and major events from the public affairs database, and associate the spatial vector data of the event locations to generate feature sets of holidays and major events; Furthermore, a traffic event retrieval algorithm (parameters: road network topology ID, event time interval) is used to retrieve records of emergencies such as road closures, traffic congestion levels, and power grid maintenance plans from the traffic and emergency database, and to analyze the event impact radius and duration to generate a traffic and power grid event feature set. By combining and processing multi-source feature sets, the meteorological impact feature set, the holiday and large-scale event feature set, and the traffic and power grid event feature set are integrated into a unified external factor candidate set. This enables the establishment of a time-space matching relationship with the current abnormal event and provides structured input for subsequent causal correlation calculations. For example, an abnormal fluctuation event occurred at a charging station at 15:00 on July 15, 2024, with spatial coordinates of longitude 120.15°E and latitude 30.25°N. Using a time-space index query method, the time range was set to 14:30 to 15:30 on July 15, 2024, and the spatial location code was the administrative division code of the city. Meteorological databases were searched to obtain records of a sudden temperature change from 30°C to 38°C and strong gusts of wind from 3 m / s to 9 m / s during this period. A public calendar association algorithm was used to identify any large-scale events that were not public holidays or registered on that date. The traffic and emergency database returned information on a traffic accident and subsequent closure of an adjacent highway section between 15:05 and 15:40, with an impact radius of 8 km and a duration of 35 minutes. After merging, the generated candidate set of external factors includes meteorological change features (temperature change range of 8℃, wind speed change range of 6m / s) and traffic accident features (impact radius of 8km, duration of 35min), providing accurate multi-source feature input for the causal correlation calculation of S6.3; S6.3: Perform causal correlation calculation on the candidate set of external factors, use Pearson correlation coefficient and Granger causality test to jointly evaluate the time series correlation strength between each external factor and the observed load fluctuation, and set a significance threshold to screen out statistically significant strong correlation factors to form a preliminary causal matching list; S6.4: Based on the strongly correlated factors in the preliminary causal matching list, call the pre-trained domain knowledge graph inference engine to perform semantic-level attribution inference, analyze whether the physical path logic of external factors acting on the charging load is valid, such as 'extreme high temperature → air conditioning load increase → electric vehicle charging demand delay and aggregation'. If the path is reachable, it is marked as interpretable; otherwise, pseudo-correlation interference items are removed. Based on the strongly correlated factors in the preliminary causal matching list, a pre-trained domain knowledge graph reasoning engine (parameters: node category vector, relation type matrix) is used to realize the semantic entity mapping function between external factors and charging load changes. Furthermore, through a path search algorithm (parameters: maximum hop count limit, relation weight threshold), the directed relation link between strongly correlated factors and load fluctuation nodes is retrieved, and a set of candidate paths that can be verified by subsequent physical logic is obtained; Furthermore, a causal link reachability detection algorithm (parameters: path length, node semantic consistency score) is adopted to calculate the reachability of each candidate path and generate a path reachability index. Furthermore, by using a physical action mechanism matching model (parameters: equipment type, energy efficiency curve library, demand response mode), the physical mechanism of each relationship chain in the candidate path is verified, ensuring that the direction and magnitude of the impact of each hop in the path conform to the physical laws of charging load change. Furthermore, a path scoring function is used to quantitatively evaluate each candidate path; the scoring formula is as follows:

[0023] in The path score. Let i be the relation weight for the i-th hop. Score the semantic consistency of the i-th hop. This is the path length penalty coefficient; Through the aforementioned inference engine and physical path verification method, the strongly correlated factors in the previous step are transformed into interpretable path reachability data, thereby enabling a technical assessment of whether the charging load fluctuation can be explained by external factors. For example, at a charging station on a major urban traffic artery, the initial causal matching list includes the strongly correlated factor "significant increase in traffic congestion index." The domain knowledge graph includes node categories "traffic events," "travel demand," and "charging load," along with their relationship types "impact" and "drive." The path search algorithm sets a maximum hop limit of 3 and a relationship weight threshold of 0.6, retrieving the following path set: traffic congestion → travel delay → concentrated charging demand → increased load. The causal link reachability detection algorithm calculates the path reachability index to be 0.82. The physical mechanism matching model finds that the "concentrated charging demand" and "increased load" phases in this path conform to the rated power and demand response pattern of the equipment in this region, and the energy efficiency curve library backtests to verify that the equipment status changes are consistent. According to the formula... The calculations are as follows: Let the weights of the three-hop relationships be 0.7, 0.8, and 0.9, respectively; the semantic consistency scores be 0.85, 0.88, and 0.9, respectively; and the path length penalty coefficient be... =0.2, thus obtaining The score was approximately 1.627, which is higher than the interpretability threshold of 1.5. Therefore, the fluctuation was determined to be interpretable. The application results showed that this determination effectively avoided false alarms in the same situation in the subsequent sensitivity adjustment stage, and significantly improved the robustness of the system. S6.5: By combining the statistical correlation strength and semantic logical reachability results, the final fluctuation interpretability judgment result is generated, and a binary classification label ('interpretable' or 'uninterpretable') and the corresponding confidence score are output as the input control signal for the next stage dynamic sensitivity adjustment mechanism.

[0024] Step S7: Based on the fluctuation interpretability determination result, a dynamic sensitivity adjustment mechanism based on confidence feedback is triggered: if there are interpretable factors, the detection threshold sensitivity in the corresponding scenario is lowered; if there is no clear cause and the deviation continues, the local sensitivity parameter is increased, generating an adaptively adjusted set of anomaly detection parameters. Specifically, this includes: S7.1: Obtain the fluctuation interpretability determination result output by the online verification module. This result includes a causal matching conclusion on whether potential abnormal fluctuations are caused by external factors such as weather changes, holiday effects, or sudden events. Perform a classification judgment based on the causal matching conclusion. If the match is successful, generate an 'interpretable fluctuation' label; otherwise, generate an 'uninterpretable fluctuation' label, which serves as the basis for subsequent sensitivity parameter adjustment decisions. S7.2: Based on the 'interpretable fluctuation' label, retrieve prior response records for similar scenarios from the historical fluctuation database, and use the Bayesian inference algorithm to calculate the posterior confidence of the false alarm probability in the current situation; input the confidence into the threshold parameter tuning function, perform negative gain adjustment to reduce the anomaly scoring weight of the isolated forest algorithm in the corresponding scenario, and generate a desensitized subset of anomaly detection parameters to suppress false alarms caused by known reasonable perturbations; S7.3: For the 'Unexplained Fluctuations' label, combine the trend deviation index output by the time series residual analysis module to calculate the cumulative standardized deviation between the load data and the dynamic trend baseline within the continuous sampling window; construct the mutation intensity index based on this cumulative deviation, and map it to the local sensitivity enhancement level through the fuzzy logic controller, and output a positive adjustment signal to enhance the splitting threshold response sensitivity of the isolated forest in the auxiliary channel. S7.4: Input the desensitization or amplification adjustment signal to the online learning unit. This unit uses a lightweight Q-learning strategy to maintain a sensitivity adjustment rule base. Its state space consists of context stability index, regional load density and weather level, and the action space corresponds to different levels of threshold offset. Based on the current situation, match the optimal adjustment action and generate an adaptive adjustment anomaly detection parameter set to ensure that the adjustment behavior meets the dual constraints of long-term operating experience and real-time situation. S7.5: Output the optimized anomaly detection parameter set to the auxiliary channel of the trend analysis module to update the node splitting threshold and subsampling ratio of the isolated forest algorithm; at the same time, write the current adjustment event and its confidence feedback information into the system audit log to form a closed-loop learning sample, providing labeled data support for the retraining of the subsequent reinforcement learning model and realizing the continuous evolution of the detection strategy.

[0025] Step S8: Based on the adaptively adjusted anomaly detection parameter set, update the trend analysis strategy and output a structured load fluctuation identification report containing fluctuation type classification, occurrence location, duration, and confidence level for use in the early warning and control process. Specifically, this includes: S8.1: Based on the adaptively adjusted anomaly detection parameter set generated in the previous steps, the dual-channel fusion trend baseline in the current period is dynamically calibrated. The latest context stability index and confidence feedback record in the sliding window are used to correct the periodic prediction offset of the lightweight Transformer main channel and adjust the anomaly scoring threshold of the isolated forest auxiliary channel to generate a trend analysis strategy parameter set that is adapted to the current operating environment. S8.2: Perform segmented aggregation processing on the residual sequence between the dynamic trend baseline output after gating fusion and the real-time sampled load data. Combine the geographical location and topological weight marked in the spatiotemporal joint representation vector to identify abnormal fluctuation segments with deviations exceeding the calibration threshold and mark them as candidate load events. Output a preliminary event list containing start and end timestamps, spatial node numbers and original deviation amplitudes. S8.3: Based on the fluctuation interpretability judgment results output by the online verification module, perform causal attribution classification on candidate load events: if the event has a spatiotemporal matching relationship with entries in the database of meteorological changes, holiday travel peaks, or emergencies, it is classified as 'externally driven fluctuation'; otherwise, it is judged as 'endogenous abnormal fluctuation', and further classified into sudden impact type or continuous shift type according to the change rate characteristics and the degree of periodic intensity decay, generating a set of classified events with fluctuation type labels; S8.4: For the classified load fluctuation events, calculate the spatial impact range of each event—the context impact weights output by the graph neural network are backpropagated to adjacent charging nodes to assess their cascading response probability, and combined with the duration and peak load ratio to generate a multi-dimensional evaluation index vector, including event duration, number of affected nodes, estimated load gap and propagation risk level. S8.5: Integrate fluctuation type labels, spatial node numbers, start and end timestamps, duration, multi-dimensional evaluation index vectors, and confidence level scores, and encapsulate them into a structured load fluctuation identification report according to a preset communication protocol format. The report is then pushed to the early warning control module via an API interface. At the same time, the characteristics of this event are stored in the historical case library for iterative optimization of the sensitivity adjustment rule library in the reinforcement learning strategy.

[0026] The present invention also provides an electric vehicle charging station power consumption trend analysis and early warning system, which uses the above-mentioned electric vehicle charging station power consumption trend analysis and early warning method to perform electric vehicle charging station power consumption trend analysis and early warning.

[0027] The technical solution of the present invention has been described above with reference to the preferred embodiments shown in the accompanying drawings. However, it will be readily understood by those skilled in the art that the scope of protection of the present invention is obviously not limited to these specific embodiments. Without departing from the principles of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will all fall within the scope of protection of the present invention.

[0028] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and rules of the present invention should be included within the scope of protection of the present invention.

Claims

1. A method for analyzing and early warning of electricity consumption trends at electric vehicle charging stations, characterized in that, Includes the following steps: S1: Collect high-frequency power load data sequences of electric vehicle charging stations and record the timestamp information of each sampling point to form raw load data with time sequence markings; S2: Divide the original load data into a sliding window, extract the statistical features within each time window, and generate a basic time series feature vector; S3: Based on the geographical attributes of the area where the charging station is located and the real-time load status of adjacent charging nodes, a graph neural network is used to model the topological relationship between stations, calculate the contextual influence weight of each node, and integrate local dynamics and global situation to generate a spatiotemporal joint representation vector. S4: Input the basic time series feature vector and the spatiotemporal joint representation vector into the dual-channel trend analysis structure, wherein the main channel adopts the Transformer architecture to capture long-term periodic patterns, and the auxiliary channel integrates the improved isolated forest algorithm to identify short-term deviation points, and outputs the trend estimation results of the dual channels. S5: Based on the context stability index calculated in real time, perform gated fusion on the trend estimation results of the dual-channel separation to generate a fused dynamic trend baseline; S6: Input the detected potential abnormal fluctuations into the online verification module, combine them with the external factor database to perform causal matching analysis, determine whether there are explanatory external causes for the potential abnormal fluctuations, and output the fluctuation interpretability determination result. S7: Based on the fluctuation interpretability determination result, trigger the dynamic sensitivity adjustment mechanism based on confidence feedback to generate an adaptively adjusted set of anomaly detection parameters.

2. The method for analyzing and warning the electricity consumption trend of electric vehicle charging stations according to claim 1, characterized in that, The process following step S7 also includes: S8: Based on the adaptively adjusted anomaly detection parameter set, update the trend analysis strategy and output a structured load fluctuation identification report containing fluctuation type classification, occurrence location, duration, and confidence level for use in the early warning and control process.

3. The method for analyzing and warning the electricity consumption trend of electric vehicle charging stations according to claim 1, characterized in that, Step S1 specifically includes: The system acquires the raw current, voltage, and power signals output by the power metering device in the electric vehicle charging station, and digitally samples the analog signals based on the analog-to-digital conversion module to generate a discrete high-frequency power load data stream. Based on the system synchronous clock source, a UTC standard timestamp is applied to each sampling point in the high-frequency power load data stream, and the network time protocol is used to perform microsecond-level time synchronization between multiple sites to generate an original load data sequence with a unified time sequence mark. A preliminary quality check is performed on the original load data sequence with unified time-series label. Abnormal values ​​exceeding the rated range of the equipment are identified based on the threshold comparison algorithm. Suspected bad points are marked and a retransmission mechanism is triggered. If they cannot be repaired, the missing values ​​are filled in by linear interpolation to generate a time-series dataset after verification. The verified time-series dataset is structured and categorized according to charging station ID, charging pile number, and phase type. Local caching and compression storage are performed using edge computing nodes to generate distributed raw load data packets. The distributed raw load data packets are uploaded to the central data lake via a secure communication link. Low-latency batch push is performed based on the message queue telemetry transmission protocol. The time range, geographical location and sampling frequency information of the data packets are registered in the cloud metadata directory to form a standardized raw load data resource pool that can be globally scheduled and invoked.

4. The method for analyzing and warning the electricity consumption trend of electric vehicle charging stations according to claim 1, characterized in that, Step S2 specifically includes: Obtain the original load data sequence with time-series markers, define the width and step size of the sliding window based on the preset time granularity, perform equal-width sliding slicing processing on the original load data sequence to generate time window segments, each segment corresponding to a local time-series observation segment; For the load sampling values ​​within each sliding window segment, the mean and variance are calculated using statistical methods to generate primary statistical characteristic parameters. Based on the changing relationship of the mean sequences between adjacent windows, a numerical differentiation algorithm is used to calculate the rate of change. Perform periodic intensity analysis on the load data within the current window, extract the energy amplitude of the dominant spectral components through Fourier transform, and combine it with the peak height of the autocorrelation function at the main period delay point to calculate the periodic intensity index. The statistical feature parameters of the four dimensions—mean, variance, rate of change, and periodic intensity index—are vectorized and concatenated to generate a structured basic time series feature vector.

5. The method for analyzing and warning the electricity consumption trend of electric vehicle charging stations according to claim 1, characterized in that, Step S3 specifically includes: Geographic attribute data of electric vehicle charging stations and real-time load status sequences of adjacent charging nodes are obtained. Semantic alignment processing is performed based on the geographic attribute data and the real-time load status sequences. Discrete geographic labels are mapped into low-dimensional dense vectors using an embedding layer. At the same time, the continuous load sequence is normalized to generate spatial attribute embedding vectors. Based on the geographical distance threshold between charging stations and the connection relationship with the power grid, a weighted undirected graph structure is constructed as the input topology of the graph neural network. The spatial attribute embedding vector is organized using the weighted undirected graph structure to form a graph data object. A message propagation algorithm based on graph attention mechanism is deployed on the graph data object. The feature information received by each node from its first-order neighbors is weighted and aggregated. The node representation is iteratively updated through a multi-layer graph attention network to generate a local context feature vector. Based on the local context feature vector, the context influence weight of each charging node is calculated, and the influence weights of all nodes are summarized using a global average pooling operation to extract the global context feature vector. The local context feature vector and the global context feature vector are concatenated and fused, and then compressed into a fixed-length spatiotemporal joint representation vector.

6. The method for analyzing and warning the electricity consumption trend of electric vehicle charging stations according to claim 5, characterized in that, The geographic attribute data includes urban functional area categories, traffic density index, and surrounding facility type codes, and the real-time load status sequence includes active power sampling values ​​and equipment online rate.

7. The method for analyzing and warning the electricity consumption trend of electric vehicle charging stations according to claim 1, characterized in that, Step S4 specifically includes: Based on the generated basic temporal feature vector and spatiotemporal joint representation vector, they are concatenated into a joint input feature matrix to generate a dual-channel shared multidimensional input tensor. The multidimensional input tensor is processed by the main channel. The self-attention mechanism in the Transformer architecture is used to calculate the dependency weights between temporal positions, extract the periodic and trend patterns across time windows, generate the main channel trend encoding sequence, and decode and output the long-term load trend estimate through a feedforward neural network. Parallel auxiliary channel processing is performed on the multidimensional input tensor. An anomaly scoring function is constructed based on the improved isolated forest algorithm. Random segmentation path modeling is performed on the sample subset in the input feature space. Anomaly scores for each sampling point are calculated. Short-term fluctuation points that significantly deviate from the normal distribution are identified, and a short-term deviation intensity sequence is generated. The long-term load trend estimate and the short-term deviation intensity sequence are time-series aligned and normalized to generate a dual-channel separation trend vector group with consistent structure.

8. The method for analyzing and warning the electricity consumption trend of electric vehicle charging stations according to claim 1, characterized in that, Step S5 specifically includes: Based on the generated spatiotemporal joint representation vector and the basic time series feature vector, the context stability index of the current running segment is calculated. The statistical dispersion and periodic consistency deviation of the load sequence within the sliding time window are used as input variables. The quantitative index is generated through weighted normalization and the context stability index value is output. Based on the context stability index value, a gating weight adjustment function is set, a piecewise linear mapping relationship is constructed, and a dynamic gating weight vector is generated. The long-term trend estimation sequence output by the main channel and the short-term deviation intensity sequence output by the auxiliary channel are multiplied point by point with the dynamic gating weight vector respectively. The two trend estimation results are then weighted and fused to obtain the comprehensive trend response value at each time point. The comprehensive trend response sequence is subjected to smoothing correction processing. An adaptive Kalman filter algorithm is used to suppress local oscillation artifacts caused by weight switching. The process noise covariance parameter is dynamically updated based on the current observation residual to generate an intermediate fusion trend curve. The intermediate fusion trend curve is subjected to trend continuity verification and extreme value correction to detect whether there are non-physical jumps or platform drift phenomena. If an anomaly is found, local reconstruction is performed based on the trend slope and confidence feedback information of the adjacent window to output a dynamic trend baseline.

9. The method for analyzing and warning the electricity consumption trend of electric vehicle charging stations according to claim 8, characterized in that, The piecewise linear mapping relationship is as follows: when the context stability index is higher than the preset high threshold, the environment is determined to be stable, the output main channel weight coefficient approaches 1 and the auxiliary channel weight approaches 0; when the index is lower than the preset low threshold, the environment disturbance is determined to be significant, the output main channel weight decreases to the minimum allowable value and the auxiliary channel weight increases to approach 1; the intermediate interval is smoothed by linear interpolation.

10. A power consumption trend analysis and early warning system for electric vehicle charging stations, characterized in that: The method for analyzing and warning the electricity consumption trend of electric vehicle charging stations as described in any one of claims 1-9 is used to perform electricity consumption trend analysis and warning for electric vehicle charging stations.