Meteorological data collection method based on power grid prediction demand
By constructing a multi-source meteorological data access layer and a unified spatiotemporal benchmark conversion module, and dynamically matching preprocessing sub-architecture units, the heterogeneity and redundancy issues of multi-source meteorological data in power grid forecasting are solved, achieving efficient and automated data processing and improving the accuracy of forecasting models.
Patent Information
- Application Number
- CN202511514707.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-22
- Publication Date
- 2026-01-30
AI Technical Summary
Existing technologies cannot effectively address the heterogeneity, redundancy, and lack of unified preprocessing issues in power grid forecasting from multiple meteorological data sources. This results in a large amount of repetitive data processing, low automation, slow response speed, and difficulty in balancing data integrity and physical consistency.
A multi-source meteorological data access layer is constructed. The data is mapped to a unified geographic coordinate system and timestamp system through a unified spatiotemporal reference conversion module. The preprocessing sub-architecture unit is dynamically matched to perform format standardization, physical dimension normalization, spatial interpolation and time alignment processing. The inference and completion model based on spatiotemporal correlation and physical constraints is used to repair missing or abnormal data.
It enables efficient and unified processing of meteorological data, improves the accuracy and response speed of power grid forecasting models, ensures data integrity and consistency, and supports the dynamic adjustment and adaptive capabilities of automated preprocessing pipelines.
Smart Images

