Substation model generation methods, devices, electronic equipment and storage media

By simulating rigid body motion in a gravity field environment using substation description files and force-directed graph layout algorithms, the positions of equipment nodes are automatically adjusted, solving the problem of non-standard layout in substation model generation and realizing automated model generation and improved standardization.

CN123069682APending Publication Date: 2026-11-10BEIJING HEXINRUITONG POWER TECH +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611272287.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-20
Publication Date
2026-11-10

AI Technical Summary

Technical Problem

In the existing process of generating substation models, manually drawn models have problems such as non-standard layout, inconsistent element styles, and large differences in spacing, making it difficult to form a unified and standardized output result.

Method used

The equipment nodes and their relationships are determined based on a pre-built substation description file. The rigid body motion and collision response of the equipment nodes are simulated by combining a force-directed graph layout algorithm and a gravity field environment. The positions of the equipment nodes are iteratively adjusted to obtain the target positions, and a substation model is generated based on the target positions and connections.

Benefits of technology

The system enables automated generation of substation models, improving the regularity of model layout, consistency of node arrangement, and standardization of wiring, thereby enhancing the standardization of model generation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123069682A_ABST
    Figure CN123069682A_ABST
Patent Text Reader

Abstract

This application discloses a method, apparatus, electronic device, and storage medium for generating substation models, belonging to the field of substation monitoring. The method includes determining the equipment nodes of the substation and the relationships between these nodes based on a pre-constructed substation description file. Each equipment node is a graphical node with a graphical outline corresponding to a physical entity node, possessing preset geometric and dynamic information. A weight value is determined for each equipment node based on its bay type. Based on the weight value of each equipment node, and combined with a force-directed graph layout algorithm, the rigid body motion and collision response between equipment nodes under a gravity field are simulated to determine the target positions of the equipment nodes. Based on the target positions and relationships between the equipment nodes, target paths between them are determined, and a substation model is generated based on the target positions and paths. This method enables automated generation of substation models, significantly improving the standardization of model generation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of substation monitoring technology, specifically to a substation model generation method, device, electronic equipment, and storage medium. Background Technology

[0002] Substations are key nodes in power systems that realize voltage transformation, power distribution, and control. Their operating status can be presented through the substation model in the substation monitoring system. The substation model can graphically display the topological connection relationship of primary equipment and electrical logic nodes, which is the basis for dispatchers to perform remote operations, fault diagnosis, and system analysis.

[0003] The construction of substation models typically relies on manual drawing to configure elements and topological relationships. Due to the diverse types of equipment, complex bay types, and intricate connections within a substation, manually drawn models often exhibit variations in layout specifications, element styles, and bay arrangements. Therefore, improving the standardization of substation model generation is a pressing technical challenge in this field. Summary of the Invention

[0004] This invention provides a method, apparatus, electronic device, and storage medium for generating substation models, aiming to improve the standardization of substation model generation.

[0005] Firstly, a method for generating a substation model is provided, including the following steps: Based on the pre-constructed substation description file, the equipment nodes of the substation and the relationships between the equipment nodes are determined; the equipment nodes are graphic nodes with graphic outlines corresponding to physical entity nodes, and have preset geometric and dynamic information. The weight value of each device node is determined according to the bay type to which each device node belongs. The bay is used to characterize the electrical circuit unit in the substation. The bay type includes main transformer bay, bus bay and outgoing line bay. The weight value of each device node under the same bay type is the same, and the weight value corresponding to different bay types is different. Based on the weight value of each device node and combined with the force-guided graph layout algorithm, the rigid body motion and collision response between the device nodes under a gravitational field environment are simulated to determine the target position of the device node. Based on the target location of the device nodes and the relationship between the device nodes, the target path between each device node is determined, and the substation model is generated based on the target location and the target path.

[0006] In some embodiments, determining the target position of a device node by simulating rigid body motion and collision response between device nodes under a gravitational field environment based on the weight value of each device node and in conjunction with a force-directed graph layout algorithm includes: The device nodes are prioritized according to their weight values. According to the order of priority from high to low, for multiple device nodes of the first priority, combined with the force-directed graph layout algorithm, the rigid body motion and collision response between the device nodes of the first priority under the gravity field environment are simulated, and the position of each device node of the first priority is iteratively adjusted until the change in position between two adjacent positions of each device node of the first priority is less than a preset threshold, so as to obtain the initial position of each device node of the first priority. For device nodes of second priority and below, the rigid body motion and collision response between the device node and the device node with a determined initial position are simulated under a gravity field environment, and the position of the device node is iteratively adjusted until the change in position between two adjacent positions of all the device nodes is less than a preset threshold, so as to obtain the target position of the device node.

[0007] In some embodiments, the dynamic information includes rigid body dynamic parameters and gravitational field intensity, wherein the rigid body dynamic parameters include at least one of the coefficient of restitution, friction, and impulse; for device nodes of second priority and below, in conjunction with the force-directed graph layout algorithm, the rigid body motion and collision response between the device node and a device node with a determined initial position under a gravitational field environment are simulated, and the position of the device node is iteratively adjusted until the change in position between two adjacent positions of all device nodes is less than a preset threshold, thereby obtaining the target position of the device node, including: Based on the weight values ​​of interconnected device nodes, an attractive force is applied between interconnected device nodes; based on the spatial distance between adjacent device nodes, a repulsive force is applied between adjacent device nodes, wherein the graphic outer contour coverage areas of the two device nodes do not have the graphic outer contour coverage areas of other device nodes. In a gravitational field environment, the physics engine iteratively calculates the velocity and position of each device node based on the gravitational and repulsive forces of each device node, and performs collision detection. The positions of the device nodes are adjusted according to the collision response, and the steps of applying attraction between interconnected device nodes based on the weight values ​​of interconnected device nodes and applying repulsion between adjacent device nodes based on the spatial distance between adjacent device nodes are repeated until the change in position of all device nodes between two consecutive times is less than a preset threshold, thereby obtaining the target position of the device nodes.

[0008] In some embodiments, the collision detection includes: The bounding box detection algorithm is used to detect the projection overlap between the device nodes to determine that two device nodes have collided.

[0009] In some embodiments, after obtaining the target location of the device node, the method further includes: Based on the weight values ​​of the device nodes, the target positions of the device nodes are adjusted in the horizontal and vertical directions to form the corrected target positions. The step of determining the target path between each device node based on the target location of the device node and the relationship between the device nodes, and generating the substation model based on the target location and the target path, includes: Based on the corrected target location and the relationship between the device nodes, the target path between each device node is determined; The substation model is generated based on the corrected target location and the target path.

[0010] In some embodiments, the step of performing horizontal and vertical layout corrections on the target position of the device node based on the weight value of the device node to form a corrected target position includes: Based on the positional and connection relationships of the device nodes within each interval at the target location, determine the number of steps and the hierarchical structure of the steps; The contact position of the device node on the steps is determined by a collision detection algorithm; Based on the geometric information and dynamic information of each device node, the motion state of the device node on the steps is determined; The contact position is adjusted according to the motion state and weight value of the device node to obtain the corrected target position of the device node.

[0011] In some embodiments, determining the equipment nodes of the substation and the relationships between the equipment nodes based on a pre-built substation description file includes: Load and parse the substation description file to obtain the primary equipment logical nodes of the substation and the logical node relationships between the primary equipment logical nodes; Map the primary device logical node to the device node; The logical node relationships are mapped to the relationships between the device nodes.

[0012] In some embodiments, the method for constructing the substation description file includes: The pre-acquired substation configuration description file is verified, cleaned, and standardized to obtain basic substation information, which includes the substation's wiring method, bay type, and bay quantity. The basic information of the substation is configured to obtain configuration information; Obtain a preset standard interval template library, which includes template files for each of the interval types; Based on the configured wiring method, the interval type, and the number of intervals, the corresponding template file is copied from the standard interval template library to generate the interval and the primary device logic node within each interval; Based on the interval and the primary equipment logical nodes within each interval, a global substation topology connection relationship is established, and the substation description file is determined based on the global substation topology connection relationship.

