A method and system for automatic generation of a topology of a power communication network

By using an automated generation system that integrates edge terminals and the cloud, the problems of manual dependence and cloud latency in the generation of power communication network topology have been solved. This system enables accurate identification of entities at different scales and real-time dynamic topology generation, thereby improving the operation and maintenance efficiency and reliability of power communication networks.

CN122226622APending Publication Date: 2026-06-16EAST CHINA BRANCH OF STATE GRID CORP
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610152653.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2025-11-26
Filing Date
2026-02-03
Publication Date
2026-06-16

AI Technical Summary

Technical Problem

Existing methods for generating power communication network topologies suffer from problems such as cumbersome manual drawing that relies on experience, difficulty in accurately capturing entity features at different scales with automatic model reconstruction, and real-time issues caused by cloud computing latency, leading to topology misjudgments and high latency.

Method used

An automatic generation system that combines edge terminals and cloud computing is adopted. Initial images are collected through edge terminals, and multi-scale feature enhancement, deformation correction and hierarchical attention processing are performed in the cloud. Combined with knowledge graphs and classification models, connection relationships are identified to generate dynamic topology structures, and lightweight analysis is performed on edge terminals.

Benefits of technology

It improves the ability to perceive entities at different scales, reduces the false negative rate of small-scale entities, enhances the ability to express information, ensures the accuracy and real-time performance of the topology, and reduces latency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122226622A_ABST
    Figure CN122226622A_ABST
Patent Text Reader

Abstract

The application provides a method and system for automatically generating a topology of a power communication network, and relates to the technical field of intelligent operation and maintenance of a power system. The method comprises: collecting initial images containing at least one entity of a site, a device and a port at different time points; adjusting the weight of different entities in the initial images to obtain target images corresponding to the initial images, and arranging the target images corresponding to the initial images in the order of time points to obtain a time sequence image set; identifying the connection relationship between entities in any target image in the time sequence image set; and generating a dynamic topology according to the connection relationship between entities in each target image in the time sequence image set. The application adjusts the weight of different entities in the initial images to enhance the information expression ability of each entity and reduce the probability of missing detection. In addition, the dynamic topology is constructed according to the connection relationship between entities, which facilitates subsequent accurate maintenance of the power communication network.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of intelligent operation and maintenance technology for power systems, and in particular to a method and system for automatically generating the topology of a power communication network. Background Technology

[0002] The topology of power communication networks accurately carries key design information such as site layout, equipment configuration, and port connection relationships. Its level of detail and real-time performance play an important role in the effectiveness and reliability of communication construction and operation.

[0003] Currently, the generation of topology diagrams faces multiple core challenges. On the one hand, traditional manual drawing methods are not only labor-intensive and time-consuming, but their accuracy also heavily relies on human experience. This method is ill-suited to handle frequent topology changes caused by network optimization, equipment upgrades, and port expansion, and is prone to early design deviations such as incorrect entity labeling and missing connection relationships due to human oversight, creating hidden dangers for later operation. On the other hand, existing automatic reconstruction methods based on electronic raster image data (using pixelated image carriers such as CAD-derived drawings, planning schematics, and equipment layout pixel maps from the early design phase) are still limited by technical bottlenecks: in topology-related electronic raster images, the scale differences between different entities are extremely significant. For example, site areas typically occupy 100-500 pixels, power communication equipment occupies 20-50 pixels, while core ports only occupy 5-10 pixels. The receptive field of traditional automatic reconstruction models remains fixed, making it impossible to accurately capture the feature information of both macroscopic sites and microscopic ports simultaneously. This results in a high rate of missed detection for small-scale entities (especially ports), leading to topology logic confusion and misjudgment of connection relationships.

[0004] Furthermore, at the application deployment level, existing topology generation models mostly adopt a centralized cloud computing architecture. Completing a global topology reconstruction and analysis requires image backhaul and cloud processing, with end-to-end latency typically exceeding 500 milliseconds, severely reducing the efficiency of the deployment method.

[0005] In view of this, the present invention is hereby proposed. Summary of the Invention

[0006] To address the aforementioned technical problems, this application provides a method and system for automatically generating the topology of power communication networks, which solves problems such as missed detection of multi-scale entities and lag in tracking dynamic relationships of entities. The technical solution is as follows: Firstly, a method for automatically generating the topology of a power communication network is provided, including: Acquire initial images containing at least one entity among sites, devices, and ports at different time points; Adjust the weights of different entities in the initial image to obtain the target image corresponding to the initial image, and arrange the target images corresponding to each initial image in chronological order to obtain a time-series image set; For any target image in the time-series image set, identify the connection relationships between entities in the target image; wherein, the connection relationships include actual connection relationships based on physical cabling and temporary connection relationships based on temporary service paths; A dynamic topology is generated based on the connection relationships between entities in each target image in the time-series image set.

