A micro-grid edge terminal multi-source fusion monitoring method and system
By time correction and resampling of microgrid data, combined with load forecasting models and anomaly detection algorithms, the problems of data inconsistency and insufficient anomaly identification in existing microgrid monitoring systems have been solved. This has enabled high-precision terminal-level anomaly monitoring and rapid response, thereby improving the operational safety and intelligence of microgrids.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- STATE GRID JIANGSU ELECTRIC POWER CO LTD NANJING POWER SUPPLY COMPANY
- Filing Date
- 2026-02-04
- Publication Date
- 2026-06-05
AI Technical Summary
Existing microgrid monitoring systems cannot accurately reflect real-time operating status, cannot dynamically and adaptively adjust prediction rhythm, cannot distinguish between local anomalies and global anomalies, and anomaly detection lacks hierarchical and neighborhood correlation judgment.
By collecting microgrid electrical data, equipment status data, and environmental data, performing time correction and resampling, calculating fusion coding features, and combining load forecasting models and anomaly detection algorithms, high-precision fusion and adaptive prediction of multi-source data are achieved. Temporal convolutional networks and isolated forest algorithms are used for terminal-level anomaly identification and classification.
It enables high-precision monitoring and rapid response of microgrid edge terminals, accurately distinguishes between local and global anomalies, and provides clear anomaly classification and response strategies, thereby improving operational safety and intelligence.
Smart Images

