Electric hydrogen heat microgrid scenario reduction method, device and equipment and storage medium
Patent Information
- Application Number
- CN202510414783.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-03
- Publication Date
- 2026-10-16
AI Technical Summary
[0003]本申请实施例提供一种电氢热微电网场景缩减方法、装置、设备及存储介质,以解决现有场景缩减方法中新能源利用率较低的问题
[0049] The scenario reduction method of this application includes: clustering the scenario set based on the time information of each scenario in the scenario set using a temporal clustering algorithm to obtain multiple first categories, with different time dimensions corresponding to different first categories, wherein the scenario set is a scenario set of a power system; clustering the first categories spatially using a spatial clustering algorithm to obtain multiple second categories under each category, with different spatial dimensions corresponding to different second categories; and reducing the multiple second categories corresponding to each first category using a synchronous back-substitution elimination method to determine the reduced scenario set, which is used for the planning and scheduling optimization of the power system. This method overcomes the limitations of traditional single-dimensional clustering through a spatiotemporal step-by-step clustering mechanism, reducing the computational load while preserving temporal regularity and spatial differences, and improving regional adaptability through multi-dimensional feature fusion. Furthermore, by using a synchronous back-substitution elimination method to probabilistically drive scenario reduction, the probability distribution of the scenario set maintains a high degree of consistency with the original data, improving model adaptability while ensuring high representativeness of the scenarios.
Smart Images