[0007] Secondly, an automatic topology generation system for power communication networks is provided. This system is used to execute the aforementioned automatic topology generation method for power communication networks. The system includes: An edge terminal is used to acquire initial images containing at least one entity among sites, devices, and ports at different points in time. The cloud, which is communicatively connected to at least one edge terminal, is configured to: Adjust the weights of different entities in the initial image to obtain the target image corresponding to the initial image, and arrange the target images corresponding to each initial image in chronological order to obtain a time-series image set; For any target image in the time-series image set, identify the connection relationships between entities in the target image; wherein, the connection relationships include actual connection relationships based on physical cabling and temporary connection relationships based on temporary service paths; A dynamic topology is generated based on the connection relationships between entities in each target image in the time-series image set.

[0008] The technical solutions provided in this application can achieve the following technical effects: (1) This application extracts regions corresponding to entities of different scales, such as sites, devices, and ports, and processes the extracted regions through convolution at different scales and deformation correction to improve the system's ability to perceive entities of different scales, thereby reducing the probability of small-scale ports being missed. At the same time, it also suppresses background noise in the areas where sites and devices are located, enhances the information expression ability of sites and devices, and suppresses background noise in the areas where ports are located and increases port weight, achieving the dual purpose of enhancing the information expression ability of ports, and providing data support for accurately identifying different types of entities such as sites, devices, and ports.

[0009] (2) In identifying the connection relationships between entities, this application first identifies the entities and their connection relationships in a single frame of the target image, constructs an initial topology based on the entities and their connection relationships, and then updates the nodes in the initial topology and dynamically adjusts the weights of each edge. Simultaneously, it constructs various constraints based on a knowledge graph. Finally, a classification model is used to predict the true connection relationships between entities based on the weights of the nodes and edges in the initial topology and the constraints. That is, the classification model integrates multiple factors to predict the connection relationships between entities, ensuring the reliability of the prediction results and providing data assurance for the subsequent dynamic topology to have temporal consistency with the power communication network.

[0010] (3) In addition, after generating the dynamic topology, the cloud in this application will also return the local dynamic topology related to the edge terminal to the edge terminal, which will then use a lightweight model to analyze and process it, ensuring that the local dynamic topology held by the edge terminal is highly consistent with the actual network structure, thereby avoiding the centralized computing mode in the cloud and meeting the real-time requirements of the dynamic topology in real-world scenarios. Attached Figure Description

[0011] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the description of the embodiments of this application will be briefly introduced below. In the drawings: Figure 1 This is a structural diagram of an automatic topology generation system for a power communication network according to an embodiment of this application; Figure 2 This is a flowchart of a method for automatically generating the topology of a power communication network according to an embodiment of this application; Figure 3 This is a flowchart illustrating how the cloud obtains the target image based on the initial image in an embodiment of the method of this application; Figure 4 This is a flowchart illustrating the cloud-based identification of connection relationships between entities in the embodiments of the method of this application; Figure 5 This is a structural diagram of an electronic device provided in an embodiment of this application. Detailed Implementation

[0012] Exemplary embodiments of the present application will now be described in more detail with reference to the accompanying drawings. While exemplary embodiments of the present application are shown in the drawings, it should be understood that the present application may be implemented in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this application will be thorough and complete, and will fully convey the scope of the present application to those skilled in the art.

[0013] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such use can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the term "comprising" and its variations should be interpreted as open-ended terms meaning "including but not limited to."

[0014] As mentioned earlier, in existing technologies, the topology of power communication networks is mostly generated manually or by scanning images. Manual drawing is labor-intensive and its accuracy depends heavily on human experience. Furthermore, the frequent adjustments to the drawn topology for routine maintenance and optimization further complicate this process. Scanning images suffers from missed detections. For example, a site typically occupies 100-500 pixels, power equipment 20-50 pixels, and a port 5-10 pixels. The large difference in pixel size between these entities, coupled with the fixed receptive field of traditional automatic reconstruction models, makes it difficult to effectively capture both large-scale sites and small-scale ports simultaneously, resulting in a high rate of missed detections for fine-grained entities. Additionally, existing automatic reconstruction models are mostly deployed in the cloud, leading to long generation times for the global topology and latency issues when transmitting the topology to edge terminals, hindering its practical application in edge terminal operation and maintenance management.

[0015] Based on this, this application proposes an automatic topology generation system for power communication networks, such as... Figure 1 As shown, the system includes a cloud and multiple edge terminals. The cloud consists of one or more servers and may also include displays for page presentation. Edge terminals are typically installed in various power plants and are intelligent devices used to collect data, intelligently analyze data, and execute control commands issued from the cloud to maintain the stable and efficient operation of the power communication network. Examples include distribution automation terminals (DTU / FTU), smart gateways, and other intelligent devices.

[0016] This embodiment constructs a cloud-edge collaborative automatic generation system through the cloud and multiple edge terminals. In this system, edge terminals deployed at each power station first preprocess and analyze the locally collected data; then, the refined key data is uploaded to the cloud. Based on the network-wide data, the cloud generates a global network topology and distributes the local topology related to each power station to the corresponding edge terminals. The edge terminals then utilize this topology to achieve precise maintenance and management of the local power communication network.