[0013] In some embodiments, determining the target path between the device nodes based on the target location of the device nodes and the relationship between the device nodes includes: Based on the target location of the device nodes and the relationship between the device nodes, the A* optimization algorithm is used to determine the target path between the device nodes.

[0014] Secondly, a substation model generation device is also provided, comprising: The file parsing module is used to determine the equipment nodes of the substation and the relationships between the equipment nodes based on the pre-built substation description file; the equipment nodes are graphic nodes with graphic outlines corresponding to physical entity nodes, and have preset geometric and dynamic information. The weight determination module is used to determine the weight value of each device node according to the bay type to which each device node belongs. The bay is used to characterize the electrical circuit unit in the substation. The bay type includes main transformer bay, bus bay and outgoing line bay. The weight value of each device node is the same under the same bay type, and the weight value is different for different bay types. The location determination module is used to determine the target location of the device node by simulating the rigid body motion and collision response between the device nodes under a gravity field environment based on the weight value of each device node and the force-guided graph layout algorithm. The path determination module is used to determine the target path between the device nodes based on the target location of the device nodes and the relationship between the device nodes, and to generate the substation model based on the target location and the target path.

[0015] Thirdly, an electronic device is also provided, comprising: Memory and processor; The memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions. When the computer-executable instructions are executed by the processor, they implement the steps of the substation model generation method as described in the first aspect and any one of the claims.

[0016] Fourthly, a computer-readable storage medium is also provided, storing computer-executable instructions that, when executed by a processor, implement the steps of the substation model generation method as described in the first aspect and any one of the claims.

[0017] The substation model generation method of this application automatically determines equipment nodes and their relationships based on a pre-built substation description file, improving the arbitrariness introduced by manual identification and drawing. Furthermore, it assigns weight values ​​based on the bay type to which the equipment nodes belong, and combines a force-directed graph layout algorithm with simulations of rigid body motion and collision response, enabling equipment nodes of different bay types to obtain reasonable and stable spatial positions during iterative adjustments, effectively improving node overlap and layout chaos. On this basis, it determines the target path based on the relationship between the target location and the equipment nodes, improving the clarity and regularity of the connections. Overall, this scheme can achieve automated generation of substation models, significantly improving the standardization of model generation. Attached Figure Description

[0018] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying 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.

[0019] Figure 1 This is a schematic diagram of the overall process of the substation model generation method according to an embodiment of this application; Figure 2 This is a schematic diagram illustrating a specific example of the substation model generation method according to an embodiment of this application. Figure 3 A schematic diagram illustrating an example of a substation model generated by the substation model generation method according to an embodiment of this application. Figure 4 This is a schematic diagram of the substation model generation device according to an embodiment of this application.

[0020] Explanation of reference numerals in the attached figures: 401 - File parsing module; 402 - Weight determination module; 403 - Location determination module; 404 - Path determination module. Detailed Implementation

[0021] 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, and 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.

[0022] In the description of this application, it should be understood that the terms "center," "longitudinal," "lateral," "length," "width," "thickness," "upper," "lower," "front," "rear," "left," "right," "vertical," "horizontal," "top," "bottom," "inner," and "outer," etc., indicating orientation or positional relationships based on the orientation or positional relationships shown in the accompanying drawings, are used only for the convenience of describing this application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this application. Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include one or more of the stated features. In the description of this application, "a plurality of" means two or more, unless otherwise explicitly specified.

[0023] "A and / or B" includes the following three combinations: A only, B only, and a combination of A and B.

[0024] The use of "applies to" or "configured to" in this application implies open and inclusive language, which does not exclude the applicability to or configuration to devices performing additional tasks or steps. Additionally, the use of "based on" implies openness and inclusivity, because processes, steps, calculations, or other actions "based on" one or more of the stated conditions or values ​​may in practice be based on additional conditions or values ​​beyond those stated.

[0025] In this application, the term "exemplary" is used to mean "used as an example, illustration, or description." Any embodiment described as "exemplary" in this application is not necessarily to be construed as being more preferred or advantageous than other embodiments. The following description is provided to enable any person skilled in the art to make and use this application. Details are set forth in the following description for purposes of explanation. It should be understood that those skilled in the art will recognize that this application can be made without using these specific details. In other instances, well-known structures and processes are not described in detail to avoid obscuring the description of this application with unnecessary detail. Therefore, this application is not intended to be limited to the embodiments shown, but is consistent with the broadest scope of the principles and features disclosed in this application.

[0026] Substations are crucial nodes in power systems, responsible for voltage transformation, power distribution, and control. Their operational status is presented through substation models within substation monitoring systems. Substation models typically graphically display the topological connections of primary equipment and electrical logic nodes, serving as the foundation for dispatchers to perform remote operations, fault diagnosis, and system analysis. Currently, most substation monitoring system displays still rely on conventional manual drawing methods for configuring graphic elements and model relationships, as well as topology construction. This manual drawing method has significant drawbacks, such as high workload, long processing time, susceptibility to errors, difficulty in modification, and poor standardization. Furthermore, it demands a high level of technical skill from the drawing personnel. In particular, due to the diverse types of equipment, complex bay types, and intricate connections within substations, manually drawn models often exhibit significant differences in layout specifications, graphic element styles, and bay arrangements, making it difficult to achieve a unified and standardized output. Therefore, improving the standardization of substation model generation is a pressing technical problem that needs to be addressed in this field.

[0027] In view of this, embodiments of this application provide a substation model generation method, which determines equipment nodes and connections based on a pre-constructed substation description file, determines weight values ​​based on the interval type to which each equipment node belongs, combines a force-directed graph layout algorithm and simulates rigid body motion and collision response between equipment nodes under a gravity field environment, iteratively adjusts the positions of equipment nodes to obtain target positions, and then determines target paths and generates a substation model based on the target positions and connections, thereby achieving automated generation of substation models, improving the layout regularity, node arrangement consistency and connection standardization of the model, and thus improving the standardization of model generation, so as to solve at least one of the above-mentioned technical problems.

[0028] Please see Figure 1 , Figure 1 This is a schematic diagram of the overall process of the substation model generation method according to an embodiment of this application. The method specifically includes the following steps: Step S101: Based on the pre-built substation description file, determine the equipment nodes of the substation and the relationships between the equipment nodes.

[0029] Specifically, the substation description file is an SSD (System Specification Description, Intelligent Substation Description Model) file. The SSD file describes the primary equipment logical nodes of the substation and the logical node relationships between them. The logical node relationships between primary equipment logical nodes represent the electrical connection relationships between them. Equipment nodes are graphical nodes with graphical outlines corresponding to physical entity nodes, and they have preset geometric and dynamic information.

[0030] In some embodiments, step S101 is implemented in the following manner: Load and parse the substation description file to obtain the primary equipment logical nodes of the substation and the logical node relationships between them; map the primary equipment logical nodes to equipment nodes; and map the logical node relationships to the relationships between equipment nodes.

[0031] Specifically, by loading and parsing the substation description file, the system analyzes the defined primary equipment logical nodes and their electrical connections, treating these connections as edges. The attributes of primary equipment logical nodes can include equipment type, voltage level, bay size, etc.; edge attributes can include current capacity, transmission direction, etc. Mapping the primary equipment logical nodes and their attributes to a two-dimensional space generates corresponding equipment nodes, each carrying information such as type, voltage level, and bay size from the original primary equipment logical node. Simultaneously, the electrical connections between primary equipment logical nodes are mapped to relationships between equipment nodes, i.e., lines, with corresponding attributes such as current capacity and transmission direction recorded for each line. Equipment nodes map to various devices in the substation, and lines are represented by two-dimensional arrays with (X-axis, Y-axis) coordinates. This provides the basic graphical elements and their initial relationships required for subsequent layout and path planning.

[0032] For example, a mapping table between equipment types and geometric parameters can be pre-established. The mapping table at least includes the default width, height, and shape (rectangular or circular) corresponding to the equipment type (such as circuit breaker, disconnector, busbar). When mapping a primary equipment logical node to a device node, the mapping table is queried according to the equipment type field of the primary equipment logical node to assign the corresponding geometric size and shape to the device node.

