Distribution network ground screen corrosion detection method and device based on parallel double-hop depth residual BP neural network
Through the distribution network corrosion detection method of parallel double-hop depth residual BP neural network, the double-hop depth residual model is used to perform shallow low nonlinear feature extraction and BP neural network for corrosion detection, which solves the problem of poor manual detection accuracy and achieves efficient and accurate corrosion detection.
Patent Information
- Application Number
- CN202510498367.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-21
- Publication Date
- 2025-07-08
AI Technical Summary
The existing corrosion detection methods for distribution networks mainly rely on manual detection, resulting in poor detection accuracy. Traditional methods are prone to missed detection and false detection when facing complex and changeable corrosion patterns.
The detection method based on parallel double-hop deep residual BP neural network is adopted, shallow low nonlinear feature extraction is performed through double-hop deep residual model, and corrosion detection is performed in combination with BP neural network, and multi-GPU parallel computing is used to accelerate the training and inference process.
It improves the accuracy and efficiency of corrosion detection, can process a larger range of data, significantly shortens detection time, and improves the real-time and reliability of detection.
Smart Images

Figure CN120279000A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of artificial intelligence technology, and in particular, to a method and device for detecting corrosion of a distribution network grounding grid based on a parallel double-hop deep residual BP neural network. Background Art
[0002] Corrosion of the distribution network grounding grid refers to the oxidation and corrosion of metal components such as steel and iron in the distribution network grounding grid due to long-term exposure to harsh environments and being eroded by factors such as moisture, salt spray, and acid rain. Corrosion not only affects the structural integrity of the grounding grid but also leads to a decline in the reliability of power equipment, increases maintenance costs, and may even cause power accidents in severe cases, affecting the stable operation of the power system. At the same time, the corrosion of the grounding grid also significantly reduces the load-bearing capacity of the distribution network grounding grid, affects the conductivity of the grounding system, and further affects the safety of the power system.
[0003] As the service life of the distribution network grounding grid increases, the corrosion problem becomes more serious, especially in humid and corrosive climatic conditions, where the degree of corrosion intensifies and the maintenance and inspection work become more complex. Therefore, timely and accurately detecting the corrosion state of the distribution network grounding grid is of great significance for ensuring the safe operation of the power system and extending the service life of equipment.
[0004] Most of the existing methods for detecting corrosion of the distribution network grounding grid are carried out manually. However, the manual detection method is not only time-consuming and easily affected by human factors, but also due to the concealment of the grounding grid corrosion, with different degrees and types of corrosion, the manual detection method is prone to missed detection and false detection when facing complex and variable corrosion patterns, resulting in poor accuracy of corrosion detection. Summary of the Invention
[0005] The present invention provides a method and device for detecting corrosion of a distribution network grounding grid based on a parallel double-hop deep residual BP neural network, which is used to solve the technical problem that most of the existing methods for detecting corrosion of the distribution network grounding grid are carried out manually, resulting in poor accuracy of corrosion detection.
[0006] A method for detecting corrosion of a distribution network grounding grid based on a parallel double-hop deep residual BP neural network provided in the first aspect of the present invention includes:
[0007] Obtaining a plurality of distribution network grounding grid images to be detected;
[0008] Respectively inputting each of the distribution network grounding grid images to be detected into a plurality of preset parallel double-hop deep residual BP neural networks, where the preset parallel double-hop deep residual BP neural network includes a double-hop deep residual model and a BP neural network model;
[0009] Each of the double-hop deep residual models extracts shallow low-nonlinear features from the input to-be-detected distribution network ground grid image, and outputs the target shallow low-nonlinear features corresponding to each of the to-be-detected distribution network ground grid images;
[0010] Each of the BP neural network models performs corrosion detection on the input target shallow low-nonlinear features, and generates the target distribution network ground grid corrosion detection results corresponding to each of the to-be-detected distribution network ground grid images.
[0011] Optionally, the double-hop deep residual model includes a first residual network module, a second residual network module, a third residual network module, and a ReLU activation function layer; the image processing process of the double-hop deep residual model is specifically as follows:
[0012] Feature extraction is performed on the to-be-detected distribution network ground grid image input to the double-hop deep residual model to generate a target feature vector;
[0013] The first residual network module performs a non-linear transformation on the target feature vector to generate a first non-linear transformation feature;
[0014] The ReLU activation function layer performs a non-linear mapping on the first non-linear transformation feature to generate a first non-linear mapping feature;
[0015] The first non-linear mapping feature is used as the input of the second residual network module, and a second non-linear transformation feature is output;
[0016] Element-wise addition is performed on the second non-linear transformation feature and the first non-linear transformation feature to generate a first and second non-linear transformation feature;
[0017] The ReLU activation function layer performs a non-linear mapping on the first and second non-linear transformation features to generate a first and second non-linear mapping feature;
[0018] The third residual network module performs a non-linear transformation on the first and second non-linear mapping features to generate a third non-linear transformation feature;
[0019] Element-wise addition is performed on the third non-linear transformation feature and the first non-linear transformation feature to generate a first and third non-linear transformation feature;
[0020] The ReLU activation function layer performs a non-linear mapping on the first and third non-linear transformation features to generate the target shallow low-nonlinear features.
[0021] Optionally, the model training process of multiple pre-set parallel double-hop deep residual BP neural networks is specifically as follows:
[0022] Obtain an initial power distribution ground grid image training dataset, and preprocess the initial power distribution ground grid image training dataset to generate a target power distribution ground grid image training dataset;
[0023] Segment the target power distribution ground grid image training dataset to generate multiple batches of power distribution ground grid image data;
[0024] Use multiple batches of the power distribution ground grid image data to perform parallel model training on multiple initial parallel double-hop deep residual BP neural networks, and determine multiple trained preset parallel double-hop deep residual BP neural networks.
[0025] Optionally, the preprocessing of the initial power distribution ground grid image training dataset to generate a target power distribution ground grid image training dataset includes:
[0026] Screen the initial power distribution ground grid image training dataset to determine multiple intermediate power distribution ground grid images;
[0027] Scale each of the intermediate power distribution ground grid images to determine multiple scaled power distribution ground grid images;
[0028] Crop each of the scaled power distribution ground grid images to determine multiple cropped power distribution ground grid images;
[0029] Perform image enhancement on each of the cropped power distribution ground grid images to determine multiple target power distribution ground grid images;
[0030] Use multiple of the target power distribution ground grid images to construct a target power distribution ground grid image training dataset.
[0031] Optionally, the using multiple batches of the power distribution ground grid image data to perform parallel model training on multiple initial parallel double-hop deep residual BP neural networks, and determining multiple trained preset parallel double-hop deep residual BP neural networks includes:
[0032] Input each batch of the power distribution ground grid image data into multiple initial parallel double-hop deep residual BP neural networks respectively;
[0033] Each of the initial parallel double-hop deep residual BP neural networks outputs a training first non-linear transformation feature, a training third non-linear transformation feature, and a training first and third non-linear transformation feature corresponding to each of the initial parallel double-hop deep residual BP neural networks according to the input batch of the power distribution ground grid image data;
[0034] Based on the preset chain derivation rule of backpropagation, determine multiple weighted average gradients of second moment estimation according to the training first non-linear transformation feature, the training third non-linear transformation feature, and the training first and third non-linear transformation feature corresponding to each of the initial parallel double-hop deep residual BP neural networks;
[0035] Perform gradient merging on the weighted average gradients of the second moment estimates, and determine the merged model gradient;
[0036] Use the merged model gradient to update the model parameters of each of the initial parallel double-hop deep residual BP neural networks, determine multiple intermediate parallel double-hop deep residual BP neural networks, and count the number of model updates in real time;
[0037] Determine whether the number of model updates reaches a preset update threshold;
[0038] If it reaches, use each of the intermediate parallel double-hop deep residual BP neural networks as the corresponding trained preset parallel double-hop deep residual BP neural network.
[0039] Optionally, based on the preset backpropagation chain derivation rule, determine the weighted average gradients of multiple second moment estimates according to the trained first non-linear transformation features, trained third non-linear transformation features, and trained first and third non-linear transformation features corresponding to each of the initial parallel double-hop deep residual BP neural networks, including:
[0040] Use the preset backpropagation chain derivation rule to determine the observed gradients corresponding to each of the initial parallel double-hop deep residual BP neural networks according to the trained first non-linear transformation features, trained third non-linear transformation features, and trained first and third non-linear transformation features corresponding to each of the initial parallel double-hop deep residual BP neural networks;
[0041] Based on each of the observed gradients, determine the weighted average gradients of the first moment estimates corresponding to each of the observed gradients;
[0042] According to the observed gradients and the weighted average gradients of the first moment estimates corresponding to each of the initial parallel double-hop deep residual BP neural networks, calculate the weighted average gradients of the second moment estimates corresponding to each of the initial parallel double-hop deep residual BP neural networks.
[0043] A distribution network grounding grid corrosion detection device based on a parallel double-hop deep residual BP neural network provided by the second aspect of the present invention includes:
[0044] An acquisition module, configured to acquire multiple distribution network grounding grid images to be detected;
[0045] An input module, configured to respectively input each of the distribution network grounding grid images to be detected into multiple preset parallel double-hop deep residual BP neural networks, and the preset parallel double-hop deep residual BP neural network includes a double-hop deep residual model and a BP neural network model;
[0046] An extraction module for each of the double-hop deep residual models to perform shallow low non-linear feature extraction on the input to-be-detected distribution network grounding grid image, and output the target shallow low non-linear feature corresponding to each of the to-be-detected distribution network grounding grid images;
[0047] A detection module for each of the BP neural network models to perform corrosion detection on the input target shallow low non-linear feature, and generate the target distribution network grounding grid corrosion detection result corresponding to each of the to-be-detected distribution network grounding grid images.
[0048] A computer device provided in the third aspect of the present invention includes a memory and a processor. When the computer program stored in the memory is executed by the processor, the processor executes the steps of the distribution network grounding grid corrosion detection method based on the parallel double-hop deep residual BP neural network as described in any one of the above.
[0049] A computer-readable storage medium provided in the fourth aspect of the present invention has a computer program stored thereon. When the computer program is executed, it implements the steps of the distribution network grounding grid corrosion detection method based on the parallel double-hop deep residual BP neural network as described in any one of the above.
[0050] A computer program product provided in the fifth aspect of the present invention includes a computer program stored on a non-transitory computer-readable storage medium. The computer program includes program instructions. When the program instructions are executed by a computer, the computer executes the steps of the distribution network grounding grid corrosion detection method based on the parallel double-hop deep residual BP neural network as described in any one of the above.
[0051] It can be seen from the above technical solutions that the present invention has the following advantages:
[0052] The above technical solution of the present invention provides a method for detecting corrosion of a distribution network grounding grid based on a parallel double-hop deep residual BP neural network. First, obtain multiple distribution network grounding grid images to be detected; input each distribution network grounding grid image to be detected into multiple pre-set parallel double-hop deep residual BP neural networks. The pre-set parallel double-hop deep residual BP neural network includes a double-hop deep residual model and a BP neural network model; each double-hop deep residual model performs shallow low non-linear feature extraction on the input distribution network grounding grid image to be detected, and outputs the target shallow low non-linear feature corresponding to each distribution network grounding grid image to be detected; each BP neural network model performs corrosion detection on the input target shallow low non-linear feature, and generates the target distribution network grounding grid corrosion detection result corresponding to each distribution network grounding grid image to be detected; based on the above solution, through the process of the double-hop deep residual model performing shallow low non-linear feature extraction on the input distribution network grounding grid image to be detected, outputting the target shallow low non-linear feature, and then combining the BP neural network model to perform corrosion detection according to the target shallow low non-linear feature to generate the target distribution network grounding grid corrosion detection result, the double-hop deep residual model proposed by the present invention can enhance the transmission and reuse of shallow low non-linear feature information to the deep network, thereby improving the accuracy of corrosion detection. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the following drawings are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.
[0054] Figure 1 It is a flowchart of the steps of a method for detecting corrosion of a distribution network grounding grid based on a parallel double-hop deep residual BP neural network provided in Embodiment 1 of the present invention;
[0055] Figure 2 It is a schematic structural diagram of the double-hop deep residual model provided in Embodiment 1 of the present invention;
[0056] Figure 3 It is a flowchart of the steps of the model training process of multiple pre-set parallel double-hop deep residual BP neural networks provided in Embodiment 2 of the present invention;
[0057] Figure 4 It is a schematic diagram of a collected distribution network grounding grid corrosion map provided in Embodiment 2 of the present invention;
[0058] Figure 5 It is a schematic flowchart of the image preprocessing process provided in Embodiment 2 of the present invention;
[0059] Figure 6Schematic diagram of the change in loss value during the training of the proposed method provided in the second embodiment of the present invention;
[0060] Figure 7 Schematic diagram of the change in accuracy during the model training provided in the second embodiment of the present invention;
[0061] Figure 8 Schematic flow chart of the model training of the pre - set parallel double - jump deep residual BP neural network provided in the second embodiment of the present invention;
[0062] Figure 9 Experimental schematic diagram of the performance comparison of different methods provided in the second embodiment of the present invention;
[0063] Figure 10 Experimental schematic diagram of the comparison of the corrosion test results of different methods provided in the second embodiment of the present invention;
[0064] Figure 11 Structural block diagram of a distribution network grounding grid corrosion detection device based on a parallel double - jump deep residual BP neural network provided in the third embodiment of the present invention. Detailed implementation manners
[0065] The embodiment of the present invention provides a distribution network grounding grid corrosion detection method and device based on a parallel double - jump deep residual BP neural network, which is used to solve the technical problem that most of the existing distribution network grounding grid corrosion detection methods are detected manually, resulting in poor accuracy of corrosion detection.
[0066] In order to make the objectives, features, and advantages of the present invention more obvious and understandable, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the embodiments described below are only a part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.
[0067] Please refer to Figure 1 , Figure 1 Step - flow chart of a distribution network grounding grid corrosion detection method based on a parallel double - jump deep residual BP neural network provided in the first embodiment of the present invention.
[0068] A distribution network grounding grid corrosion detection method based on a parallel double - jump deep residual BP neural network provided by the present invention includes:
[0069] Step 101, obtain multiple distribution network grounding grid images to be detected.
[0070] In this embodiment, multiple distribution network grounding grid images to be detected are obtained.
[0071] Step 102: Input each power distribution network grounding grid image to be detected into multiple pre-set parallel double-hop deep residual BP neural networks. The pre-set parallel double-hop deep residual BP neural network includes a double-hop deep residual model and a BP neural network model.
[0072] It should be noted that the present invention uses the DataParallel method (data parallel method) based on PyTorch to achieve GPU (Graphics Processing Unit) parallelism of multiple pre-set parallel double-hop deep residual BP (Back Propagation) neural networks. When using multi-GPU parallelism, it is necessary to ensure that each GPU can access data and perform calculations. Usually, PyTorch allocates resources according to the available GPU devices in the system, and checks the number of available GPUs in the system through torch.cuda.device_count(). During the multi-GPU parallel computing process, PyTorch will automatically copy the model to each GPU for calculation.
[0073] In this embodiment, the present invention accelerates the network training and inference processes by introducing multi-GPU parallel computing, significantly shortens the detection time, and improves the processing ability of the model on large-scale data sets. The advantages of this parallelization can not only process a wider range of data, but also improve the detection efficiency and real-time performance, making it more efficient and reliable in the corrosion detection of large-scale power distribution network grounding grids such as substations.
[0074] Step 103: Each double-hop deep residual model performs shallow low non-linear feature extraction on the input power distribution network grounding grid image to be detected, and outputs the target shallow low non-linear features corresponding to each power distribution network grounding grid image to be detected.
[0075] The double-hop deep residual model includes a first residual network module, a second residual network module, a third residual network module, and a ReLU activation function layer (Rectified Linear Unit).
[0076] Specifically, step 103 may include the following sub-steps S31:
[0077] Step S31: Perform feature extraction on the power distribution network grounding grid image to be detected input to the double-hop deep residual model to generate a target feature vector;
[0078] Step S32: Perform non-linear transformation on the target feature vector through the first residual network module to generate a first non-linear transformation feature;
[0079] Step S33: Use the ReLU activation function layer to perform non-linear mapping on the first non-linear transformation feature to generate a first non-linear mapping feature;
[0080] Step S34: Use the first non-linear mapping feature as the input of the second residual network module, and output the second non-linear transformation feature;
[0081] Step S35: Element-wise add the second non-linear transformation feature and the first non-linear transformation feature to generate the first and second non-linear transformation features;
[0082] Step S36: Use the ReLU activation function layer to perform non-linear mapping on the first and second non-linear transformation features to generate the first and second non-linear mapping features;
[0083] Step S37: Perform non-linear transformation on the first and second non-linear mapping features through the third residual network module to generate the third non-linear transformation feature;
[0084] Step S38: Element-wise add the third non-linear transformation feature and the first non-linear transformation feature to generate the first and third non-linear transformation features;
[0085] Step S39: Use the ReLU activation function layer to perform non-linear mapping on the first and third non-linear transformation features to generate the target shallow low non-linear feature.
[0086] It should be noted that, please refer to Figure 2 , the double-hop deep residual model mainly consists of three residual network modules (i.e., the first residual network module, the second residual network module, and the third residual network module) and three ReLU activation function layers. Based on the traditional neural network structure, the present invention introduces double-hop connections.
[0087] Specifically, the jump connection from the first layer to the second layer is denoted as S1, and the jump connection from the first layer to the third layer is denoted as S2. In a single residual module, the processing of the input sample mainly includes the following three steps.
[0088] Step 1: Use the target feature vector x as the input of the first residual network module, and the output is the first non-linear transformation feature , this process can be expressed as:
[0089] ;
[0090] Among them, is the weight of the first residual network module; is the bias parameter of the first residual network module.
[0091] Furthermore, process the first non-linear transformation feature through the ReLU activation function layer, and output the first non-linear mapping feature F1(x), this process can be expressed as F1(x)=ReLU .
[0092] Step 2: Take the non-linear output of the first layer, i.e., the first non-linear mapping feature F1(x), as the input of the second residual network module. After weighted bias, add the output second non-linear transformation feature to the skip connection of the first layer . This process can be expressed as:
[0093] ;
[0094] ;
[0095] where is the second non-linear transformation feature; is the weight of the second residual network module; is the bias parameter of the second residual network module; is the first and second non-linear transformation feature, representing the superposition of the first layer jump information output and the second layer linear information output.
[0096] Furthermore, process the first and second non-linear transformation features through the ReLU activation function layer to output the first and second non-linear mapping feature F2(x). This process can be expressed as F2(x)=ReLU .
[0097] Step 3: Take the non-linear output of the second layer, i.e., the first and second non-linear mapping feature F2(x), as the input of the third layer network. After weighted bias, output the third non-linear transformation feature , and this process can be expressed as:
[0098] ;
[0099] where is the weight of the third residual network module; is the bias parameter of the third residual network module.
[0100] Furthermore, perform element-wise addition on the third non-linear transformation feature and the first non-linear transformation feature to generate the first and third non-linear transformation feature V(x). This process can be expressed as: V(x)= + represents the basic mapping that the residual module expects to fit after adding the skip connection.
[0101] Finally, use the ReLU activation function layer to perform non-linear mapping on the first and third non-linear transformation feature to generate the target shallow low non-linear feature F3(x). This process can be expressed as: F3(x)=ReLU[V(x)].
[0102] In this embodiment, each double-hop deep residual model performs shallow low-nonlinear feature extraction on the input power distribution grid ground network image to be detected, and outputs the target shallow low-nonlinear features corresponding to each power distribution grid ground network image to be detected.
[0103] Step 104: Each BP neural network model performs corrosion detection on the input target shallow low-nonlinear features to generate the target power distribution grid ground network corrosion detection results corresponding to each power distribution grid ground network image to be detected.
[0104] It should be noted that the process of each BP neural network model performing corrosion detection on the input target shallow low-nonlinear features can refer to the processing process of the prior art, and the present invention will not elaborate too much.
[0105] In this embodiment, each BP neural network model performs corrosion detection on the input target shallow low-nonlinear features to generate the target power distribution grid ground network corrosion detection results corresponding to each power distribution grid ground network image to be detected.
[0106] As a comparison of technical effects, it can be referred to in combination with the prior art. There are some technical problems in the existing power distribution grid ground network corrosion detection methods in practical applications. First, the traditional manual detection method is not only time-consuming but also easily affected by human factors, with low detection accuracy and unable to meet the detection requirements of large-scale power distribution grid ground networks. Second, the traditional detection methods based on sensors, ultrasonic waves or other hardware devices, although able to provide a certain detection accuracy, have problems such as high equipment cost, limited detection range, and unsatisfactory detection effects for small-scale corrosion areas. Due to the concealment of ground network corrosion and the different degrees and types of corrosion, traditional methods are prone to missed detections and false detections when facing complex and variable corrosion patterns.
[0107] To address the above problems, the present invention proposes a power distribution grid ground network corrosion detection method based on a parallel double-hop deep residual BP neural network to solve the problems existing in the prior art. The deep residual network can solve the problem of gradient disappearance in deep neural networks by introducing skip connections. However, in the case of small sample data, the traditional network still has certain fitting deficiencies. For this reason, the present invention proposes a double-hop deep residual network model, which can enhance the transmission and reuse of shallow low-nonlinear feature information to the deep network, thereby improving the accuracy of corrosion detection. At the same time, by introducing multi-GPU parallel computing, the network training and inference processes are accelerated, significantly shortening the detection time and improving the processing ability of the model on large-scale data sets. The advantages of this parallelization can not only process a larger range of data but also improve the detection efficiency and real-time performance, making it more efficient and reliable in the corrosion detection of large-scale power distribution grid ground networks such as substations.
[0108] In an embodiment of the present invention, the present invention provides a method for detecting corrosion of a distribution network grounding grid based on a parallel double-hop deep residual BP neural network. First, a plurality of distribution network grounding grid images to be detected are obtained; each distribution network grounding grid image to be detected is respectively input into a plurality of preset parallel double-hop deep residual BP neural networks, and the preset parallel double-hop deep residual BP neural network includes a double-hop deep residual model and a BP neural network model; each double-hop deep residual model performs shallow low non-linear feature extraction on the input distribution network grounding grid image to be detected, and outputs the target shallow low non-linear feature corresponding to each distribution network grounding grid image to be detected; each BP neural network model performs corrosion detection on the input target shallow low non-linear feature, and generates the target distribution network grounding grid corrosion detection result corresponding to each distribution network grounding grid image to be detected; based on the above solution, through the process that the double-hop deep residual model performs shallow low non-linear feature extraction on the input distribution network grounding grid image to be detected, outputs the target shallow low non-linear feature, and then combines the BP neural network model to perform corrosion detection according to the target shallow low non-linear feature to generate the target distribution network grounding grid corrosion detection result, the present invention proposes a double-hop deep residual model, which can enhance the transmission and reuse of shallow low non-linear feature information to the deep network, thereby improving the accuracy of corrosion detection
[0109] For better illustration, refer to Figure 3 , which shows the step flowchart of the model training process of a plurality of preset parallel double-hop deep residual BP neural networks provided in the second embodiment of the present invention. This process may include the following steps:
[0110] Step 301, obtain an initial distribution network grounding grid image training dataset, and preprocess the initial distribution network grounding grid image training dataset to generate a target distribution network grounding grid image training dataset.
[0111] It should be noted that the initial distribution network grounding grid image training dataset includes a plurality of distribution network grounding grid corrosion images and a plurality of distribution network grounding grid non-corrosion images; the present invention collects distribution network grounding grid corrosion images through two methods: network collection and manual collection. A high-quality dataset is the basis for successfully training a deep learning model. Search for corrosion images through a search engine and obtain network data through manual screening. The common feature of these pictures is low resolution, usually not exceeding 1000*1000. Due to the low efficiency of network acquisition, the corrosion images of the distribution network grounding grid are mainly collected manually.
[0112] During the process of collecting distribution network grounding grid corrosion images, the following principles should be followed:
[0113] (1) From the whole to the local: Photograph the local corrosion components of the distribution network grounding grid to obtain component information.
[0114] (2) Consider corrosion components and normal components: In order to avoid misjudgment, during the process of constructing the dataset, it is necessary to collect images of non-corroded components.
[0115] (3) Multi-scale and multi-angle shooting: During the process of constructing the dataset, the same location is photographed at different scales and angles.
[0116] (4) Shooting under multiple lighting conditions: By collecting images under different lighting conditions, the influence of lighting conditions on the corrosion degree recognition system is reduced. During the collection process, in addition to considering the above principles during manual collection, the shooting distance is also controlled at about 1.5 m. Figure 4 Partial corrosion maps of the distribution network grounding grid are collected.
[0117] Furthermore, when the commonly used image input size of the deep learning model is too large, it will cause insufficient memory during the training process. Therefore, the original images need to be preprocessed before being used to train the deep learning model. Usually, the pictures are cropped into small pictures of a specified size. Figure 4 As can be seen, the original pictures contain background information unrelated to the structure. Therefore, after cropping the original images, the images need to be enhanced to expand the data samples.
[0118] Specifically, step 301 may include the following sub-steps S3011 - S3015:
[0119] Step S3011: Screen the initial training dataset of the distribution network grounding grid images to determine multiple intermediate distribution network grounding grid images;
[0120] Step S3012: Scale each intermediate distribution network grounding grid image to determine multiple scaled distribution network grounding grid images;
[0121] Step S3013: Crop each scaled distribution network grounding grid image to determine multiple cropped distribution network grounding grid images;
[0122] Step S3014: Enhance the images of each cropped distribution network grounding grid image to determine multiple target distribution network grounding grid images;
[0123] Step S3015: Use multiple target distribution network grounding grid images to construct a training dataset of the target distribution network grounding grid images.
[0124] It should be noted that, please refer to Figure 5 , the process of image preprocessing can be divided into four steps:
[0125] (1) Image screening: During the data collection process, background images that have nothing to do with the anti-rust recognition task, as well as blurred images with poor quality that cannot be used for classification, are often collected. Duplicate images are also collected when shooting at multiple scales and angles. Therefore, the background images that have nothing to do with the anti-rust recognition task, the blurred images with poor quality that cannot be used for classification, and the duplicate images in the initial distribution network ground grid image training dataset are removed, and the remaining images are used as intermediate distribution network ground grid images.
[0126] (2) Image scaling: Before image shearing, the image needs to be scaled to a specified size to avoid the loss of image edge information caused by shearing.
[0127] (3) Image cropping: The size of the original image is much larger than the size of the input image commonly used in deep learning models. The memory required for model calculation will increase exponentially as the size of the model input image increases. Since the corrosion ratio in the image is small, directly scaling the original image to the size required by the deep learning model will make it difficult to identify the corrosion level and corrosion pixels. Therefore, the original image is cut into several sub-images of size 256×256.
[0128] (4) Image enhancement: The size of the dataset is increased through rotation transformation, flipping transformation, scaling transformation, and translation transformation.
[0129] In this embodiment, for the distribution network ground grid corrosion detection method based on the traditional backpropagation (BP) neural network, when the sample size is relatively small, when the number of network layers reaches a certain depth, the fitting ability of the network will reach saturation, and it is difficult to improve the classification accuracy. If the number of network layers is further increased, it will lead to network degradation. In order to improve the accuracy of the distribution network ground grid corrosion detection method, the present invention proposes a parallel double-hop deep residual BP neural network. The present invention preprocesses the collected dataset, then uses the preprocessed dataset to train the initial parallel double-hop deep residual BP neural network, and finally uses the trained parallel double-hop deep residual BP neural network for corrosion detection.
[0130] Step 302: Segment the target distribution network ground grid image training dataset to generate multiple batches of distribution network ground grid image data.
[0131] It should be noted that during the training process of large-scale datasets and deep learning models, especially tasks such as distribution network ground grid corrosion detection that require a large amount of computing resources, multi-GPU parallel computing is an important method to improve training efficiency and shorten training time. When using the double-hop deep residual BP neural network in the present invention, PyTorch is used for multi-GPU parallel training, which can effectively accelerate the training process of the neural network, significantly improve the training efficiency of the model, and solve the computational bottleneck problem.
[0132] During the training process, data parallelism is the most commonly used multi-GPU parallelism method. Specifically, the dataset is split into multiple mini-batches, that is, multiple batches of distribution network ground grid image data, and distributed to multiple GPUs (each GPU corresponds to a parallel double-hop deep residual BP neural network) for parallel computing. After each GPU finishes its own part of the calculation, PyTorch will aggregate the results calculated by each GPU to obtain the final output. To ensure the balanced computational load of each GPU, it is necessary to ensure that the training data is evenly distributed to each GPU.
[0133] The present invention has a corrosion detection dataset of 12,000 pieces of data, among which 9,000 pieces are non-corroded data and 3,000 pieces are corroded data. In multi-GPU training, these 12,000 pieces of data will be sliced into multiple batches, and then these batches are distributed to each GPU for training. PyTorch will achieve this through the DataLoader (data loader) combined with torch.nn.DataParallel, ensuring that each GPU receives different mini-batches of data for calculation.
[0134] In this embodiment, the target distribution network ground grid image training dataset is segmented to generate multiple batches of distribution network ground grid image data.
[0135] Step 303: Use multiple batches of distribution network ground grid image data to perform parallel model training on multiple initial parallel double-hop deep residual BP neural networks, and determine multiple trained preset parallel double-hop deep residual BP neural networks.
[0136] It should be noted that during the multi-GPU parallel training process, PyTorch will automatically copy the model to each GPU for calculation. Specifically for the double-hop deep residual BP neural network model, the data is divided into multiple mini-batches, and the calculation of each mini-batch of data will be completed on the corresponding GPU. Each layer of the model can be jointly processed by multiple GPUs. The DataParallel module of PyTorch will automatically handle the gradient calculation and update of each GPU, and finally aggregate the gradients of all GPUs to ensure the synchronous update of the model parameters.
[0137] In the double-hop deep residual network, due to the existence of skip connections, the information flow between different levels in the network needs to be efficiently processed. Through parallel computing, each GPU only needs to process its own assigned part of the levels. By automatically aggregating the results through DataParallel, not only can the computational burden of each GPU be reduced, but also the calculation and propagation of gradients can be accelerated, avoiding the bottleneck in traditional single-GPU training.
[0138] During the parallel training process, special attention needs to be paid to how to synchronize the gradients of each GPU when using an optimizer. To improve the training efficiency, the present invention uses an improved Adam algorithm (Adaptive Moment Estimation), and combines a learning rate scheduling strategy, introducing a weighted average gradient of the first moment estimation to dynamically adjust the weighted average gradient of the second moment estimation. In PyTorch, by using torch.optim.Adam, the optimizer can efficiently synchronize the updates of each GPU in a multi-GPU environment. A cosine annealing learning rate scheduler (CosineAnnealingLR) is used to dynamically adjust the learning rate to ensure the global optimization ability during the training process.
[0139] After each training iteration, each GPU calculates its own loss function and updates the gradient through backpropagation. PyTorch automatically handles gradient synchronization, that is, merging the gradients calculated by all GPUs and synchronously updating the parameters in all GPUs. This can ensure that each GPU has the same model parameters after each training step, that is, ensuring that each parallel double-hop deep residual BP neural network has the same model parameters.
[0140] During the training process, PyTorch manages the calculations of multiple GPUs through torch.nn.DataParallel, ensuring that each GPU processes different batches of training data, reducing the training time. At the same time, the accuracy during the training process will gradually converge as the number of training steps increases. Finally, the trained model will be evaluated using the test set and the classification results of corrosion detection will be output.
[0141] Through these parallelization steps, PyTorch can efficiently utilize multi-GPU resources, greatly accelerating the speed of model training and improving the detection accuracy and real-time performance of distribution network grounding grid corrosion detection.
[0142] Specifically, step 303 may include the following sub-steps S3031 - S3031:
[0143] Step S3031: Input each batch of distribution network grounding grid image data into multiple initial parallel double-hop deep residual BP neural networks respectively;
[0144] Step S3032: Each initial parallel double-hop deep residual BP neural network outputs the corresponding training first non-linear transformation feature, training third non-linear transformation feature, and training first and third non-linear transformation features of each initial parallel double-hop deep residual BP neural network according to the input batch of distribution network grounding grid image data;
[0145] Step S3033: Based on the preset chain derivation rule of backpropagation, determine the weighted average gradients of multiple second-moment estimates according to the training first non-linear transformation features, training third non-linear transformation features, and training first-third non-linear transformation features corresponding to each initial parallel double-hop deep residual BP neural network.
[0146] Specifically, step S3033 may include the following sub-steps S331 - S333:
[0147] Step S331: Using the preset chain derivation rule of backpropagation, determine the observed gradients corresponding to each initial parallel double-hop deep residual BP neural network according to the training first non-linear transformation features, training third non-linear transformation features, and training first-third non-linear transformation features corresponding to each initial parallel double-hop deep residual BP neural network.
[0148] Step S332: Based on each observed gradient, determine the weighted average gradient of the first-moment estimate corresponding to each observed gradient.
[0149] Step S333: According to the observed gradients and the weighted average gradients of the first-moment estimates corresponding to each initial parallel double-hop deep residual BP neural network, calculate the weighted average gradients of the second-moment estimates corresponding to each initial parallel double-hop deep residual BP neural network.
[0150] Step S3034: Perform gradient merging on the weighted average gradients of each second-moment estimate to determine the merged model gradient.
[0151] Step S3035: Use the merged model gradient to update the model parameters of each initial parallel double-hop deep residual BP neural network, determine multiple intermediate parallel double-hop deep residual BP neural networks, and count the model update times in real time.
[0152] Step S3036: Determine whether the model update times reach the preset update threshold.
[0153] Step S3037: If so, regard each intermediate parallel double-hop deep residual BP neural network as the corresponding trained preset parallel double-hop deep residual BP neural network.
[0154] It should be noted that through the skip connection, the identity mapping that is difficult to fit by the traditional deep BP neural network is transformed into a residual mapping that is easy to learn. The loss function is represented by L, and the gradient transfer process between the jump connection layers is represented by the gradient descent method. The preset chain derivation rule of backpropagation is:
[0155] ;
[0156] Among them, is the partial derivative of the loss function L with respect to the shallow feature , i.e., the gradient for training the first non-linear transformation feature; is the deep gradient. Due to the additional gradient , the gradient information can be directly transmitted from the deep layer to the shallow layer, avoiding the problem of gradient disappearance; is the output , i.e., the gradient for training the first and third non-linear transformation features with respect to the shallow layer features ; is the gradient of the residual path.
[0157] Furthermore, in deep learning, since the training time used in different model training environments varies, it has a high degree of dependence on computer hardware. The proposed parallel double-hop deep residual BP neural network in the present invention has certain requirements for the computer during network training, otherwise it will consume a large amount of time and affect the adjustment of parameters. There are 12,000 pieces of distribution network grounding corrosion detection data, among which 9,000 are non-corrosion data and 3,000 are corrosion data. During the training process, the first n - 1 layers are activated using the Relu function, and the last n layers are activated using the softmax function for output. The data set is divided into a training set and a test set in a ratio of 8:2. The number of iterations is set to 1,000 times, and the present invention uses an improved Adam algorithm for optimization. The step annealing idea is introduced, and the weighted average gradient m t of the first moment estimation is used to adjust the weighted average gradient v t of the second moment estimation. Specifically, after obtaining the observed gradient based on the above steps, based on the observed gradient, the weighted average gradient of the first moment estimation is determined, and then based on the observed gradient and the weighted average gradient of the first moment estimation, the weighted average gradient of the second moment estimation is calculated; among them, the calculation process of the weighted average gradient of the second moment estimation is specifically:
[0158] ;
[0159] where is the weighted average gradient of the second moment estimation at time t; is the decay factor of the second moment estimation; is the weighted average gradient of the second moment estimation at time t - 1; g t is the observed gradient at time t.
[0160] Furthermore, through the improvement of the Adam algorithm in the present invention, the learning rate can be reasonably and dynamically adjusted, accelerating the global optimization ability of the algorithm, enabling the objective function to converge as soon as possible without falling into local minima.
[0161] Further, if the number of model updates does not reach the preset update threshold, the intermediate parallel double-hop deep residual BP neural network is used as the new parallel double-hop deep residual BP neural network, and the process jumps to step S3031 until the number of model updates reaches the preset update threshold. The intermediate parallel double-hop deep residual BP neural networks determined when the number of model updates reaches the preset update threshold are used as the corresponding trained preset parallel double-hop deep residual BP neural networks.
[0162] Further, please refer to Figures 6 - 7 , the change trends of the accuracy and experimental loss error of model training are as Figures 6 - 7 shown. It can be seen from Figure 6 that the model gradually converges and remains stable. When Epoch is 200, the loss value and accuracy are stable, Train_loss and Val_loss converge, and the difference between them is very small. Finally, Train_loss stabilizes at about 0.05, Val_loss stabilizes at about 0.08, Figure 7 and Train_acc in
[0163] stabilizes at about 0.89, and Val_acc stabilizes at about 0.83. Figure 8 Exemplarily, please refer to . First, surface image samples of the distribution network grounding grid with real labels are obtained, and a corrosion detection method based on deep learning is constructed. Among them, there are 9000 non-corrosion data and 3000 corrosion data. Second, two methods, network acquisition and manual image acquisition, are used to obtain the dataset. The collected image samples are used for feature extraction, and the feature extraction is divided into a training dataset and a test dataset. The training set is used to train the proposed distribution network grounding grid corrosion detection model, and the test set is used to test the detection performance of the proposed method. The dataset has two output types:
[0164] Furthermore, after the training of the model is completed, for the evaluation of the model, in the experiment, precision, recall rate, CAR, and F1 score are used to evaluate the detection performance of the distribution network grounding grid corrosion method. Specifically, the present invention is implemented through block image separation processing. During the separation process, each block corresponds to a size of 256×256 samples, and the training samples are used to train the proposed corrosion detection model. The overall performance of the present invention in the training and testing phases is shown in Table 1. As can be seen from Table 1, the present invention has achieved good detection accuracy in both phases. The accuracy obtained in the training phase is 0.981, the recall rate is 0.924, the CAR is 0.987, and the F1 score is 0.953; the accuracy obtained in the testing phase is 0.928, the recall rate is 0.933, the CAR is 0.934, and the F1 score is 0.928. Therefore, it can be judged that this method has ideal corrosion detection ability.
[0165] Table 1 Detection performance of the model
[0166]
[0167] Furthermore, in order to better prove the corrosion detection ability of the proposed method for the distribution network grounding grid, under the same experimental conditions, the method proposed in the present invention is compared with the metal corrosion detection method (CAMCD, Conventional Artificial Metal Corrosion Detection) and the crowdsourced corrosion detection method (CAD, Crowdsourced Artificial Detection). The experimental results are as Figure 9 shown. As Figure 9 can be seen, the precision of the CAMCD method is only 0.837, the recall rate is 0.812, the CAR (Correct Acceptance Rate) is 0.792, and the F1 score is 0.824, while the precision of the CAD method is 0.897, the recall rate is 0.873, the CAR is 0.851, and the F1 score is 0.885. The precision, recall rate, CAR, and F1 score of the proposed corrosion detection method are 0.932, 0.923, 0.917, and 0.927 respectively, which are the best among the 4 indicators. This is because this method enhances the direct transmission and reuse of shallow low-nonlinear feature information to the deep network, avoids the disappearance of gradients during the backpropagation process, and improves the accuracy of model classification. Compared with the reference literature. The corrosion detection efficiency of CAD has been improved, but it is difficult to handle large-scale detection tasks of distribution network grounding grids. In addition, the comparison method ignores the transfer of feature information between different layers of the network and is difficult to handle the corrosion detection task of the distribution network grounding grid. Therefore, when dealing with the corrosion detection task of the above-ground distribution network grounding grid, the values of each indicator are lower than the method proposed in the present invention.
[0168] Further, please refer to Figure 10 , Figure 10 which is a comparison of the local corrosion detection results between the present invention and other algorithms. As can be seen from the classification results, Figure 10 the corrosion area in (a) is very easy to distinguish, but CAMCD does not well understand the contour of the corrosion area.
[0169] Although CAD has learned the contour of the corrosion area, the blurred area in the lower left of the picture is also recognized as the corrosion area. Figure 10 In (b), there is rust on all structural surfaces. However, due to the coating peeling off, the color difference between the middle position and the surrounding area of the image is large, which misleads the judgment of CAMCD and CAD. The present invention can accurately identify the rust pixels and transfer and reuse the underlying feature information to the deep network, so the detection effect is better. Experiments show that the corrosion detection of the distribution network ground grid by the present invention is effective.
[0170] In the embodiment of the present invention, aiming at the problems of long time consumption and low accuracy of the existing corrosion detection methods for distribution network ground grids, and in order to solve the problem of insufficient fitting ability of the shallow neural network model and improve the feature extraction ability of the network, the present invention establishes a double-hop deep residual network model. The improved Adam algorithm is used to optimize the model, which improves the convergence ability of the model. Experimental results show that the proposed corrosion detection method for distribution network ground grids has good corrosion detection ability. The field of deep learning is developing rapidly. In the future, the performance of the model can be improved from three aspects: using new models, expanding the dataset, and integrating traditional methods.
[0171] Please refer to Figure 11 , Figure 11 which is a structural block diagram of a distribution network ground grid corrosion detection device provided in Embodiment 3 of the present invention.
[0172] A distribution network ground grid corrosion detection device based on a parallel double-hop deep residual BP neural network provided by the present invention includes:
[0173] An acquisition module 1101, configured to acquire multiple distribution network ground grid images to be detected;
[0174] An input module 1102, configured to respectively input each distribution network ground grid image to be detected into a plurality of preset parallel double-hop deep residual BP neural networks, and the preset parallel double-hop deep residual BP neural network includes a double-hop deep residual model and a BP neural network model;
[0175] An extraction module 1103, configured to perform shallow low-nonlinear feature extraction on the input distribution network ground grid image to be detected by each double-hop deep residual model, and output the target shallow low-nonlinear feature corresponding to each distribution network ground grid image to be detected;
[0176] The detection module 1104 is used to perform corrosion detection on the input target shallow low non-linear features by each BP neural network model, and generate the target distribution network grounding grid corrosion detection results corresponding to each to-be-detected distribution network grounding grid image.
[0177] Furthermore, the double-hop deep residual model includes a first residual network module, a second residual network module, a third residual network module, and a ReLU activation function layer; the image processing process of the double-hop deep residual model is specifically as follows:
[0178] Extract features from the to-be-detected distribution network grounding grid image input to the double-hop deep residual model to generate a target feature vector;
[0179] Perform non-linear transformation on the target feature vector through the first residual network module to generate a first non-linear transformation feature;
[0180] Use the ReLU activation function layer to perform non-linear mapping on the first non-linear transformation feature to generate a first non-linear mapping feature;
[0181] Take the first non-linear mapping feature as the input of the second residual network module and output a second non-linear transformation feature;
[0182] Perform element-wise addition on the second non-linear transformation feature and the first non-linear transformation feature to generate a first and second non-linear transformation feature;
[0183] Use the ReLU activation function layer to perform non-linear mapping on the first and second non-linear transformation features to generate a first and second non-linear mapping feature;
[0184] Perform non-linear transformation on the first and second non-linear mapping features through the third residual network module to generate a third non-linear transformation feature;
[0185] Perform element-wise addition on the third non-linear transformation feature and the first non-linear transformation feature to generate a first and third non-linear transformation feature;
[0186] Use the ReLU activation function layer to perform non-linear mapping on the first and third non-linear transformation features to generate the target shallow low non-linear features.
[0187] In an optional device embodiment, it further includes:
[0188] The first module is used to obtain the initial distribution network grounding grid image training dataset and preprocess the initial distribution network grounding grid image training dataset to generate the target distribution network grounding grid image training dataset;
[0189] The second module is used to segment the target distribution network grounding grid image training dataset to generate multiple batches of distribution network grounding grid image data;
[0190] The third module is used to perform parallel model training on multiple initial parallel double-hop deep residual BP neural networks using multiple batches of distribution network ground grid image data, and determine multiple trained preset parallel double-hop deep residual BP neural networks.
[0191] The first module is specifically used for:
[0192] Screen the initial distribution network ground grid image training dataset to determine multiple intermediate distribution network ground grid images;
[0193] Scale each intermediate distribution network ground grid image to determine multiple distribution network ground grid scaled images;
[0194] Crop each distribution network ground grid scaled image to determine multiple distribution network ground grid cropped images;
[0195] Perform image enhancement on each distribution network ground grid cropped image to determine multiple target distribution network ground grid images;
[0196] Use multiple target distribution network ground grid images to construct a target distribution network ground grid image training dataset.
[0197] The third module includes:
[0198] The first sub-module is used to input each batch of distribution network ground grid image data into multiple initial parallel double-hop deep residual BP neural networks respectively;
[0199] The second sub-module is used for each initial parallel double-hop deep residual BP neural network to output the training first non-linear transformation feature, training third non-linear transformation feature, and training first and third non-linear transformation features corresponding to each initial parallel double-hop deep residual BP neural network according to the input batch of distribution network ground grid image data;
[0200] The third sub-module is used to determine multiple weighted average gradients of second moment estimates based on the preset backpropagation chain derivation rule, according to the training first non-linear transformation feature, training third non-linear transformation feature, and training first and third non-linear transformation features corresponding to each initial parallel double-hop deep residual BP neural network;
[0201] The fourth sub-module is used to perform gradient merging on each weighted average gradient of second moment estimates to determine the merged model gradient;
[0202] The fifth sub-module is used to update the model parameters of each initial parallel double-hop deep residual BP neural network using the merged model gradient, determine multiple intermediate parallel double-hop deep residual BP neural networks, and statistically count the number of model updates in real time;
[0203] The sixth sub-module is used to determine whether the number of model updates reaches the preset update threshold;
[0204] The seventh sub-module is used to, if the condition is met, regard each intermediate parallel double-hop deep residual BP neural network as the corresponding trained preset parallel double-hop deep residual BP neural network.
[0205] The third sub-module is specifically used for:
[0206] Using the chain derivation rule of preset backpropagation, based on the training first non-linear transformation feature, training third non-linear transformation feature, and training first-third non-linear transformation feature corresponding to each initial parallel double-hop deep residual BP neural network, determine the observation gradient corresponding to each initial parallel double-hop deep residual BP neural network;
[0207] Based on each observation gradient, determine the weighted average gradient of the first moment estimation corresponding to each observation gradient;
[0208] According to the observation gradient and the weighted average gradient of the first moment estimation corresponding to each initial parallel double-hop deep residual BP neural network, calculate the weighted average gradient of the second moment estimation corresponding to each initial parallel double-hop deep residual BP neural network.
[0209] Those skilled in the art can clearly understand that for the convenience and conciseness of description, the specific working processes of the above-described devices, modules, and sub-modules can refer to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0210] An embodiment of the present invention also provides a computer device, including a memory and a processor, and a computer program is stored in the memory; when the computer program is executed by the processor, the processor is caused to execute the steps of the method for detecting the corrosion of the distribution network ground grid based on the parallel double-hop deep residual BP neural network in any of the above embodiments.
[0211] An embodiment of the present invention also provides a computer-readable storage medium, on which a computer program / instructions are stored, and when the computer program / instructions are executed by the processor, the steps of the method for detecting the corrosion of the distribution network ground grid based on the parallel double-hop deep residual BP neural network in any of the above embodiments are implemented.
[0212] An embodiment of the present invention also provides a computer program product, including a computer program / instructions, and when the computer program / instructions are executed by the processor, the steps of the method for detecting the corrosion of the distribution network ground grid based on the parallel double-hop deep residual BP neural network in any of the above embodiments are implemented.
[0213] In several embodiments provided by the present application, it should be understood that the disclosed systems, devices, and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed couplings or direct couplings or communication connections between each other can be through some interfaces, indirect couplings or communication connections of devices or units, and can be in electrical, mechanical or other forms.
[0214] The units described as separate components may or may not be physically separated. The components displayed as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0215] As mentioned above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements for some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for detecting corrosion of a distribution network grounding grid based on a parallel double-hop deep residual BP neural network, characterized in that, Including: Obtain multiple distribution network ground grid images to be detected; Input each of the distribution network ground grid images to be detected into multiple preset parallel double-hop deep residual BP neural networks, where the preset parallel double-hop deep residual BP neural network includes a double-hop deep residual model and a BP neural network model; Each of the double-hop deep residual models performs shallow low-nonlinear feature extraction on the input distribution network ground grid image to be detected, and outputs the target shallow low-nonlinear feature corresponding to each of the distribution network ground grid images to be detected; Each of the BP neural network models performs corrosion detection on the input target shallow low-nonlinear feature, and generates the target distribution network ground grid corrosion detection result corresponding to each of the distribution network ground grid images to be detected.
2. The method for detecting the corrosion of the distribution network grounding grid based on the parallel double-hop deep residual BP neural network according to claim 1, characterized in that The double-hop deep residual model includes a first residual network module, a second residual network module, a third residual network module, and a ReLU activation function layer; the image processing process of the double-hop deep residual model is specifically as follows: Perform feature extraction on the distribution network ground grid image to be detected input to the double-hop deep residual model to generate a target feature vector; Perform a non-linear transformation on the target feature vector through the first residual network module to generate a first non-linear transformation feature; Use the ReLU activation function layer to perform non-linear mapping on the first non-linear transformation feature to generate a first non-linear mapping feature; Use the first non-linear mapping feature as the input of the second residual network module, and output a second non-linear transformation feature; Perform element-wise addition on the second non-linear transformation feature and the first non-linear transformation feature to generate a first and second non-linear transformation feature; Use the ReLU activation function layer to perform non-linear mapping on the first and second non-linear transformation features to generate a first and second non-linear mapping feature; Perform a non-linear transformation on the first and second non-linear mapping features through the third residual network module to generate a third non-linear transformation feature; Perform element-wise addition on the third non-linear transformation feature and the first non-linear transformation feature to generate a first and third non-linear transformation feature; Use the ReLU activation function layer to perform non-linear mapping on the first and third non-linear transformation features to generate the target shallow low-nonlinear feature.
3. The method for detecting the corrosion of the distribution network grounding grid based on the parallel double-hop deep residual BP neural network according to claim 1, wherein, The model training process of the multiple preset parallel double-hop deep residual BP neural networks is specifically as follows: Obtain an initial distribution network ground grid image training dataset, and preprocess the initial distribution network ground grid image training dataset to generate a target distribution network ground grid image training dataset; Segment the target distribution network ground grid image training dataset to generate multiple batches of distribution network ground grid image data; Use the multiple batches of distribution network ground grid image data to perform parallel model training on multiple initial parallel double-hop deep residual BP neural networks to determine multiple trained preset parallel double-hop deep residual BP neural networks.
4. The method for detecting the corrosion of the distribution network grounding grid based on the parallel double-hop deep residual BP neural network according to claim 3, characterized in that The preprocessing of the initial distribution network ground grid image training dataset to generate a target distribution network ground grid image training dataset includes: Screen the initial distribution network ground grid image training dataset to determine multiple intermediate distribution network ground grid images; Scale each of the intermediate distribution network ground grid images to determine multiple distribution network ground grid scaled images; Crop the scaled images of each distribution network ground grid to determine multiple cropped images of the distribution network ground grid; Perform image enhancement on each of the cropped images of the distribution network ground grid to determine multiple target images of the distribution network ground grid; Use the multiple target images of the distribution network ground grid to construct a training data set of the target images of the distribution network ground grid.
5. The method for detecting the corrosion of the distribution network grounding grid based on the parallel double-hop deep residual BP neural network according to claim 3, wherein, The step of using the multiple batch image data of the distribution network ground grid to perform parallel model training on multiple initial parallel double-hop deep residual BP neural networks to determine multiple trained preset parallel double-hop deep residual BP neural networks includes: Input each of the batch image data of the distribution network ground grid into the multiple initial parallel double-hop deep residual BP neural networks respectively; According to the input batch image data of the distribution network ground grid, each of the initial parallel double-hop deep residual BP neural networks outputs a training first non-linear transformation feature, a training third non-linear transformation feature, and a training first and third non-linear transformation feature corresponding to each of the initial parallel double-hop deep residual BP neural networks; Based on the preset chain derivation rule of backpropagation, determine multiple weighted average gradients of second moment estimation according to the training first non-linear transformation feature, the training third non-linear transformation feature, and the training first and third non-linear transformation feature corresponding to each of the initial parallel double-hop deep residual BP neural networks; Perform gradient merging on each of the weighted average gradients of second moment estimation to determine a merged model gradient; Use the merged model gradient to update the model parameters of each of the initial parallel double-hop deep residual BP neural networks to determine multiple intermediate parallel double-hop deep residual BP neural networks, and statistically count the number of model updates in real time; Judge whether the number of model updates reaches a preset update threshold; If it reaches, use each of the intermediate parallel double-hop deep residual BP neural networks as the corresponding trained preset parallel double-hop deep residual BP neural network.
6. The method for detecting corrosion of a distribution network grounding grid based on a parallel double-hop deep residual BP neural network according to claim 5, characterized in that, The step of determining multiple weighted average gradients of second moment estimation based on the preset chain derivation rule of backpropagation according to the training first non-linear transformation feature, the training third non-linear transformation feature, and the training first and third non-linear transformation feature corresponding to each of the initial parallel double-hop deep residual BP neural networks includes: Use the preset chain derivation rule of backpropagation to determine the observed gradient corresponding to each of the initial parallel double-hop deep residual BP neural networks according to the training first non-linear transformation feature, the training third non-linear transformation feature, and the training first and third non-linear transformation feature corresponding to each of the initial parallel double-hop deep residual BP neural networks; Based on each of the observed gradients, determine the weighted average gradient of first moment estimation corresponding to each of the observed gradients; According to the observed gradient and the weighted average gradient of first moment estimation corresponding to each of the initial parallel double-hop deep residual BP neural networks, calculate the weighted average gradient of second moment estimation corresponding to each of the initial parallel double-hop deep residual BP neural networks.
7. A distribution network grounding grid corrosion detection device based on a parallel double-hop deep residual BP neural network, characterized in that, It includes: An acquisition module for acquiring multiple to-be-detected images of the distribution network ground grid; An input module, configured to respectively input each of the to-be-detected distribution network ground grid images into a plurality of preset parallel double-hop deep residual BP neural networks, where the preset parallel double-hop deep residual BP neural network includes a double-hop deep residual model and a BP neural network model; An extraction module, configured to perform shallow-layer low non-linear feature extraction on the input to-be-detected distribution network ground grid images by each of the double-hop deep residual models, and output target shallow-layer low non-linear features corresponding to each of the to-be-detected distribution network ground grid images; A detection module, configured to perform corrosion detection on the input target shallow-layer low non-linear features by each of the BP neural networks models, and generate target distribution network ground grid corrosion detection results corresponding to each of the to-be-detected distribution network ground grid images.
8. A computer device, characterized in that, It includes a memory and a processor. A computer program is stored in the memory. When the computer program is executed by the processor, the processor is caused to execute the steps of the distribution network ground grid corrosion detection method based on a parallel double-hop deep residual BP neural network according to any one of claims 1-6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed, it implements the distribution network ground grid corrosion detection method based on a parallel double-hop deep residual BP neural network according to any one of claims 1-6.
10. A computer program product, characterized in that, The computer program product includes a computer program stored on a non-transitory computer-readable storage medium. The computer program includes program instructions. When the program instructions are executed by a computer, the computer is caused to execute the distribution network ground grid corrosion detection method based on a parallel double-hop deep residual BP neural network according to any one of claims 1-6.