[0017] To improve the accuracy of the topology, this embodiment also proposes an enhancement scheme: a lightweight topology generation model can be deployed on the edge terminal. Upon receiving the topology from the cloud, the model can perform secondary verification and correction based on local real-time data to ensure that the topology held by the terminal is highly consistent with the actual network structure of the power plant, thereby further improving the reliability and efficiency of operation and maintenance and reducing latency.

[0018] To illustrate in detail the process by which the cloud and multiple edge terminals cooperate to generate the dynamic topology of a power communication network, this application also provides a method for automatically generating the topology of a power communication network, such as... Figure 2 As shown, the method may include the following steps S100 to S400.

[0019] Step S100: Acquire initial images containing at least one entity among sites, devices, and ports at different time points.

[0020] The initial images are collected by edge terminals, containing electronic grid images of at least one entity, including sites, devices, and ports. These electronic grid images include pixelated image carriers such as static topology diagrams selected from power grid operation and maintenance files, real-time images of typical maintenance scenarios, and sample images under special environments (strong light / weak light). Specifically, there are three methods for collecting the initial images: The first method is to select multiple static topology diagrams from the power grid operation and maintenance archives, such as 1,000 or more images. The static topology diagrams cover channel verification tables and equipment layouts in different regions and periods. The channel verification table is a standardized checklist that ensures all key parameters and statuses are correct before the communication channel is put into use or during regular maintenance.

[0021] The second approach involves selecting multiple typical maintenance scenarios, including temporary service paths such as fiber optic cable detours and breaks. For each typical maintenance scenario, an 8-hour maintenance window is set daily, and one image frame is extracted every hour. In this embodiment, 50 typical maintenance scenarios are selected, resulting in 400 images per day.

[0022] The third method involves collecting special sample images with 15° distortion and 30% blur. These special sample images were obtained by taking pictures in strong light and low light environments using cameras with different resolutions.

[0023] Therefore, by using the three acquisition methods described above, initial images with different timestamps can be obtained. Each initial image contains at least one entity among a site, a device, and a port. A site is the basic physical unit in a power communication network that carries communication equipment, enables service access, and constitutes the network topology. A site is both the location of primary equipment in the power system (such as transformers and circuit breakers) and the deployment point of secondary systems (such as protection, control, and communication systems). Devices refer to all power equipment existing in the power communication network, and ports refer to the ports on power equipment.

[0024] Based on the obtained initial images, data annotation was performed on the initial images. Specifically, the LabelStudio data annotation tool was used to annotate the sites, devices, and ports in the initial images. For example, red rectangles were used to mark sites, blue rectangles to mark devices, and green rectangles to mark ports. The device model and port number for each port were also entered. The LabelStudio data annotation tool can also annotate the routing types between devices. Routing types mainly include primary, backup, and temporary. Temporary routes are added with timestamps and resource-restricted tags to facilitate subsequent determination of the route's existence period. For example, a temporary route with a timestamp of 2023-10-01 09:00-17:00 indicates that the temporary route existed between 09:00 and 17:00 on October 1, 2023. In addition, the LabelStudio data annotation tool was used to annotate the cabling methods deployed between entities. Cabling methods mainly include fiber optic cables, electrical cables, and wireless cables. The bandwidth supported by each cabling method was also annotated.

[0025] To ensure the accuracy of the annotations, a "dual-person cross-annotation + expert review" annotation mechanism is adopted. Specifically, the initial images are annotated simultaneously using the LabelStudio data annotation tool on different servers, and finally, experts review and verify the annotations on each initial image to ensure that the annotations are correct.

[0026] For the multiple initial images after annotation, this embodiment randomly divides the multiple initial images in a ratio of 7:2:1 to obtain a training set, a validation set and a test set, so as to ensure a balanced distribution of different types of initial images in each image set.

[0027] Based on the obtained training set, validation set, and test set, the edge terminal sends all three to the cloud.

[0028] Step S200: Adjust the weights of different entities in the initial image to obtain the target image corresponding to the initial image, and arrange the target images corresponding to each initial image in chronological order to obtain a time series image set.

[0029] like Figure 3 As shown, the cloud-based system includes a multi-scale feature enhancement module, a deformation compensation module, a hierarchical attention module, and a feature fusion module. The initial images in the training set are sequentially processed by each module in the cloud to obtain their respective target images. To facilitate the explanation of the working process of multiple modules working together in the cloud, steps S210 to S240 take the example of multiple modules processing an initial image together.

[0030] Step S210: Extract the regions corresponding to the site, device and port from the initial image to obtain the first local image, the second local image and the third local image.