[0033] In some embodiments, the method for constructing a substation description file includes: Step 1: Verify, clean, and standardize the pre-acquired substation configuration description file to obtain the basic information of the substation.

[0034] Specifically, the substation configuration description file is an SCD (Substation Configuration Description) file. The SCD file is an XML format file defined in the IEC 61850 standard for describing the complete configuration of a substation. This file contains the primary equipment structure, secondary equipment model, communication network configuration, and the relationships between them. In this embodiment, the SCD file is used as raw input, loaded into memory, and then read from memory and preprocessed to extract basic substation information for subsequent construction of the substation description file.

[0035] For example, basic substation information includes the substation's wiring method, bay type, and number of bays. The wiring method represents the electrical connection topology of the substation's main busbar, determining how the bays are physically connected and operated. The bay type represents the specific type of electrical circuit unit. The number of bays represents the number of electrical circuit units. Verification means using tools that support verification specifications (such as a self-developed SCD verification tool) to check whether the substation configuration description file conforms to the prescribed structure and syntax, ensuring that the substation configuration description file has no formatting errors, missing tags, or mismatches. Cleaning means traversing the data in the substation configuration description file, removing duplicate records (such as duplicate equipment configuration information or connection relationship descriptions), and checking and processing invalid or erroneous data (such as checking whether the voltage level conforms to common standard values), correcting or marking obviously unreasonable values. Standardization means unifying the data format, naming conventions, and encoding methods to ensure that all related data are represented consistently. For example, for equipment names, a unified naming convention is specified, converting names with different capitalization or abbreviations to a standard format or marking them; date, time, and other data are also standardized according to a specific format to facilitate automatic association between primary and secondary equipment bays. After the above preprocessing, standardized basic information about the substation can be obtained.

[0036] Step two: Configure the basic information of the substation to obtain the configuration information.

[0037] Specifically, the pre-processed basic substation information can be stored in JSON file format, and specific data such as substation name, voltage level, wiring method, bay type, number of bays, and bay equipment can be filled in as required. Alternatively, relevant specific data can be manually entered through a dedicated configuration interface, and then the input information can be serialized and saved to a database or a specific file for subsequent operations.

[0038] Step 3: Obtain the preset standard interval template library, which includes template files for each interval type.

[0039] Specifically, the standard bay template library is pre-created based on the actual needs of substations and relevant standards, and is written in XML format. The library contains template files for different bay types (e.g., line bays, bus bays, etc.). Each template file defines the type, quantity, internal numbering, and composition of primary equipment within that bay, clarifies the connection relationships of primary equipment within the bay (either by drawing connection diagrams or describing the connection order and method using text), specifies the paths to secondary equipment, records the location of the secondary equipment model files for each bay, and determines the mapping relationship between primary and secondary equipment (e.g., which primary equipment corresponds to which logical nodes of secondary equipment). The template files are saved to a designated directory for easy retrieval.

[0040] Step 4: Based on the configured wiring method, bay type, and number of bays, copy the corresponding template file from the standard bay template library to generate the bays and the primary device logic nodes within each bay.

[0041] Specifically, the system reads information from the configuration file, including substation wiring methods, bay types, and the number of bays (i.e., a JSON file). Based on the wiring method, it determines which types of bays need to be created and the quantity of each type. It iterates through the bay types, copying the standard bay template file a corresponding number of times based on the bay quantity to quickly construct new bays and basic primary equipment information. It generates primary equipment connection relationships within each bay based on the connection relationships defined in the template, adding unconnected terminals to the unconnected terminal queue and busbar connection points to the busbar connection relationship queue. It generates primary and secondary equipment mapping relationships according to the primary and secondary equipment mapping relationships in the template, combined with the actual substation conditions. It processes the primary equipment connection relationships between bays under different wiring methods, such as related bay connection relationships, busbar connection relationships, and transformer connection relationships, generating the overall substation topology connection relationships.

[0042] For example, after copying the standard interval template file the corresponding number of times according to the number of intervals, a unique identifier for each device node can be automatically generated according to the full path name structure of the power grid, substation, and equipment within the substation, as well as the full path name structure of transmission and distribution lines and equipment directly belonging to the power grid. Fields such as substation name, voltage level, and interval number are obtained from the configuration information, and it is ensured that the names of all device nodes within the same substation are not duplicated.

[0043] Step 5: Establish the substation topology connection relationship based on the bay and the primary equipment logical nodes within each bay, and determine the substation description file based on the substation topology connection relationship.

[0044] Specifically, based on the substation's wiring configuration (such as single busbar, double busbar, bridge connection, etc.), connection processing can be performed between different types of bays. This includes processing connections between related bays (e.g., the connection between a transformer bay and a busbar bay), connections between each bay and the busbar, and connections between the high and low voltage sides of the transformer bay. In this way, according to electrical principles, the primary equipment logic nodes within all bays and their inter-bay connections can be merged and connected into a complete station-wide topology connection. This station-wide topology connection includes path information between all primary equipment logic nodes, as well as attributes such as connection direction and voltage level.

[0045] A dedicated substation description file verification tool or a verification program written according to the format specifications and semantic requirements of the substation description file can be used to check the syntax of the entire substation topology connection relationship (e.g., whether the labels are correctly closed, whether the attributes meet the requirements, etc.) and verify the rationality of the semantics (e.g., whether the connection relationship of primary equipment conforms to electrical principles, whether the mapping relationship between primary and secondary equipment is correct, etc.). If the verification passes, the entire substation topology connection relationship is saved as a substation description file and saved to a specified storage location. The file name can be named according to the substation name, generation time, and other information for easy management and retrieval. If the verification fails, the relevant configuration and generation process are checked, the problems are corrected, and the verification is performed again.

[0046] The above-described solution, through automated preprocessing, template matching, and topology generation, directly converts the primary equipment logical nodes and their electrical connections described in the substation configuration description file into visualized equipment nodes and connections, improving the tedious process of manual reading and data entry. The entire conversion process is based on unified preprocessing rules and a standard bay template library, contributing to consistency in data format, equipment naming, and connection relationship expression among substation description files generated from different substations, and mitigating drawing errors and discrepancies caused by personal habits or oversights. The equipment nodes and connections mapped from the substation description file already possess accurate electrical attributes (such as equipment type, voltage level, bay size, current capacity, and transmission direction), providing reliable foundational data for subsequent processing, thus contributing to the accuracy and standardization of the final substation model. Furthermore, the entire process requires no manual intervention; for multiple substations or a large number of bays, corresponding substation description files and subsequent models can be generated quickly in batches, significantly improving work efficiency.

[0047] Step S102: Determine the weight value of each device node according to the interval type to which each device node belongs.

[0048] For example, a bay is used to characterize an electrical circuit unit in a substation. Specifically, a bay refers to an independent and fully functional electrical circuit unit within a substation, rather than a macroscopic division of the entire power network. It is composed of devices such as circuit breakers, disconnectors, instrument transformers, and surge arresters, acting like an independent small electrical module with control and protection devices. The core purpose of setting up bays is to achieve segmented control and protection. Disconnecting a bay during maintenance will not affect the normal operation of other parts of the substation. Simultaneously, safety regulations define the safe scope for live-line work, preventing personnel from accidentally entering energized areas. Bay types include main transformer bays, busbar bays, and outgoing line bays. Each equipment node within the same bay type has the same weight value, while different bay types correspond to different weight values. The weight value is used to reflect the importance of equipment bays during subsequent layout. For example, the weight values ​​of main transformer bays, busbar bays, and outgoing line bays decrease sequentially. The weight value of the main transformer bay is set to 90%, the busbar bay to 60%, and the outgoing line bay to 30%. Other values ​​can also be set, depending on the specific requirements. The weight value can affect the gravity of the equipment nodes in the simulated gravity field environment. The larger the weight value, the greater the gravity.