Figure CN122159494A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the fields of industrial Internet of Things and microgrid technology, and relates to a multi-source fusion monitoring method and system for microgrid edge terminals. Background Technology
[0002] With the continuous development of energy technologies, microgrids, as a highly autonomous distributed energy system, can effectively improve power supply flexibility, stability, and renewable energy absorption capacity by integrating "source-load-storage" units. Therefore, they are widely used in scenarios such as industrial parks, remote rural areas, isolated power grids, and disaster emergency power systems. Microgrids generally have the characteristics of multi-source heterogeneity, dynamic coupling, and time-varying complexity, which places higher demands on the real-time monitoring and intelligent management of their operating status.
[0003] Currently, the status monitoring methods used in microgrid operation and management systems include: Patent CN117595504A provides an intelligent monitoring and early warning method for power grid operation status. This method extracts abnormal interference signals by classifying and tracing the attributes of a power grid operation fault event database, and trains a power grid operation anomaly prediction network library based on multiple operation scenarios to achieve intelligent monitoring and early warning of power grid operation status; Patent CN118971339A proposes a power grid operation status monitoring method and system based on multi-source data analysis. This method collects power grid operation parameters through multi-source sensors, performs quality assessment, weighted fusion, and dynamic weight adjustment on the data to construct a high-quality multi-source dataset, and then uses the fused data to identify abnormal patterns in power grid operation, significantly improving the accuracy and response speed of power grid monitoring; Patent CN119089401A... The patent discloses a data fusion method and system for multi-source microgrids. This method intelligently aggregates multi-source operation and maintenance data through hierarchical data acquisition and a spatiotemporal data fusion model enhanced by deep learning, and adopts a dynamic adaptive strategy to adjust model parameters, thereby improving the real-time performance, security and intelligence level of microgrid operation.
[0004] While such solutions can achieve basic remote monitoring and optimized control under certain conditions, they have the following problems: ① The inconsistent collection frequencies and delays of electrical data, equipment status data, and environmental data generated by microgrid terminals make it impossible for traditional fusion methods to accurately reflect the real-time operating status. ② Existing monitoring systems typically use fixed-period prediction or event triggering based on simple thresholds, which are difficult to cope with rapid load fluctuations in microgrids and cannot dynamically and adaptively adjust the prediction rhythm based on multi-source data; ③ Existing anomaly detection methods are mostly limited to the whole network or regional level, and cannot distinguish between local anomalies and global anomalies of each terminal in the microgrid, nor can they combine neighborhood correlation to determine whether anomalies have a systemic impact. Summary of the Invention
[0005] To address the technical problems in existing technologies, such as inconsistent sampling frequencies of multi-source data, insufficient fusion quality, inaccurate prediction triggering timing, lack of hierarchical anomaly identification, and inability to unify decision-making between alarm and detection results, this invention provides a multi-source fusion monitoring method and system for microgrid edge terminals. The method includes: collecting and processing microgrid electrical data, equipment status data, and environmental data; calculating fusion coding features; determining periodic prediction triggering conditions and event prediction triggering conditions; performing short-term load prediction when periodic or event prediction is triggered; calculating the anomaly score of the corresponding terminal when the calculated load difference exceeds a predetermined load difference threshold; indicating the existence of a local anomaly when the anomaly score is not less than a predetermined local anomaly threshold; calculating the neighborhood consistency coefficient of the terminal to determine whether a global anomaly exists; acquiring equipment fault alarm tags; and calculating rule scores to classify the terminal as anomaly when a terminal has equipment fault alarms or a global anomaly. This invention achieves high-precision monitoring, rapid response, and intelligent operation and maintenance of microgrid edge terminals through multi-source data quality assessment and fusion, adaptive prediction triggering mechanisms, and hierarchical anomaly identification.
[0006] The present invention adopts the following technical solution: The first aspect of the present invention provides a multi-source fusion monitoring method for a microgrid edge terminal, comprising: S1. Collect microgrid electrical data, equipment status data, and environmental data, and perform time correction and resampling processing; calculate the quality score of each type of data after processing, and perform linear coding based on this to obtain fused coding features; S2. Calculate the fluctuation of the fused coding features at different time locations, and determine the periodic prediction trigger conditions by combining the predefined base period and period value range; determine the event prediction trigger conditions based on the load power of the microgrid access, the resampled equipment status data and environmental data; when periodic prediction or event prediction is triggered, input the fused coding features into the constructed load prediction model to perform short-term load prediction. S3. Monitor load data mutations in the load forecast results and calculate load differences. When the load difference is greater than the predetermined load difference threshold, use the resampled device status data of each terminal in the microgrid as the input of the isolated forest and calculate the anomaly score of the corresponding terminal. When the anomaly score is not less than the predetermined local anomaly threshold, it indicates that the corresponding terminal has a local anomaly. Set the neighboring terminal set for each terminal, calculate the neighborhood consistency coefficient of each terminal, and determine whether the terminal has a global anomaly. S4. Obtain the device fault alarm flag for each terminal. When a terminal has a device fault alarm or a global anomaly, calculate the rule score for the corresponding terminal. Based on the device fault alarm and the rule score, classify the terminal as an anomaly.
[0007] Preferably, the process of obtaining fused coding features through linear coding in S1 is as follows: For any electrical data, equipment status data, and environmental data, the absolute values of the differences between the corresponding data at each time point and the adjacent timestamps before resampling are calculated and averaged to obtain the mean time difference for each type of data at the corresponding time point. The exponential coefficient of the mean time difference is multiplied by the mean time difference and converted to a negative number, which is used as the exponent of an exponential function with the natural constant as the base to obtain the timeliness parameter for each type of data at the corresponding time point. The total number of collections for each type of data before resampling is divided by the total number of collections after resampling to obtain the integrity parameter for the corresponding data. For each type of data, the timeliness parameter and integrity parameter at each time point are weighted to obtain the quality score for the corresponding data at the corresponding time point. The quality score for each type of data is then subjected to a softmax transformation to obtain the fusion weight for the corresponding data. A single-layer linear coding method is used to encode features for each type of data, resulting in encoded features. By using fusion weights, the encoded features of different data at the same time are weighted to obtain fused encoded features.
[0008] Preferably, the process of determining the periodic prediction triggering condition in S2 is as follows: For any position of the fused coding feature, calculate the absolute value of the difference between the current position and the previous position as the numerator, and the absolute value of the previous position as the denominator to obtain the feature difference at the current position; weight the feature difference at the current position with the volatility of the fused coding feature at the previous position to obtain the volatility of the fused coding feature at the current position; add 1 to the volatility at the current position as the denominator, use the basic period as the numerator, and round down the calculated ratio to obtain the adaptive period at the current position and limit it to the range of period values; When the difference between the current time and the previous prediction completion time reaches the corresponding adaptive period, periodic prediction is triggered.
[0009] Preferably, the process of determining the event prediction triggering conditions in S2 is as follows: For any sampling time, calculate the absolute value of the difference between the total load power connected to the microgrid at the current sampling time and the previous sampling time, as the load power change; calculate the first norm of the difference between the equipment state data after resampling at the current sampling time and the previous sampling time, to obtain the average change of equipment state; calculate the first norm of the difference between the environmental data after resampling at the current sampling time and the previous sampling time, to obtain the average environmental disturbance. Predefined power change thresholds, equipment status change thresholds, and environmental disturbance thresholds are used. When the load power change, average equipment status change, or average environmental disturbance is not less than the predefined threshold, event prediction is triggered.
[0010] Preferably, the process of short-term load forecasting in S2 is as follows: When a periodic prediction or event prediction is triggered, the fused encoded features within a predetermined time period before the trigger time are obtained as a historical time series. A temporal convolutional network is used to extract local and long-term dependency features from the historical time series to obtain historical dependency features. Through a gated recurrent unit, the temporal dependency relationships of the historical dependency features are extracted to obtain temporal fusion features. An attention mechanism is used to weight the temporal fusion features to obtain a context vector. A window length is set, and the resampled device state data is linearly mapped after a window moving average, and then an activation function is used to obtain a device state gating vector. The context vector and the device state gating vector are concatenated and input into the prediction layer to obtain the predicted value.
[0011] Preferably, the process of determining whether a global anomaly exists in the terminal in S3 is as follows: Define the set of neighboring terminals for each terminal as , and obtain the adjacency weight by normalizing the distances between different terminals; For each terminal, calculate the absolute value of the difference between the abnormal scores of the corresponding terminal and the abnormal scores of the neighboring terminals in the neighboring terminal set to obtain the abnormal score difference between each terminal and its corresponding neighboring terminals; accumulate the adjacency weights of the neighboring terminals in the neighboring terminal set whose abnormal score difference is not greater than a predetermined tolerance and whose abnormal scores are not less than a predetermined local abnormal threshold, and use this as the neighborhood consistency coefficient of the corresponding terminal; when the neighborhood consistency coefficient of the terminal is not less than the predetermined consistency threshold and the abnormal score of the corresponding terminal is not less than the predetermined local abnormal threshold, it indicates that the corresponding terminal has a global abnormality.
[0012] Preferably, the process of calculating the rule score for the corresponding terminal in S4 is as follows: For each terminal, when the corresponding terminal has a device fault alarm or a global anomaly, the anomaly score, global anomaly flag, and device fault alarm flag of the corresponding terminal are weighted and summed and then restricted to the interval (0,1) to obtain the rule score of the corresponding terminal.
[0013] Preferably, the process of classifying the terminal as abnormal in S4 is as follows: When a device fault alarm is detected, it indicates a device fault, and a selective tripping and reclosing scheme is implemented. When there is no device fault alarm and the rule score is greater than a predetermined first threshold, abnormal device disturbances cause system instability, and load is selectively disconnected and the operating voltage and frequency are stabilized. When there is no device fault alarm and the rule score is not greater than the predetermined first threshold and not less than the predetermined second threshold, abnormal device fluctuations occur, and the power supply or energy storage device is adjusted to maintain power balance. When there is no device fault alarm and the rule score is less than the predetermined second threshold, sensor interference or local noise occurs, and a manual maintenance work order is dispatched.
[0014] A second aspect of the present invention provides a multi-source fusion monitoring system for a microgrid edge terminal, using a multi-source fusion monitoring method for a microgrid edge terminal, comprising: The data acquisition and processing module collects microgrid electrical data, equipment status data, and environmental data, and performs time correction and resampling processing; it calculates the quality score of each type of data after processing, and performs linear encoding based on this to obtain fused coding features; The load forecasting module calculates the fluctuation of the fused coding features at different time locations, and determines the periodic forecasting trigger conditions by combining the predefined base period and period value range; it determines the event forecasting trigger conditions based on the load power connected to the microgrid, the resampled equipment status data, and environmental data; when periodic forecasting or event forecasting is triggered, the fused coding features are input into the constructed load forecasting model to perform short-term load forecasting. The anomaly monitoring module monitors load data mutations in the load forecast results and calculates load differences. When the load difference exceeds a predetermined load difference threshold, it uses the resampled device status data of each terminal in the microgrid as input for the isolated forest and calculates the anomaly score of the corresponding terminal. When the anomaly score is not less than a predetermined local anomaly threshold, it indicates that the corresponding terminal has a local anomaly. It sets a set of neighboring terminals for each terminal, calculates the neighborhood consistency coefficient of each terminal, and determines whether the terminal has a global anomaly. The anomaly classification module obtains the device fault alarm flag for each terminal. When a terminal has a device fault alarm or a global anomaly, it calculates the rule score for the corresponding terminal. Based on the device fault alarm and the rule score, the terminal is classified as an anomaly.
[0015] A third aspect of the present invention provides a terminal, including a processor and a storage medium; The storage medium is used to store instructions; The processor is configured to operate according to the instructions to execute the steps of a multi-source fusion monitoring method for a microgrid edge terminal.
[0016] A fourth aspect of the invention provides a computer-readable storage medium having a computer program stored thereon that, when executed by a processor, implements the steps of a multi-source fusion monitoring method for a microgrid edge terminal.
[0017] Compared to existing technologies, the beneficial effects of this invention include at least the following: 1. This invention achieves high-precision fusion of microgrid electrical data, equipment status data, and environmental data by constructing a multi-source data quality assessment model that includes timeliness parameters, integrity parameters, and quality scores. Before fusion, data with different sampling frequencies undergo time correction and resampling, and the contribution of various data types is dynamically adjusted based on softmax weights, ensuring that the fused encoding features accurately reflect the validity and reliability of different types of data at the current moment. Unlike existing technologies that only achieve data cleaning or static weight fusion, this invention achieves adaptive coupling between data quality and weights, significantly improving the real-time performance and accuracy of multi-source data fusion, and providing a stable data foundation for subsequent load forecasting and anomaly detection.
[0018] 2. This invention solves the problem that traditional fixed-period prediction cannot adapt to rapid changes in microgrids by dynamically calculating the adaptive period through the fusion of coded features. Simultaneously, it effectively captures sudden changes in operating status by using load power changes, equipment state changes, and environmental disturbances as triggering events. When a prediction is triggered, this invention utilizes a temporal convolutional network, gated recurrent units, and an attention mechanism to jointly model historical dependencies and temporal features, and constructs equipment state gating vectors to enhance prediction decisions, making the prediction results highly sensitive to changes in the state of terminal equipment.
[0019] 3. This invention achieves a hierarchical identification mechanism for terminal-level anomalies through load mutation detection, isolated forest local anomaly scoring, and neighborhood consistency coefficient calculation, accurately distinguishing between local and global anomalies. Based on this, combined with equipment fault alarms and rule scores, anomaly terminals are clearly classified, including equipment faults, instability caused by equipment disturbances, fluctuations caused by power imbalances, and sensor interference. Corresponding handling strategies are matched for each type of anomaly, such as tiered load shedding, power supply or energy storage adjustment, tripping and reclosing, or dispatching manual work orders. Compared to the fuzzy judgment of existing technologies, this invention can achieve anomaly source location, severity assessment, and output of executable response strategies, greatly improving the operational safety, interpretability, and intelligence level of microgrid edge terminals. Attached Figure Description
[0020] Figure 1 This is a flowchart of a multi-source fusion monitoring method for microgrid edge terminals proposed in this invention. Detailed Implementation
[0021] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of this invention. The embodiments described in this application are merely some embodiments of this invention, and not all embodiments. Based on the spirit of this invention, all other embodiments obtained by those skilled in the art without creative effort are within the protection scope of this invention.
[0022] Example 1 Embodiment 1 of the present invention provides a multi-source fusion monitoring method for microgrid edge terminals, see below. Figure 1 This includes the following steps: S1. Collect microgrid electrical data, equipment status data, and environmental data, and perform time correction and resampling processing; calculate the quality score of each type of data after processing, and perform linear encoding based on this to obtain fused coding features.
[0023] Electrical data, equipment status data, and environmental data were collected separately; among them, electrical data... Includes three-phase voltage, three-phase current, active / reactive power, frequency, phase angle difference, total harmonic distortion; equipment status data. This includes circuit breaker status, tap position, equipment temperature, DC bus voltage; environmental data. This includes ambient temperature, humidity, wind speed, wind direction, and rainfall; Correcting time offsets in data from different data sources involves resampling the data using time delay compensation and linear interpolation. ; in, Representing modes data In the sequence after time delay compensation; Indicates resampling to t k Data; Indicates adjacent timestamps in the interpolation; This is the time delay compensation amount for mode m; As a preferred implementation method, the specific process for obtaining the fused coding features is as follows: For any electrical data, equipment status data, and environmental data, the absolute value of the difference between the corresponding data at each time point and the adjacent timestamp before resampling is calculated and averaged to obtain the mean time difference for each type of data at the corresponding time point. The exponential coefficient of the mean time difference is multiplied by the mean time difference and converted to a negative number, which is then used as the exponent of an exponential function with the natural constant as its base to obtain the timeliness parameter for each type of data at the corresponding time point. The total number of collections for each type of data before resampling is divided by the total number of collections after resampling to obtain the integrity parameter for the corresponding data. For each type of data, the timeliness parameter and integrity parameter at each time point are weighted to obtain the quality score for the corresponding data at that time point. The quality score for each type of data is then subjected to a softmax transformation to obtain the fusion weight for the corresponding data. The specific formula is as follows: ; in, For modal m data in The quality score at any given moment; This represents the total number of modal m data collected. This represents the total number of data points collected for each modality after resampling. For modal m data in Timeliness parameters at any given moment; Integrity parameters Weighting coefficients for timeliness parameters; It is an exponential function with the natural constant as its base; The exponential coefficient of the mean time difference; For modal m data in Moment-level fusion weights; The exponential coefficient of the quality fraction; A single-layer linear coding method is used to encode features for each type of data, resulting in encoded features. Then, by using fusion weights, the encoded features of different data at the same time are weighted to obtain fused encoded features. The specific formula is as follows: ; in, Encoding features for modal m data; The encoding matrix and bias parameters for modality m data; For the final result Moment-by-moment fusion of coding features.
[0024] In this embodiment, the original sequence for any mode is denoted as Let the set of all modes be denoted as These correspond to electrical data, equipment status data, and environmental data, respectively; through resampling, the data is unified to a sampling time interval of [missing information]. Sampling time is The data.
[0025] S2. Calculate the fluctuation of the fusion coding features at different time locations, and determine the periodic prediction trigger conditions by combining the predefined base period and period value range; determine the event prediction trigger conditions based on the load power of the microgrid access, the resampled equipment status data and environmental data; when periodic prediction or event prediction is triggered, input the fusion coding features into the constructed load prediction model to perform short-term load prediction.
[0026] As a preferred implementation method, the specific process for determining the periodic prediction triggering conditions is as follows: For any position of the fused encoded feature, calculate the absolute value of the difference between the current position and the previous position's fused encoded feature value as the numerator, and the absolute value of the previous position's fused encoded feature value as the denominator to obtain the feature difference at the current position; weight the feature difference at the current position with the volatility of the fused encoded feature at the previous position to obtain the volatility of the fused encoded feature at the current position; add 1 to the volatility at the current position as the denominator, use the base period as the numerator, and round down the calculated ratio to obtain the adaptive period at the current position, which is limited to the range of period values; the specific formula is: ; Where v(k) represents the fluctuation of the fused encoded feature at time k; It is the sliding factor; It is an adaptive period; The basic cycle; Indicates rounding down; This is a limiting function used to restrict the adaptive period to its minimum value. and period maximum value between; Represents the L2 norm; Get the last completed prediction time The difference between the current time and the previous prediction completion time reaches the corresponding adaptive period. At that time, periodic predictions are triggered.
[0027] As a preferred implementation method, the specific process for determining the event prediction triggering conditions is as follows: For any sampling time, calculate the absolute value of the difference between the total load power connected to the microgrid at the current sampling time and the previous sampling time, as the load power change; calculate the first norm of the difference between the resampled equipment state data at the current sampling time and the previous sampling time to obtain the average equipment state change; calculate the first norm of the difference between the resampled environmental data at the current sampling time and the previous sampling time to obtain the average environmental disturbance; the specific formula is as follows: ; in, , They represent the sampling times respectively. and Total load power connected to the microgrid; It is a norm; Sampling time Resampled device status data and environmental data; Predefined power change thresholds, equipment status change thresholds, and environmental disturbance thresholds are used. When the load power change, average equipment status change, or average environmental disturbance is not less than the predefined threshold, event prediction is triggered.
[0028] As a preferred implementation method, the specific process of short-term load forecasting is as follows: The load forecasting model employs an architecture combining temporal convolutional networks (TCN), gated recurrent units (GRU), and attention mechanisms to train and infer historical load data from microgrids in order to obtain short-term load forecasts. Once a periodic prediction or event prediction is triggered, the trigger time is obtained. Fusion coding features within the pre-determined duration T The data is used as a historical time series. Local and long-term dependency features are extracted from the historical time series using TCN to obtain historical dependency features. Temporal dependencies of these historical dependency features are extracted using GRU to obtain temporal fusion features. An attention mechanism is used to weight the temporal fusion features to obtain a context vector. A window length is set, and the resampled device state data is linearly mapped after window moving average. An activation function is then applied to obtain the device state gating vector. The context vector and the device state gating vector are concatenated and input into the prediction layer to obtain the predicted value. The specific process is as follows: Causal convolution is used to ensure that the convolution output depends only on the current and past inputs. At the same time, dilated convolution is introduced to expand the receptive field, thereby capturing long-term dependencies. The specific expression is as follows: ; in, Let u represent the u-th parameter in the l-th convolutional kernel, and K represent the kernel size. This represents the output of the current layer l; Indicates the expansion factor of the l-th layer; The first step of skip sampling One input; The ReLU activation function and residual connections are used to improve training stability. The specific formula is as follows: ; In the formula, This represents the output result of the l-th layer and t-th time step of the TCN, and the final output sequence is denoted as ; The output of TCN, i.e., the historical dependency features, is input into GRU, and the final output is the temporal fusion features. ; An attention mechanism is used to weight the temporal fusion features for each... Calculate its score, and then calculate the context vector after normalizing the score weights: ; in, This is the weight matrix; Here, v represents the bias; v represents the weight vector, calculated via a self-attention mechanism. The attention map is obtained; Indicates hidden state The importance of the prediction result; c is the context vector; To further consider the impact of sudden changes in equipment operating conditions, real-time features of the equipment status are introduced. A window length is set, and the resampled equipment status data is linearly mapped after a window moving average. An activation function is then used to obtain the equipment status gating vector. The specific formula is as follows: ; in, W is the device state gating vector; g b g represents the weights and bias coefficients of the linear mapping; D is the window length of the moving average of the device states. It is the sigmoid activation function; The context vector and the device state gating vector are concatenated and then input into the prediction layer to obtain the predicted value: ; in, This is a predicted value; These are the output layer weights and biases; This indicates that the context vector is concatenated with the device state gating vector; As a preferred implementation method, MSE is used as the loss function during training; the specific formula is as follows: ; In the formula, This represents the true value of the i-th sample. Let be the predicted value for the i-th sample; This represents the number of training samples.
[0029] S3. Monitor load data mutations in the load forecast results and calculate load differences. When the load difference is greater than the predetermined load difference threshold, use the resampled device status data of each terminal in the microgrid as the input of the isolated forest and calculate the anomaly score of the corresponding terminal. When the anomaly score is not less than the predetermined local anomaly threshold, it indicates that the corresponding terminal has a local anomaly. Set the neighboring terminal set for each terminal, calculate the neighborhood consistency coefficient of each terminal, and determine whether the terminal has a global anomaly.
[0030] Calculate the difference between the predicted load power and the load power predicted at the previous moment, as the load differential: ; When the load difference exceeds the predetermined load difference threshold, it indicates a sudden change in load power and triggers the anomaly monitoring process. For any terminal, the resampled device status data of the corresponding terminal is used as input to the isolated forest to calculate the anomaly score of the corresponding terminal; the specific process is as follows: The device status data is fed into each isolated tree in the forest, recording the path length from which it is partitioned to a leaf node within that tree, and calculating its average path length. ; in, is the average path length; n is the total number of trees; sample The path length in the j-th tree; The outlier score is calculated after normalizing the average path length; the specific formula is: ; In the formula, This is a normalization constant for the average path length, i.e., the subsample size. The expected path length; This represents the number of samples per tree, i.e., the subsample size. The harmonic number is used to calculate the expected average depth. is Euler's constant, approximately equal to 0.577, used to approximate the harmonic number; For the sample The closer the abnormal score is to 1, the more likely it is to be abnormal; When a terminal's anomaly score is not less than a predetermined local anomaly threshold, the corresponding terminal is considered to have a local anomaly, and the local terminal anomaly is marked as... ;in, This is a local exception flag for the terminal; it is set to 1 when an exception exists on the local terminal. For indicator functions; Predetermine the local anomaly threshold; Define the set of neighboring terminals for each terminal i as follows: , the distance between different terminals is obtained and normalized to obtain the adjacency weight; For each terminal, calculate the absolute value of the difference between the anomaly scores of the corresponding terminal and the neighboring terminals in the set of neighboring terminals to obtain the anomaly score difference between each terminal and the corresponding neighboring terminal; accumulate the adjacency weights of the neighboring terminals whose anomaly score differences are not greater than a predetermined tolerance and whose anomaly scores are not less than a predetermined local anomaly threshold in the set of neighboring terminals of the corresponding terminal as the neighborhood consistency coefficient of the corresponding terminal; when the neighborhood consistency coefficient of the terminal is not less than a predetermined consistency threshold and the anomaly score of the corresponding terminal is not less than a predetermined local anomaly threshold, it indicates that there is a global anomaly in the corresponding terminal; the specific formula is: ; where, is the neighborhood consistency coefficient of terminal i; is the adjacency weight between terminal i and the corresponding neighboring terminal j; is the anomaly score of terminal i; is the predetermined tolerance for controlling the anomaly score; is the global anomaly flag of terminal i; is the local anomaly flag of terminal i; is the predetermined consistency threshold; is the AND symbol.
[0031] S4. Obtain the device fault alarm flag of each terminal. When there is a device fault alarm or global anomaly in the terminal, calculate the rule score of the corresponding terminal; based on the device fault alarm and the rule score, classify the anomaly of the terminal.
[0032] For any terminal i, there are two sources of alarms, namely device fault alarms and local detection anomalies; local detection anomalies are determined by the local anomaly flag and global anomaly flag of the corresponding terminal; the device fault alarm flag is the alarm quantity from disposable devices, relay protections, intelligent switches, inverters, and energy storage devices. These alarm signals from the underlying devices themselves are sent to the edge terminal through the communication interface, denoted as , indicating the alarm quantity at the corresponding moment; For each terminal, when there is a device fault alarm or global anomaly in the corresponding terminal, sum the anomaly score, global anomaly flag, and device fault alarm flag of the corresponding terminal after weighting and limit it within the interval (0,1) to obtain the rule score of the corresponding terminal; the specific formula is: ; In the formula, is the rule score of terminal i; , and These are the adjustment coefficients for the anomaly score, global anomaly flag, and equipment fault alarm flag, respectively, with values all within the interval (0,1). ; After scoring, the emergency control measures phase begins. Taking into account the fault type, severity, and scope of impact, measures are selected to minimize the impact, and different thresholds are set. ;when When this occurs, it indicates a equipment malfunction. A selective tripping and reclosing solution will be implemented, and a manual replacement and maintenance work order will be dispatched. and When this occurs, it indicates that equipment malfunction or severe disturbance has threatened system stability. A plan to stabilize system operation is implemented, including tiered load shedding and stabilizing operating voltage and frequency. and In practice, equipment tends to experience abnormal fluctuations, requiring adjustments to the power supply or energy storage device to maintain power balance and reduce these fluctuations. and When this occurs, it indicates that there may be sensor interference or local noise, and a manual maintenance work order will be dispatched. After completing the emergency control, return to the monitoring state and continue to track the operation of the microgrid after the fault isolation; if necessary, dispatch center personnel can also intervene to confirm the control measures and handle subsequent matters.
[0033] Example 2 Embodiment 2 of this invention uses a microgrid in a suburban factory area as an application scenario, providing a multi-source fusion monitoring system for microgrid edge terminals. This microgrid includes various distributed power sources and loads, exhibiting typicality and versatility. The microgrid is connected at a 400V level (low-voltage factory grid) and consists of a "source-load-storage" system composed of photovoltaic power generation units, battery energy storage devices, key factory loads, and public grid interconnection lines. Four edge intelligent terminals (embedded terminals integrating AI chips) are deployed on-site, installed at key nodes of the microgrid, for local collection of multi-source data, intelligent analysis, and autonomous control. Each terminal runs the system module of this embodiment. The terminal sampling period is uniformly set to 1 second (i.e., data is collected once per second), and parameters such as the scheduling cycle and model window are reasonably configured according to the operating conditions to meet the requirements of real-time monitoring and control.
[0034] Terminal 1 (Main Grid Connection Point) is installed at the interconnection switch between the plant's microgrid and the public grid. It collects three-phase line voltage, current, and incoming circuit breaker status data to monitor total incoming power and grid status. Terminal 2 (Photovoltaic Power Generation Unit) is installed at the output of the photovoltaic inverter on the plant roof. It collects the inverter's output voltage, current, power, and operating status (alarm signals, switch status, etc.), and connects to environmental sensors to obtain data on irradiance and photovoltaic panel temperature. Terminal 3 (Energy Storage Unit) is installed at the battery energy storage converter. It collects DC bus voltage, battery current, SOC (State of Charge), energy storage converter operating status (charge / discharge mode, fault alarms), and equipment temperature data. Terminal 4 (Load Feeder) is installed at the feeder outlet of the main load. It collects the three-phase voltage, current, active / reactive power, power factor, and total harmonic distortion (THD) of this branch, as well as the circuit breaker status, relay protection action signals, and equipment status data. It also obtains environmental information on plant temperature and humidity.
[0035] The data types collected by the aforementioned terminals cover electrical quantities (such as three-phase voltage, current, active / reactive power, frequency, phase angle difference, and harmonic distortion rate), equipment status quantities (such as circuit breaker opening and closing status, tap position of on-load tap-changing transformers, equipment operating mode, fault alarm signals, and DC bus voltage), and environmental quantities (such as ambient temperature, humidity, wind speed, wind direction, light intensity, and rainfall). This multi-source heterogeneous data provides a comprehensive information foundation for subsequent fusion analysis.
[0036] The multi-source fusion monitoring system includes: The data acquisition and processing module collects microgrid electrical data, equipment status data, and environmental data, and performs time correction and resampling processing; it calculates the quality score of each type of data after processing, and performs linear encoding based on this to obtain fused coding features; Each terminal acquires the aforementioned multi-source data from the connected sensors and device interfaces according to a 1-second sampling period, and performs preprocessing locally on the terminal.
[0037] Since timestamps from different data sources may be inconsistent, this embodiment first performs time alignment on the collected multi-source data, and then resamples all data onto a unified 1-second time grid using time synchronization and linear interpolation methods. Let's assume a terminal is at time... A set of electrical quantities, equipment status quantities, and environmental quantity data were acquired, and a sequence was obtained after time correction and resampling. For each data mode, its data quality score is calculated, including completeness and timeliness indicators, and then normalized using the Softmax function. Subsequently, a linear feature encoding layer is used to transform the data from each mode to obtain the fused coded features for the current moment. The fused feature vector integrates information from electrical quantities, equipment status, and environmental quantities, achieving a unified representation of the microgrid's operating status, and can more accurately reflect the system state compared to single-source data.
[0038] The load forecasting module calculates the fluctuation of the fused coding features at different time locations, and determines the periodic forecasting trigger conditions by combining the predefined base period and period value range; it determines the event forecasting trigger conditions based on the load power connected to the microgrid, the resampled equipment status data, and environmental data; when periodic forecasting or event forecasting is triggered, the fused coding features are input into the constructed load forecasting model to perform short-term load forecasting. Each terminal inputs the real-time fused feature sequence obtained in step S1 into the pre-trained load prediction model to perform load prediction.
[0039] On the one hand, set the basic scheduling period T base =60s, meaning that by default, the load forecasting model is automatically triggered by the terminal every 60 seconds. Simultaneously, the terminal monitors data changes and adaptively schedules in advance based on predefined event rules. On the other hand, event forecasting is triggered when load power changes, average equipment status changes, or average environmental disturbances are not less than predefined thresholds. In this embodiment, the predefined power change threshold is 5% of the rated capacity, representing a sudden load increase; the environmental disturbance threshold is 20% of the previous time value. When any of the above conditions are met, the event-driven scheduling module immediately schedules the load forecasting model to perform a calculation and... Update to the current time to get the latest load trend forecast results.
[0040] In this embodiment, the prediction model adopts a TCN-GRU-Attention hybrid architecture, which is a deep neural network composed of a Temporal Convolutional Network (TCN), a Gated Recurrent Unit Network (GRU), and an attention mechanism. This model has been trained offline using historical running data and can run efficiently on embedded AI chips. The TCN module has 4 convolutional layers, a kernel size of 3, and the number of channels per layer is [32, 32, 32, 32], with a dilation factor of [1, 2, 4, 8]. The GRU module has an input dimension of 32, 64 hidden units, and 1 GRU layer. The Attention module uses additive attention. The model input is a fused feature sequence from the terminal over a recent period, with the fused features from a window of 60 data points (i.e., the past 60 seconds) forming the input sequence. The model extracts local patterns and long-term dependency features from the load sequence through TCN and expands the receptive field using multi-layer causal convolution and dilated convolution to ensure that predictions rely only on past information. Subsequently, a GRU layer further learns the dynamic evolution of the time series and assigns weights to features at different time steps using an attention mechanism, obtaining a context vector of the fused sequence for future moments. Finally, device state data is introduced again, combined with the context vector, and a short-term load prediction is given through a fully connected output layer. Each run of the prediction model outputs the active power load prediction curve and predicted values of related state variables for the next 30 seconds, with a single inference latency of 0.18 seconds, having minimal impact on the terminal CPU / GPU load.
[0041] The anomaly monitoring module monitors load data mutations in the load forecast results and calculates load differences. When the load difference exceeds a predetermined load difference threshold, it uses the resampled device status data of each terminal in the microgrid as input for the isolated forest and calculates the anomaly score of the corresponding terminal. When the anomaly score is not less than a predetermined local anomaly threshold, it indicates that the corresponding terminal has a local anomaly. It sets a set of neighboring terminals for each terminal, calculates the neighborhood consistency coefficient of each terminal, and determines whether the terminal has a global anomaly. When a sudden change in load power is detected, the anomaly detection algorithm is triggered to analyze recent equipment status data.
[0042] In anomaly detection, each edge terminal runs a pre-built anomaly detection model using its local AI inference module. This embodiment uses the Isolation Forest algorithm as the anomaly detection model. Each terminal constructs a sample set based on its own collected multi-source fusion data from the last 30 seconds and inputs it into the Isolation Forest model for analysis. The Isolation Forest consists of multiple random binary trees, with 100 trees, 128 subsamples, a maximum tree depth of 10, a contamination rate of 0.02, and a local anomaly detection threshold. =0.8 (can be selected based on the distribution of historical normal operation data); when the abnormal score calculated by a terminal is greater than 0.8, it is determined that the terminal is currently exhibiting abnormal behavior.
[0043] To improve the accuracy of anomaly detection, a collaborative anomaly determination mechanism among terminals was designed. Each terminal shares status information through the microgrid's local network, forming a neighborhood terminal set. In this embodiment, Terminal 1 (main incoming line) and Terminal 4 (load feeder) are electrically directly related, indicating they are neighboring terminals; Terminal 2 (photovoltaic) and Terminal 3 (energy storage) are both parallel power supply units and can also be neighboring terminals. The neighborhood consistency coefficient C is calculated. i The predetermined tolerance is set to 0.1, and the predetermined consistency threshold is 0.8; if C i If the value is below the predetermined consistency threshold, the anomaly is suspected to be a local anomaly or false alarm in terminal i, possibly caused by a local sensor malfunction or noise interference; conversely, if C... i Not less than If a local anomaly exists, it is determined to be a global anomaly event, and the alarm priority is increased. By comparing differences between terminals, false alarms from a single terminal can be effectively suppressed, improving the robustness of anomaly detection. In this embodiment, when a sudden increase in the total load of the plant causes both terminals 1 and 4 to experience global anomalies, a widespread abnormal operating condition is confirmed; when only terminal 2 reports an anomaly and its neighboring terminal 3 does not show an anomaly, it may be a false alarm caused by noise from the photovoltaic side sensors, and a global alarm is not triggered temporarily.
[0044] The anomaly classification module obtains the device fault alarm flag for each terminal. When a terminal has a device fault alarm or a global anomaly, it calculates the rule score for the corresponding terminal. Based on the device fault alarm and the rule score, the terminal is classified as an anomaly. In this embodiment, after entering the emergency control process, the edge intelligent terminal first performs rule-based event type judgment and scoring. The control strategy prioritizes minimizing the impact, ensuring personal and equipment safety first, then maintaining system stability, and finally considering economical and continuous operation. A rule score is generated for different terminals. Based on different thresholds (in this embodiment) , Based on whether there are direct equipment failure signals, the emergency response measures are categorized as follows: Hardware equipment failure events: If a clear equipment failure alarm is detected (e.g., circuit breaker trip signal, inverter fault indicator light), it is determined to be a hardware equipment failure. For example, at a certain moment, terminal 2 receives an internal fault alarm from the photovoltaic inverter, indicating a photovoltaic inverter failure, and performs selective tripping to isolate the faulty device; terminal 2 immediately sends a tripping command to the photovoltaic grid-connected switch to isolate the faulty inverter from the microgrid and prevent the fault from spreading. After tripping, terminal 2 also attempts an automatic reclosing strategy to improve power supply restoreability (the number of reclosing attempts and the interval can be set according to the protection procedure; in this embodiment, it attempts once with a 5-second interval). At the same time, terminal 2 sends a maintenance work order and alarm message to the maintenance personnel, indicating that the photovoltaic inverter has failed and needs maintenance. Since the local terminal autonomously completes the fault identification and isolation, the entire process from alarm occurrence to tripping takes only a few hundred milliseconds, achieving rapid protection and effectively preventing the fault from escalating.
[0045] Overload event (overload anomaly): If no specific equipment fault signal is received, but the rule score is high, it is determined to be an overload anomaly caused by overload. For example, if multiple high-power devices suddenly start up in the factory area in the evening, causing the total load to exceed 110% of the transformer's rated capacity threshold and the frequency to drop below 49.5 Hz, terminals 1 and 4 will detect a serious anomaly but no single equipment fault alarm, and this event can be classified as system overload. A tiered load shedding and voltage / frequency stabilization are then implemented. First, terminal 1 communicates with the system's collaborative control layer and sends low-priority load disconnection commands sequentially according to a pre-set load priority list: first, interruptible loads such as factory lighting and air conditioning are disconnected in sequence, and then some production line loads are reduced as needed until the total load drops to a safe range. Simultaneously with load shedding, terminal 3 (energy storage) automatically switches the energy storage converter from charging to discharging, rapidly injecting active power into the microgrid to support the frequency and stabilize the voltage within ±5%. Through these measures, the microgrid frequency and voltage gradually return to normal, and the overload situation is eliminated. Throughout the process, each terminal autonomously performs load reduction and adjustment based on local detection results, without the need for commands issued by the central control center. This achieves rapid and stable control, ensuring stable system operation and continuous power supply to critical loads.
[0046] Noise Interference Events: If no specific equipment fault signal is received and the rule score is low, it is likely to be judged as a false alarm caused by data noise or environmental interference. For example, if terminal 4 detects a short-term current signal spike and there are no abnormalities in nearby terminals, and the equipment does not issue any alarms, the event can be attributed to noise interference. Simultaneously, if the electromagnetic environment is poor due to thunderstorms in the factory area, terminal 4 may also receive transient abnormal data, but multi-source cross-verification confirms it is not a real fault. For pure noise interference, this embodiment selects an alarm-but-not-act strategy. Terminal 4 records the abnormality as a general alarm event but does not perform tripping or other power-off controls to avoid false alarms. At the same time, terminal 4 issues a maintenance work order to maintenance personnel, suggesting checking the corresponding measurement circuit or equipment grounding status to rule out potential sensor faults or interference sources. After the above processing, the entire microgrid system maintains normal operation and is not affected by false alarms.
[0047] After completing the above emergency control measures, the edge terminal will switch the microgrid back to normal monitoring mode and continue to track its operational status after fault isolation or load shedding. If new anomalies are subsequently detected, the above process will be repeated. In addition, all abnormal events and control actions will be reported to the dispatch master station and operators. Upon receiving the report, dispatch center personnel can intervene as needed to confirm the control measures and handle subsequent actions, arrange maintenance plans, or adjust the microgrid's operating strategy.
[0048] It is important to emphasize that this embodiment relies on the local intelligent analysis and autonomous control of edge terminals to achieve closed-loop operation of microgrid fault detection and response control, significantly reducing dependence on the central controller and communication network. Even in the event of communication interruption, each terminal can still independently complete monitoring, analysis, and protection actions, realizing local autonomous operation of the microgrid and improving the continuity and anti-interference capability of system operation. Multi-source data fusion improves the accuracy and robustness of anomaly detection, avoiding misjudgments caused by inaccurate signals from a single sensor; high-speed inference via edge AI chips enables millisecond-level rapid response and autonomous control (such as immediate tripping and load shedding), ensuring the safety of personnel and equipment as well as power supply stability. This fully demonstrates the key advantages of this invention in multi-source fusion, edge intelligence, and autonomous control, providing a highly reliable and real-time microgrid monitoring and control solution for typical application scenarios such as suburban factories.
[0049] This disclosure can be a system, method, and / or computer program product. A computer program product may include a computer-readable storage medium having computer-readable program instructions loaded thereon for causing a processor to implement various aspects of this disclosure.
[0050] Computer-readable storage media can be tangible devices capable of holding and storing instructions for use by an instruction execution device. Computer-readable storage media can be, for example—but not limited to—electrical storage devices, magnetic storage devices, optical storage devices, electromagnetic storage devices, semiconductor storage devices, or any suitable combination of the foregoing. More specific examples (a non-exhaustive list) of computer-readable storage media include: portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), static random access memory (SRAM), portable compact disc read-only memory (CD-ROM), digital multifunction disc (DVD), memory sticks, floppy disks, mechanical encoding devices, such as punch cards or recessed protrusions storing instructions thereon, and any suitable combination of the foregoing. The computer-readable storage media used herein are not to be construed as transient signals themselves, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through waveguides or other transmission media (e.g., light pulses through fiber optic cables), or electrical signals transmitted through wires.
[0051] The computer-readable program instructions described herein can be downloaded from computer-readable storage media to various computing / processing devices, or downloaded via a network, such as the Internet, local area network, wide area network, and / or wireless network, to an external computer or external storage device. The network may include copper transmission cables, fiber optic transmission, wireless transmission, routers, firewalls, switches, gateway computers, and / or edge servers. A network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards them to the computer-readable storage media in the respective computing / processing device.
[0052] Computer program instructions used to perform the operations of this disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, status setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages such as Smalltalk, C++, etc., and conventional procedural programming languages such as the "C" language or similar programming languages. The computer-readable program instructions may execute entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or may be connected to an external computer (e.g., via the Internet using an Internet service provider). In some embodiments, electronic circuitry, such as programmable logic circuitry, field-programmable gate arrays (FPGAs), or programmable logic arrays (PLAs), is personalized by utilizing the status information of the computer-readable program instructions to implement various aspects of this disclosure.
[0053] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the specific implementation of the present invention. Any modifications or equivalent substitutions that do not depart from the spirit and scope of the present invention should be covered within the protection scope of the claims of the present invention.
Claims
1. A multi-source fusion monitoring method for microgrid edge terminals, characterized in that, include: S1. Collect microgrid electrical data, equipment status data, and environmental data, and perform time correction and resampling processing; Calculate the quality score for each type of data after processing, and perform linear coding based on this to obtain the fused coding features; S2. Calculate the fluctuation of the fused coding features at different time locations, and determine the periodic prediction trigger conditions by combining the predefined base period and period value range; determine the event prediction trigger conditions based on the load power of the microgrid access, the resampled equipment status data and environmental data. When periodic or event-based forecasting is triggered, the fused coded features are input into the constructed load forecasting model to perform short-term load forecasting. S3. Monitor load data abrupt changes in the load forecast results and calculate load differences; When the load difference is greater than the predetermined load difference threshold, the device status data of each terminal in the microgrid after resampling is used as the input of the isolated forest to calculate the anomaly score of the corresponding terminal; when the anomaly score is not less than the predetermined local anomaly threshold, it indicates that the corresponding terminal has a local anomaly; set the neighboring terminal set of each terminal, calculate the neighborhood consistency coefficient of each terminal, and determine whether the terminal has a global anomaly. S4. Obtain the device fault alarm flag for each terminal. When a terminal has a device fault alarm or a global anomaly, calculate the rule score for the corresponding terminal. Based on the device fault alarm and the rule score, classify the terminal as an anomaly.
2. The multi-source fusion monitoring method for a microgrid edge terminal according to claim 1, characterized in that: The process of obtaining fused encoded features through linear encoding in S1 is as follows: For any electrical data, equipment status data, and environmental data, the absolute values of the differences between the corresponding data at each time point and the adjacent timestamps before resampling are calculated and averaged to obtain the mean time difference for each type of data at the corresponding time point. The exponential coefficient of the mean time difference is multiplied by the mean time difference and converted to a negative number, which is used as the exponent of an exponential function with the natural constant as the base to obtain the timeliness parameter for each type of data at the corresponding time point. The total number of collections for each type of data before resampling is divided by the total number of collections after resampling to obtain the integrity parameter for the corresponding data. For each type of data, the timeliness parameter and integrity parameter at each time point are weighted to obtain the quality score for the corresponding data at the corresponding time point. The quality score for each type of data is then subjected to a softmax transformation to obtain the fusion weight for the corresponding data. A single-layer linear coding method is used to encode features for each type of data, resulting in encoded features. By fusion weights, the coding features of different data at the same time are weighted to obtain fused coding features.
3. The multi-source fusion monitoring method for a microgrid edge terminal according to claim 1, characterized in that: The process of determining the periodic prediction triggering conditions in S2 is as follows: For any position of the fused coding feature, calculate the absolute value of the difference between the current position and the previous position as the numerator, and the absolute value of the previous position as the denominator to obtain the feature difference at the current position; weight the feature difference at the current position with the volatility of the fused coding feature at the previous position to obtain the volatility of the fused coding feature at the current position; add 1 to the volatility at the current position as the denominator, use the basic period as the numerator, and round down the calculated ratio to obtain the adaptive period at the current position and limit it to the range of period values; When the difference between the current time and the previous prediction completion time reaches the corresponding adaptive period, periodic prediction is triggered.
4. The multi-source fusion monitoring method for a microgrid edge terminal according to claim 1, characterized in that: The process of determining the event prediction trigger conditions in S2 is as follows: For any sampling time, calculate the absolute value of the difference between the total load power connected to the microgrid at the current sampling time and the previous sampling time, as the load power change; calculate the first norm of the difference between the equipment state data after resampling at the current sampling time and the previous sampling time, to obtain the average change of equipment state; calculate the first norm of the difference between the environmental data after resampling at the current sampling time and the previous sampling time, to obtain the average environmental disturbance. Predefined power change thresholds, equipment status change thresholds, and environmental disturbance thresholds are used. When the load power change, average equipment status change, or average environmental disturbance is not less than the predefined threshold, event prediction is triggered.
5. The multi-source fusion monitoring method for a microgrid edge terminal according to claim 1, characterized in that: The process of short-term load forecasting in S2 is as follows: When a periodic prediction or event prediction is triggered, the fused encoded features within a predetermined time period before the trigger time are obtained as a historical time series. Using a temporal convolutional network, the local and long-term dependency features of the historical time series are extracted to obtain historical dependency features. Through a gated recurrent unit, the temporal dependency relationship of the historical dependency features is extracted to obtain temporal fusion features. The temporal fusion features are weighted using an attention mechanism to obtain a context vector. The window length is set, and the resampled device state data is linearly mapped after window moving average. The device state gating vector is obtained by passing an activation function. The context vector and the device state gating vector are concatenated and input into the prediction layer to obtain the predicted value.
6. The multi-source fusion monitoring method for a microgrid edge terminal according to claim 1, characterized in that: The process for determining whether a global anomaly exists in the terminal in S3 is as follows: Define the set of neighboring terminals for each terminal as , and obtain the adjacency weight by normalizing the distances between different terminals; For each terminal, calculate the absolute value of the difference between the abnormal scores of the corresponding terminal and the abnormal scores of the neighboring terminals in the neighboring terminal set to obtain the abnormal score difference between each terminal and its corresponding neighboring terminals; accumulate the adjacency weights of the neighboring terminals in the neighboring terminal set whose abnormal score difference is not greater than a predetermined tolerance and whose abnormal scores are not less than a predetermined local abnormal threshold, and use this as the neighborhood consistency coefficient of the corresponding terminal; when the neighborhood consistency coefficient of the terminal is not less than the predetermined consistency threshold and the abnormal score of the corresponding terminal is not less than the predetermined local abnormal threshold, it indicates that the corresponding terminal has a global abnormality.
7. The multi-source fusion monitoring method for a microgrid edge terminal according to claim 1, characterized in that: The process of calculating the rule score for the corresponding terminal in S4 is as follows: For each terminal, when the corresponding terminal has a device fault alarm or a global anomaly, the anomaly score, global anomaly flag, and device fault alarm flag of the corresponding terminal are weighted and summed and then restricted to the interval (0,1) to obtain the rule score of the corresponding terminal.
8. The multi-source fusion monitoring method for a microgrid edge terminal according to claim 1, characterized in that: The process of classifying terminals as abnormal in S4 is as follows: When a device fault alarm is detected, it indicates that there is a device fault, and a selective tripping and reclosing scheme is adopted; when there is no device fault alarm and the rule score is greater than the predetermined first threshold, the abnormal disturbance of the device causes system instability, and the load is cut off in stages and the operating voltage and frequency are stabilized; when there is no device fault alarm, the rule score is not greater than the predetermined first threshold and not less than the predetermined second threshold, the device exhibits abnormal fluctuations, and the power supply or energy storage device is adjusted to maintain power balance. When there are no equipment fault alarms and the rule score is less than the predetermined second threshold, sensor interference or local noise occurs, and a manual maintenance work order is dispatched.
9. A multi-source fusion monitoring system for a microgrid edge terminal, using the method described in any one of claims 1-8, characterized in that, include: The data acquisition and processing module collects electrical data, equipment status data, and environmental data from the microgrid, and performs time correction and resampling processing. Calculate the quality score for each type of data after processing, and perform linear coding based on this to obtain the fused coding features; The load forecasting module calculates the fluctuation of the fused coding features at different time locations, and determines the periodic forecasting trigger conditions by combining the predefined base period and period value range. Based on the load power of the microgrid access, the resampled equipment status data, and the environmental data, the event prediction triggering conditions are determined. When periodic or event-based forecasting is triggered, the fused coded features are input into the constructed load forecasting model to perform short-term load forecasting. The anomaly monitoring module monitors sudden changes in load data in the load forecast results and calculates load differences; When the load difference is greater than the predetermined load difference threshold, the device status data of each terminal in the microgrid after resampling is used as the input of the isolated forest to calculate the anomaly score of the corresponding terminal; when the anomaly score is not less than the predetermined local anomaly threshold, it indicates that the corresponding terminal has a local anomaly; set the neighboring terminal set of each terminal, calculate the neighborhood consistency coefficient of each terminal, and determine whether the terminal has a global anomaly. The anomaly classification module obtains the device fault alarm flag for each terminal. When a terminal has a device fault alarm or a global anomaly, it calculates the rule score for the corresponding terminal. Based on the device fault alarm and the rule score, the terminal is classified as an anomaly.
10. A terminal, comprising a processor and a storage medium; characterized in that: The storage medium is used to store instructions; The processor is configured to operate according to the instructions to perform the steps of the method according to any one of claims 1-8.
11. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the program implements the steps of the method according to any one of claims 1-8.