[0031] Before the initial image enters the multi-scale feature enhancement module, an object detection algorithm is first used to identify the stations, devices, and ports in the initial image. Then, an image segmentation algorithm is used to extract the regions where the stations, devices, and ports are located and label them as the first local image, the second local image, and the third local image, respectively. The object detection algorithm for identifying entities in the initial image and the image segmentation algorithm for segmenting each region are both existing technologies.

[0032] In this embodiment, the initial image has a pixel resolution of 1920×1080. The extracted first, second, and third local images are uniformly converted into images with 3 channels but different heights and widths, such as... Figure 3 The transformed image is represented by 3×H×W. When the width H and height W are different, it may represent one of the first local image, the second local image, and the third local image.

[0033] Step S220: Perform convolution and deformation correction processing on the first local image, the second local image, and the third local image respectively to obtain the corresponding first processed image, the second processed image, and the third processed image.

[0034] The multi-scale feature enhancement module consists of three scale channels: a large-scale channel, a medium-scale channel, and a small-scale channel, with the receptive fields decreasing sequentially for each channel. In this embodiment, the large-scale channel uses a 16×16 convolutional layer with a receptive field of (16-1)×4+1=61, and is mainly used for convolution operations on the first local image. The medium-scale channel uses an 8×8 convolutional layer with a receptive field of 33, and is mainly used for convolution operations on the second processed image. The small-scale channel uses a 3×3 convolutional layer with a receptive field of 17, and is mainly used for convolution operations on the third processed image.

[0035] As can be seen from the above, by setting different scale channels and performing convolution on different local images using different scale channels, it is possible to capture entities of various scales in the initial image and avoid missing small-scale entities.

[0036] The deformation compensation module consists of three 3×3 convolutional layers, each connected to one of the scale channels. It corrects the deformation of the scale channel output image after convolution. Simultaneously, it employs bilinear interpolation resampling to ensure the accuracy of the output image. Specifically: ; ; in, Represents a pixel in a local image, ( , ) represents a pixel Pixels after deformation correction Represents the pixel after deformation correction The corresponding pixels after output, for example Let represent a pixel in the first local image, then ( , ) represents a pixel Pixels after deformation correction Represents the pixel in the first processed image. The corresponding pixels.

[0037] In this embodiment, the first local image is processed through a large-scale channel and a 3×3 convolutional layer connected to the large-scale channel, outputting the first processed image; the second local image is processed through a medium-scale channel and a 3×3 convolutional layer connected to the medium-scale channel, outputting the second processed image; and the third local image is processed through a small-scale channel and a 3×3 convolutional layer connected to the small-scale channel, outputting the third processed image. It is evident that the first, second, and third processed images undergo convolutional processing and deformation correction at different scales, and the entities (sites, devices, ports) in each processed image receive varying degrees of attention, providing technical assurance against missing small-scale entities.

[0038] Step S230: Perform noise suppression on the first and second processed images, and simultaneously perform noise suppression on the third processed image and increase the weight factor.

[0039] The hierarchical attention module employs a spatial attention + channel attention model. It adds masks to the first and second processed images to suppress background noise, enhancing the information representation of sites in the first image and devices in the second. Simultaneously, it adds a mask to the third processed image to suppress background noise and increase the weight multiplier of ports. Specifically, this is achieved through two fully connected layer products, resulting in ports with increased weights. The formula for calculating the weight W is: ,in, Indicates the global scaling factor. The enhancement coefficient is represented by W1 and W2, which represent two fully connected layers respectively. S is the scale factor of the port, which can usually be expressed as the pixel area occupied by the port in the initial image or the normalized size value of the pixel area.

[0040] Therefore, it can be seen that the hierarchical attention module can not only enhance the information expression ability of the stations in the first processed image, the devices in the second processed image, and the ports in the third processed image, but also further enhance the information expression ability of the ports in the third processed image, so as to facilitate the subsequent analysis of various entities of different scales in the image, thereby reducing the probability of missing small-scale entities.

[0041] Step S240: Fuse the first and second processed images after noise suppression, and the third processed image after noise suppression and weight increase, to obtain the target image.

[0042] The feature fusion module fuses the first and second processed images after noise suppression, as well as the third processed image after noise suppression and weighting, to obtain a 512-channel target image.

[0043] Therefore, each initial image will obtain its corresponding target image after going through the processing flow of steps S210 to S240. In this embodiment, the target images corresponding to each initial image are arranged in chronological order to obtain a time-series image set, in which multiple frames of target images in the time-series image set have a time-series relationship.

[0044] Step S300: For any target image in the time-series image set, identify the connection relationships between entities in the target image; wherein, the connection relationships include actual connection relationships based on physical cabling and temporary connection relationships based on temporary service paths.

[0045] The cloud-based system employs a temporal graph convolutional network to identify the connections between entities in any target image within a temporal image set. For example... Figure 4 As shown, for ease of explanation, steps S310 to S3... 0. Take the identification of the connection relationships between entities in one of the target images as an example.

[0046] Step S310: Represent entities in the target image as nodes and the connection relationships between nodes as edges to obtain the initial topology corresponding to the target image.