[0049] The main transformer bay refers to the bay connecting the main wiring of the transformer. Depending on the level of the connected equipment, it can be divided into primary main transformer bays and secondary main transformer bays. The main function of the main transformer bay is to achieve interface conversion between different voltage levels. Depending on the characteristics of the connected equipment, interface conversion can be achieved using different types of disconnect switches, such as double-sided disconnect switches and grounding switches. The outgoing line bay refers to the parallel outgoing line bays and single-circuit outgoing line bays connecting the low-voltage side of the transformer. The main function of the outgoing line bay is to ensure stable operation at the interface with the low-voltage power grid. In the distribution system, the outgoing line bay usually adopts a bottom-opening structure, and its outgoing terminals can adopt a plug-in structure or a fixed screw connection. The busbar bay (usually referring to the busbar equipment bay) is an independent electrical functional unit within the substation specifically used to connect and monitor the busbars and ensure their safe operation.

[0050] Specifically, device nodes belonging to the same interval type are grouped into the same node set, different weight values ​​are set for different interval types, and all device nodes under the same interval type are assigned the same weight value.

[0051] In this way, each device node has a weight value corresponding to its interval type. The larger the weight value of the interval, the higher the priority of its placement. This weight value will be used in subsequent steps for gravity calculation, repulsion adjustment, and rigid body motion parameter setting in the influence-directed graph algorithm, thereby achieving a reasonable distribution of device nodes of different importance in the final model.

[0052] Step S103: Based on the weight value of each device node and combined with the force-directed graph layout algorithm, simulate the rigid body motion and collision response between device nodes under a gravity field environment to determine the target position of the device node.

[0053] Specifically, the Force-Directed Graph Algorithm (FGA) is a visualization method that automatically lays out graph structures by simulating physical mechanics (attraction and repulsion between nodes), aiming to achieve clear node distribution, balanced edge lengths, and minimal intersections. Device nodes can be viewed as weightless charged bodies with the same charge and a graphical outline. Attraction is applied between nodes based on their electrical connections (the lines connecting nodes are considered springs or rubber bands with a stiffness coefficient), and repulsion is applied based on the spatial distance between nodes. Collision detection prevents nodes from penetrating each other. In each iteration, the velocity and position of each device node are calculated, and the attraction and repulsion forces in the FGA are adjusted according to the influence of weight values. This iteration is repeated until the position changes of all device nodes are less than a preset threshold, at which point a stable state is reached, yielding the target position for each device node. The target position refers to the final coordinate position reached by each device node in two-dimensional space. This position is obtained by combining weight values, the FGA layout algorithm, rigid body motion simulation, and collision response, through multiple iterations until the convergence condition (such as the position changes of all nodes being less than a preset threshold) is met. The target location determines the actual coordinates of the equipment node in the final generated substation model, and is the basic data for subsequently determining the connection path between nodes and generating a complete model.

[0054] In some embodiments, step S103 is implemented in the following manner: Step 1: Prioritize the device nodes according to their weight values.

[0055] Step 2: According to the order of priority from high to low, for multiple first-priority device nodes, combined with the force-guided graph layout algorithm, simulate the rigid body motion and collision response between each first-priority device node under the gravity field environment, and iteratively adjust the position of each first-priority device node until the change in position between two adjacent first-priority device nodes is less than a preset threshold, and obtain the initial position of each first-priority device node.

[0056] Step 3: For device nodes with the second priority and below, combine the force-directed graph layout algorithm to simulate the rigid body motion and collision response between the device nodes and the device nodes with the determined initial positions under the gravity field environment, and iteratively adjust the positions of the device nodes until the change in position between two adjacent device nodes is less than the preset threshold, and obtain the target position of the device nodes.

[0057] Specifically, for the highest priority (first priority) device nodes, a force-directed graph layout algorithm is used to simulate the rigid body motion and collision response between these nodes under a gravity field. The positions of each first priority device node are iteratively adjusted until the change in position between two adjacent positions is less than a preset threshold, thus obtaining the initial positions of each first priority device node. Then, multiple second priority device nodes are added, and the force-directed graph layout algorithm is used again to simulate the rigid body motion and collision response between each second priority device node and the device nodes with determined initial positions under a gravity field. The positions of each device node are iteratively adjusted until the change in position between two adjacent positions of all device nodes is less than a preset threshold. Then, multiple lower priority device nodes (below the second priority) are added, and this process is repeated until the target positions of all device nodes are determined. At this point, the positions of all device nodes and edges reach a stable layout state.

[0058] In some examples, the dynamic information includes rigid body dynamic parameters and gravitational field strength, where the rigid body dynamic parameters include at least one of the coefficient of restitution, friction, and impulse. Step three of step S103 is achieved in the following manner: An attractive force is applied between interconnected device nodes based on their weight values, with the magnitude of the attractive force adjusted according to the weight values. A repulsive force is applied between adjacent device nodes based on their spatial distance. Adjacent device nodes are defined as those whose graphic outlines are not covered by the graphic outlines of any other device node.

[0059] In a gravitational field environment, the physics engine iteratively calculates the velocity and position of each device node based on the gravitational and repulsive forces of each device node, and performs collision detection.

[0060] Adjust the position of the device nodes according to the collision response, and re-execute the steps of applying attraction between interconnected device nodes based on the weight values ​​of interconnected device nodes and applying repulsion between adjacent device nodes based on the spatial distance between adjacent device nodes, until the change in position of all device nodes between two consecutive times is less than a preset threshold, and obtain the target position of the device nodes.

[0061] In this context, "adjacent" means that within a two-dimensional layout plane, for any two device nodes A and B, if there are no other device nodes' outer contours between the outer contours of device node A and device node B, then device node A and device node B are considered adjacent. In other words, adjacent means that there is no third device node between the two device nodes that would completely occlude them.

[0062] In one specific embodiment, the graphical outline of a device node is its axis-aligned bounding box (AABB) on a two-dimensional plane. The extent of the bounding box not covered by the graphical outlines of other device nodes can be determined using a ray casting method or a line segment and rectangle intersection detection algorithm. For any two bounding boxes of device nodes, a detection line segment is emitted from the geometric center or vertex of one bounding box towards the geometric center or vertex of the other bounding box. If the detection line segment intersects (including tangents to) the bounding box of any third device node, the two device nodes are considered not fully visible and are not considered adjacent. If the detection line segment does not intersect the bounding box of any third device node, the two device nodes are considered directly visible and are considered adjacent.

[0063] Rigid body dynamics parameters refer to the physical properties used to simulate the motion behavior of equipment nodes in a gravitational field. The coefficient of restitution, e, represents the degree to which the velocity of the equipment node recovers after a collision; the example value ranges from 0 ≤ e ≤ 1. Friction represents the tangential resistance between the contact surfaces of the equipment nodes, affecting the sliding behavior of the nodes; its dimension is Newton (N). Impulse is the integral of force over time, used to change the momentum of the node; its dimension is MLT. 1 The corresponding unit is Newton-second (N·s). Gravitational field strength is the value of gravitational acceleration in the simulated environment, with dimensions in LT. -2 The example value is 9.8.

[0064] For any two electrically connected device nodes, an attractive force is applied between them according to their weights. This force is applied based on Hooke's Law, as shown in the formula: In the formula of Hooke's Law, k s denoted as the spring stiffness coefficient, x as the deformation, and the negative sign indicates that the direction of the elastic restoring force is opposite to the direction of the deformation.

[0065] For any two adjacent device nodes, regardless of whether they are connected, a repulsive force is applied based on the spatial distance between them. This repulsive force is specifically treated as the repulsive force between like-minded charged particles, and the formula is as follows: In this repulsive force formula, k p Let q1 and q2 be the equivalent electrical charges of two adjacent device nodes, and r be the distance between the center points of the two device nodes. Each device node is assigned an electrical charge that is positively correlated with its weight value.

[0066] For example, since different bay types correspond to different weight values ​​(e.g., the main transformer bay weight value is 0.9, the bus bay weight value is 0.6, and the outgoing line bay weight value is 0.3), the weight value of each device node can be determined based on the preset basic charge amount. The product of these factors determines the equivalent electrical charge of each device node. Among these, the preset base charge is... This is used to control the magnitude of the overall repulsive force. In this way, equipment nodes in the main transformer bay, due to their larger weight values, can be assigned larger electrical charges, while equipment nodes in the outgoing line bay can be assigned smaller electrical charges. Alternatively, the electrical charge can also be determined using a piecewise step function, for example, by dividing the weights of the equipment nodes into different levels, with each level corresponding to a preset electrical charge. This application does not specifically limit the method of determining the equivalent electrical charge based on weights.