Figure CN121434589A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the technical field of power system analysis, and particularly relates to a meteorological data collection method based on power grid predicted demand. BACKGROUND
[0002] With the deepening of the construction of smart grid, the dependence of power grid load and new energy output prediction on meteorological data is increasing, and the accuracy, timeliness and spatial granularity of meteorological information as a key external variable affecting the operation state of the power system directly determine the upper limit of the performance of the prediction model. At present, the sources of meteorological data are increasingly diverse, covering national meteorological centers, regional observation stations, satellite remote sensing and third-party commercial platforms, etc. However, these data have significant heterogeneity in format, coordinate system, time resolution and physical dimension, which makes it difficult to directly and efficiently use them in the power grid prediction scenario.
[0003] Among them, the meteorological data collection based on the prediction demand of the power grid faces multiple technical bottlenecks. The existing meteorological data processing flow usually adopts the mode of "first collection, then adaptation", that is, after obtaining the original meteorological data, cleaning, interpolation, resampling and format conversion are carried out for each type of prediction task, which not only has a large amount of repetitive work, but also lacks a unified data preprocessing standard; at the same time, a large amount of original meteorological data contains redundant or irrelevant dimensions, and the meteorological precision of the key area is often insufficient, which needs to rely on manual intervention for secondary processing, which seriously restricts the automation and response speed of the prediction system.
[0004] The existing technology has not yet constructed a meteorological data preprocessing architecture facing the dynamic demand of power grid prediction tasks. On the one hand, multi-source meteorological data lack a mechanism to realize semantic alignment and structural unification at the collection end; on the other hand, the preprocessing logic is deeply coupled with the prediction target, but the existing system cannot automatically combine processing modules according to the prediction demand, resulting in the need to rebuild the data pipeline for each task; in addition, in the face of missing values, sensor abnormalities or spatio-temporal discontinuity in meteorological observation, traditional methods mostly rely on simple interpolation or discard processing, which is difficult to maintain the physical consistency while ensuring the integrity of the data, thereby forcing the downstream prediction model to bear the additional burden of data repair. SUMMARY
[0005] Therefore, the application aims to provide a meteorological data collection method based on the prediction demand of the power grid. In order to solve the above technical problems, the technical scheme of the application is as follows:
[0006] Step S110, a multi-source meteorological data access layer is constructed, original meteorological data is obtained, and all data are mapped to a unified geographic coordinate system and time stamp system through a unified space-time reference conversion module;
[0007] Step S120: Analyze the power grid forecasting task requirements, extract the forecasting task type, target area range, time window length and required meteorological element dimensions, dynamically match and splice the corresponding preprocessing sub-architecture units based on the preset sub-architecture mapping rule library, and form a customized preprocessing pipeline for the current forecasting task.
[0008] Step S130: Execute a customized preprocessing pipeline to standardize the format, normalize the physical dimensions, perform spatial interpolation and time alignment on the raw meteorological data, and dynamically adjust the spatial resolution of the meteorological data according to the distribution density of power grid facilities in the target area to generate a numerical mapping map with one-to-one correspondence between location and meteorological value; Step S140: Perform integrity verification on the numerical mapping map, identify missing values or abnormal observation points, call the inference completion model based on spatiotemporal correlation and physical constraints, and use meteorological data from nearby spatiotemporal points and auxiliary information on power grid operation status to perform logical consistency repair on missing or abnormal data;
[0009] Step S150: Output the numerical mapping map after integrity repair to the power grid prediction model interface as the input meteorological feature dataset for the prediction task.
[0010] Furthermore, in step S110, the unified spatiotemporal reference conversion module adopts the internationally used geographic coordinate system as the unified spatial reference, and the timestamp system adopts the global standard time system and is aligned with a fixed time granularity. For local sensor network data, high-precision positioning mapping is achieved through the coordinate conversion interface provided by the power facility geographic information system. This conversion interface achieves accurate conversion between geographic coordinates and projected coordinates based on the coordinate conversion parameter matrix.
[0011] Furthermore, in step S120, the sub-architecture mapping rule base stores multiple types of preprocessing sub-architecture units. Each type of sub-architecture unit is optimized for a specific type of power grid forecasting task. Each type of sub-architecture unit defines its applicable meteorological element combination strategy, spatial interpolation algorithm selection logic, and time resampling mechanism.
[0012] Furthermore, in step S130, the spatial interpolation adopts a strategy of integrating multiple interpolation algorithms. It combines regional terrain features, spatial distribution patterns of meteorological elements, and spatial layout of power grid facilities to dynamically select the optimal combination of interpolation methods. The interpolation algorithm library includes Kriging interpolation, inverse distance weighted interpolation, and spline interpolation. The selection logic is based on the terrain complexity index and the spatial variation function characteristics of meteorological elements.
[0013] Furthermore, in step S130, the physical dimension normalization adopts a dynamic standardization method based on historical statistical characteristics to convert all meteorological elements into dimensionless standardized values. The normalization parameters are dynamically calculated based on the statistical distribution of recent historical meteorological data of the target area.
[0014] Furthermore, in step S140, the integrity verification identifies abnormal observation points by setting a reasonable threshold range that conforms to meteorological physical laws and a dynamic upper limit of the rate of change of adjacent spatiotemporal points. The threshold range is set according to the historical statistical distribution of meteorological elements, and the normal value range is determined by the 3σ principle. The dynamic upper limit of the rate of change is calculated based on the time autocorrelation characteristics of meteorological elements.
[0015] Furthermore, in step S140, the inference completion model adopts a spatiotemporal inference engine based on graph neural networks. This engine can achieve logical consistency repair of missing or abnormal data by introducing basic constraints such as mass conservation and energy balance in atmospheric physical processes, based on the spatial correlation between the grid cell to be repaired and its neighboring cells, the historical meteorological evolution patterns of the same period, the dynamic response characteristics of the power grid load, and the equipment operating status labels.
[0016] Furthermore, in step S150, the power grid prediction model interface adopts a standardized data exchange protocol, which encapsulates the numerical mapping map into a structured geospatial data format, including the precise geographical location information of each grid cell, a unified time identifier, and a multi-dimensional meteorological feature vector. The feature vector covers a variety of meteorological elements and their derived features, and supports two transmission modes: batch data push and incremental update. The transmission protocol is based on the JSON format, and the data compression adopts the LZ4 algorithm.
[0017] Furthermore, in step S120, if the parsed prediction task requirements cannot fully match the existing sub-architecture units, an automatic sub-architecture generation mechanism is triggered. This mechanism automatically selects and combines multiple basic processing modules from the atomic processing module library based on the meteorological element combination characteristics, spatial accuracy requirements, and time response characteristics contained in the task requirements, constructs a new preprocessing sub-architecture that adapts to the current task, and registers it in the sub-architecture mapping rule library.
[0018] Furthermore, after step S140, a multi-dimensional quality assessment is performed on the repaired numerical mapping map. The assessment system comprehensively considers data integrity, spatiotemporal continuity, and physical consistency. A comprehensive quality score is calculated through a weighted fusion method. When the score result is lower than a preset threshold, the system automatically triggers a manual review process and records the abnormal event log simultaneously.
[0019] The main technical effects of this invention are reflected in the following aspects: By constructing a complete technical chain from data acquisition, feature analysis, scene recognition, impact assessment to adaptive prediction and scheduling decision-making, this invention systematically solves the problem of increased load characteristics brought about by new types of electrical equipment. The load feature analysis module accurately depicts the dynamic behavior of the load through multi-dimensional feature extraction, providing high-quality input for subsequent analysis. The scene pattern recognition module, based on a dynamic time warping algorithm, effectively identifies the inherent patterns of user electricity consumption behavior, significantly improving the depth of understanding of electricity consumption scenarios. The impact load assessment module, by quantitatively analyzing key parameters of impact loads, achieves early warning and intensity prediction of short-term load surges. The adaptive prediction engine, by dynamically adjusting model parameters, ensures the strong adaptability of the prediction model to the randomness and uncertainty of electricity consumption, thereby greatly improving the accuracy of load prediction. The scheduling decision generation module, based on accurate prediction results, generates scientific and reasonable power grid scheduling instructions, providing direct technical support for ensuring the safe and stable operation of the power grid and optimizing resource allocation. The various modules of the entire system work together to form a closed-loop, adaptive intelligent load analysis solution, which effectively overcomes the limitations of traditional methods in dealing with the load characteristics of new types of electrical equipment. Attached Figure Description
[0020] Figure 1 This is a schematic diagram of the overall technical solution architecture of the meteorological data collection method based on power grid forecasting demand proposed in this invention;
[0021] Figure 2 This is a schematic diagram of the core principle framework of the dynamic splicable preprocessing sub-architecture matching and generation mechanism in this invention;
[0022] Figure 3 This is a logical flowchart of the multi-source meteorological data access and unified spatiotemporal benchmark conversion in this invention;
[0023] Figure 4 This is a schematic diagram of the data integrity verification and reasoning completion principle framework based on physical constraints and spatiotemporal correlation in this invention;
[0024] Figure 5 This is a schematic diagram of the multi-level interaction relationship and data flow between the power grid prediction model interface and the numerical mapping output in this invention. Detailed Implementation
[0025] The specific embodiments of the present invention will be further described in detail below with reference to the accompanying drawings, so that the technical solution of the present invention can be more easily understood and mastered.
[0026] A method for collecting meteorological data based on power grid demand forecasting, characterized by the following steps:
[0027] Step S110 involves constructing a multi-source meteorological data access layer, acquiring raw meteorological data, and mapping all data to a unified geographic coordinate system and timestamp system through a unified spatiotemporal reference conversion module. In step S110, the unified spatiotemporal reference conversion module uses an internationally recognized geographic coordinate system as the unified spatial reference, and the timestamp system uses a global standard time system aligned with a fixed time granularity. For local sensor network data, high-precision positioning mapping is achieved through the coordinate transformation interface provided by the power facility geographic information system. This transformation interface achieves accurate conversion between geographic coordinates and projected coordinates based on a coordinate transformation parameter matrix. The specific implementation process of constructing the multi-source meteorological data access layer and the unified spatiotemporal reference conversion in step S110 is as follows: First, a multi-source meteorological data access layer is constructed. This access layer adopts a distributed data gateway architecture, capable of accommodating the access requirements of different types of data sources. Specific data sources include GRIB2 format data released by the national meteorological center, CSV format real-time observation data collected by regional meteorological observation stations, HDF5 format data output by the Fengyun-4 meteorological satellite remote sensing platform, and streaming data transmitted by the local sensor network of power facilities via the MQTT protocol. For data of different formats, the access layer is configured with independent protocol parsing modules. GRIB2 format data is parsed using the ecCodes library developed by the European Centre for Medium-Range Weather Forecasts (ECMWF), which enables efficient decoding of meteorological element codes. CSV format data is parsed using the OpenCSV library, supporting custom field delimiters and data type mappings. HDF5 format data is read using the HDF5Java library provided by HDFGroup, meeting the parsing requirements of multi-dimensional arrays of remote sensing data. MQTT protocol data is received in real-time by subscribing to specified topics through the Eclipse Paho client library. After acquiring raw meteorological data, the access layer adds a data source identifier and acquisition timestamp to each type of data for subsequent data traceability and quality assurance. Data standardization is then completed through a unified spatiotemporal reference conversion module. This module sets the internationally recognized WGS84 geographic coordinate system as the unified spatial reference, ensuring spatial consistency of data from different regions. The timestamp system adopts Coordinated Universal Time (UTC), a time standard derived from International Atomic Time, ensuring global time uniformity. For local sensor network data of power facilities, which typically uses a local plane coordinate system, it needs to be converted to the WGS84 coordinate system through the coordinate transformation interface provided by the power facility geographic information system. The conversion adopts the Bursa-Wolf seven-parameter model, and the formula is X. WGS84 =X 本地 +ΔX+ε x ×Y 本地 -ε y ×X 本地 +m×X 本地 Y WGS84 =Y 本地 +ΔY+εy ×Z 本地 -ε y ×Y 本地 +m×Y 本地 Z WGS84 =Z 本地 +ΔZ+ε z ×X 本地 -ε y ×Y 本地 +m×Z 本地 , where X WGS84 Y WGS84 Z WGS84 For the transformed WGS84 3D Cartesian coordinates, X 本地 Y 本地 Z 本地 The coordinates are three-dimensional coordinates in the local coordinate system, where ΔX, ΔY, and ΔZ are translation parameters, and ε is the coordinate of the local coordinate system. x ε y ε z Here, is the rotation parameter, and m is the scale parameter. After the transformation, the three-dimensional rectangular coordinates need to be converted to latitude and longitude, which is achieved through iterative calculation. Initially, the latitude is set as B = arcsin(Z). WGS84 / sqrt(X WGS84 2 +Y WGS84 2 +Z WGS84 2 Then, using the radius of curvature of the ramusoidal circle N = a / sqrt(1-e) 2 ×sin 2 B), where a is the major semi-axis of WGS84 and e is the first eccentricity; iteratively correct B until the difference between the two calculations is less than 1e-8 degrees.
[0028] Step S120 involves parsing the power grid forecasting task requirements, extracting the forecasting task type, target area range, time window length, and required meteorological element dimensions. Based on a pre-defined sub-architecture mapping rule base, corresponding preprocessing sub-architecture units are dynamically matched and assembled to form a customized preprocessing pipeline for the current forecasting task. In step S120, the sub-architecture mapping rule base stores multiple types of preprocessing sub-architecture units. Each type of sub-architecture unit is optimized for a specific type of power grid forecasting task, and each type defines its applicable meteorological element combination strategy, spatial interpolation algorithm selection logic, and time resampling mechanism. In step S120, if the parsed forecasting task requirements cannot fully match existing sub-architecture units, an automatic sub-architecture generation mechanism is triggered. This mechanism automatically selects and combines multiple basic processing modules from the atomic processing module library based on the meteorological element combination characteristics, spatial accuracy requirements, and time response characteristics included in the task requirements, constructing a new preprocessing sub-architecture adapted to the current task, and registering it in the sub-architecture mapping rule base. The specific implementation process of step S120, parsing the power grid forecasting task requirements and dynamically constructing a customized preprocessing pipeline, is as follows: First, the structured parsing of the power grid forecasting task requirements is performed. This parsing process requires obtaining the forecasting task instructions submitted by the user or upstream system through the task requirement input interface. The instructions must contain parsable text or structured data format. The parsing process extracts key parameters sequentially from four core dimensions. The first dimension is the forecasting task type. This type must be clearly defined as a common standardized task category in the power grid field, including short-term load forecasting, medium- and long-term load forecasting, new energy output forecasting, and power grid equipment failure rate forecasting. During parsing, the specific type is determined by matching keywords in the task instructions. If the instructions do not specify, it is processed as short-term load forecasting by default. The second dimension is the target area range. This range needs to be converted into precise geographic latitude and longitude boundary parameters. During parsing, the area identifier contained in the instructions is read. By calling the power grid geographic information system interface, the area identifier is mapped to the starting value of east longitude, the ending value of east longitude, the starting value of north latitude, and the ending value of north latitude, forming a closed latitude and longitude rectangular area. If the instructions directly provide latitude and longitude, the rationality of the boundary is directly verified. The third dimension is the time window length. During parsing, the prediction start time and prediction end time are extracted from the command and converted to UTC timestamp format. The time window length is determined by calculating the time window duration, and the required time resolution is recorded. If the resolution is not specified, the default configuration is used according to the prediction task type. The fourth dimension is the required meteorological elements. During parsing, the names of meteorological elements and their corresponding monitoring indicators specified in the command are enumerated. Common elements include wind speed at 10 meters altitude, air temperature at 2 meters altitude, relative humidity, precipitation, and solar irradiance. If there are elements for which the monitoring indicators are not specified, the industry standard monitoring frequency for that element is configured.
[0029] After completing the requirements analysis, dynamic matching is performed based on the preset sub-architecture mapping rule library. The sub-architecture mapping rule library is a structured database that stores the matching relationship between preprocessing sub-architecture units and task requirements. Each rule in the library includes a rule ID, the type of the adapted task, the regional range threshold, the time window threshold, the set of adapted meteorological elements, the corresponding sub-architecture unit ID, and the sub-architecture description information. The preprocessing sub-architecture unit is a combination of preprocessing modules optimized for a specific prediction task. Each unit includes the module combination order, the default parameter configuration of each module, and defines the applicable meteorological element combination strategy, the spatial interpolation algorithm selection logic, and the time resampling mechanism. The time resampling mechanism is a processing flow that adjusts the time interval of the original meteorological data to be consistent with the time resolution of the prediction task. Common methods include mean resampling and maximum resampling. Mean resampling is suitable for continuously changing elements such as temperature and humidity, while maximum resampling is suitable for peak-sensitive elements such as wind speed and precipitation. The dynamic matching process follows these steps: The first step is initial task type screening, which selects a set of rules from the rule base that perfectly match the predicted task type obtained from the parsing. If this set is empty, the process proceeds to the automatic sub-architecture generation stage. The second step is region range matching, which calculates the overlap rate S2 between the parsed target region and the region range threshold in the rules. The formula is S2 = A. overlap / A target A overlap It is the overlapping area of the target area and the regular area, calculated using the formula A = (Lon) / (Lon) = 1 / 2. end -Lon start )×111×cos(Lat avg ×π / 180)×(Lat end -Lat start )×111; 111 is the distance in kilometers corresponding to 1 degree of longitude on the Earth's equator, Lat_avg is the average latitude of the region, π is pi, A target The first step is to determine the area of the target region, retaining only the rule where S2 ≥ 0.8; the third step is time window matching, calculating the time window similarity S3, with the formula S3 = 1 - |T|. window -T rule | / T rule T rule It is the median value (T) of the time window threshold in the rule. rule =(T min +T max If the calculation result is negative, take 0, and retain the rule that S3≥0.7; the fourth step is meteorological element matching, and calculate the element matching rate S4=N match / N target , where N match N is the number of elements in the target meteorological element set that exist in the rule-fitting meteorological element set. targetThe first step is to calculate the total number of target meteorological elements, retaining the rule that S4 ≥ 0.9. The fifth step is to calculate the comprehensive matching degree, with the formula S = w1 × S1 + w2 × S2 + w3 × S3 + w4 × S4. Here, the preferred values w1 = 0.4, w2 = 0.2, w3 = 0.2, and w4 = 0.2 are the weights of each dimension, and S1 is the task type matching score. The sub-architecture unit corresponding to the rule with a comprehensive matching degree S ≥ 0.8 is selected. If there are multiple units that meet the conditions, the first one is selected in ascending order of rule ID. If there are no units that meet the conditions, the automatic sub-architecture generation mechanism is triggered.
[0030] The implementation of the sub-architecture automatic generation mechanism relies on the atomic processing module library, which is a resource pool that stores the smallest granularity preprocessing functional modules. Each atomic module contains a clear input data format, output data format, configurable parameters, and functional description. Common modules include format standardization module, physical dimension normalization module, Kriging interpolation module, inverse distance weighted interpolation module, time resampling module, and outlier preliminary filtering module. The automatic generation process consists of three steps. The first step is module selection, which determines the core module category based on the analyzed prediction task type, selects processing modules for corresponding meteorological elements based on their dimensions, selects spatial processing modules based on spatial accuracy requirements, and selects temporal processing modules based on temporal response characteristics. The second step is module sorting, which sorts the selected modules according to a fixed logic of "format standardization → preliminary outlier filtering → physical dimension normalization → spatial interpolation → temporal resampling" to ensure that the output format of the previous module matches the input format of the next module. If there are format incompatibilities, a format adaptation sub-module is automatically inserted. The third step is module parameter configuration, which configures parameters based on the historical data characteristics of the target area to form a new preprocessing sub-architecture unit. Then, a unique sub-architecture ID is assigned to this unit, its corresponding task requirement parameters and module combination information are recorded, and it is registered to the sub-architecture mapping rule base and the base index is updated to support subsequent matching.
[0031] Taking a wind power output forecasting task for a provincial power grid as an example, when analyzing the task requirements, the forecasting task type is first determined to be wind power output forecasting. The target area is mapped to longitude 110.2°-110.8°E and latitude 38.5°-39.1°N, the time window is from 00:00 on July 1, 2024 to 00:00 on July 2, 2024, the time resolution requirement is 1 hour, and the required meteorological elements are wind speed at 10 meters altitude, air temperature at 2 meters altitude, and horizontal solar irradiance. When querying the sub-architecture mapping rule library, the rule corresponding to wind power output forecasting is selected. The threshold area for this rule is longitude 109.5°-111.0°E and latitude 38.0°-39.5°N, the time window threshold is 12-48 hours, and the set of suitable meteorological elements includes wind speed at 10 meters altitude, air temperature at 2 meters altitude, and horizontal solar irradiance. When calculating the matching degree, S1 = 1, A overlap With A targetSince both are the area of the target region, S2 = 1, T rule = (12+48) / 2 = 30 hours, therefore S3 = 1 - |24-30| / 30 = 0.8, N match =3, N target =3, therefore S4 = 1, the overall matching degree S = 0.4×1 + 0.2×1 + 0.2×0.8 + 0.2×1 = 0.96 ≥ 0.8, the match is successful, and the corresponding sub-architecture unit is called. This unit includes a format standardization module, a wind speed outlier filtering module, a temperature smoothing module, a physical dimension normalization module, a Kriging interpolation module, and a 1-hour time resampling module. The modules are assembled in sequence to form a customized preprocessing pipeline for this wind power output prediction task. If the task requirement adds the meteorological element of "cloud cover", but the matching element set in the rule base does not include cloud cover, then S4 = 3 / 4 = 0.75, the overall matching degree S = 0.4×1 + 0.2×1 + 0.2×0.8 + 0.2×0.75 = 0.4 + 0.2 + 0.16 + 0.15 = 0.91 ≥ 0.8, the match is still successful;
[0032] If the task type changes to "photovoltaic power output prediction" and there is no corresponding rule in the rule base, the automatic generation mechanism is triggered. The photovoltaic-specific irradiance fine processing module, cloud cover processing module, and 10-meter wind speed module are selected from the atomic processing module library, sorted by "format standardization → irradiance anomaly filtering → cloud cover data conversion → temperature processing → Kriging interpolation → 1-hour resampling", the irradiance module parameters are configured, a new sub-architecture is generated and registered to the rule base, and the customized pipeline construction is completed.
[0033] Step S130 involves executing a customized preprocessing pipeline to standardize the format, normalize the physical dimensions, perform spatial interpolation, and align the time of the raw meteorological data. The spatial resolution of the meteorological data is dynamically adjusted based on the distribution density of power grid facilities in the target area, generating a numerical mapping map where location and meteorological value correspond one-to-one. In step S130, spatial interpolation employs a strategy that integrates multiple interpolation algorithms. It dynamically selects the optimal combination of interpolation methods, considering regional terrain features, the spatial distribution patterns of meteorological elements, and the spatial layout of power grid facilities. The interpolation algorithm library includes Kriging interpolation, inverse distance weighted interpolation, and spline interpolation. The selection logic is based on the terrain complexity index and the spatial variability function characteristics of meteorological elements. The specific implementation process of executing the customized preprocessing pipeline and generating the numerical mapping map in step S130 is as follows: First, the customized preprocessing pipeline is started. This pipeline follows a fixed process of "format standardization → physical dimension normalization → spatial interpolation → time alignment → dynamic adjustment of spatial resolution." Each step requires parameter configuration based on the analyzed power grid prediction task requirements and target area characteristics to ensure that the output data meets the input requirements of the subsequent prediction model. First, format standardization is performed. This step aims to convert multi-source, heterogeneous raw meteorological data into a unified structured format. JSON-LD is chosen as the standard format. JSON-LD is a lightweight data exchange format that extends the semantic association capabilities of JSON, supporting the definition of data semantics through the "@context" field, facilitating subsequent data traceability and cross-system interaction. Standardized data entries must contain four core fields. The first field, "dataId," is a unique string composed of the data source identifier, collection timestamp, and region code, such as "national_meteo_202408011200_320100," representing the national meteorological center, UTC August 1, 2024 12:00, and region code 320100, respectively. The second field, "timestamp," records the UTC timestamp of data collection, accurate to the second. The third field... The "geometry" field uses WKT format to describe the geographic coordinates of the data collection point. For example, "POINT(114.333.6)" represents the location at 114.3°E and 33.6°N. The fourth field, "elements," stores the raw values of each meteorological element in key-value pairs. The key is the element identifier, such as "temp_2m" representing temperature at 2 meters altitude and "wind_10m" representing wind speed at 10 meters altitude. The values are the corresponding raw observation values and units, such as "25.3,℃" and "3.5,m / s". During the format conversion process, if there are missing fields in the raw data, such as some regional observation station data lacking a "collection timestamp", the default value rules in the data source configuration table will be used to complete the data. For example, the default timestamp for regional observation station data is the exact 10 minutes prior to the data reception time.
[0034] Next, physical dimension normalization is performed using the Z-score dynamic standardization method based on historical statistical characteristics. This method converts the original meteorological element values into dimensionless standardized values, eliminating the impact of differences in element dimensions on subsequent models. The normalization formula is:
[0035]
[0036] Where z is the normalized standard value, x is the original observed value of a meteorological element, and μ is the mean value of that element in the recent historical meteorological data of the target area. This represents the standard deviation of the recent historical data for this element. "Recent historical data" is defined as data from the same period 30 days prior to the start date of the forecast task. For example, when forecasting the load on August 1, 2024, historical data from July 1 to July 30, 2024, is selected. If the historical data is less than 30 days, it is expanded to the previous 90 days, and missing periods are filled using weekly averages. μ and The calculation employs a sliding window update mechanism, recalculating daily at 3 AM based on the latest historical data to ensure that parameters dynamically adapt to regional meteorological changes. For example, in the 2-meter height temperature data for a certain region from July 1st to July 30th, μ = 26.5℃. The normalized result of the original value of 25.3℃ is (25.3-26.5) / 4.2℃=0.286.
[0037] Following this, spatial interpolation is performed. This step requires considering the topographic features of the target area, the spatial distribution patterns of meteorological elements, and the spatial layout of power grid facilities. An optimal algorithm combination is dynamically selected from an interpolation algorithm library, including Kriging interpolation, inverse distance weighted interpolation, and spline interpolation. First, two core decision indicators are calculated. The first indicator is the topographic complexity index TC, used to quantify the degree of topographic relief in the region. The formula is:
[0038]
[0039] Among them, H max H represents the highest altitude within the target area. min A is the lowest altitude within the target area. target The first indicator is the target area, TC, measured in meters per square kilometer (m² / km²). A higher value indicates more complex terrain. The second indicator is the grid infrastructure density, D, calculated using the following formula:
[0040]
[0041] Where, N facilityLet \(N\) be the total number of power grid facilities in the target area. The unit of \(D\) is number per square kilometer, and the larger the value, the denser the facility distribution. The interpolation algorithm is determined based on two indicators: when \(TC < 50\) and \(D\geq5\), inverse distance weighting interpolation is selected. This algorithm calculates the grid point value through the principle of "the closer the distance, the greater the weight" and is applicable to scenarios where data points are evenly distributed; when \(50\leq TC\leq150\) and \(D < 5\), Kriging interpolation is selected. This algorithm models based on the spatial variogram of meteorological elements, can quantify the interpolation error, and is applicable to elements with obvious spatial gradual change patterns; when \(TC>150\), spline interpolation is selected. This algorithm constructs a smooth curve to fit the data points and can better adapt to the sudden change of meteorological elements caused by terrain undulation. Before interpolation, the target area needs to be divided into uniform grids first. The grid side length \(L\) is determined by the power grid facility density \(D\): when \(D\geq10\), \(L = 1\) kilometer; when \(5\leq D < 10\), \(L = 2\) kilometers; when \(D < 5\), \(L = 5\) kilometers, ensuring that each grid cell contains at least 1 power grid facility or 2 observation points to avoid distortion of the interpolation result.
[0042] After that, time alignment processing is performed to uniformly align meteorological data with different sampling frequencies to the fixed time granularity determined in step S110. First, count the original sampling frequencies of each meteorological element. For example, the data of the national meteorological center is once every 6 hours, the regional observation station is once every 1 hour, and the local sensor network is once every 5 minutes. The alignment rules are divided into two categories: for data with a sampling frequency higher than the fixed time granularity, the mean aggregation algorithm is used to calculate the arithmetic mean of all original data within the target time window as the aligned value. The formula is:
[0043]
[0044] where, is the aligned mean value, \(n\) is the number of original data within the target time window, and \(x\) i is the \(i\)-th original data value; for data with a sampling frequency lower than the fixed time granularity, the linear interpolation algorithm is used to complete the missing time values. The formula is:
[0045]
[0046] where, \(y\) is the interpolation result corresponding to the target timestamp \(t\), \(t1 < t < t2\), \(y1\) is the original value at time \(t1\), and \(y2\) is the original value at time \(t2\).
[0047] Finally, dynamic spatial resolution adjustment and numerical mapping map generation are performed. Spatial resolution adjustment further optimizes grid accuracy based on the power grid facility density D: if there are key power grid facilities in the target area, the grid side length is reduced to 0.5 kilometers within a 1-kilometer radius of the facility to form a local high-resolution area, while other areas maintain the original grid side length. After adjustment, the spatial continuity of the grid needs to be verified to ensure that adjacent grids do not overlap and completely cover the target area. The numerical mapping map is generated using GeoJSON format, an open standard for encoding geospatial data that supports storing the geographic information and attribute data of grid units in a single file. Each grid unit in the mapping map contains five attributes: a unique grid identifier, the latitude and longitude coordinates of the grid center, a unified timestamp, normalized multidimensional meteorological element values, and the grid side length. After generation, data integrity verification is required to ensure that the attribute fields of each grid unit are complete and that the latitude and longitude are within the target area. After successful verification, the data repair step S140 is initiated.
[0048] Step S140 involves performing an integrity check on the numerical mapping map to identify missing values or abnormal observation points. A reasoning completion model based on spatiotemporal correlation and physical constraints is then invoked. Meteorological data from neighboring spatiotemporal points and auxiliary information on power grid operation status are used to logically repair the missing or abnormal data. In step S140, the integrity check identifies abnormal observation points by setting a reasonable threshold range consistent with meteorological physical laws and a dynamic upper limit for the rate of change of adjacent spatiotemporal points. The threshold range is set based on the historical statistical distribution of meteorological elements, and the normal value range is determined using the 3σ principle. The dynamic upper limit for the rate of change is calculated based on the time autocorrelation characteristics of meteorological elements. The reasoning completion model in step S140 employs a spatiotemporal reasoning engine built on a graph neural network. This engine can achieve logical consistency repair of missing or abnormal data by introducing basic constraints such as mass conservation and energy balance in atmospheric physical processes, based on the spatial correlation between the grid cell to be repaired and its neighboring cells, historical meteorological evolution patterns, dynamic response characteristics of power grid load, and equipment operation status labels. After step S140, a multi-dimensional quality assessment is performed on the repaired numerical mapping map. The assessment system comprehensively considers data integrity, spatiotemporal continuity and physical consistency. A comprehensive quality score is calculated through a weighted fusion method. When the score is lower than a preset threshold, the system automatically triggers a manual review process and records the abnormal event log simultaneously.
[0049] The specific implementation process of step S140, which performs integrity verification and logical consistency repair on the numerical mapping diagram, is as follows. This step consists of two main parts: integrity verification and spatiotemporal inference completion. Additionally, a multi-dimensional quality assessment is added after repair to ensure data reliability. Each step requires an executable technical solution designed by combining meteorological and physical laws with the characteristics of power grid operation. The specific implementation method for integrity verification is as follows:
[0050] Integrity verification aims to systematically identify missing values and outlier observations in a numerical mapping graph, preventing unfiltered data from directly entering the repair stage and causing result deviations. The verification process follows the logical order of "first identifying missing values, then determining outliers." The specific steps and technical details are as follows:
[0051] Missing values refer to situations where the meteorological element values of a grid cell in a numerical mapping map cannot properly represent the actual observation status. The criteria for determining missing values must cover three scenarios: first, the numerical field of a meteorological element in the grid cell is empty or marked with invalid identifiers such as "NaN," "NULL," or "no data"; second, the data acquisition status field is marked with abnormal states such as "sensor failure," "transmission interruption," or "verification failure"; and third, the grid cell has not acquired valid meteorological data for three or more consecutive time steps. The identification process requires a traversal algorithm: first, the GeoJSON data of the numerical mapping map is loaded, and each data item is scanned sequentially according to the hierarchy of "grid cell → meteorological element → time step"; then, each data item is matched against the three missing scenarios mentioned above, and if it meets any one of them, it is marked as a missing value, and the missing type and the spatiotemporal coordinates of the missing value are recorded; finally, a missing value statistical report is generated to clarify the proportion of each missing type, providing a basis for subsequent priority allocation for repair. 2. Identification of Abnormal Observation Points
[0052] Anomaly observation points refer to observational data that exist but do not conform to meteorological physical laws or spatiotemporal variation logic. Identification requires a dual mechanism of "physical threshold verification" and "spatiotemporal change rate verification." Both mechanisms must be based on historical data and physical laws to construct quantitative judgment criteria. The physical threshold verification method is as follows:
[0053] The 3σ principle is a statistical verification method based on the characteristics of normal distribution. Its core logic is: if the historical observation data of a meteorological element follows a normal distribution, then 99.73% of the normal data will fall within the range of "mean ± 3 standard deviations," and data exceeding this range are likely outliers. In practice, the threshold range needs to be calculated first, and then data comparison performed. The formula and steps are as follows:
[0054] First, calculate the historical statistical parameters of a certain meteorological element in the target area using the following formula:
[0055]
[0056] Where μ is the historical mean of the meteorological element, σ is the historical standard deviation of the meteorological element, n is the number of historical data samples, and x i Let be the i-th historical observation.
[0057] Subsequently, the physical threshold range was determined to be [μ-3σ, μ+3σ]. All non-missing data in the numerical mapping were traversed. If the meteorological element value x of a certain grid cell... curr Satisfy x curr <μ-3σ or x curr If the value is greater than μ+3σ, then the data is marked as a "physical threshold anomaly candidate point". It should be noted that for elements with a lower bound of zero, such as precipitation and wind speed, if the calculated lower bound is less than 0, the threshold lower bound is corrected to 0 to ensure that the threshold conforms to physical common sense.
[0058] The method for verifying the spatiotemporal rate of change is as follows:
[0059] The spatiotemporal changes of meteorological elements are continuous. For example, the temperature difference between adjacent areas usually does not exceed 5℃, and the temperature change within one hour usually does not exceed 10℃. Changes exceeding these ranges do not conform to physical laws. Spatiotemporal change rate verification calculates the rate of change between the target data and adjacent spatiotemporal point data to determine whether it exceeds a reasonable upper limit. This includes two types of calculations: spatial change rate and temporal change rate.
[0060] Spatial change rate calculation: Select the "8-neighborhood grid" of the current grid cell as the comparison object, and calculate the change rate of the current data with the data of each neighboring grid in the same period. The formula is:
[0061]
[0062] Among them, SCR ij x represents the spatial rate of change between the current grid i and its neighboring grid j. curr,i Let x be the meteorological element value of the current grid i. neigh,j Let d be the meteorological element value of the neighboring grid j during the same period. ij The straight-line distance between the centers of the two grids; calculated using latitude and longitude coordinates: Where ΔLon is the longitude difference between the two grids, ΔLat is the latitude difference, and Lat is the latitude difference. avg The average latitude of the two grids.
[0063] Calculation of the rate of change over time: Select the data from the previous and next time steps of the current grid cell as the comparison objects, and calculate the rate of change of the current data with the data from the adjacent time steps. The formula is:
[0064]
[0065] Among them, TCR t x is the rate of change of time at the current time step t. curr,t Let x be the meteorological element value at the current time step t. curr,t±1 ΔT represents the meteorological element values at adjacent time steps, and ΔT is the time step interval.
[0066] The reasonable upper limit of the spatiotemporal rate of change needs to be determined based on historical data statistics, using the following formula:
[0067] U SCR =quantile(SCR) history ,0.95)
[0068] U TCR =quantile(TCR) history ,0.95)
[0069] Among them, U SCR U is the upper limit of the spatial rate of change. TCR SCR is the upper limit of the rate of change over time. history The TCR is the set of spatial variability rates of this meteorological element based on its historical data over the past 30 days. history Let be the set of historical rates of change, and quantile(·,0.95) be the quantile function, taking the 95th percentile of the set as the upper limit.
[0070] The method for confirming abnormal observation points is as follows: Further perform spatiotemporal rate of change verification on the "physical threshold abnormal candidate points": If the spatial rate of change (SCR) of the candidate point is... ij More than 50% of the neighboring grids satisfy SCR ij >U SCR And the time-varying rate of change (TCR) t >U TCR If a point meets one of the criteria, it is officially designated as an "abnormal observation point". If only one of the criteria is met, further judgment is required based on meteorological event records (such as whether there are extreme weather events like typhoons or cold waves). If there are no extreme weather records, it is still considered abnormal. If there are, it is marked as an "abnormal point pending verification".
[0071] The implementation method of the spatiotemporal reasoning completion model is as follows:
[0072] The spatiotemporal inference completion model employs a spatiotemporal inference engine based on graph neural networks. Its core is to capture the spatial dependence and temporal evolution of meteorological data by constructing a spatiotemporal correlation graph, and to incorporate atmospheric physical constraints to ensure the logical consistency of the repair results. Simultaneously, it combines grid operation status auxiliary information to improve repair accuracy. The specific implementation consists of the following four steps: 1. Spatiotemporal correlation graph construction: Node definition: The state of each grid cell in the numerical mapping graph at each time step is defined as a "spatiotemporal node," and the unique identifier of each node is "grid ID-timestamp." Each node needs to store basic attributes: grid center latitude and longitude, grid edge length, current timestamp, and the original value of the meteorological element to be repaired. Edge definition: Edges are used to represent the correlation between nodes, and are divided into two categories: "spatial edges" and "temporal edges": Spatial edges: connect adjacent grid nodes at the same time step. The weight of the edge is determined by the distance between the two grids and the terrain connectivity, as shown in the formula:
[0073]
[0074] Among them, W spatial,ij For the spatial edge weights, d ij C is the distance between the centers of the two grids. ij The terrain connectivity coefficient is determined based on the terrain type between the two grids: Plain region C ij =1.0, Gentle Hill Area C ij =0.8, Mountainous or watery areas C ij =0.5, reflecting the degree to which terrain hinders the transmission of meteorological elements. Time edge: Connects nodes within the same grid cell at adjacent time steps, such as "GRID_1143336-202408011400" and "GRID_1143336-202408011500". The edge weight is determined by the time autocorrelation between the time interval and the meteorological element, using the formula:
[0075] W temporal,t =exp(-α×ΔT)×ρ
[0076] Among them, W temporal,t The time edge weight is α, the decay coefficient is ΔT, the time interval is ρ, and the time autocorrelation coefficient of the meteorological element is calculated using historical data from the past 30 days. For example, ρ≈0.8 for temperature and ρ≈0.6 for wind speed, reflecting the continuity of the element over time.
[0077] 2. Multi-source feature fusion: To improve repair accuracy, the model needs to input multi-source features, including meteorological features and power grid auxiliary features. These two types of features need to be standardized before fusion.
[0078] Meteorological features: These include the original values of meteorological elements at the current node, the values of meteorological elements at adjacent spatiotemporal nodes, the historical average values of meteorological elements for the same period, and meteorological trend characteristics. Power grid auxiliary features: These include power grid load data, power grid equipment operating status, and power facility distribution density for the target area. The role of power grid auxiliary features is to establish the correlation between meteorology and the power grid; the data is acquired in real time through the power grid SCADA system interface. The fusion process employs a feature concatenation method: the meteorological features of each spatiotemporal node are concatenated with the corresponding grid auxiliary features of the grid to form a high-dimensional feature vector, which serves as the input features for the nodes of the graph neural network.
[0079] 3. Embedding Physical Constraints: Atmospheric physical constraints are crucial to ensuring that the restoration results conform to natural laws. The two core constraints—mass conservation and energy balance—must be quantified into mathematical formulas and integrated into the model's loss function. Mass Conservation Constraint: Precipitation in a given region must satisfy "local cumulative consistency" spatially and "time-period cumulative consistency" temporally. The quantification formula is as follows:
[0080]
[0081] Where N(i) is the set of 8 neighboring grids of grid i, x j,t Let A be the precipitation restoration value for neighboring grid j at time t. j Let x be the area of grid j. i,t A is the precipitation restoration value for grid i. i Let be the area of grid i, and k be the terrain attenuation coefficient. The formula means that the area-weighted sum of precipitation of neighboring grids should be approximately equal to the area-weighted sum of precipitation of the current grid.
[0082] Energy balance constraint: Temperature changes between adjacent grids must conform to the laws of heat conduction, i.e., heat flux density is proportional to the temperature gradient. The quantization formula is:
[0083]
[0084] Where, q ij Let k be the heat flux density between grids i and j. cond x is the thermal conductivity coefficient of air. i,t x j,t The temperature restoration values for the two grids, d ij This refers to the grid spacing. The heat flux density must meet the following requirements. Heat conduction beyond this range does not conform to the laws of atmospheric physics.
[0085] L total =L pred +β×L constraint
[0086] Where β is the constraint weight, set to 0.3, to ensure that the constraint does not dominate the prediction but can correct unreasonable results, and L constraint To constrain the loss, the sum of squared deviations between the actual repair value and the constraint formula is calculated.
[0087] 4. Repair Value Generation and Secondary Validation: After model training is completed, repair is performed on missing or abnormal nodes: First, the constructed spatiotemporal correlation graph and fused features are input into the neural network. The network outputs the meteorological element repair value for each node to be repaired. Then, a secondary validation is performed on the repair value to check whether it meets the physical threshold range, μ-2σ to μ+2σ, which is more stringent than the range in the validation stage and the upper limit of the spatiotemporal change rate. If it does not meet the requirements, the model parameters are readjusted and the repair value is generated again until it meets the requirements. Finally, the repair value replaces the original missing or abnormal value and the numerical mapping graph is updated.
[0088] III. Post-repair quality assessment and review
[0089] To ensure that the repaired data meets the power grid forecasting requirements, a multi-dimensional quality assessment of the updated numerical mapping map is necessary. The assessment system covers three core dimensions: data integrity, spatiotemporal continuity, and physical consistency. The specific calculation and verification process is as follows: Data integrity rate: reflects the proportion of non-missing data after repair, and the formula is:
[0090]
[0091] Where, N non-missing N represents the number of valid data points after repair. total The total number of data points is represented by C, which ranges from 0 to 1. The closer the value is to 1, the better the completeness.
[0092] Spatiotemporal continuity rate: reflects the consistency between the repaired value and adjacent spatiotemporal data, and the formula is:
[0093]
[0094] Where, N consistent To ensure that the repaired values meet the spatiotemporal rate of change (SCR) requirement. ij ≤U SCR And TCR t ≤U TCR The number of ) N repaired The total amount of data to be repaired is represented by a value of T ranging from 0 to 1, with a value closer to 1 indicating better continuity.
[0095] Physical consistency rate: reflects the proportion of repaired values that conform to physical constraints, and the formula is:
[0096]
[0097] Where, N constraint-satisfied P represents the number of values in the repair that satisfy the constraints of mass conservation and energy balance. The value of P ranges from 0 to 1, and the closer it is to 1, the better the physical consistency.
[0098] The overall quality score is calculated using a weighted summation method, as shown in the formula:
[0099] S = 0.4 × C + 0.3 × T + 0.3 × P
[0100] Here, S represents the comprehensive score, with weights allocated based on the impact of each dimension on power grid forecasting. A scoring threshold of 0.8 is set: if S ≥ 0.8, the repair is deemed satisfactory, and the data can proceed to the S150 output stage; if S < 0.8, a review process is automatically triggered, and the system generates a review report containing specific issues in the low-scoring dimensions, their corresponding grid coordinates and timestamps, and the original logs of the model repair. After manual review, the user must manually confirm whether the repair result is accepted. If not, the model constraint parameters are readjusted, and the repair is performed again.
[0101] Step S150: Output the integrity-repaired numerical mapping map to the power grid prediction model interface as the input meteorological feature dataset for the prediction task. In step S150, the power grid prediction model interface adopts a standardized data exchange protocol, encapsulating the numerical mapping map into a structured geospatial data format. This format includes precise geographic location information for each grid cell, a unified time identifier, and multi-dimensional meteorological feature vectors. The feature vectors cover various meteorological elements and their derived features. It supports both batch data push and incremental update transmission modes, using a JSON format as the transmission protocol and the LZ4 algorithm for data compression. The specific implementation process of outputting the integrity-repaired numerical mapping map to the power grid prediction model interface in step S150 is as follows. This step requires standardized interface design, structured data encapsulation, multi-mode transmission, and interactive verification to ensure that the repaired data can be efficiently received and parsed by the power grid prediction model, while maintaining the correlation between the data and the quality assessment results of S140, avoiding integrity loss or format deviation during data transmission. Specific technical details and execution flow are as follows:
[0102] First, a standardized design for the power grid forecasting model interface is implemented. The interface must adopt a two-layer protocol architecture: an application layer and a transport layer. The transport layer uses the TCP / IP protocol to ensure reliable data transmission, while the application layer uses a custom standardized data exchange protocol. This protocol must clearly define the data encapsulation format, transmission command set, and interaction logic. The core structured geospatial data format must include three layers: a grid cell attribute layer, a meteorological feature vector layer, and a metadata layer. The grid cell attribute layer is used to locate the spatial and temporal dimensions of the data. The meteorological feature vector layer stores normalized meteorological data and derived features. The vectors must cover all basic meteorological elements and derived features processed by S130. All features are stored in key-value pairs, with the key being the feature identifier and the value being numerical data. The metadata layer describes data quality and provenance information, and must include the data version number, data generation time, the comprehensive quality score calculated by S140, and the original data source identifier.
[0103] Next, the data encapsulation process is executed, which follows the steps of "grid cell traversal → feature vector assembly → metadata addition → overall format verification": The first step is grid cell traversal, loading the numerical mapping map after S140 repair, and processing each data cell in the order of "time step → grid cell" to ensure that no spatiotemporal node is missed; the second step is feature vector assembly, for each grid cell, extracting the normalized values of basic meteorological elements from the repaired data, calculating the derived feature values according to the above formula, and integrating the basic elements and derived features into a key-value pair set to form a meteorological feature vector; the third step is metadata addition, reading the S140 quality assessment report, extracting the quality score of the current data batch, generating generateTime in combination with the system time, generating dataVersion according to fixed rules, and summarizing it into the metadata layer; the fourth step is overall format verification, checking whether the fields of each level are complete, if any fields are missing, returning to S140 to supplement them, and after the verification is passed, integrating the three layers of data into a single grid data object in JSON format.
[0104] Subsequently, the data transmission modes were determined, supporting both batch data push and incremental update modes. The triggering conditions and data ranges for the two modes need to be clearly distinguished: the batch data push mode is suitable for the first data transmission or full update scenario, and the transmission range is the complete data of all grid cells and all time steps within the target area required by the prediction task. Before transmission, all single grid data objects need to be grouped by time step, and a unique feedback tag is generated for each group of data; the incremental update mode is suitable for local adjustment scenarios after data repair, and the transmission range is only the data of the grid cells and time steps that have changed. Before transmission, feedback information needs to be generated for the changed data blocks, and the change type needs to be marked in the transmission message to avoid the prediction model repeatedly processing unchanged data.
[0105] Before data transmission, LZ4 compression is required. LZ4 is a lossless data compression algorithm characterized by fast compression and decompression speeds, making it suitable for real-time data transmission scenarios. The compression process consists of three steps: data segmentation, compression, and verification. The first step is data segmentation, where the JSON data to be transmitted in batches or incrementally is divided into several data blocks of a fixed size, and each data block is marked with a block index. The second step is compression, where each data block is compressed using the LZ4 standard compression algorithm. The third step is checksum calculation, where a CRC32 checksum is calculated for each compressed data block. CRC32 is a type of cyclic redundancy check used to detect errors during data transmission. The compressed data blocks and checksums must be bound and stored together to form a "compressed block - checksum" pair.
[0106] Finally, the interface interaction process is executed. The interaction must follow a closed-loop logic of "request-response-confirmation-error handling" to ensure reliable data transmission: The first step is request initiation. The power grid prediction model interface sends a data request message to the meteorological data collection system. The message includes the transmission mode, required time window, target area latitude and longitude range, and a list of required meteorological elements. The second step is request verification. The collection system verifies the validity of the request parameters: such as whether the time range is within the data storage range, whether the area is consistent with the target area of S110, and whether the elements are included in the processing range of S130. If valid, a response is returned; otherwise, an error message is returned. The third step is data transmission. The collection system encapsulates and compresses the data according to the request type and sends a data transmission packet to the prediction model interface. The packet contains a unique identifier for the transmission packet, a data batch / update identifier, the total number of data blocks, and the compression value. The first step is to generate a list of compressed blocks, including the blockIndex, compressed_block, and crc32_value for each block. The second step is to receive and verify the data. After receiving the transmission packet, the prediction model interface extracts the compressed blocks sequentially according to the blockIndex, calculates the CRC32 value of each compressed block, and compares it with the sender's crc32_value. If all blocks are verified to be consistent, LZ4 decompression is performed, the decompressed JSON data is parsed into the input feature dataset required by the prediction model, and confirmation information is returned. If there are blocks with inconsistent verification, the system returns the blockIndex that needs to be retransmitted and specifies the blockIndex that needs to be retransmitted. The third step is to handle exceptions. After receiving the data, the aggregation system retransmits the compressed block corresponding to the blockIndex, with a maximum of 3 retries. If the retry still fails, an exception log is recorded, and a manual investigation process is triggered.
[0107] Of course, the above are only typical examples of the present invention. In addition, the present invention may have many other specific embodiments. All technical solutions formed by equivalent substitution or equivalent transformation fall within the scope of protection claimed by the present invention.
Claims
1. A method for collecting weather data based on grid forecast demand, characterized by, The method comprises the following steps: Step S110, constructing a multi-source weather data access layer, obtaining original weather data, and mapping all data to a unified geographic coordinate system and time stamp system through a unified space-time reference conversion module; Step S120, analyzing power grid prediction task requirements, extracting prediction task types, target area ranges, time window lengths, and required weather element dimensions, dynamically matching and splicing corresponding preprocessing sub-architecture units based on a preset sub-architecture mapping rule library, and forming a customized preprocessing pipeline for the current prediction task; Step S130, executing the customized preprocessing pipeline, performing format standardization, physical quantity normalization, spatial interpolation, and time alignment processing on the original weather data, and dynamically adjusting the spatial resolution of the weather data according to the distribution density of the power grid facilities in the target area to generate a numerical mapping graph with one-to-one correspondence between location and weather value; Step S140, performing integrity checking on the numerical mapping graph, identifying missing values or abnormal observation points therein, calling an inference completion model based on space-time correlation and physical constraints, and using the weather data of adjacent space-time points and power grid operation state auxiliary information to repair the missing or abnormal data logically; Step S150, outputting the numerical mapping graph after integrity repair to a power grid prediction model interface as an input weather feature data set for the prediction task.
2. The method for weather data aggregation based on grid forecast demand of claim 1, wherein, The unified space-time reference conversion module in step S110 uses an internationally recognized geographic coordinate system as the unified spatial reference, and the time stamp system uses the global standard time system and is aligned at a fixed time granularity. For local sensor network data, high-precision positioning mapping is achieved through a coordinate conversion interface provided by a power facility geographic information system. The conversion interface realizes accurate conversion between geographic coordinates and projection coordinates based on a coordinate conversion parameter matrix.
3. The grid forecast demand based weather data aggregation method of claim 1, wherein, The sub-architecture mapping rule library in step S120 stores multiple preprocessing sub-architecture units. Each type of sub-architecture unit is optimized for a specific type of power grid prediction task. Each sub-architecture unit defines its applicable weather element combination strategy, spatial interpolation algorithm selection logic, and time resampling mechanism.
4. The method for weather data aggregation based on grid forecast demand of claim 1, wherein, In step S130, multiple interpolation algorithms are used to dynamically select the optimal interpolation method combination based on regional terrain features, spatial distribution of weather elements, and spatial layout of power grid facilities. The interpolation algorithm library includes Kriging interpolation, inverse distance weighting interpolation, and spline interpolation. The selection logic is based on terrain complexity indicators and weather element spatial variation function characteristics.
5. The grid forecast demand based weather data aggregation method of claim 1, wherein, In step S130, the physical quantity normalization adopts a dynamic standardization method based on historical statistical characteristics to convert all weather elements into dimensionless standardized values. The normalization parameters are dynamically calculated based on the statistical distribution of recent historical weather data in the target area.
6. The grid forecast demand based weather data aggregation method of claim 1, wherein, The integrity check in step S140 identifies abnormal observation points by setting reasonable threshold ranges consistent with meteorological physical laws and dynamic upper limits of adjacent spatiotemporal point change rates. The threshold ranges are set according to the historical statistical distribution of meteorological elements, and the normal value interval is determined using the 3σ principle. The dynamic upper limit of the change rate is calculated based on the time autocorrelation characteristics of meteorological elements.
7. The grid forecast demand based weather data aggregation method of claim 1, wherein, The reasoning completion model in step S140 uses a spatiotemporal reasoning engine based on a graph neural network. This engine can repair missing or abnormal data based on the spatial correlation between the grid cells to be repaired and their neighboring cells, historical synchronous meteorological evolution laws, dynamic response characteristics of power grid load, and device operation state labels. By introducing basic constraints such as mass conservation and energy balance in atmospheric physics, the engine can achieve logical consistency repair of missing or abnormal data.
8. The grid forecast demand based weather data aggregation method of claim 1, wherein, In step S150, the power grid prediction model interface uses a standardized data exchange protocol to encapsulate the numerical mapping map into a structured geographic spatial data format. This format includes the precise geographic location information of each grid cell, a unified time identifier, and a multi-dimensional meteorological feature vector. The feature vector covers multiple meteorological elements and their derived features, supports batch data pushing and incremental updating transmission modes, and the transmission protocol is based on JSON format. Data compression uses the LZ4 algorithm.
9. The grid forecast demand based weather data aggregation method of claim 1, wherein, In step S120, if the parsed prediction task requirements cannot fully match the existing sub-architecture units, the sub-architecture automatic generation mechanism is triggered. This mechanism automatically selects and combines multiple basic processing modules from the atomic processing module library based on the meteorological element combination features, spatial precision requirements, and time response characteristics contained in the task requirements, constructs a new pre-processing sub-architecture that adapts to the current task, and registers it in the sub-architecture mapping rule library.
10. The grid forecast demand based weather data aggregation method of claim 1, wherein, After step S140, the repaired numerical mapping map is subjected to multi-dimensional quality assessment. The evaluation system considers data integrity, spatiotemporal continuity, and physical consistency, and calculates a comprehensive quality score through weighted fusion. When the score result is below the preset threshold, the system automatically triggers the manual review process and synchronously records abnormal event logs.
Citation Information
Cited By
A big data-based data cleaning system
CN122241033A
A big data-based data cleaning system
CN122241033B