[0047] First, extract entities from the target image; entities are represented by h. i express, Then, nodes are used to replace the extracted entities, and edges are used to replace the connections between entities, thus obtaining the initial topology corresponding to the target image.

[0048] Step S320: For any node in the initial topology, determine whether the node meets the conflict condition. If yes, update the node; otherwise, retain the node.

[0049] In this embodiment, a conflict condition refers to a discrepancy between the connection status of nodes in the initial topology and the actual deployment status of the entity. For example, if the number of ports connected to the device in the actual deployment does not exceed 8, then when the number of ports corresponding to the nodes belonging to the device in the initial topology exceeds 8, an alarm message is generated to prompt maintenance personnel to update the nodes in the initial topology and pay attention to the actual device connection status in order to correct the routing.

[0050] Traverse all nodes in the initial topology, update nodes that meet the conflict conditions, and retain nodes that do not meet the conflict conditions to ensure that the initial topology is consistent with the actual deployment of the power communication network and improve the accuracy of the obtained initial topology.

[0051] Step S330: For any edge in the initial topology, perform the following operations: Step a: Assign initial weights to the edge based on the physical wiring between the entities at both ends of the edge; Step b: Adjust the initial weights based on the temporary business paths between the entities at both ends of the edge to obtain the first weight of the edge; Step c: Based on the initial weight or first weight of the edge, obtain the final weight of the edge; Specifically, an initial weight is assigned to the edge based on the physical cabling between the entities at both ends. For example, when detecting lines deployed between entities, the initial weight is assigned according to the confidence level of the detection result. The higher the confidence level, the greater the probability that the edge is a real physical cabling, so the initial weight is set larger. Then, temporary service paths are extracted from the maintenance work order. It is determined whether the edges in the initial topology are the extracted temporary service paths, that is, although there is a connection between entities, the connection is a temporary connection. If so, it is further determined whether the edge belongs to optical path detour / temporary optical cable connection, optical path interruption recovery connection, or other temporary connection. When: If a temporary connection is a detour / temporary fiber optic cable connection, then the first weight of that edge is... , , t represents the time when the edge disappears, and t0 represents the earliest time when the edge appears. This indicates the initial weight of the edge; If a temporary connection is a connection restored after an optical path interruption, then the first weight of that edge... , , t represents the time when the edge disappears, and t0 represents the earliest time when the edge appears. This indicates the initial weight of the edge; If a temporary connection belongs to another temporary connection, the initial weight of that edge is reduced to weaken it, thus obtaining a first weight. The reduction value can be fixed or non-fixed; in this embodiment, it is preferred to be non-fixed. For example, the initial weights of edges whose temporary connection belongs to other temporary connections (regardless of the initial weight size) are uniformly reduced to a first weight of 0.5, i.e., the first weight... After the temporary connection ends, the weights will be restored to their original initial values.

[0052] Finally, if the edge has a first weight, then the first weight is used as the final weight; otherwise, the initial weight is used as the final weight. Thus, by following steps a to c above, the final weight corresponding to each edge in the initial topology is obtained.

[0053] Step S340: Using a preset classification model, predict the connection relationships between entities in the target image based on the final weights of all nodes and all edges in the initial topology.

[0054] A pre-defined classification model, such as any of the traditional classification models like ResNet, VGGNet, or SIFT+, is used. The final weights of all nodes and edges in the initial topology are input into the selected classification model, which then predicts the connectivity relationships between entities in the target image. These connectivity relationships include actual connections based on physical wiring and temporary connections based on temporary service paths. The above classification model for predicting connectivity relationships between entities utilizes existing technology.

[0055] In one possible implementation, it is also necessary to retrieve the knowledge graph between entities, and construct the constraints of all nodes in the initial topology using the knowledge graph. When predicting the connections between entities, the classification model also needs to consider the constraints between nodes. Specifically, the constraints include: 1. Hard constraints: ; Where r and R hard These represent rules and sets of hard constraint rules, respectively. The sets contain information such as ports must belong to devices and devices have no more than 8 ports. The `violates(·)` function indicates that a rule violates the set of hard constraint rules. `I` represents an indicator function. If `violates(r)` is determined to be "true" (the set of hard constraint rules is violated), the indicator function `I(·)` takes the value 1, thus triggering a penalty. When triggering a penalty, the function needs to be multiplied by a fixed coefficient C. In this embodiment, C=10. If `violates(r)` is determined to be "false" (the set of hard constraint rules is not violated), then `I(·)` takes the value 0, and no penalty is generated, i.e., there is no need to multiply by the fixed coefficient C.

[0056] 2. Soft constraints: ; Rsoft represents a set of soft constraint rules. The information contained in this set needs to be flexibly determined in conjunction with resource conditions. For example, a port bandwidth requirement of ≥10G should be strictly met when resources are sufficient, but can be appropriately relaxed when resources are limited. r The standard threshold for the soft constraint rule r is represented by x, which is the ideal target value required by the rule. T This represents the prediction value of the classification model for the soft constraint rule r; This represents the basic penalty coefficient, which is used to control the basic penalty intensity when soft constraint rule r violates the set of soft constraint rules, ensuring that the penalty signal is significant enough but not extreme. This represents the resource coefficient, used to adapt to the resource levels of different sites.