[0067] In a gravitational field environment, each device node is subjected to a downward gravitational force, as well as the combined force of the aforementioned attractive and repulsive forces. The velocity and position of each device node are iteratively calculated using a physics engine (such as the PhysX component in the Unity engine): in each iteration, the acceleration is calculated based on the resultant force, the velocity is updated, and then the position is updated based on the velocity.

[0068] Collision detection is performed while updating the position. Specifically, the core components of the Unity engine, Rigidbody and Collider, can be used to simulate a gravitational field environment and perform rigidbody collision detection to ensure that the motion conforms to the law of conservation of momentum.

[0069] In this embodiment, a repulsive force is applied to each pair of spatially adjacent device nodes. The magnitude of the repulsive force is inversely proportional to the Euclidean distance between their center points and positively correlated with their weight values. Since the repulsive force only acts on spatially adjacent node pairs, while the gravitational force only acts on node pairs with electrical connections, their objects of action are different, and they will not produce opposite directions or cancel each other out. When two device nodes are both electrically connected and spatially adjacent, the gravitational and repulsive forces act as continuous external forces on the rigid body center of mass of the device nodes. Within each physical iteration step, the physics engine calculates the acceleration based on the vector sum of gravity, repulsion, and gravitational forces, updates the velocity of the device nodes, and then updates the position of the device nodes. Collision detection is performed after the position update; the impulse generated by the collision response corrects the velocity direction, ensuring that nodes do not overlap.

[0070] In some examples, the implementation of step two of step S103 is the same as the implementation of step three of step S103 mentioned above, and will not be repeated here.

[0071] With only one device node of the first priority, the rigid body motion and collision response of the device node under a gravitational field are simulated using a force-directed graph layout algorithm. The position of the device node is iteratively adjusted until the change in position between two consecutive positions is less than a preset threshold, thus obtaining the initial position of the device node. At this point, there is no attraction or repulsion between this device node and other device nodes; only gravity has an effect. Attraction and repulsion will only occur after a device node of the second priority is added.

[0072] For example, collision detection includes: By using a bounding box detection algorithm to detect the projection overlap between device nodes, a collision between two device nodes can be determined.

[0073] Specifically, the bounding box detection algorithm uses axis-aligned bounding boxes (AABB) for collision detection. A bounding box is generated for each device node, circumscribed in 2D space by its graphical outline and with edges parallel to the coordinate axes. The projection intervals of the bounding boxes of any two device nodes in the horizontal direction (X-axis) and vertical direction (Y-axis) are calculated. If the projection intervals of one device node's bounding box on the X-axis overlap with those of another device node's bounding box on the X-axis, and also overlap in their projection intervals on the Y-axis, then the two device nodes are considered to have a projection overlap (i.e., a collision).

[0074] Collision response refers to the physical reaction the physics engine takes when two objects (device nodes) come into contact (overlap) in virtual space. This reaction might involve pushing the device nodes apart to create a bounce or slide effect. When a collision is detected, the position of the device nodes is adjusted according to collision response rules. This could involve moving the nodes along the overlapping direction to separate them, or changing the nodes' speed and direction of movement to prevent them from visually overlapping. This detection process is performed in each iteration, ensuring that the device nodes remain non-overlapping throughout the dynamic adjustment process.

[0075] For example, the generated substation model is two-dimensional, and the bounding boxes of the primitives are all two-dimensional rectangles. If the AABB (Axis-Aligned Bounding Box) algorithm is used, without considering gravity, the steps are as follows: First, based on the force-directed graph algorithm, nodes are considered as charged particles and edges are considered as springs (or rubber bands). The repulsive and attractive forces are quantitatively calculated using formulas, which will disperse these points from the center outwards, but not too far apart, because of the presence of attraction (at this time, nodes are considered as points without size or outer contour). In other words, each node on the horizontal plane reaches force equilibrium under the combined action of attraction and repulsion.

[0076] Then, using bounding box detection algorithms (to recover the outer contour rectangle of primitives), such as the AABB algorithm, a large number of primitives in the image will be found to be colliding (e.g., a pair of primitives overlap in both the X and Y coordinates). For colliding primitives, the penalty method in repulsion force calculation can be used. The core idea is to convert the penetration depth of the object into elastic repulsion force, as shown in the formula: The elastic repulsive force f can be calculated separately in the X and Y directions. The coefficients in this penalty formula are penalty coefficients (elastic coefficients), applicable only to the collision response calculations described in this section. A larger penalty coefficient kp indicates a harder object. d represents the penetration depth (overlap degree); a larger penetration depth d indicates a stronger repulsive force. N is the collision normal direction, pointing in the direction that pushes the object away. Gravity arises because some primitives are "connected," and under the combined action of elastic repulsion, edge attraction, and other forces, a relatively stable state (relative positional relationship) is ultimately achieved. The above process can be iterated multiple times.

[0077] Step S104: Determine the target path between each device node based on the target location of the device node and the relationship between the device nodes, and generate a substation model based on the target location and target path.

[0078] Specifically, after obtaining the target location of each device node, the connections between the device nodes are topologically clear (i.e., which nodes have electrical connections is clear), but the specific routing paths of the connections in two-dimensional space are not yet determined. To avoid connections passing through device nodes or other connections, it is necessary to plan an actual routing path from the starting point to the ending point for each pair of device nodes with electrical connections.

[0079] For example, the target path includes at least one of polylines, curves, and straight lines.

[0080] In some embodiments, step S104 can be implemented in the following ways: Based on the target location of the device nodes and the relationship between the device nodes, the A-Star optimization algorithm is used to determine the target path between each device node.

[0081] Specifically, the evaluation function f(n) = g(n) + h(n) is defined first. g(n) is the actual cost from the starting point to the current node n. g(n) includes, for example, path length cost, turning cost, and obstacle avoidance cost. The path length cost represents the distance of the grid already traversed by the current path, the turning cost is used to reduce the number of inflection points on the polyline, and the obstacle avoidance cost is used to prevent the target path from crossing the bounding box of the device node or approaching other connections. h(n) is the heuristically estimated cost from the current node n to the destination. f(n) is the total estimated cost, which determines the node expansion order (preferably selecting the node with the smallest f value). In this embodiment, since the device node moves in a two-dimensional grid or continuous space, and the movement direction is limited to up, down, left, and right (four-connected or eight-connected), h(n) can use the Manhattan distance, as shown in the following formula: ; Where (x1, y1) are the coordinates of the current node n, and (x2, y2) are the coordinates of the endpoint, with the dimension L.

[0082] The specific process of the A-Star optimization algorithm is as follows: During the initialization phase, an open list (to store device nodes to be evaluated) and a closed list (to store device nodes that have already been evaluated) are created. The starting point is added to the open list, and its f-value is calculated.

[0083] In the main loop phase, the node with the smallest f value is selected from the open list as the current node. It is then checked whether the current node is the endpoint. If it is, the path is backtracked, starting from the endpoint and traversing back to the starting point using the parent node pointers recorded by each node, to obtain the complete path. If the current node is not the endpoint, it is moved from the open list to the closed list, and all its adjacent nodes are processed.

[0084] For each neighboring node of the current node, skip it if it is already in the closed list. Calculate the cost g of the new path from the starting point through the current node to that neighboring node. new =g(n)+|xs xn∣+∣ys Let yn|, where (xn,yn) and (xs,ys) are the coordinates of the current node and its neighboring nodes, respectively. The heuristic estimate h(m) = |mx - ex| + |my - ey| is calculated using the Manhattan distance formula, where (mx,my) are the coordinates of neighboring nodes, and (ex,ey) are the coordinates of the destination node. The total cost f is then calculated. new =g new +h(m). If the adjacent node is not in the open list, or the newly calculated f new If the value of f is less than the original value of the adjacent node, then update the information of the adjacent node by setting its parent node as the current node and updating the value of g to g. new Update f to f new And add it to the open list (if it is not already in the open list).

