Substation scene change monitoring method and system based on connected domain optimization
By applying deep learning models and connectivity domain optimization technology in substation hidden danger identification, the problem of insufficient accuracy and efficiency of hidden danger identification in the existing technology is solved, and more efficient and reliable hidden danger identification is achieved.
Patent Information
- Application Number
- CN202411821465.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-11
- Publication Date
- 2025-04-11
AI Technical Summary
The existing methods of substation hidden danger identification rely on manual inspection and manual recording, which have problems such as insufficient timeliness, accuracy and comprehensiveness of data acquisition, and the misjudgment rate of traditional image processing technology is high.
The substation scene change monitoring method based on connectivity domain optimization is adopted, and image recognition is recognized using deep learning models (such as Transformer models), and the change map is generated, and the recognition reliability is improved by analyzing the connectivity domain and filtering small-area noise.
It realizes accurate identification of substation scene changes, improves the reliability of hidden danger identification, reduces misjudgment, and significantly improves the response speed of the hidden danger detection system.
Smart Images

Figure CN119810735A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field related to substation monitoring, and specifically, to a substation scene change monitoring method and system based on connectivity domain optimization. Background Art
[0002] The statements in this section merely provide background information related to the present disclosure and do not necessarily constitute prior art.
[0003] With the continuous expansion of the scale of power grids and the increase in the number of substations, the operational safety of substations has become increasingly important. In particular, the development of smart grids has accelerated the demand for efficient and safe hidden danger identification systems. As an important hub of the power grid, the operating status of substations is directly related to the stability and safety of the power system. Timely and accurate identification and elimination of potential hidden dangers in substations are of vital importance to ensuring the stable operation of the power grid. However, existing hidden danger identification methods mainly rely on manual inspections and manual records, and there are significant limitations in the timeliness, accuracy and comprehensiveness of data acquisition. These limitations may directly affect the accuracy and efficiency of substation hidden danger identification, and it is difficult to meet the requirements of modern power systems for efficient and reliable hidden danger identification.
[0004] The inventors found in their research that the manual recording and empirical judgment methods that rely on manual inspections are easily affected by human factors and may lead to inaccurate data, especially when hidden dangers are complex and conditions are changing, misjudgment and missed judgments often occur. At present, image recognition technology is also used to detect foreign body intrusion in substations, but the generated change graphs, noise points and minor changes are often misjudged as hidden dangers or fail to be correctly identified, resulting in a high misjudgment rate in traditional image processing technology. Summary of the invention
[0005] In order to solve the above problems, the present invention proposes a substation scene change monitoring method and system based on connected domain optimization, and uses a deep learning model for image recognition, so that the system can accurately identify the changed areas in the image; and then further improve the reliability of recognition and effectively reduce misjudgment by analyzing the connected domain and filtering small area noise points.
[0006] In order to achieve the above objectives, the present disclosure adopts the following technical solutions:
[0007] One or more embodiments provide a method for monitoring substation scene changes based on connectivity domain optimization, comprising the following steps:
[0008] Acquire substation scene images at different time points;
[0009] Input the acquired image into the trained Transformer model to generate a change graph of the image at two time points;
[0010] Identify the connected domains in the change graph, filter out areas with an area smaller than the average connected domain area, perform noise filtering, filter the updated change graph based on the connected domain, and output the change areas of the substation scene graph at two time points.
[0011] One or more embodiments provide a substation scene change monitoring system based on connectivity domain optimization, including:
[0012] An acquisition module is configured to acquire substation scene images at different time points;
[0013] a change graph recognition module, configured to input the acquired image into the trained Transformer model to generate a change graph of the image at two time points;
[0014] The filtering module is configured to identify the connected domains in the change graph, filter out areas whose areas are smaller than the average connected domain area, and perform noise filtering operations, filter the updated change graph based on the connected domain, and output the change areas of the substation scene graph at two time points.
[0015] An electronic device includes a memory and a processor, and computer instructions stored in the memory and running on the processor. When the computer instructions are run by the processor, the steps in the above-mentioned substation scene change monitoring method based on connected domain optimization are completed.
[0016] A computer-readable storage medium is used to store computer instructions. When the computer instructions are executed by a processor, the steps in the above-mentioned substation scene change monitoring method based on connected domain optimization are completed.
[0017] Compared with the prior art, the present invention has the following beneficial effects:
[0018] In this disclosure, the deep learning model is used for image recognition, which can accurately identify the changed areas in the image; and by analyzing the connected domain and filtering small area noise points, the change points in the substation monitoring image can be effectively identified, which can further improve the reliability of identification and effectively reduce misjudgment. The newly added noise point filtering mechanism reduces unnecessary computing burden, optimizes the overall algorithm performance, accelerates the hidden danger identification process, and significantly improves the response speed of the hidden danger detection system through intelligent connected domain analysis and area screening.
[0019] The advantages of the present disclosure and the advantages of additional aspects will be described in detail in the following specific embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] The accompanying drawings constituting a part of the present disclosure are used to provide a further understanding of the present disclosure. The exemplary embodiments of the present disclosure and the description thereof are used to explain the present disclosure but do not constitute a limitation of the present disclosure.
[0021] Figure 1 is a flow chart of the monitoring method of Embodiment 1 of the present disclosure;
[0022] Figure 2 is a schematic diagram of the structure of the Transformer model of Embodiment 1 of the present disclosure;
[0023] Figure 3 It is a schematic diagram of the training process of Example 1 of the present disclosure. DETAILED DESCRIPTION
[0024] The present disclosure is further described below in conjunction with the accompanying drawings and embodiments.
[0025] It should be noted that the following detailed descriptions are exemplary and are intended to provide further explanation of the present disclosure. Unless otherwise specified, all technical and scientific terms used herein have the same meanings as those commonly understood by those skilled in the art to which the present disclosure belongs.
[0026] It should be noted that the terms used herein are only for describing specific embodiments and are not intended to limit exemplary embodiments according to the present disclosure. As used herein, unless the context clearly indicates otherwise, the singular form is also intended to include the plural form. In addition, it should be understood that when the terms "comprising" and / or "including" are used in this specification, it indicates the presence of features, steps, operations, devices, components and / or combinations thereof. It should be noted that, in the absence of conflict, the various embodiments in the present disclosure and the features in the embodiments can be combined with each other. The embodiments will be described in detail below in conjunction with the accompanying drawings.
[0027] Example 1
[0028] In the technical solutions disclosed in one or more embodiments, Figures 1 to 3 As shown, a method for monitoring substation scene changes based on connected domain optimization includes the following steps:
[0029] Step 1: Obtain substation scene images at different time points;
[0030] Step 2: Input the acquired image into the trained Transformer model to generate a change graph of the image at two time points;
[0031] Step 3: Identify the connected domains in the change graph, filter out areas with an area smaller than the average connected domain area, and perform noise filtering operations. Filter the updated change graph based on the connected domain, and output the change areas of the substation scene graph at two time points.
[0032] In this embodiment, the deep learning model is used for image recognition, so that the system can accurately identify the changed areas in the image; then by analyzing the connected domain and filtering small area noise points, the change points in the substation monitoring image can be effectively identified, which can further improve the reliability of identification and effectively reduce misjudgment. The newly added noise point filtering mechanism reduces unnecessary computing burden, optimizes the overall algorithm performance, accelerates the hidden danger identification process, and significantly improves the response speed of the hidden danger detection system through intelligent connected domain analysis and area screening.
[0033] In step 1, the images at two time points can be used as comparison images. They are required to be collected by the same camera at the same angle and focal length, and the time interval should not be too long. Except for the obvious changes in the hidden dangers in the image, the other background, lighting and other factors have little change.
[0034] In step 2 above, a Transformer-based scene change detection model (TransCD) analysis script is built. The TransCD structure includes a CNN backbone network, Siamese ViT, and a prediction head.
[0035] In step 2, a change graph of the images at two time points is generated, including the following steps:
[0036] Step 21: Input the acquired image into the encoder of the Transformer for multi-scale encoding, model the image from a low-dimensional space to a high-dimensional space, generate embedded semantic tags, and obtain an encoded feature map;
[0037] Step 22: Input the obtained semantic tags into the Siamese ViT (Visual Transformer) module of Transformer, extract the global context information in the images at different time points by modeling the semantic information and establishing long-distance relationships between each tag, and obtain the global feature maps of the images at different time points;
[0038] Step 23: Based on the obtained global features, a feature difference map of the two time point labels is calculated, and then the high-level feature representation is mapped back to the pixel space through the decoder to generate a change map;
[0039] The change map represents the change area in two images acquired at different time points.
[0040] In step 21, before encoding the image data, preprocessing is performed to make it compatible with the encoder; optionally, the image may be divided into small patches (patches), each small patch is flattened into a one-dimensional vector, and embedded into a set dimensional space through a linear transformation;
[0041] The encoder includes multiple convolution layers, and features of the preprocessed image are extracted based on multiple convolution layers.
[0042] In order to preserve the spatial position information of the image block, the Transformer encoder adds position encoding to each embedded image block. This position encoding helps the model understand the relative position of the image block, so that the spatial information is effectively preserved during the multi-scale encoding process;
[0043] In step 22, the method for extracting global features of images at different time points includes the following steps:
[0044] Step 221: input the semantically labeled encoded feature map output by the CNN backbone network into the Siamese ViT (abbreviated as: visual Transformer) module of the Transformer; Figure 2 The marked encoded feature map is F raw; the final updated feature image is F new;
[0045] Step 222: Serialize the feature graph of the semantic tag based on the Tokenizer module, perform position embedding (PositionEmbedding), add the position information on the feature graph to the semantic tag, and obtain a feature sequence containing the added position information;
[0046] Specifically, the two-dimensional image features of the encoded feature map are flattened and expanded into a one-dimensional sequence, and a vector representation is generated for each pixel or image block to obtain the serialized features;
[0047] Perform position embedding. Specifically, add position coding to each serialized feature vector to maintain the image spatial position information and prevent the loss of feature arrangement information in space, thus obtaining a feature sequence with position coding.
[0048] In the scheme of this step 222, spatial information is maintained by position embedding to ensure that the model can understand the relative position relationship between features;
[0049] Step 223, Siamese ViT adopts a dual-branch input method, inputs the two feature sequences corresponding to the images at the two time points into two ViT network branches respectively, and models based on the self-attention mechanism to obtain the feature sequence enhanced by self-attention; each feature sequence includes global context information;
[0050] Specifically, in each ViT branch, the relationship between each tag is calculated through the self-attention mechanism to capture global information. This can enhance the relevance of each tag in long-distance relationships and highlight semantic consistency.
[0051] Step 224, the feature sequences after self-attention enhancement from the two branches are transposed and reconstructed (Subtraction and Absolution) to restore the context-rich markers to feature maps, that is, convert them back to feature maps of image dimensions to obtain global feature maps, which provide a basis for the prediction head to generate change maps.
[0052] In step 23, in the prediction head, the global feature maps of the two time points are subtracted element by element and the absolute value is taken to obtain a feature difference map, namely a change map, and the formula is as follows:
[0053] change map=E ph (|resh ape(transpose(T new0 ))-resh ape(transpose(T new1 ))|)
[0054] Among them, T new0 and T new1 represents the semantic label of the global feature map corresponding to different time images, E ph This indicates a prediction head operation.
[0055] A further technical solution, identifying connected domains in the change graph, can be implemented using the function connectedComponents With Stats in OpenCV;
[0056] Among them, OpenCV (Open Source Computer Vision Library) is an open source computer vision and image processing library;
[0057] Specifically, call the connectedComponentsWithStats function, which calculates all connected domains in the image and returns the following information:
[0058] The label of each connected domain;
[0059] The bounding box of each connected domain;
[0060] The area (number of pixels) of each connected domain;
[0061] The returned result is a label matrix (of the same size as the input image) and an array containing statistics for each connected component.
[0062] Calculate the average connected domain area: Calculate the average area of all connected domains based on the statistical information of connectedComponentsWithStats;
[0063] Area filtering: Traverse all connected domains, mark the connected domains with an area smaller than the average area as noise and remove them.
[0064] Optionally, a condition can be set on the label matrix to directly set the labels of small-area connected domains to 0 (indicating no change) to achieve denoising.
[0065] Furthermore, to remove isolated pixels and connected domains with an area smaller than a threshold, morphological operations (such as opening operations) can be used to smooth the boundaries and remove isolated noise points; or, a small convolution kernel (such as 3x3) can be applied to the binary image for opening operations to remove some small noise points and retain larger change areas. Larger change areas can use the threshold comparison method, and areas larger than the set value are considered large change areas.
[0066] Furthermore, during the training of the Transformer model, a comparative test set can be built by collecting normal and hidden danger images of the substation. The comparative images here are required to be collected by the same camera at the same angle and focal length, and the time interval should not be too long. Except for the obvious changes in the hidden dangers in the image, the other background, lighting and other factors have little change; a data set is built based on the reference image and the hidden danger image for training and testing; the training process includes the following steps:
[0067] Step S1, obtaining substation scene images in the data set, each set of comparison images includes a reference image and a test image, and marking the changed area;
[0068] Step S2: input the acquired image into the Transformer model for training to generate a change graph of the image at two time points;
[0069] Step S3, identifying the connected domain in the change graph, filtering out the areas with an area smaller than the average connected domain area, and performing a noise point filtering operation, comparing the feature graphs after the connected domain filtering, and outputting the changed areas of the two compared substation scene graphs;
[0070] Step S4, based on the marked change area and the identified change area, calculate the loss function value, adjust the model parameters and iterate the above steps until the training accuracy requirement is met to obtain the trained model;
[0071] In this embodiment, a deep learning model is used for image recognition, so that the system can accurately identify the changed areas in the image; the connected components with the connected component with the statistical function is used to analyze the connected domain and filter small noise points, so as to further improve the reliability of recognition and effectively reduce misjudgment.
[0072] Example 2
[0073] Based on Example 1, this embodiment provides a substation scene change monitoring system based on connectivity domain optimization, including:
[0074] An acquisition module is configured to acquire substation scene images at different time points;
[0075] a change graph recognition module, configured to input the acquired image into the trained Transformer model to generate a change graph of the image at two time points;
[0076] The filtering module is configured to identify the connected domains in the change graph, filter out areas whose areas are smaller than the average connected domain area, and perform noise filtering operations, filter the updated change graph based on the connected domain, and output the change areas of the substation scene graph at two time points.
[0077] It should be noted here that the various modules in this embodiment correspond one-to-one to the various steps in Example 1, and the specific implementation process is the same, which will not be repeated here.
[0078] Example 3
[0079] Based on Example 1, this embodiment provides an electronic device, including a memory and a processor, and computer instructions stored in the memory and running on the processor. When the computer instructions are executed by the processor, the steps in the substation scene change monitoring method based on connected domain optimization described in Example 1 are completed.
[0080] Example 4
[0081] Based on Example 1, this embodiment provides a computer-readable storage medium for storing computer instructions. When the computer instructions are executed by a processor, the steps in the substation scene change monitoring method based on connectivity domain optimization described in Example 1 are completed.
[0082] The above description is only a preferred embodiment of the present disclosure and is not intended to limit the present disclosure. For those skilled in the art, the present disclosure may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present disclosure shall be included in the protection scope of the present disclosure.
[0083] Although the above describes the specific implementation methods of the present disclosure in conjunction with the accompanying drawings, it is not intended to limit the scope of protection of the present disclosure. Technical personnel in the relevant field should understand that on the basis of the technical solution of the present disclosure, various modifications or variations that can be made by those skilled in the art without creative work are still within the scope of protection of the present disclosure.
Claims
1. A method for monitoring substation scene changes based on connected domain optimization, characterized in that: The steps include: Acquire substation scene images at different time points; Input the acquired image into the trained Transformer model to generate a change graph of the image at two time points; Identify the connected domains in the change graph, filter out areas with an area smaller than the average connected domain area, perform noise filtering, filter the updated change graph based on the connected domain, and output the change areas of the substation scene graph at two time points.
2. The method for monitoring substation scene changes based on connected domain optimization according to claim 1, characterized in that: Generating a change graph of images at two time points includes the following steps: The acquired image is input into the encoder of Transformer for multi-scale encoding, the image is modeled from low-dimensional space to high-dimensional space, and embedded semantic tags are generated to obtain the encoded feature map; The obtained semantic tags are used to extract global context information in images at different time points by modeling semantic information and establishing long-distance relationships between each tag, thus obtaining global feature maps of images at different time points. Based on the obtained global features, the feature difference map of the two time point labels is calculated, and then the high-level feature representation is mapped back to the pixel space through the decoder to generate a change map.
3. The method for monitoring substation scene changes based on connected domain optimization according to claim 2, characterized in that: Before encoding the image data, preprocessing is performed to divide the image into small blocks, flatten each small block into a one-dimensional vector, and embed it into the set dimensional space through linear transformation.
4. The method for monitoring substation scene changes based on connected domain optimization according to claim 2, characterized in that: The method for extracting global features of images at different time points includes the following steps: The semantically labeled encoded feature map output by the CNN backbone network is input into the SiameseViT module of the Transformer; The feature map of the semantic tag is serialized and positionally embedded, and the position information on the feature map is added to the semantic tag to obtain a feature sequence containing the added position information; Siamese ViT uses a dual-branch input method to input the two feature sequences corresponding to the images at the two time points into two ViT network branches respectively, and then models the self-attention mechanism to obtain the feature sequence enhanced by self-attention. The feature sequences after self-attention enhancement from the two branches are transposed and reconstructed to restore the tags containing contextual information into feature maps to obtain the global feature map.
5. The method for monitoring substation scene changes based on connected domain optimization according to claim 1, characterized in that: In the prediction head, the global feature maps of two time points are subtracted element by element and the absolute value is taken to obtain a feature difference map.
6. The method for monitoring substation scene changes based on connected domain optimization according to claim 1, characterized in that: Filter out areas smaller than the average connected domain area and perform noise filtering operations. Specifically, remove isolated pixels and connected domains with small areas, use morphological operations to smooth boundaries and remove isolated noise points.
7. The method for monitoring substation scene changes based on connected domain optimization according to claim 1, characterized in that: Filter out areas with an area smaller than the average connected domain area and perform noise filtering operations. Specifically: remove isolated pixels and connected domains with an area smaller than a set value, use a convolution kernel to perform an opening operation to remove noise and retain the changed areas with an area larger than the set value.
8. The substation scene change monitoring system based on connected domain optimization is characterized by: include: An acquisition module is configured to acquire substation scene images at different time points; a change graph recognition module, configured to input the acquired image into the trained Transformer model to generate a change graph of the image at two time points; The filtering module is configured to identify the connected domains in the change graph, filter out areas whose areas are smaller than the average connected domain area, and perform noise filtering operations, filter the updated change graph based on the connected domain, and output the change areas of the substation scene graph at two time points.
9. An electronic device, characterized in that: It includes a memory and a processor, and computer instructions stored in the memory and running on the processor. When the computer instructions are run by the processor, the steps in the substation scene change monitoring method based on connected domain optimization described in any one of claims 1 to 7 are completed.
10. A computer-readable storage medium, characterized in that: Used to store computer instructions, which, when executed by a processor, complete the steps in the substation scene change monitoring method based on connected domain optimization as described in any one of claims 1 to 7.