[0057] 3. Entity detection constraints: ; Where N represents the total number of entities in the training samples, such as the total number of stations, devices, and ports in a single initial image, y i This represents the actual category label of the i-th entity, such as site = 0, device = 1, port = 2; Pt i This represents the probability that the classification model predicts the true category of the i-th entity. For example, the probability that the classification model predicts the i-th entity as a port is 0.9. This represents the class balance coefficient, which is used to balance the differences in the number of samples of different types of entities. For example, if there are more samples at the port, the class balance coefficient is set to a smaller value to avoid the classification model being biased towards the port. This represents the focusing coefficient, which is set in this embodiment. This is used to reduce the loss weight of easily classified entity samples, so that the classification model focuses on difficult-to-classify entity samples.

[0058] In other words, the core function of entity detection constraints is to solve the problem of entity class imbalance in the topology of power communication networks. For example, when the number of ports is much greater than the number of sites, entity detection constraints can prevent the classification model from being biased towards predicting the port class with the larger number of predictions.

[0059] 4. Dynamic relational reasoning constraints: ; L cls This represents the loss for connection type classification. This loss uses cross-entropy loss and is primarily used to optimize the classification model's accuracy in identifying the three connection types: optical fiber, electrical cable, and wireless. Where k=1,2,3, k=1 represents optical fiber, k=2 represents electrical cable, and k=3 represents wireless. Y k The actual label indicating the connection type, L represents the predicted probability of the classification model for the k-th connection type; reg This represents the connectivity attribute regression loss, primarily used to optimize the prediction accuracy of classification models for connectivity attributes such as bandwidth and transmission distance. Where x represents the actual value of the connection attribute, such as the actual bandwidth of a connection being 100G and the actual transmission distance being 5km. This represents the predicted value of the classification model for the connection attribute. For example, the classification model predicts that the bandwidth of the connection is 95G and the transmission distance is 4.8km. The 0.7 and 0.3 mentioned above are pre-set weight values. The weight value corresponding to the connection type classification loss is set to be greater than the weight value of the connection attribute regression loss because the connection type directly determines the direction of operation and maintenance, and has a higher priority than the attribute value. Therefore, it needs to be optimized during training.

[0060] 5. General constraints: ; As can be seen, the total constraint is determined by hard constraints, soft constraints, entity detection constraints, and dynamic relationship reasoning constraints, and 0.5 and 0.3 are both pre-set weight values.

[0061] In this embodiment, when the classification model predicts the connection relationship between entities, it combines the above five constraints between nodes to ensure the accuracy of the output prediction result, that is, to ensure the accuracy of the connection relationship between entities in the predicted target image.

[0062] Step S400: Generate a dynamic topology based on the connection relationships between entities in each target image in the time-series image set.

[0063] As can be seen from step S300, each frame of the target image corresponds to an initial topological structure. The initial topological structure represents the static connection relationship between entities in this frame, that is, the connection relationship between entities is predicted by the classification model. In step S400, according to the time order of the target image in the temporal image set, the discrete initial topological structures are temporally associated and integrated to finally construct a dynamic topological structure that shows the evolution of entity connection relationship over time.

[0064] Finally, the cloud platform outputs the entity attributes in JSON format and the labeled images in PNG format for each frame of the target image based on the dynamic topology, enabling maintenance personnel to perform maintenance and management of the power communication network based on the output data. Of course, the cloud platform also sends the local dynamic topology related to each edge terminal to the corresponding edge terminal. In this embodiment, the edge terminal receives the local dynamic topology within a 5km radius. The edge terminal uses a teacher model and a student model to sequentially perform knowledge distillation on the received dynamic topology, and uses channel pruning technology to remove redundant convolution kernels and reduce model parameters. This ensures that the local dynamic topology generated by the model is adapted to the edge terminal, facilitating the edge terminal to obtain the local JSON format entity attributes and PNG format labeled images of the power communication network after analysis based on the local dynamic topology, thereby enabling more accurate maintenance of the local power communication network.

[0065] In summary, the implementation principle of the automatic generation method for the topology of a power communication network according to the embodiments of this application is as follows: First, the edge terminal collects initial images containing at least one entity among stations, devices, and ports at different time points. After feature enhancement processing of the entities in each initial image, a target image corresponding to the initial image is obtained. The information expression ability of each entity in the target image is amplified to a certain extent, thus avoiding the situation where small-scale entities are missed. Then, the target images corresponding to each initial image are arranged in chronological order to obtain a time-series image set composed of multiple frames of target images with temporal relationships. Second, for any target image in the time-series image set, the cloud first constructs an initial topology for the target image, then adjusts the weights of nodes and edges in the initial topology, and constructs various constraints based on the knowledge graph. Using a classification model, based on the weights of nodes and edges in the initial topology and various constraints, the true connection relationship between entities in the target image is predicted. The classification model integrates multiple factors to predict the connection relationship of entities, ensuring the accuracy of the obtained connection relationship. Finally, based on the temporal order of the target images in the temporal image set, the discrete initial topology is temporally correlated and integrated to construct a dynamic topology that shows the evolution of entity connection relationships over time, which facilitates the maintenance and management of the power communication network based on this dynamic topology.