[0085] The node information is updated only when the cost of the new path is lower, ensuring that the final path found is optimal (i.e., with the minimum total cost). The algorithm repeats the main loop until the open list is empty (indicating no path is reachable) or the destination is found.

[0086] For example, in the A-star optimization algorithm, the bounding box regions of all located device nodes are marked as impassable obstacle grids; for other generated connections, a penalty coefficient λ is set, and when the distance between the candidate path and other connections is less than the preset spacing D, the heuristic cost h(m) is increased.

[0087] Using the above method, a shortest and smooth connection path can be planned for each pair of electrically connected equipment nodes without passing through other equipment nodes. Combining all connection paths with the target locations of the equipment nodes generates a complete and well-organized substation model.

[0088] Please see Figure 2 , Figure 2 This is a schematic flowchart illustrating a specific example of the substation model generation method according to an embodiment of this application. In some embodiments, after step S103 and before step S104, the substation model generation method according to an embodiment of this application further includes: Step S105: Based on the weight values ​​of the device nodes, perform horizontal and vertical layout corrections on the target positions of the device nodes to form the corrected target positions.

[0089] Specifically, the corrected target locations will form a stepped layout. A stepped layout refers to a substation model where each bay and its internal equipment are arranged vertically in layers and horizontally aligned, resembling a stepped structure. This layout conforms to the traditional drawing habits of primary wiring diagrams in the power industry, making it easier for maintenance personnel to read.

[0090] In some examples, step S105 is implemented in the following ways: Based on the positional and connection relationships of the equipment nodes within each interval at the target location, determine the number of steps and the hierarchical structure of the steps; The contact position of the device node on the step is determined by a collision detection algorithm; Based on the rigid body dynamics parameters and gravitational field strength of each equipment node, determine the motion state of the equipment node on the steps; The contact position is adjusted based on the motion state and weight value of the device node to obtain the corrected target position of the device node.

[0091] Specifically, the method for determining the number of steps and the hierarchical structure of the steps is as follows: A preliminary estimate of the number of steps is made based on the layout diagram. For example, based on the intervals, the positional relationships between intervals, the positional relationships of primary equipment within each interval, and the connection relationships between primary equipment, the number of upper and lower levels (i.e., the number of steps) is formed in a two-dimensional space for clear representation. For example, the main transformer interval is usually located in the lower level, the busbar interval in the middle level, and the outgoing line interval in the upper level or on both sides, thus forming a three-level ladder. For example, for each equipment node within each interval, a clustering method can be used to group equipment nodes whose vertical coordinate differences are less than a preset height threshold into the same ladder level; and to group equipment nodes whose vertical coordinate differences are greater than or equal to the preset height threshold into different ladder levels. The ladder levels are then sorted from largest to smallest according to their vertical coordinate averages, numbered sequentially as Level 1, Level 2, ..., Level N, where N is the total number of steps within the interval. Based on the total number of steps and the set of equipment nodes contained in each level, the hierarchical structure of the ladder is constructed.

[0092] The contact position of a device node on a step is determined by a collision detection algorithm. Aligned-Bounding Box (AABB) or GJK collision detection algorithms can be used to calculate the intersection or nearest point between the device node and the step plane (i.e., the boundary line between different levels on a 2D screen). This intersection or nearest point serves as the support point or anchor point for the device node on that step. For example, the contact position of a device node on a step refers to the intersection or tangent point between the bottom edge of the device node's graphic outline and the horizontal baseline of the current step level (i.e., the horizontal line containing the average vertical position coordinates of that level). When a device node is located on a certain step level, its bottom vertical position coordinates (i.e., the Y-axis coordinate) are constrained to the horizontal baseline containing the average vertical position coordinates of that level, and its horizontal position coordinates (i.e., the X-axis coordinate) are constrained to the vertical baseline containing the average horizontal position coordinates of that level.

[0093] Based on the rigid body dynamics parameters and gravitational field intensity of each equipment node, the motion state of the equipment node on the steps is simulated, which can be achieved in the following way: Calculate the tangential component of gravity F along the stepped contact surface. 切 (Dimension is N), the formula is as follows: ; Calculate the vertical component F of gravity along the stepped contact surface. 法 (Dimension is N), the formula is as follows: ; Where mg is gravity, with dimensions in N, and θ is the step slope angle, with dimensions in degrees or radians.

[0094] Calculate the maximum static friction force f based on the friction coefficient μ. max(Dimension is N), the formula is as follows: .

[0095] Determine whether the equipment node is stationary or sliding relative to the stairs. If it is determined to be sliding, simulate the bouncing or continuous sliding trajectory of the equipment node between the stairs, taking into account the height difference between the stairs (e.g., step height h, width w), and consider energy loss during the simulation, for example, by introducing a collision recovery coefficient to adjust the velocity after each collision. If it is determined to be stationary, calculate the center of gravity position of the stair structure to ensure that the line of action of gravity falls within the foundation bottom surface to avoid overturning due to center of gravity shift. Specifically, the center of gravity eccentricity ce can be calculated using the following formula: ; Where B is the base width, and xc is the distance from the center of gravity to the edge of the base, measured in units of L, such as meters. For example, the eccentricity ce of the center of gravity satisfies: ce ≤ B / 6.

[0096] For example, in a stepped layout, the step height *h* is the vertical distance between the upper and lower steps, and the width *w* is the horizontal extension distance. When a device node moves from one step to the next, it may slide or bounce. Sliding occurs when the device node moves continuously along the step's slope or edge, with a constant contact surface. Bouncing occurs when the device node leaves the step edge, falls, collides with the next step, and rebounds. The simulated trajectory is the path of the node under gravity calculated using Newtonian mechanics, including changes in position and velocity over time. The tangential component force *F*... 切 Greater than the maximum static friction force f max At this time, the node will slide, and the kinetic friction of the slide... ,in The coefficient of kinetic friction. The net acceleration along the inclined plane. .

[0097] In actual physics, nodes lose energy during collisions or sliding, causing their velocity to gradually decrease. A collision restitution coefficient e (a value between 0 and 1) is introduced to quantify this energy loss. A restitution coefficient of 1 indicates a perfectly elastic collision (no energy loss), while a restitution coefficient of 0 indicates a perfectly inelastic collision (the velocity drops to zero after the collision, and the node does not bounce). After each collision, the node velocity is multiplied by the restitution coefficient, thus simulating the process of the bounce height gradually decreasing until the node comes to rest. Let the initial fall height be h. before (Referring to the point of collision), the velocity before the collision was The velocity after the collision is The height of the rise after the collision is Finally, the eccentricity ce of the center of gravity of the stepped structure is verified to avoid overturning due to the shift in the center of gravity.

[0098] For example, determining the motion state of a device node on a staircase specifically includes: applying a downward simulated gravity force to each device node and detecting whether the bottom of the device node is in contact with the horizontal baseline of the current staircase level. If the bottom of the device node crosses the baseline of the current level under the influence of gravity, contact is determined to have occurred, a rebound is generated according to the collision recovery coefficient e, and the velocity after the rebound is calculated; if the device node falls again after the rebound and repeatedly collides with the same level baseline, the rebound height is gradually reduced according to the recovery coefficient. When the difference in rebound height between two consecutive collisions is less than a preset height threshold (for example, 5% of the device node's bounding box height), the device node is determined to have reached a stationary state on that staircase level. If the bottom Y-axis coordinate of a device node crosses the baseline of an adjacent staircase level during the bouncing process, the device node is determined to have fallen into an adjacent staircase level, and its level is switched.

[0099] When a device node reaches a stationary state at a certain step level, the difference Δy between the bottom Y-axis coordinate of the device node and the current layer's reference Y-value is obtained. If the absolute value of Δy is less than a preset accuracy threshold (for example, 2% of the device node's bounding box height), the device node's Y-axis coordinate is directly corrected to the current layer's reference Y-value, while the X-axis coordinate remains unchanged. If the absolute value of Δy is greater than or equal to the accuracy threshold, the difference is determined based on the device node's weight value w. i The contact positions are then fine-tuned using weighted methods. Device nodes with larger weight values ​​tend to be more stable at the center of the layer (i.e., their contribution to Δy is smaller), while device nodes with smaller weight values ​​are allowed some floating offset within the layer. Through this layer-by-layer, node-by-node position correction, the final target position of each device node is obtained, resulting in a stepped, layered layout for the entire site model.