Figure CN122931650A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of wind power technology, and in particular to a method, apparatus, equipment and storage medium for reducing the scale of an electric-hydrogen-thermal microgrid scenario. Background Technology
[0002] With the increase in the installed capacity of wind power and photovoltaic power in my country, stochastic optimization scheduling based on scenario analysis methods has received increasing attention. The significance of scenario reduction lies in using a small number of representative scenarios to describe the characteristics of a large number of complex scenarios, thereby reducing computational complexity. Existing scenario clustering analysis often requires deterministic annual renewable energy output data and load data for 8760 hours, which involves a large amount of computation and is difficult to adapt to power system planning and scheduling optimization in different regions. Summary of the Invention
[0003] This application provides a method, apparatus, device, and storage medium for reducing the scenario of an electric-hydrogen-thermal microgrid, in order to solve the problem of low utilization rate of new energy in existing scenario reduction methods.
[0004] To solve the above-mentioned technical problems, this application is implemented as follows:
[0005] In a first aspect, embodiments of this application provide a method for reducing the scale of an electro-hydrogen-thermal microgrid scenario, the method comprising:
[0006] Based on the time information of each scenario in the scenario set, the scenario set is clustered using a time clustering algorithm to obtain multiple first categories. Different first categories correspond to different time dimensions. The scenario set is a scenario set of a power system.
[0007] Based on the spatial clustering algorithm, the first category is clustered in terms of spatial dimension to obtain multiple second categories under each category. The spatial dimensions corresponding to different second categories are different.
[0008] The synchronous back-substitution elimination method is used to reduce the number of second categories corresponding to each first category to determine the reduced scenario set, which is used for the planning and scheduling optimization of the power system.
[0009] Optionally, the step of clustering the scene set based on the time information of each scene in the scene set using a time clustering algorithm includes:
[0010] Obtain the time-series characteristics of the scene set;
[0011] Based on the time series characteristics of the scene set, the scene set is clustered using fuzzy mean clustering and difference determination index.
[0012] Optionally, the time series characteristics include the natural attribute characteristics of the scene set and the state probability transition matrix of the scene set, wherein the natural attribute characteristics include seasonal characteristics, intraday time characteristics, and weather characteristics.
[0013] Optionally, the spatial clustering algorithm is used to cluster the first category along the spatial dimension, including:
[0014] The weights of each type of spatial factor in the first category are determined based on the analytic hierarchy process.
[0015] Multiple first categories and the weights of various spatial factors in the first categories are input into a self-supervised clustering algorithm for clustering processing;
[0016] Based on the output of the self-supervised clustering algorithm, multiple second categories are determined under each category.
[0017] Optionally, determining the weights of each spatial factor in the first category based on the analytic hierarchy process includes:
[0018] The various spatial factors are normalized and a weight judgment matrix is constructed.
[0019] Determine the largest eigenvalue and the corresponding eigenvector of the weight judgment matrix;
[0020] If the consistency of the weight judgment matrix meets the first condition, the feature vector is determined as the weight vector, and the weight vector represents the weight of the various spatial factors.
[0021] Optionally, the step of inputting multiple first categories and the weights of various spatial factors in the first categories into a self-supervised clustering algorithm for clustering processing includes:
[0022] Based on the weights of various spatial factors in each of the first categories, the scenes in each of the first categories are divided into multiple categories, and the following steps are repeated until the second condition is met:
[0023] Obtain the total number of categories and the centroid of each category;
[0024] The scenes are reclassified based on the distance between each scene and the centroid in each category;
[0025] Update the total number of categories and the centroid of each category.
[0026] Secondly, embodiments of this application also provide a scene reduction device. The scene reduction device includes:
[0027] The first clustering module is used to cluster the scene set based on the time information of each scene in the scene set using a time clustering algorithm to obtain multiple first categories. The time dimensions corresponding to different first categories are different. The scene set is a scene set of the power system.
[0028] The second clustering module is used to perform spatial dimension clustering on the first category based on the spatial clustering algorithm, so as to obtain multiple second categories under each category, and the spatial dimensions corresponding to different second categories are different.
[0029] The reduction module is used to reduce the multiple second categories corresponding to each first category based on the synchronous back substitution elimination method, and determine the reduced scenario set. The reduced scenario set is used for the planning and scheduling optimization of the power system.
[0030] Optionally, the first clustering module includes:
[0031] The acquisition module is used to acquire the time-series characteristics of the scene set;
[0032] The third clustering module is used to cluster the scene set based on the time series characteristics of the scene set, using fuzzy mean clustering and difference determination index.
[0033] Optionally, the time series characteristics include the natural attribute characteristics of the scene set and the state probability transition matrix of the scene set, wherein the natural attribute characteristics include seasonal characteristics, intraday time characteristics, and weather characteristics.
[0034] Optionally, the second clustering module includes:
[0035] The first determining module is used to determine the weights of various spatial factors in each of the first categories based on the analytic hierarchy process.
[0036] The input module is used to input multiple first categories and the weights of various spatial factors in the first categories into a self-supervised clustering algorithm for clustering processing;
[0037] The output module is used to determine multiple second categories under each category based on the output of the self-supervised clustering algorithm.
[0038] Optionally, the first determining module includes:
[0039] The normalization module is used to normalize the various spatial factors and construct a weight judgment matrix;
[0040] The second determining module is used to determine the largest eigenvalue and the corresponding eigenvector of the weight judgment matrix.
[0041] The third determining module is used to determine the feature vector as a weight vector when the consistency of the weight judgment matrix meets the first condition, and the weight vector represents the weight of the various spatial factors.
[0042] Optionally, the input module includes:
[0043] The iterative module is used to divide the scene in each first category into multiple categories according to the weights of various spatial factors in each first category, and repeat the following steps until the second condition is met:
[0044] Obtain the total number of categories and the centroid of each category;
[0045] The scenes are reclassified based on the distance between each scene and the centroid in each category;
[0046] Update the total number of categories and the centroid of each category.
[0047] Thirdly, embodiments of this application also provide an electronic device, including a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the above-described scenario reduction method.
[0048] Fourthly, embodiments of this application also provide a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps of the above-described scenario reduction method.
[0049] The scenario reduction method of this application includes: clustering the scenario set based on the time information of each scenario in the scenario set using a temporal clustering algorithm to obtain multiple first categories, with different time dimensions corresponding to different first categories, wherein the scenario set is a scenario set of a power system; clustering the first categories spatially using a spatial clustering algorithm to obtain multiple second categories under each category, with different spatial dimensions corresponding to different second categories; and reducing the multiple second categories corresponding to each first category using a synchronous back-substitution elimination method to determine the reduced scenario set, which is used for the planning and scheduling optimization of the power system. This method overcomes the limitations of traditional single-dimensional clustering through a spatiotemporal step-by-step clustering mechanism, reducing the computational load while preserving temporal regularity and spatial differences, and improving regional adaptability through multi-dimensional feature fusion. Furthermore, by using a synchronous back-substitution elimination method to probabilistically drive scenario reduction, the probability distribution of the scenario set maintains a high degree of consistency with the original data, improving model adaptability while ensuring high representativeness of the scenarios. Attached Figure Description
[0050] To more clearly illustrate the technical solutions of the embodiments of this application, the drawings used in the description of the embodiments of this application will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0051] Figure 1 This is a flowchart of the scenario reduction method provided in the embodiments of this application;
[0052] Figure 2 This is a structural diagram of a scene reduction device provided in an embodiment of this application;
[0053] Figure 3 This is a structural diagram of an electronic device provided in an embodiment of this application;
[0054] Figure 4 This is a flowchart of the technical route for reducing the application scenarios of an electro-hydrogen-thermal microgrid system provided in one embodiment of this application. Detailed Implementation
[0055] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0056] This application provides a method for reducing the scale of an electro-hydrogen-thermal microgrid scenario. See also... Figure 1 , Figure 1 This is a flowchart of the scenario reduction method provided in the embodiments of this application, such as... Figure 1 As shown, it includes the following steps:
[0057] Step 101: Based on the time information of each scene in the scene set, cluster the scene set according to the time clustering algorithm to obtain multiple first categories. Different first categories correspond to different time dimensions. The scene set is the scene set of the power system.
[0058] In this step, the aforementioned scenario set is a collection of multiple scenarios. Each scenario represents a set of relevant information under specific conditions. These scenarios can originate from different times, spaces, or other environmental factors. For example, in a power system, the scenario set could be power load data at different times of day throughout the year, with each scenario representing the power load situation at a specific time on a particular day. The aforementioned time information can be understood as the time-related characteristics of the scenario; it can be a specific point in time, a time period, or a time interval, used to describe the time location or time pattern of the scenario's occurrence.
[0059] The aforementioned temporal clustering algorithm is a specialized algorithm for clustering data with temporal attributes. It can be understood as an algorithm model that groups data that are close in time or have similar time patterns into one class based on the temporal characteristics of the data. The specific form of the temporal clustering algorithm is not specifically limited in the embodiments of this application. For example, a density clustering algorithm based on the density distribution of data points in the time dimension can be used, or the K-Means temporal clustering algorithm or other types of algorithms can be used.
[0060] The first category mentioned above, namely the time clustering result, is generated based on the time information of each scenario in the scenario set. For example, in an electric-hydrogen-heat microgrid system, these scenarios can include time-series data such as wind power, photovoltaic output, and electric-hydrogen-heat load. These data have distinct time attributes, forming the basis for time clustering. For instance, wind power and photovoltaic output are affected by factors such as weather and diurnal variations, exhibiting different power values at different times; electric-hydrogen-heat load also varies depending on user habits and production needs, showing different patterns within a day, a week, or different seasons. These different time dimensions can include various time-related dimensions such as seasonal dimensions, weather type dimensions, and intraday time periods.
[0061] Step 102: Based on the spatial clustering algorithm, cluster the first category in terms of spatial dimension to obtain multiple second categories under each category. The spatial dimensions corresponding to different second categories are different.
[0062] In this step, the spatial amplitude of the basic datasets such as wind power output, photovoltaic power output, electricity load, hydrogen load, and heat load exhibits fluctuations, randomness, and uncertainty over a certain period of time. Therefore, based on the temporal clustering results obtained in the first step, spatial dimension clustering can be performed to determine multiple spatiotemporal clustering results with different spatiotemporal dimensions.
[0063] The aforementioned spatial dimension can be understood as a characteristic dimension related to physical spatial attributes such as geographical location, energy distribution, and load characteristics. For example, in an electric-hydrogen-thermal microgrid system, the spatial dimension can include the following elements: latitude and longitude coordinates characterizing the geographical location of a wind farm or photovoltaic power station, energy distribution characteristics, and load spatial characteristics, etc.
[0064] The aforementioned spatial clustering is a method specifically designed for clustering data with spatial attributes. It can be understood as a clustering method that groups data that are spatially close or have similar spatial attributes into one class based on the spatial characteristics of the data. The specific form of spatial clustering is not specifically limited in the embodiments of this application. For example, density-based spatial clustering, ordered point clustering, or Gaussian mixture models can be used to identify clusters.
[0065] The second classification mentioned above, namely the spatiotemporal clustering results obtained by clustering in the spatial dimension, can be understood as dividing the scene set into multiple sets of categories with similar spatiotemporal characteristics after processing the scene set according to its temporal and spatial features using appropriate clustering algorithms. These categories reflect both the temporal regularity of the scenes and their spatial distribution characteristics.
[0066] Step 103: Based on the synchronous back-substitution elimination method, reduce the multiple second categories corresponding to each first category to determine the reduced scenario set. The reduced scenario set is used for the planning and scheduling optimization of the power system.
[0067] This step can be understood as further processing the spatiotemporal clustering results obtained after spatiotemporal clustering across multiple dimensions. A synchronous back-substitution elimination method is used to reduce the number of scenarios while retaining key features, resulting in a relatively concise reduced set of scenarios that reflects the main characteristics of the original data, thus reducing the computational complexity of subsequent analysis and decision-making. In this scenario reduction process, the synchronous back-substitution elimination method primarily relies on probability distance to filter and merge scenarios. This can be understood as comparing the probability relationships between scenarios, gradually eliminating scenarios with less impact on overall features, and merging their probabilities into scenarios with similar probabilities, thereby achieving scenario reduction.
[0068] The aforementioned reduced set of scenarios can be used for the planning and scheduling optimization of the power system. In some optional implementations, the reduced set of scenarios can be used to determine the optimal capacity of hydrogen energy storage devices in the electric-hydrogen-thermal microgrid; it can also be used to optimize the routing of hydrogen pipelines from hydrogen production plants to load centers by classifying regions based on spatial clustering results. In some other optional implementations, the reduced set of scenarios can also be used to determine the intraday scheduling plan for the electric-hydrogen-thermal microgrid; the reduced set of scenarios can make the power system planning more accurate and provide support for intelligent scheduling.
[0069] In the scene reduction method of this application embodiment, the limitations of traditional single-dimensional clustering are overcome by using a spatiotemporal step-by-step clustering mechanism, which reduces the amount of computation while preserving temporal regularity and spatial differences. Multi-dimensional feature fusion improves regional adaptability. In addition, the scene reduction is driven by probability through synchronous back-substitution elimination method, which makes the probability distribution of the scene set highly consistent with the original data, improving the model adaptability while making the scene highly representative.
[0070] Optionally, the step of clustering the scene set based on the time information of each scene in the scene set using a time clustering algorithm includes:
[0071] Obtain the time-series characteristics of the scene set;
[0072] Based on the time series characteristics of the scene set, the scene set is clustered using fuzzy mean clustering and difference determination index.
[0073] In the scenario reduction method of this application embodiment,
[0074] The aforementioned acquisition of the time-series characteristics of the scene set can be understood as extracting key time-related features from the original scene set to construct a dataset containing temporal patterns. For example, taking photovoltaic power output data, historical data is divided by month, and each day is divided into morning, noon, and evening periods, with weather types labeled to form a dataset containing time-series labels.
[0075] The above-mentioned clustering of the scene set based on fuzzy mean clustering and difference determination index can be understood as dividing time subclasses according to natural attributes, such as dividing photovoltaic data by month, then performing fuzzy clustering on each subclass, outputting cluster centers and membership degrees as inner layer optimization, and then calculating I. DBI Value, iterate through k = 2 to K (K = 5 to 12), and select I. DBI The smallest k is used as the optimal cluster number as the outer optimization objective.
[0076] In some alternative implementations, after the time series is pre-divided into scenarios by incorporating natural factors, i.e., after data preprocessing, an improved fuzzy mean clustering algorithm can be used to accurately extract the time series characteristics of the dataset.
[0077] For example, the above data preprocessing can take the photovoltaic power output dataset as an example. First, the historical photovoltaic power output data is divided into 12 groups by month. Then, each day of each month is divided into morning, noon and evening periods. Further subdivision is carried out according to different weather types (such as sunny, cloudy, overcast, etc.). The photovoltaic power output sequences under different scenarios are classified and then the state probability transition matrix is calculated. The search range of the number of scenarios k is set to [2, K]. The value of K should take into account the actual situation of local natural factors and the configured computing resources. The suggested value range of K is 5 to 12.
[0078] Furthermore, the objective function of the improved fuzzy mean clustering algorithm described above can be:
[0079]
[0080] Where c is the number of clusters; m is the convergence factor; u ij For the original vector y j The membership function corresponding to the i-th clustering scenario; d ij For the original vector y j With cluster center v i Euclidean distance.
[0081] In some other alternative implementations, the difference determination index is defined as follows:
[0082]
[0083] In the formula: d (ek) and d (ej) Class C k and class C j The average distance from internal samples to their respective cluster centers; d (vk,vj) For class C k Cluster center v k With class C j Cluster center v j The distance. When the intra-class distance d (ek) and d (ej) The smaller the value, the greater the inter-class distance d. (vk,vj) When I is larger, DBI The smaller the value, the better the time clustering effect;
[0084] In this implementation, after performing fuzzy mean clustering and difference determination, the clustering effectiveness index value I after inner-layer optimization is calculated and recorded. DBI And let k = k + 1; if k ≤ K, then repeat the fuzzy mean clustering and difference determination; if k is greater than K, then take the historical maximum I. DBI The value corresponding to k is the optimal clustering split point, and the optimal clustering result is output.
[0085] In the energy storage configuration method of this application embodiment, the temporal correlation is preserved while using the fuzzy mean clustering partitioning mechanism through I DBI The number of clusters was optimized to improve model adaptability. Furthermore, data preprocessing and iterative optimization reduced computational complexity, thus improving the efficiency of scene compression to some extent.
[0086] Optionally, the time series characteristics include the natural attribute characteristics of the scene set and the state probability transition matrix of the scene set, wherein the natural attribute characteristics include seasonal characteristics, intraday time characteristics, and weather characteristics.
[0087] In the scenario reduction method of this application embodiment,
[0088] There is a certain probability of transition between different application scenarios due to weather changes, probability fluctuations, etc. In order to ensure the time dependence of the scenario sequence and avoid the time sequence break caused by hard partitioning, a state probability transition matrix between scenarios can be constructed to preserve the time sequence continuity. For example, in a scenario where the photovoltaic output of a certain region is at noon on a sunny day, there is still an 80% probability that it will be a sunny afternoon at the next moment.
[0089] In some optional implementations, the state probability transition matrix between scenarios is constructed as follows:
[0090]
[0091] p ab =p(S=b|S-1=a),a,b∈[1,k]
[0092] Where, p ab S represents the probability that the previous day's wind power and solar power output sequences, as well as electricity, hydrogen, and heat load sequences, belong to scenario a, while today's data time series belongs to scenario b; S represents the scenario to which today's time series belongs.
[0093] In this implementation, by combining natural attribute annotation with state transition matrix, the limitations of traditional single time period division are overcome, and multi-dimensional feature extraction and temporal continuity preservation of scene set are realized, providing high-quality input for subsequent time clustering, so as to improve the accuracy and adaptability of scene reduction.
[0094] Optionally, the spatial clustering algorithm is used to cluster the first category along the spatial dimension, including:
[0095] The weights of each type of spatial factor in the first category are determined based on the analytic hierarchy process (AHP).
[0096] Multiple first categories and the weights of various spatial factors in the first categories are input into a self-supervised clustering algorithm for clustering processing;
[0097] Based on the output of the self-supervised clustering algorithm, multiple second categories are determined under each category.
[0098] In the scenario reduction method of this application embodiment,
[0099] The aforementioned analytic hierarchy process (AHP) can be understood as a multi-criteria decision-making method combining qualitative and quantitative analysis. The aforementioned self-supervised clustering algorithm can be understood as a hybrid method combining supervised and unsupervised learning. It generates pseudo-labels by utilizing some known labels or the inherent structure of the data to guide the clustering process. Algorithms such as Deep Cluster, PICA, or DEC can be used. In some optional implementations, the self-supervised K-means clustering algorithm can be employed. For example, geographical location information data and corresponding output data for renewable energy construction such as wind turbines and photovoltaic arrays, as well as geographical and energy consumption data for residential / industrial electricity, hydrogen, and heat loads, are extracted to form data clusters. Then, assuming the number of clusters K equals the number of categories, if one category corresponds to multiple clusters, these clusters are treated as sub-clusters of a larger cluster, thus simplifying the algorithm in finding the optimal K value. Finally, the K value and the label of each cluster are determined based on the categories in the training set. Combined with the label of each sample in the training set, they are sequentially assigned to each cluster.
[0100] In this implementation, the analytic hierarchy process (AHP) fully considers the interrelationships and relative importance of each factor, assigning reasonable weights to each spatial factor. Determining the weights of spatial factors improves the accuracy of scene clustering. Furthermore, using a self-supervised clustering algorithm enhances the adaptability and robustness of the clustering, making the clustering results more consistent with reality.
[0101] Optionally, determining the weights of each spatial factor in the first category based on the analytic hierarchy process includes:
[0102] The various spatial factors are normalized and a weight judgment matrix is constructed.
[0103] Determine the largest eigenvalue and the corresponding eigenvector of the weight judgment matrix;
[0104] If the consistency of the weight judgment matrix meets the first condition, the feature vector is determined as the weight vector, and the weight vector represents the weight of the various spatial factors.
[0105] In the scene reduction method of this application embodiment, the above-mentioned normalization processing of various spatial factors can be understood as using numerical normalization methods to normalize data feature values with different value ranges. The calculation formula is as follows:
[0106]
[0107] In the formula, X i The result is the normalized value; X is the current true value of the data; X max and X min These are the maximum and minimum eigenvalues in the dataset, respectively.
[0108] Further, construct the weight judgment matrix. Determine the state index a. i With a j The correlation between the indicators is compared in pairs, and the result of the comparison of the importance of the i-th indicator and the j-th indicator is expressed as a. ij This allows us to construct a weighted judgment matrix A, which measures the relevance of the judgment indicators. The calculation formula is as follows:
[0109]
[0110] Next, calculate the weights. First, normalize each column of elements in the hierarchy:
[0111]
[0112] Among them, a ij Let i be the element in the i-th row and j-th column of matrix A; q represents the element in the i-th row and j-th column after normalization; q is the matrix order.
[0113] Then, summing each row yields the eigenvector of the element in the i-th row:
[0114]
[0115] Finally, normalize the summed eigenvector Wi:
[0116]
[0117] Where Wri is the true weight of the element in the i-th row after normalization.
[0118] The first condition mentioned above can be understood as the consistency verification condition of the weight judgment matrix. The analytic hierarchy process relies on pairwise comparisons of the importance of factors. If there is a logical contradiction in the judgment matrix, such as A being more important than B, B being more important than C, but C being more important than A, it will cause the weight calculation to fail. Consistency verification can eliminate such contradictions through quantitative indicators.
[0119] In some alternative implementations, consistency checks can be performed on the matrix to ensure the evaluation results are reasonable and reliable and to verify the consistency of the importance of each factor. The consistency check index is calculated as follows:
[0120]
[0121] Among them, C R R is a consistency verification indicator. I λ is a random consistency index; max It is the largest eigenvalue; (AW) i Let be the i-th element of the vector, where AW is the product of the judgment matrix A and the weight W. If C R A value ≤0.15 indicates good consistency of the weight judgment matrix, and λ is acceptable. max The corresponding feature vectors are used as the weight vectors for sorting.
[0122] In this implementation, compared with traditional subjective assignment, the analytic hierarchy process (AHP) and consistency check improve the objectivity and rationality of the weight results. Reasonable weights quantify the contribution of spatial factors, thereby improving the accuracy of clustering. In addition, consistency check ensures that the weight logic is self-consistent, avoiding clustering failure caused by contradictory judgments, and further improving the accuracy of scenario reduction.
[0123] Optionally, the step of inputting multiple first categories and the weights of various spatial factors in the first categories into a self-supervised clustering algorithm for clustering processing includes:
[0124] Based on the weights of various spatial factors in each of the first categories, the scenes in each of the first categories are divided into multiple categories, and the following steps are repeated until the second condition is met:
[0125] Obtain the total number of categories and the centroid of each category;
[0126] The scenes are reclassified based on the distance between each scene and the centroid in each category;
[0127] Update the total number of categories and the centroid of each category.
[0128] In the energy storage configuration method of this application embodiment, the second condition mentioned above can be understood as the basis for determining the termination of the iteration; the centroid acquisition method for each category mentioned above may include:
[0129]
[0130] Where Ci is the category to which the current sample belongs, and x is the i-th sample.
[0131] In some other alternative real-time methods, the following distance calculation method can be used based on a given centroid μ and sample x to avoid the shift of the training focus towards the class with a high number of samples due to differences between different classes of samples. The method is as follows:
[0132]
[0133] Among them, V i V represents the number of samples in the category corresponding to centroid i in the training set; max D represents the number of samples with the largest number of samples in all categories in the training set; D represents the sample dimension in the dataset.
[0134] The second condition mentioned above can be based on the training sample D. l The accuracy of the prediction results under adjacent cycles is judged and analyzed, and the judgment method is as follows:
[0135] AC(D l ) i <AC(D) l ) i-1
[0136] In the formula, AC(D) l ) i Let be the current centroid prediction accuracy, and be the centroid accuracy calculated in the previous round. If AC(D) is satisfied... l ) i <AC(D) l ) i-1 This indicates that due to the influence of intra-cluster noise, the centroids obtained in the new round of calculation will reduce the algorithm performance, meet the condition for stopping iteration, and finally obtain spatiotemporal clustering results with multiple different spatiotemporal dimensions.
[0137] In this implementation, clustering is performed through mechanisms such as weight guidance, dynamic adjustment, and supervised convergence, which improves the accuracy of scene clustering in the spatiotemporal dimension and provides high-quality input for subsequent scene reduction, thereby improving the accuracy and efficiency of subsequent system planning and scheduling.
[0138] Furthermore, in some optional implementations, reducing the multiple second categories corresponding to each first category based on the synchronous back-substitution elimination method to determine the reduced scene set may include the following steps:
[0139] Using the original scene set C i Let C' represent a set of Ni preserved scenes. i 'represents N' i A set of deletion scenarios. Determine set C. i The initial probability p of the retained scenario s 1 / N i set C′ i The initial probability p′ of the deletion scenario s 1 / N′ i ;
[0140] Furthermore, record the iteration number k, and at each iteration, eliminate a scenario s′ that satisfies the following formula. v Add to the deletion scene set C′ i middle;
[0141]
[0142] In the formula, p s and p′ s s v and s′ v In scene set C i and C′ i The probability of it.
[0143] Change the original number of scenes Ni = Ni-1 and the number of scenes deleted N′ i =N′ i +1, filter out the distance to scene s′ using the following formula v Recent Scenes v :
[0144] s ν =argmin[p s p' s d(s ν ,s ν′ )]
[0145] Furthermore, the changed and eliminated scenarios s′ v Recent Scenes v The probability p s =p′ s +p s To ensure the preservation of the scene set C i The sum of the probabilities of all scenarios in the set remains 1, and the probability of each scenario in the deleted scenario set is updated to 1 / N′. i Let the number of iterations be k = k + 1.
[0146] Repeat the loop to step two, iterating until the scene set C is retained. i If the number of intermediate scenes meets the target number of scenes, or if the number of iterations k is greater than or equal to the maximum number of iterations K, the iteration calculation is terminated. The maximum number of iterations K needs to take into account the size of the dataset and the amount of computing resources, and is usually in the range of 200 to 500.
[0147] Furthermore, output typical scenarios for all clusters.
[0148] Considering that only one typical scenario is retained in the scenario set of each cluster, the confidence probability of the typical scenario can be calculated as follows:
[0149] p Ci =N i / n
[0150] In the formula, Let Ni represent the confidence probability of a typical scene in the i-th cluster scene set Ci; Ni is the number of scenes Ci in the set; and n is the number of scenes in the original scene set S.
[0151] See Figure 2 , Figure 2 This is a structural diagram of a scene reduction device provided in another embodiment of this application.
[0152] like Figure 2 As shown, the scene reduction device 200 includes:
[0153] The first clustering module 201 is used to cluster the scene set based on the time information of each scene in the scene set using a time clustering algorithm to obtain multiple first categories. The time dimensions corresponding to different first categories are different. The scene set is a scene set of a power system.
[0154] The second clustering module 202 is used to perform spatial dimension clustering on the first category based on the spatial clustering algorithm to obtain multiple second categories under each category, and the spatial dimensions corresponding to different second categories are different.
[0155] The reduction module 203 is used to reduce the multiple second categories corresponding to each first category based on the synchronous back substitution elimination method to determine the reduced scenario set, which is used for the planning and scheduling optimization of the power system.
[0156] Optionally, the first clustering module includes:
[0157] The acquisition module is used to acquire the time-series characteristics of the scene set;
[0158] The third clustering module is used to cluster the scene set based on the time series characteristics of the scene set, using fuzzy mean clustering and difference determination index.
[0159] Optionally, the time series characteristics include the natural attribute characteristics of the scene set and the state probability transition matrix of the scene set, wherein the natural attribute characteristics include seasonal characteristics, intraday time characteristics, and weather characteristics.
[0160] Optionally, the second clustering module includes:
[0161] The first determining module is used to determine the weights of various spatial factors in each of the first categories based on the analytic hierarchy process.
[0162] The input module is used to input multiple first categories and the weights of various spatial factors in the first categories into a self-supervised clustering algorithm for clustering processing;
[0163] The output module is used to determine multiple second categories under each category based on the output of the self-supervised clustering algorithm.
[0164] Optionally, the first determining module includes:
[0165] The normalization module is used to normalize the various spatial factors and construct a weight judgment matrix;
[0166] The second determining module is used to determine the largest eigenvalue and the corresponding eigenvector of the weight judgment matrix.
[0167] The third determining module is used to determine the feature vector as a weight vector when the consistency of the weight judgment matrix meets the first condition, and the weight vector represents the weight of the various spatial factors.
[0168] Optionally, the input module includes:
[0169] The iterative module is used to divide the scene in each first category into multiple categories according to the weights of various spatial factors in each first category, and repeat the following steps until the second condition is met:
[0170] Obtain the total number of categories and the centroid of each category;
[0171] The scenes are reclassified based on the distance between each scene and the centroid in each category;
[0172] Update the total number of categories and the centroid of each category.
[0173] See Figure 3 , Figure 3 This is a structural diagram of an electronic device provided in another embodiment of this application, such as... Figure 3 As shown, the electronic device includes: a processor 301, a communication interface 302, a communication bus 304, and a memory 303, wherein the processor 301, the communication interface 302, and the memory 303 interact with each other through the communication bus 304.
[0174] The memory 303 is used to store computer programs; the processor 301 is used to cluster the scene set according to the time information of each scene in the scene set based on a time clustering algorithm to obtain multiple first categories, and the time dimensions corresponding to different first categories are different. The scene set is a scene set of a power system.
[0175] Based on the spatial clustering algorithm, the first category is clustered in terms of spatial dimension to obtain multiple second categories under each category. The spatial dimensions corresponding to different second categories are different.
[0176] The synchronous back-substitution elimination method is used to reduce the number of second categories corresponding to each first category to determine the reduced scenario set, which is used for the planning and scheduling optimization of the power system.
[0177] The communication bus 304 mentioned in the above electronic device can be a Peripheral Component Interconnect (PCT) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus 304 can be divided into an address bus, a data bus, a control bus, etc. For ease of identification, it is represented by only one thick line in the figure, but this does not indicate that there is only one bus or one type of data.
[0178] Communication interface 302 is used for communication between the aforementioned terminal and other devices.
[0179] The memory 303 may include random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Optionally, the memory 303 may also be at least one storage device located remotely from the aforementioned processor 301. The aforementioned processor 301 may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it may also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0180] This application also provides a computer-readable storage medium storing a computer program. When executed by a processor, the computer program implements the various processes of the above-described scenario reduction method embodiments and achieves the same technical effects. To avoid repetition, it will not be described again here. The computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0181] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0182] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of this application.
[0183] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.
Claims
1. A method for reducing the scale of an electro-hydrogen-thermal microgrid scenario, characterized in that, The method includes: Based on the time information of each scenario in the scenario set, the scenario set is clustered using a time clustering algorithm to obtain multiple first categories. Different first categories correspond to different time dimensions. The scenario set is a scenario set of a power system. Based on the spatial clustering algorithm, the first category is clustered in terms of spatial dimension to obtain multiple second categories under each category. The spatial dimensions corresponding to different second categories are different. The synchronous back-substitution elimination method is used to reduce the multiple second categories corresponding to each first category to determine the reduced scenario set, which is used for the planning and scheduling optimization of the power system.
2. The method according to claim 1, characterized in that, The step of clustering the scene set based on the time information of each scene in the scene set using a time clustering algorithm includes: Obtain the time-series characteristics of the scene set; Based on the time series characteristics of the scene set, the scene set is clustered using fuzzy mean clustering and difference determination index.
3. The method according to claim 2, characterized in that, The time series characteristics include the natural attribute characteristics of the scene set and the state probability transition matrix of the scene set. The natural attribute characteristics include seasonal characteristics, intraday time characteristics, and weather characteristics.
4. The method according to claim 1 or 2, characterized in that, The spatial clustering algorithm is used to cluster the first category in terms of spatial dimension, including: The weights of each type of spatial factor in the first category are determined based on the analytic hierarchy process. Multiple first categories and the weights of various spatial factors in the first categories are input into a self-supervised clustering algorithm for clustering processing; Based on the output of the self-supervised clustering algorithm, multiple second categories are determined under each category.
5. The method according to claim 4, characterized in that, The determination of the weights of each spatial factor in the first category based on the analytic hierarchy process includes: The various spatial factors are normalized and a weight judgment matrix is constructed. Determine the largest eigenvalue and the corresponding eigenvector of the weight judgment matrix; If the consistency of the weight judgment matrix meets the first condition, the feature vector is determined as the weight vector, and the weight vector represents the weight of the various spatial factors.
6. The method according to claim 4, characterized in that, The step of inputting multiple first categories and the weights of various spatial factors in the first categories into a self-supervised clustering algorithm for clustering processing includes: Based on the weights of various spatial factors in each of the first categories, the scenes in each of the first categories are divided into multiple categories, and the following steps are repeated until the second condition is met: Obtain the total number of categories and the centroid of each category; The scenes are reclassified based on the distance between each scene and the centroid in each category; Update the total number of categories and the centroid of each category.
7. A scene reduction device, characterized in that, The device includes: The first clustering module is used to cluster the scene set based on the time information of each scene in the scene set using a time clustering algorithm to obtain multiple first categories. The time dimensions corresponding to different first categories are different. The scene set is a scene set of the power system. The second clustering module is used to perform spatial dimension clustering on the first category based on the spatial clustering algorithm, so as to obtain multiple second categories under each category, and the spatial dimensions corresponding to different second categories are different. The reduction module is used to reduce the multiple second categories corresponding to each first category based on the synchronous back substitution elimination method, and determine the reduced scenario set. The reduced scenario set is used for the planning and scheduling optimization of the power system.
8. The apparatus according to claim 7, characterized in that, The first clustering module includes: The acquisition module is used to acquire the time-series characteristics of the scene set; The third clustering module is used to cluster the scene set based on the time series characteristics of the scene set, using fuzzy mean clustering and difference determination index.
9. An electronic device, characterized in that, It includes a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the scene reduction method as described in any one of claims 1 to 6.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the steps of the scene reduction method as described in any one of claims 1 to 6.