[0066] It should be noted that the sequence numbers of the steps in the above embodiments do not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application. In practical applications, all the above possible implementation methods can be arbitrarily combined in a combined manner to form possible embodiments of this application, which will not be described in detail here.

[0067] Based on the same inventive concept, this application also provides an electronic device, including a processor and a memory, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute an automatic topology generation method for a power communication network according to any of the above embodiments.

[0068] In an exemplary embodiment, an electronic device is provided, such as Figure 5 As shown, Figure 5 The illustrated electronic device 500 includes a processor 501 and a memory 503. The processor 501 and the memory 503 are connected, for example, via a bus 502. Optionally, the electronic device 500 may also include a transceiver 504. It should be noted that in practical applications, the transceiver 504 is not limited to one type, and the structure of this electronic device 500 does not constitute a limitation on the embodiments of this application.

[0069] Processor 501 may be a CPU (Central Processing Unit), a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. It may implement or execute the various exemplary logic blocks, modules, and circuits described in conjunction with the disclosure of this application. Processor 501 may also be a combination that implements computational functions, such as including one or more microprocessor combinations, a combination of a DSP and a microprocessor, etc.

[0070] Bus 502 may include a pathway for transmitting information between the aforementioned components. Bus 502 may be a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus, etc. Bus 502 can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 5The bus is represented by a single thick line, but this does not mean that there is only one bus or one type of bus.

[0071] The memory 503 may be a ROM (Read Only Memory) or other type of static storage device capable of storing static information and instructions, RAM (Random Access Memory) or other type of dynamic storage device capable of storing information and instructions, or an EEPROM (Electrically Erasable Programmable Read Only Memory), CD-ROM (Compact Disc Read Only Memory) or other optical disc storage, optical disc storage (including compressed optical discs, laser discs, optical discs, digital universal optical discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium capable of carrying or storing desired program code in the form of instructions or data structures and accessible by a computer, but not limited thereto.

[0072] The memory 503 stores computer program code that executes the scheme of this application, and its execution is controlled by the processor 501. The processor 501 executes the computer program code stored in the memory 503 to implement the content shown in the foregoing method embodiments.

[0073] Among them, electronic devices include, but are not limited to: mobile terminals such as mobile phones, laptops, digital radio receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), and in-vehicle terminals (such as in-vehicle navigation terminals), as well as fixed terminals such as digital TVs and desktop computers. Figure 5 The electronic device shown is merely an example and should not impose any limitation on the functionality and scope of use of the embodiments of this application.

[0074] Based on the same inventive concept, this application also provides a storage medium storing a computer program, wherein the computer program is configured to execute, at runtime, a method for automatically generating the topology of a power communication network according to any of the above embodiments.

[0075] Those skilled in the art will clearly understand that the specific working process of the systems, devices, and modules described above can be referred to the corresponding process in the foregoing method embodiments. For the sake of brevity, it will not be repeated here.

[0076] Those skilled in the art will understand that the technical solution of this application, or all or part of it, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several program instructions to cause an electronic device (e.g., a personal computer, server, or network device) to execute all or part of the steps of the methods described in the embodiments of this application when running the program instructions. The aforementioned storage medium includes various media capable of storing program code, such as a USB flash drive, portable hard drive, read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.

[0077] Alternatively, all or part of the steps of the foregoing method embodiments can be implemented by hardware (such as electronic devices like personal computers, servers, or network devices) associated with program instructions. The program instructions can be stored in a computer-readable storage medium. When the program instructions are executed by the processor of the electronic device, the electronic device executes all or part of the steps of the methods described in the embodiments of this application.

[0078] The above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit it. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that within the spirit and principles of this application, modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein; and these modifications or substitutions do not cause the corresponding technical solutions to leave the protection scope of this application.

Claims

1. A method for automatically generating the topology of a power communication network, characterized in that, include: Acquire initial images containing at least one entity among sites, devices, and ports at different time points; Adjust the weights of different entities in the initial image to obtain the target image corresponding to the initial image, and arrange the target images corresponding to each initial image in chronological order to obtain a time-series image set; For any target image in the time-series image set, identify the connection relationships between entities in the target image; wherein, the connection relationships include actual connection relationships based on physical cabling and temporary connection relationships based on temporary service paths; A dynamic topology is generated based on the connection relationships between entities in each target image in the time-series image set.