[0100] In this embodiment, step S104 is implemented in the following way: Based on the corrected target location and the relationship between device nodes, determine the target path between each device node; A substation model is generated based on the corrected target location and target path.

[0101] In other words, the aforementioned A-satellite optimization algorithm uses the corrected target position to replace the target position. Further details will not be elaborated here.

[0102] Based on the above-described scheme and the determination of the motion state, the contact position of the equipment node on the steps is adjusted. If the equipment node is stationary, its current position is maintained and the center of gravity position is calculated; if it is sliding or bouncing, the equipment node is moved along the step surface until it is stable on a certain level of the step, so that the entire substation model ultimately presents a clear, vertically aligned, stepped layout.

[0103] Please see Figure 3 , Figure 3 This is a schematic diagram illustrating an example of a substation model generated by the substation model generation method according to an embodiment of this application. Exemplarily, Figure 3 The substation model includes a stepped layout of bus bays, main transformer bay 1, main transformer bay 2, outgoing line bay 1, and outgoing line bay 2.

[0104] The substation model generation method of this application automatically determines equipment nodes and their connection relationships based on a pre-built substation description file, improving the arbitrariness introduced by manual identification and drawing. Furthermore, it assigns weight values ​​based on the bay type to which the equipment nodes belong, and combines force-directed graph layout algorithms with simulations of rigid body motion and collision responses, enabling equipment nodes of different bay types to obtain reasonable and stable spatial positions during iterative adjustments, effectively improving node overlap and layout chaos. Based on this, it determines the target path according to the target location and connection relationships, improving the clarity and regularity of the connections. Overall, this scheme can achieve automated generation of substation models, significantly improving the standardization of model generation.

[0105] Accordingly, this application provides a substation model generation device. Please refer to [link / reference]. Figure 4 , Figure 4 This is a schematic diagram of the substation model generation device according to an embodiment of this application. The device includes a file parsing module 401, a weight determination module 402, a location determination module 403, and a path determination module 404.

[0106] The file parsing module 401 is used to determine the equipment nodes of the substation and the relationships between the equipment nodes based on the pre-built substation description file; the equipment node is a graphic node with a graphic outline corresponding to the physical entity node, and has preset geometric information and dynamic information. The weight determination module 402 is used to determine the weight value of each device node according to the bay type to which each device node belongs. The bay is used to characterize the electrical circuit unit in the substation. The bay types include main transformer bay, bus bay and outgoing line bay. The weight value of each device node is the same under the same bay type, and the weight values ​​are different for different bay types. The location determination module 403 is used to determine the target location of the device node by simulating the rigid body motion and collision response between device nodes under a gravity field environment based on the weight value of each device node and the force-guided graph layout algorithm. The path determination module 404 is used to determine the target path between each device node based on the target location of the device node and the relationship between the device nodes, and to generate a substation model based on the target location and the target path.

[0107] In some embodiments, the location determination module 403 is specifically used for: The device nodes are prioritized according to their weight values. According to the order of priority from high to low, for multiple first-priority device nodes, combined with the force-directed graph layout algorithm, the rigid body motion and collision response between each first-priority device node under the gravity field environment are simulated, and the position of each first-priority device node is iteratively adjusted until the change in position between two adjacent first-priority device nodes is less than a preset threshold, thus obtaining the initial position of each first-priority device node. For device nodes of second priority and below, the rigid body motion and collision response between the device nodes and the device nodes with determined initial positions are simulated under the gravity field environment, and the positions of the device nodes are iteratively adjusted until the change in position between two adjacent device nodes is less than a preset threshold, thus obtaining the target position of the device nodes.

[0108] In some embodiments, the dynamic information includes rigid body dynamic parameters and gravitational field intensity, wherein the rigid body dynamic parameters include at least one of the coefficient of restitution, frictional force, and impulse; the position determination module 403 is specifically used for: Based on the weight values ​​of interconnected device nodes, an attractive force is applied between interconnected device nodes; based on the spatial distance between adjacent device nodes, a repulsive force is applied between adjacent device nodes, where there is no other device node's graphic outline coverage area between the graphic outline coverage areas of the two device nodes. In a gravitational field environment, the physics engine iteratively calculates the velocity and position of each device node based on the gravitational and repulsive forces of each device node, and performs collision detection. Adjust the position of the device nodes according to the collision response, and re-execute the steps of applying attraction between interconnected device nodes based on the weight values ​​of interconnected device nodes and applying repulsion between adjacent device nodes based on the spatial distance between adjacent device nodes, until the change in position of all device nodes between two consecutive times is less than a preset threshold, and obtain the target position of the device nodes.

[0109] In some embodiments, the location determination module 403 is specifically used for: By using a bounding box detection algorithm to detect the projection overlap between device nodes, a collision between two device nodes can be determined.

[0110] In some embodiments, after obtaining the target location of the device node, the location determination module 403 is further configured to: Based on the weight values ​​of the device nodes, the target positions of the device nodes are adjusted in the horizontal and vertical directions to form the corrected target positions. The location determination module 403 is specifically used for: Based on the corrected target location and the relationship between device nodes, determine the target path between each device node; A substation model is generated based on the corrected target location and target path.

[0111] In some embodiments, the location determination module 403 is specifically used for: Based on the positional and connection relationships of the equipment nodes within each interval at the target location, determine the number of steps and the hierarchical structure of the steps; The contact position of the device node on the step is determined by a collision detection algorithm; Based on the geometric and dynamic information of each device node, determine the motion state of the device node on the steps; The contact position is adjusted based on the motion state and weight value of the device node to obtain the corrected target position of the device node.

[0112] In some embodiments, the file parsing module 401 is specifically used for: Load and parse the substation description file to obtain the primary equipment logical nodes of the substation and the logical node relationships between the primary equipment logical nodes; Map a primary device logical node to a device node; Map logical node relationships to relationships between device nodes.

[0113] In some embodiments, the apparatus further includes a file building module for: The pre-acquired substation configuration description file is verified, cleaned, and standardized to obtain basic substation information, which includes the substation's wiring method, bay type, and number of bays. Configure the basic information of the substation to obtain configuration information; Obtain the preset standard interval template library, which includes template files for each interval type; Based on the configured wiring method, bay type and number of bays, copy the corresponding template file from the standard bay template library to generate the bay and the primary device logic node within each bay; Based on the bays and the primary equipment logical nodes within each bay, establish the substation topology connection relationship, and determine the substation description file based on the substation topology connection relationship.

[0114] In some embodiments, the path determination module 404 is specifically used for: Based on the target location of the device nodes and the relationship between the device nodes, the A-Star optimization algorithm is used to determine the target path between each device node.

[0115] The substation model generation device of this application automatically determines equipment nodes and their connection relationships based on a pre-built substation description file, which can improve the arbitrariness introduced by manual identification and drawing. Furthermore, it assigns weight values ​​according to the bay type to which the equipment nodes belong, and combines the force-guided graph layout algorithm with the simulation of rigid body motion and collision response, so that equipment nodes of different bay types can obtain reasonable and stable spatial positions during the iterative adjustment process, effectively improving node overlap and layout chaos. On this basis, the target path is determined according to the target position and connection relationship, improving the clarity and regularity of the connection. The whole scheme can realize the automated generation of substation models and significantly improve the standardization of model generation.

[0116] This application also provides an electronic device, including a memory and a processor. The memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions. When the computer-executable instructions are executed by the processor, they implement the steps of the substation model generation method as described in any of the above embodiments.

[0117] This application also provides a computer-readable storage medium storing a computer program thereon, which is loaded by a processor to execute the steps in the substation model generation method of any of the above embodiments.