2. The method according to claim 1, characterized in that, The step of adjusting the weights of different entities in the initial image to obtain a target image corresponding to the initial image includes: From the initial image, the regions corresponding to the station, device, and port are extracted respectively to obtain a first local image, a second local image, and a third local image; Convolution and deformation correction processes are performed on the first local image, the second local image, and the third local image respectively to obtain the corresponding first processed image, second processed image, and third processed image. Noise suppression is applied to the first and second processed images, while noise suppression is applied to the third processed image and the weighting factor is increased. The target image is obtained by fusing the first processed image after noise suppression, the second processed image, and the third processed image after noise suppression and weight increase.

3. The method according to claim 2, characterized in that, The method further includes: The first local image is convolved using a 16×16 convolutional layer; and The second local image is convolved using an 8×8 convolutional layer; and The third local image is convolved using a 3×3 convolutional layer.

4. The method according to claim 2, characterized in that, The weight after increasing the port weight by a factor of 1 is calculated using the following formula: , in, Indicates the global scaling factor. The symbol represents the enhancement coefficient, W1 and W2 represent the two fully connected layers respectively, and S represents the scale factor of the port.

5. The method according to claim 1, characterized in that, The step of identifying the connection relationships between entities in any target image in the time-series image set includes: By representing entities in the target image with nodes and representing the connections between nodes with edges, an initial topological structure corresponding to the target image is obtained. For any node in the initial topology, determine whether the node meets the conflict condition; if so, update the node. For any edge in the initial topology, perform the following steps: Step a: Assign initial weights to the edge based on the physical wiring between the entities at both ends of the edge; Step b: Adjust the initial weights according to the temporary business paths between the entities at both ends of the edge to obtain the first weight of the edge; Step c: Based on the initial weight or first weight of the edge, obtain the final weight of the edge; Using a pre-defined classification model, the connection relationships between entities in the target image are predicted based on the final weights of all nodes and edges in the initial topology.

6. The method according to claim 5, characterized in that, The method further includes: Retrieve the knowledge graph between entities; Based on the knowledge graph, construct the constraints for all nodes in the initial topology; Using a pre-defined classification model, the connection relationships between entities in the target image are predicted based on all nodes in the initial topology, the constraints of all nodes, and the final weights of all edges.

7. The method according to claim 6, characterized in that, The constraints include: Hard constraints: ; where r and R hard Let R represent the rule and the set of hard constraint rules, respectively. The violates(·) function indicates that the rule violates the set of hard constraint rules. I represents the indicator function. If (violates(r)) is determined to be a violation of the set of hard constraint rules, the indicator function (I(·)) takes the value of 1. In this case, the function needs to be multiplied by a fixed coefficient C. Otherwise, (I(·)) takes the value of 0. Soft constraints: Among them, R soft Let t represent the set of soft constraint rules. r x represents the standard threshold of the soft constraint rule r. T This represents the prediction value of the classification model for the soft constraint rule r. Indicates the base penalty coefficient. Indicates the resource coefficient; Entity detection constraints: Where N represents the total number of entities in a single initial image, and y i Pt represents the true category label of the i-th entity. i This represents the probability predicted by the classification model for the true category of the i-th entity. Represents the category balance coefficient. Indicates the focusing coefficient; Dynamic relational reasoning constraints: Among them, L cls This represents the loss for connection type classification. Where k=1,2,3, k=1 represents optical fiber, k=2 represents electrical cable, and k=3 represents wireless. Y k The actual label indicating the connection type, L represents the predicted probability of the classification model for the k-th connection type; reg This represents the regression loss based on connection properties. Where x represents the actual value of the connection attribute, This represents the predicted value of the classification model for the connectivity attribute; General constraints: .

8. The method according to claim 6, characterized in that, The step of generating a dynamic topology based on the connection relationships between entities in each target image of the time-series image set includes: Obtain the initial topological structure corresponding to each target image in the time-series image set; Based on the temporal order of each target image in the temporal image set, the initial topology is temporally correlated and integrated to obtain a dynamic topology that shows the evolution of entity connection relationships over time.

9. The method according to claim 5, characterized in that, After acquiring initial images containing at least one entity among sites, devices, and ports at different time points, the method further includes: The sites, devices, and ports in the initial image were labeled using the LabelStudio data annotation tool.

10. An automatic topology generation system for a power communication network, used to execute the method as described in any one of claims 1-9, characterized in that, include: An edge terminal is used to acquire initial images containing at least one entity among sites, devices, and ports at different points in time. The cloud, which is communicatively connected to at least one edge terminal, is configured to: Adjust the weights of different entities in the initial image to obtain the target image corresponding to the initial image, and arrange the target images corresponding to each initial image in chronological order to obtain a time-series image set; For any target image in the time-series image set, identify the connection relationships between entities in the target image; wherein, the connection relationships include actual connection relationships based on physical cabling and temporary connection relationships based on temporary service paths; A dynamic topology is generated based on the connection relationships between entities in each target image in the time-series image set.