[0118] In the embodiments of this application, the storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM), etc.

[0119] It should be noted that, in the data processing stage, the technical solution of this application has strictly limited the scope of data collection to the minimum necessary to achieve the technical objectives, preventing the acquisition of irrelevant information. For any user information to be collected, the data subject will be clearly informed and their consent obtained. Furthermore, technologies such as encrypted storage and access control are employed to strengthen data security and ensure the security and compliance of the entire data processing process. The technical model and decision-making mechanism are based on objective technical parameters and do not introduce unnecessary parameters such as gender or age that may lead to discrimination, resolutely eliminating algorithmic discrimination and upholding public order and good morals. In addition, the specification fully describes the technical implementation methods, application scenarios, and compliance protection details. The claims are consistent with the content of the specification, key compliance designs are clear and verifiable, and the overall technical design is guided by the protection of public interests and adherence to social ethics, without any circumstances that harm public interests or violate public order and good morals.

[0120] In the above embodiments, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions in other embodiments.

[0121] The above provides a detailed description of a substation model generation method, apparatus, electronic device, and storage medium provided in the embodiments of this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the method and core ideas of this application. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.

Claims

1. A method for generating a substation model, characterized in that, include: Based on a pre-built substation description file, determine the equipment nodes of the substation and the relationships between the equipment nodes; The device node is a graphical node with a graphical outline corresponding to a physical entity node, and has preset geometric and dynamic information; The weight value of each device node is determined according to the bay type to which each device node belongs. The bay is used to characterize the electrical circuit unit in the substation. The bay type includes main transformer bay, bus bay and outgoing line bay. The weight value of each device node under the same bay type is the same, and the weight value corresponding to different bay types is different. Based on the weight value of each device node and combined with the force-guided graph layout algorithm, the rigid body motion and collision response between the device nodes under a gravitational field environment are simulated to determine the target position of the device node. Based on the target location of the device nodes and the relationship between the device nodes, the target path between each device node is determined, and the substation model is generated based on the target location and the target path.

2. The substation model generation method according to claim 1, characterized in that, The step of determining the target position of the device nodes by simulating the rigid body motion and collision response between the device nodes under a gravitational field environment based on the weight value of each device node and in conjunction with the force-directed graph layout algorithm includes: The device nodes are prioritized according to their weight values. According to the order of priority from high to low, for multiple device nodes of the first priority, combined with the force-directed graph layout algorithm, the rigid body motion and collision response between the device nodes of the first priority under the gravity field environment are simulated, and the position of each device node of the first priority is iteratively adjusted until the change in position between two adjacent positions of each device node of the first priority is less than a preset threshold, so as to obtain the initial position of each device node of the first priority. For device nodes of second priority and below, the rigid body motion and collision response between the device node and the device node with a determined initial position are simulated under a gravity field environment, and the position of the device node is iteratively adjusted until the change in position between two adjacent positions of all the device nodes is less than a preset threshold, so as to obtain the target position of the device node.

3. The substation model generation method according to claim 2, characterized in that, The dynamic information includes rigid body dynamic parameters and gravitational field intensity. The rigid body dynamic parameters include at least one of the coefficient of restitution, friction, and impulse. For device nodes of second priority and below, the rigid body motion and collision response between the device node and a device node with a determined initial position are simulated under a gravitational field environment, using the force-directed graph layout algorithm. The positions of the device nodes are iteratively adjusted until the change in position between two adjacent positions of all device nodes is less than a preset threshold, thereby obtaining the target position of the device node, including: Based on the weight values ​​of interconnected device nodes, an attractive force is applied between interconnected device nodes; based on the spatial distance between adjacent device nodes, a repulsive force is applied between adjacent device nodes, wherein the graphic outer contour coverage areas of the two device nodes do not have the graphic outer contour coverage areas of other device nodes. In a gravitational field environment, the physics engine iteratively calculates the velocity and position of each device node based on the gravitational and repulsive forces of each device node, and performs collision detection. The positions of the device nodes are adjusted according to the collision response, and the steps of applying attraction between interconnected device nodes based on the weight values ​​of interconnected device nodes and applying repulsion between adjacent device nodes based on the spatial distance between adjacent device nodes are repeated until the change in position of all device nodes between two consecutive times is less than a preset threshold, thereby obtaining the target position of the device nodes.

4. The substation model generation method according to claim 3, characterized in that, The collision detection includes: The bounding box detection algorithm is used to detect the projection overlap between the device nodes to determine that two device nodes have collided.

5. The substation model generation method according to claim 1, characterized in that, After obtaining the target location of the device node, the method further includes: Based on the weight values ​​of the device nodes, the target positions of the device nodes are adjusted in the horizontal and vertical directions to form the corrected target positions. The step of determining the target path between each device node based on the target location of the device node and the relationship between the device nodes, and generating the substation model based on the target location and the target path, includes: Based on the corrected target location and the relationship between the device nodes, the target path between each device node is determined; The substation model is generated based on the corrected target location and the target path.

6. The substation model generation method according to claim 5, characterized in that, The step of adjusting the horizontal and vertical layout of the target position of the device node based on its weight value to form the adjusted target position includes: Based on the positional and connection relationships of the device nodes within each interval at the target location, determine the number of steps and the hierarchical structure of the steps; The contact position of the device node on the steps is determined by a collision detection algorithm; Based on the geometric information and dynamic information of each device node, the motion state of the device node on the steps is determined; The contact position is adjusted according to the motion state and weight value of the device node to obtain the corrected target position of the device node.

7. The substation model generation method according to claim 1, characterized in that, The step of determining the equipment nodes of the substation and the relationships between the equipment nodes based on a pre-built substation description file includes: Load and parse the substation description file to obtain the primary equipment logical nodes of the substation and the logical node relationships between the primary equipment logical nodes; Map the primary device logical node to the device node; The logical node relationships are mapped to the relationships between the device nodes.

8. The substation model generation method according to claim 1, characterized in that, The method for constructing the substation description file includes: The pre-acquired substation configuration description file is verified, cleaned, and standardized to obtain basic substation information, which includes the substation's wiring method, bay type, and bay quantity. The basic information of the substation is configured to obtain configuration information; Obtain a preset standard interval template library, which includes template files for each of the interval types; Based on the configured wiring method, the interval type, and the number of intervals, the corresponding template file is copied from the standard interval template library to generate the interval and the primary device logic node within each interval; Based on the interval and the primary equipment logical nodes within each interval, a global substation topology connection relationship is established, and the substation description file is determined based on the global substation topology connection relationship.

9. The substation model generation method according to claim 1, characterized in that, The step of determining the target path between the device nodes based on their target locations and the relationships between them includes: Based on the target location of the device nodes and the relationship between the device nodes, the A* optimization algorithm is used to determine the target path between the device nodes.

10. A substation model generation device, characterized in that, include: The file parsing module is used to determine the equipment nodes of the substation and the relationships between the equipment nodes based on the pre-built substation description file. The device node is a graphical node with a graphical outline corresponding to a physical entity node, and has preset geometric and dynamic information; The weight determination module is used to determine the weight value of each device node according to the bay type to which each device node belongs. The bay is used to characterize the electrical circuit unit in the substation. The bay type includes main transformer bay, bus bay and outgoing line bay. The weight value of each device node is the same under the same bay type, and the weight value is different for different bay types. The location determination module is used to determine the target location of the device node by simulating the rigid body motion and collision response between the device nodes under a gravity field environment based on the weight value of each device node and the force-guided graph layout algorithm. The path determination module is used to determine the target path between the device nodes based on the target location of the device nodes and the relationship between the device nodes, and to generate the substation model based on the target location and the target path.

11. An electronic device, characterized in that, include: Memory and processor; The memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions. When the computer-executable instructions are executed by the processor, they implement the steps of the substation model generation method as described in any one of claims 1 to 9.

12. A computer-readable storage medium, characterized in that, The system stores computer-executable instructions, which, when executed by a processor, implement the steps of the substation model generation method as described in any one of claims 1 to 9.