Training Method and Detection Method for Tree Obstruction Hazard Detection Model in Power Transmission Channels
The transmission channel tree obstacle detection model, which integrates a multidimensional convolution module and a channel spatial attention fusion module, solves the problems of low efficiency and low detection accuracy of traditional inspection methods, and achieves high-precision tree obstacle detection and early warning, thereby improving the safety and stability of the power system.
Patent Information
- Application Number
- CN202510218525.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-26
- Publication Date
- 2025-11-14
- Estimated Expiration
- 2045-02-26
AI Technical Summary
Traditional methods of power transmission line inspection are inefficient, costly, and pose safety hazards. Remote sensing images have low detection accuracy in complex backgrounds and are difficult to accurately identify tree obstruction hazards.
A power transmission channel tree obstacle hazard detection model is proposed, which uses a multidimensional convolutional module and a channel spatial attention fusion module. The multidimensional convolutional kernel captures features at different levels, and the weighted operation of the channel spatial attention fusion module is combined to improve the detection accuracy.
This improves the accuracy and efficiency of tree obstacle detection, enables timely detection of potential hazards in the power system, reduces the likelihood of accidents, and enhances the stability and safety of power system operation.
Smart Images

Figure CN120032182B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a method, apparatus, computer equipment, computer-readable storage medium, and computer program product for training a model to detect tree obstruction hazards in power transmission channels. Background Technology
[0002] Transmission lines cross complex terrains such as forests, farmland, and mountains. Excessive growth or fallen vegetation (especially trees) in the surrounding area can easily come into contact with or approach the transmission lines, potentially causing branches or trees to touch the power lines and triggering short circuits, resulting in power outages and huge economic losses.
[0003] Traditional transmission line inspection methods mainly rely on manual or helicopter inspections, which are inefficient, costly, and pose safety hazards. In recent years, the development of remote sensing technology has provided new means for monitoring transmission lines. Simultaneously, with the rise of machine learning methods, such as support machines and random forests, they have been introduced into image classification and have achieved some success. These methods involve manually designed features; however, when dealing with high-resolution remote sensing imagery, they often suffer from high computational complexity and poor generalization ability.
[0004] Recently, the rise of deep learning, especially complex neural networks, has provided entirely new solutions for remote sensing image analysis. However, despite the great potential of remote sensing technology and deep learning in monitoring tree obstructions along power transmission lines, some technical challenges remain. For example, remote sensing images often contain complex backgrounds, such as mountains and buildings, which can easily be confused with trees, affecting detection accuracy. Summary of the Invention
[0005] Based on this, it is necessary to address the above-mentioned technical problems by providing a method, device, computer equipment, computer-readable storage medium, and computer program product for training a tree obstacle detection model for power transmission channels that can improve the accuracy of tree obstacle detection, as well as a method, device, computer equipment, computer-readable storage medium, and computer program product for detecting tree obstacles in power transmission channels.
[0006] Firstly, this application provides a method for training a model to detect tree obstruction hazards in power transmission channels, including:
[0007] Acquire historical remote sensing images of power transmission channels, which include category labels and location information of the ground truth bounding boxes of tree-blocked areas;
[0008] Using historical remote sensing images of power transmission channels as input, an existing initial power transmission channel tree obstacle detection model is invoked. This model captures features at different levels of the historical power transmission channel remote sensing images through convolutional kernels of different dimensions in a multidimensional convolutional module. Based on these features, a power transmission channel tree obstacle feature map is generated. This feature map is then input into a channel spatial attention fusion module, which performs a weighted operation on the attention of the feature map in both the channel and spatial dimensions, resulting in an enhanced feature map. Based on this enhanced feature map and features at different levels, the category, location information, and confidence of the prediction box are determined. The prediction box is used to identify tree obstacle areas in the historical power transmission channel remote sensing images. The features at different levels include global and local features of the historical power transmission channel remote sensing images. The initial power transmission channel tree obstacle detection model includes a multidimensional convolutional module and a channel spatial attention fusion module.
[0009] Based on the category labels and location information of the ground truth bounding boxes, as well as the category, location information, and confidence level of the predicted bounding boxes, the error between the predicted bounding boxes and the ground truth bounding boxes is determined.
[0010] Based on the error, the parameters of the initial power transmission channel tree obstruction hazard detection model are iteratively updated until the preset training termination condition is met, resulting in the trained power transmission channel tree obstruction hazard detection model.
[0011] Secondly, this application also provides a method for detecting tree obstruction hazards in power transmission channels, including:
[0012] Acquire remote sensing images of power transmission channels;
[0013] Using remote sensing images of power transmission channels as input, a trained power transmission channel tree obstacle detection model is invoked to obtain tree obstacle detection results. The power transmission channel tree obstacle detection model is trained based on the above-mentioned power transmission channel tree obstacle detection model training method.
[0014] Early warnings are issued based on the results of the tree obstacle hazard detection.
[0015] Thirdly, this application also provides a training device for a power transmission channel tree obstruction hazard detection model, comprising:
[0016] The image acquisition module is used to acquire remote sensing images of historical power transmission channels. These images include category labels and location information of the ground truth bounding boxes of tree-blocked areas.
[0017] The model training module takes historical remote sensing images of power transmission channels as input and calls the pre-built initial power transmission channel tree obstacle detection model. This initial model uses convolutional kernels of different dimensions in the multidimensional convolution module to capture features at different levels of the historical power transmission channel remote sensing images. Based on these features, it generates a power transmission channel tree obstacle feature map. This feature map is then input to the channel spatial attention fusion module, which performs a weighted operation on the attention of the feature map in both the channel and spatial dimensions, resulting in an enhanced feature map. Based on this enhanced feature map and the features at different levels, the module determines the category, location information, and confidence score of the prediction box. The prediction box is used to identify tree obstacle areas in the historical power transmission channel remote sensing images. The features at different levels include global and local features of the historical power transmission channel remote sensing images. The initial power transmission channel tree obstacle detection model includes a multidimensional convolution module and a channel spatial attention fusion module.
[0018] The error determination module is used to determine the error between the predicted box and the ground truth box based on the category label and location information of the ground truth box, as well as the category, location information and confidence level of the predicted box.
[0019] The parameter update module is used to iteratively update the parameters of the initial power transmission channel tree obstruction hazard detection model based on the error until the preset training termination condition is met, thus obtaining the trained power transmission channel tree obstruction hazard detection model.
[0020] Fourthly, this application also provides a device for detecting tree obstruction hazards in power transmission channels, including:
[0021] The remote sensing image acquisition module is used to acquire remote sensing images of the power transmission channel;
[0022] The tree obstruction hazard detection module is used to take remote sensing images of the power transmission channel as input, call the trained power transmission channel tree obstruction hazard detection model, and obtain the tree obstruction hazard detection results. The power transmission channel tree obstruction hazard detection model is trained based on the above-mentioned power transmission channel tree obstruction hazard detection model training method.
[0023] The early warning module is used to issue early warnings based on the results of tree obstacle hazard detection.
[0024] Fifthly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in any of the above embodiments of the power transmission channel tree obstacle hazard detection model training method, and the steps in an embodiment of the power transmission channel tree obstacle hazard detection method.
[0025] Sixthly, this application also provides a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the steps in any of the above embodiments of the power transmission channel tree obstacle hazard detection model training method and the steps in an embodiment of the power transmission channel tree obstacle hazard detection method.
[0026] Seventhly, this application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps in any of the above embodiments of the transmission channel tree obstacle hazard detection model training method and the steps in an embodiment of the transmission channel tree obstacle hazard detection method.
[0027] The aforementioned training method, apparatus, computer equipment, computer-readable storage medium, and computer program product for detecting tree obstruction hazards in power transmission channels take into account the impact of complex backgrounds in remote sensing images of power transmission channels on the accuracy of tree obstruction hazard detection. A multidimensional convolution module containing multidimensional convolution kernels is designed to capture features at different levels of the image. Simultaneously, considering the small proportion of tree obstruction hazard areas in remote sensing images, a channel spatial attention fusion module is designed to focus the model on tree obstruction features and ignore background interference information such as the sky and buildings. Through the multidimensional convolution module and the channel spatial attention fusion module, an initial power transmission channel tree obstruction hazard detection model is constructed for detecting tree obstruction hazards in power transmission channels. Using historical remote sensing images of power transmission channels labeled with category labels and location information of ground truth bounding boxes containing tree-block areas as input, the initial power transmission channel tree-block hazard detection module is invoked. Through multidimensional convolution of the multidimensional convolution module, global and local features of the historical power transmission channel remote sensing images are captured to obtain a power transmission channel tree-block feature map. This feature map is then input into the channel spatial attention fusion module. By weighting the attention of the feature map in both the spatial and channel dimensions, detailed information is preserved to the maximum extent, reducing loss during feature extraction, resulting in an enhanced power transmission channel tree-block feature map. Based on the enhanced feature map and features at different levels, the category, location information, and confidence of the predicted bounding boxes are determined. Then, based on the category labels and location information of the ground truth bounding boxes, and the category, location information, and confidence of the predicted bounding boxes, the error between the ground truth bounding boxes and the predicted bounding boxes is determined. The model parameters are iteratively updated based on the error until a preset training termination condition is reached, resulting in the trained power transmission channel tree-block hazard detection model. The trained tree obstacle detection model for power transmission channels is beneficial to improving the accuracy of tree obstacle detection in different geographical environments of power transmission channels, as well as the model's adaptability to high-precision tree obstacle detection in different complex scenarios.
[0028] The aforementioned method, device, computer equipment, computer scale storage medium, and computer program product for detecting tree obstruction hazards in power transmission channels acquire remote sensing images of the transmission channels and input them into a trained power transmission channel tree obstruction hazard detection model obtained through the aforementioned training method. This yields tree obstruction hazard detection results, which are then used to issue early warnings. On one hand, the model-based detection method improves the accuracy and efficiency of tree obstruction hazard detection. On the other hand, the rapid and accurate detection results based on the model facilitate the timely discovery of potential hazards in the power system, enabling appropriate measures to be taken to reduce the likelihood of accidents and improve the stability and safety of power system operation. Attached Figure Description
[0029] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0030] Figure 1 This is a diagram illustrating the application environment of a power transmission channel tree obstruction hazard detection model training method in one embodiment.
[0031] Figure 2 This is a flowchart illustrating a method for training a power transmission channel tree obstruction hazard detection model in one embodiment.
[0032] Figure 3 This is a structural block diagram of a power transmission channel tree obstruction hazard detection model in one embodiment;
[0033] Figure 4 This is a structural block diagram of a multidimensional convolution module in one embodiment;
[0034] Figure 5 This is a flowchart illustrating the training method for a power transmission channel tree obstruction hazard detection model in another embodiment;
[0035] Figure 6 This is a structural block diagram of the channel spatial attention fusion module in one embodiment;
[0036] Figure 7 This is a flowchart illustrating the training method for a power transmission channel tree obstruction hazard detection model in yet another embodiment;
[0037] Figure 8 This is a flowchart illustrating a method for detecting tree obstructions in power transmission channels in one embodiment;
[0038] Figure 9This is a structural block diagram of a power transmission channel tree obstruction hazard detection model training device in one embodiment;
[0039] Figure 10 This is a structural block diagram of a power transmission channel tree obstruction hazard detection device in one embodiment;
[0040] Figure 11 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation
[0041] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0042] The power transmission channel tree obstruction hazard detection model training method provided in this application embodiment can be applied to, for example... Figure 1 In the application environment shown, terminal 102 communicates with server 104 via a network. A data storage system can store the data that server 104 needs to process. The data storage system can be integrated onto server 104, or it can be located in the cloud or on another network server.
[0043] Specifically, the operator can upload historical remote sensing images of the transmission channel to the server 104 via terminal 102, and then send model training messages to the server 104 via terminal 102. The server 104 acquires the historical transmission channel remote sensing image data. Next, using the historical transmission channel remote sensing images as input, it calls the pre-constructed initial transmission channel tree obstacle hazard detection model. This initial model uses convolutional kernels of different dimensions in the multidimensional convolution module to capture features at different levels of the historical transmission channel remote sensing images. Based on these features, it generates a transmission channel tree obstacle feature map. This feature map is then input to the channel spatial attention fusion module, which applies attention to the transmission channel tree obstacle feature map in both the channel and spatial dimensions. A weighted operation is performed to obtain a tree barrier feature enhancement map of the transmission channel. Based on the tree barrier feature enhancement map and features at different levels, the category, location information, and confidence of the prediction box are determined. The prediction box is used to identify tree barrier areas in historical remote sensing images of the transmission channel. Features at different levels include global and local features of historical remote sensing images of the transmission channel. The initial transmission channel tree barrier hazard detection model includes a multidimensional convolution module and a channel spatial attention fusion module. Then, based on the category label and location information of the ground truth box, as well as the category, location information, and confidence of the prediction box, the error between the prediction box and the ground truth box is determined. Finally, based on the error, the parameters of the initial transmission channel tree barrier hazard detection model are iteratively updated until the preset training termination condition is reached, resulting in the trained transmission channel tree barrier hazard detection model.
[0044] The terminal 102 can be, but is not limited to, various personal computers, laptops, smartphones, tablets, IoT devices, and portable wearable devices. IoT devices can include smart TVs, smart in-vehicle devices, and projection devices. Portable wearable devices can include smartwatches and smart bracelets. The server 104 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services.
[0045] In one exemplary embodiment, such as Figure 2 As shown, a training method for a power transmission corridor tree obstruction hazard detection model is provided, and this method is applied to... Figure 1 Taking server 104 as an example, the explanation includes the following steps S100 to S400. Among them:
[0046] S100: Acquire historical remote sensing images of power transmission channels. These images include category labels and location information of the ground truth bounding boxes of tree-blocked areas.
[0047] Historical remote sensing images of power transmission channels can be images acquired during a historical period. Tree obstructions along power transmission channels refer to situations where trees (such as excessively tall or dense trees) in or around the transmission line corridor contact, block, or affect power transmission equipment. Tree obstruction areas in the images can be vegetation-covered areas that may pose a threat to power lines and equipment.
[0048] The category label for the ground truth bounding box can include obstacle area and background area. Location information can include the coordinates of the top-left and bottom-right corners of the ground truth bounding box.
[0049] In practical applications, images of power transmission channels can be acquired using UAV remote sensing and satellite remote sensing. UAVs can fly at low altitudes to obtain high-resolution image data, making them suitable for monitoring key local areas; while satellite remote sensing has a wide coverage area and is suitable for monitoring large-scale power transmission channels. Acquiring historical remote sensing images of power transmission channels can involve acquiring multiple historical images of power transmission channels, including areas with tree obstructions, collected within a historical time period using UAV and satellite remote sensing.
[0050] After obtaining historical remote sensing images of power transmission channels, these images can be standardized to facilitate model processing. Specifically, the images are cropped and resized to ensure uniformity, such as 512×512 pixels. During cropping, key areas are preserved to reduce the possibility of losing information about power lines and tree obstructions. Data annotation of the historical power transmission channel images can be performed manually using image dataset annotation tools. During annotation, the location of tree obstructions is marked, and rectangular boxes are used to mark these areas. For example, areas near or in contact with power lines, trees whose growth trend may threaten the transmission channel, trees at risk of collapse due to disease or aging, trees above a certain height, and trees near critical transmission equipment are designated as tree obstruction areas. The coordinates of the upper left corner of the rectangle are marked during selection. and the coordinates of the bottom right corner Label each box with the corresponding category label.
[0051] In other implementations, to improve the model's generalization ability and robustness, data augmentation processing is performed on the remote sensing images of historical power transmission channels. Data augmentation processing includes, but is not limited to, rotation, flipping, scaling and cropping, brightness adjustment, and noise addition. Specifically, rotation processing can involve randomly rotating the image to enable the model to handle tree obstructions from different angles; flipping can involve horizontally or vertically flipping the image to increase image diversity; scaling and cropping can involve randomly scaling and cropping the image to simulate different tree obstruction distances; brightness adjustment can involve adjusting the image brightness to enhance the model's adaptability to different lighting conditions; and noise addition can involve randomly adding noise to the image to enhance the model's anti-interference ability. After data augmentation processing, the historical power transmission channel remote sensing images can be divided into training, validation, and test sets in an 8:1:1 ratio. The initial power transmission channel tree obstruction hazard detection model is trained using the historical power transmission remote sensing images in the training set.
[0052] S200 takes historical remote sensing images of power transmission channels as input and calls the pre-constructed initial power transmission channel tree obstacle detection model. This model uses convolutional kernels of different dimensions in a multi-dimensional convolutional module to capture features at different levels of the historical power transmission channel remote sensing images. Based on these features, it generates a power transmission channel tree obstacle feature map. This feature map is then input to a channel spatial attention fusion module, which performs a weighted operation on the attention of the feature map in both the channel and spatial dimensions, resulting in an enhanced feature map. Based on this enhanced feature map and the features at different levels, it determines the category, location information, and confidence score of the prediction box. The prediction box is used to identify tree obstacle areas in the historical power transmission channel remote sensing images. The features at different levels include global and local features of the historical power transmission channel remote sensing images. The initial power transmission channel tree obstacle detection model includes a multi-dimensional convolutional module and a channel spatial attention fusion module.
[0053] The initial tree obstruction hazard detection model for power transmission corridors is an improvement upon a pre-trained model. The multidimensional convolution module contains convolutional kernels of different dimensions for image feature extraction. The channel spatial attention fusion module is used for image feature enhancement and to reduce background noise interference. The enhanced feature map of tree obstructions in the power transmission corridor can be a feature map processed through feature enhancement.
[0054] In practical applications, to improve the accuracy of capturing features of tree-barrier areas in remote sensing images at different spatial resolutions, a multi-dimensional convolutional module containing one-dimensional, two-dimensional, and three-dimensional convolutions is designed to capture global features (deep-level features in spatial structure) and local features (edge information and local details) in historical power transmission channel remote sensing images. Considering the small proportion of tree-barrier areas in remote sensing images, a channel spatial attention fusion module is designed to reduce background interference, fusing attention from both the channel dimension and the spatial dimension to improve the model's sensitivity to tree-barrier areas. By improving the architecture of the pre-trained model (such as the YOLO model) through the multi-dimensional convolutional module and the channel spatial attention fusion module, an initial power transmission channel tree-barrier hazard detection model is obtained, such as... Figure 2 As shown. Initialize all neural network parameters of the initial power transmission channel tree obstruction hazard detection model, and set the relevant hyperparameters of the power transmission channel tree obstruction hazard detection model, such as: training epochs, batch size, optimizer selection, learning rate, etc.
[0055] Using historical remote sensing images of power transmission corridors as input, an existing initial power transmission corridor tree obstruction hazard detection model is invoked. Through a combination of one-dimensional, two-dimensional, and three-dimensional convolutional kernels in the multi-dimensional convolutional module of the initial model, global and local features of the historical power transmission corridor remote sensing images are captured. A power transmission corridor tree obstruction feature map is generated by fusing global and local features. A channel spatial attention fusion module performs weighted operations on the channel-level and spatial-level attention of the power transmission corridor tree obstruction feature map, enabling the model to automatically focus on key regions and features, reducing attention to irrelevant information, resulting in an enhanced power transmission corridor tree obstruction feature map. The channel dimension in the convolutional neural network represents different types of features (e.g., edge information, texture). By performing feature extraction, feature enhancement, and feature fusion on features at different levels and the enhanced power transmission corridor tree obstruction map, prediction boxes for identifying tree obstruction areas are generated, and the category, location information, and confidence score of the prediction boxes are output.
[0056] S300 determines the error between the predicted and ground truth bounding boxes based on the category labels and location information of the ground truth bounding boxes, as well as the category, location information, and confidence level of the predicted bounding boxes.
[0057] In practical applications, the cross-union ratio (CUP) between the predicted and ground truth bounding boxes can be determined based on their location information. The error between the predicted and ground truth bounding boxes can then be determined by calculating the difference between their locations, the difference between their categories, the confidence level, and the CUP using a loss function. Loss functions include, but are not limited to, mean squared error loss, cross-entropy loss, and smoothed L1 loss.
[0058] S400, based on the error, iteratively updates the parameters of the initial transmission channel tree obstacle hazard detection model until the preset training termination condition is met, thus obtaining the trained transmission channel tree obstacle hazard detection model.
[0059] In practical applications, after obtaining the error between the ground truth bounding box and the predicted bounding box using the loss function, backpropagation is performed starting from the output layer of the initial power transmission channel tree obstruction hazard detection model based on the loss function value (error). The parameter gradient values of each layer are calculated, and the parameters of the initial power transmission channel tree obstruction hazard detection model are updated to minimize the loss function value. A preset training termination condition can be set such that the loss function value is continuously less than a preset loss threshold within a preset number of iterations, at which point training of the initial power transmission channel tree obstruction hazard detection model is stopped, resulting in the trained power transmission channel tree obstruction hazard detection model.
[0060] In other implementations, after completing one round of training on the images in the training set, the model performance is verified using historical remote sensing images of power transmission channels in the validation set. The training strategy is then adjusted based on the validation results, such as terminating training early or adjusting the learning rate.
[0061] In the training method for the above-mentioned power transmission channel tree obstacle hazard detection model, considering the impact of complex backgrounds in remote sensing images of power transmission channels on the accuracy of tree obstacle hazard detection, a multidimensional convolution module containing multidimensional convolution kernels is designed to capture features of the image at different levels. At the same time, considering that the proportion of tree obstacle hazard areas in remote sensing images is relatively small, in order to make the model focus on tree obstacle features and ignore background interference information such as sky and buildings, a channel spatial attention fusion module is designed. Through the multidimensional convolution module and the channel spatial attention fusion module, an initial power transmission channel tree obstacle hazard detection model for detecting tree obstacles in power transmission channels is constructed. Using historical remote sensing images of power transmission channels labeled with category labels and location information of ground truth bounding boxes containing tree-block areas as input, the initial power transmission channel tree-block hazard detection module is invoked. Through multidimensional convolution of the multidimensional convolution module and the capture of global and local features from the historical remote sensing images, a power transmission channel tree-block feature map is obtained. This feature map is then input into the channel spatial attention fusion module. By weighting the attention of the feature map in both the spatial and channel dimensions, detailed information is preserved to the maximum extent, reducing loss during feature extraction, resulting in an enhanced power transmission channel tree-block feature map. Based on the enhanced feature map and features at different levels, the category, location information, and confidence score of the predicted bounding boxes are determined. Then, based on the category labels and location information of the ground truth bounding boxes, and the category, location information, and confidence score of the predicted bounding boxes, the error between the ground truth bounding boxes and the predicted bounding boxes is determined. The model parameters are iteratively updated based on the error until a preset training termination condition is reached, resulting in the trained power transmission channel tree-block hazard detection model. The trained tree obstacle detection model for power transmission channels is beneficial to improving the accuracy of tree obstacle detection in different geographical environments of power transmission channels, as well as the model's adaptability to high-precision tree obstacle detection in different complex scenarios.
[0062] In an exemplary embodiment, the initial power transmission channel tree obstruction hazard detection model includes a first feature extraction module and a second feature extraction module, such as... Figure 4 As shown, the initial power transmission corridor tree obstruction hazard detection model captures features at different levels of historical power transmission corridor remote sensing images through convolution kernels of different dimensions in the multidimensional convolution module. Based on the features at different levels, it generates power transmission corridor tree obstruction feature maps, including S210 to S240. Wherein:
[0063] S210, the first feature map is obtained by extracting features from the remote sensing image of the historical power transmission channel through the first feature extraction module.
[0064] The first feature map is the feature map obtained by the first feature extraction module through feature extraction operations on the remote sensing images of historical power transmission channels.
[0065] In this embodiment, the first feature extraction module is the Conv_BN_SiLU module, which consists of a Conv layer with a kernel size of 3×3 and a stride of 2, a BN layer (Batch Normalization layer), and a SiLU layer (Sigmoid LinearUnit activation function) connected in series.
[0066] In practical applications, features of historical power transmission remote sensing images are extracted through the convolutional layer, batch normalization layer, and activation function of the first feature extraction module to obtain the first feature map.
[0067] S220: Based on the different dimensions of the convolution kernels in the multidimensional convolution module, the features of different levels of the first feature map are captured respectively to obtain the second feature map.
[0068] The second feature map is obtained by the multidimensional convolution module through feature extraction and feature fusion of the first feature map.
[0069] In practical applications, the multidimensional convolution module captures features of the first feature map at different levels by combining one-dimensional, two-dimensional, and three-dimensional convolution kernels, such as the three-dimensional relationship between tree barriers and background in complex terrain, and the subtle differences between branches and cables. The features at different levels are then stitched together to obtain the second feature map.
[0070] S230, the second feature map is extracted by the second feature extraction module to obtain the third feature map.
[0071] In this embodiment, the second feature extraction module is the C3K2 module, which is used for feature extraction.
[0072] In practical applications, features are extracted from different channels of the input second feature map through parallel convolutional layers in the second feature extraction module, and the features are concatenated to obtain the third feature map.
[0073] S240, based on the second feature extraction module and the multidimensional convolution module, extracts features of the third feature map at different scales to obtain the power transmission channel tree barrier feature map.
[0074] In practical applications, the multidimensional convolution module and the second feature extraction module can be stacked multiple times in sequence. Through multiple convolution operations of the stacked multidimensional convolution module and the second feature extraction module, features of the third feature map at different scales are extracted to obtain the power transmission channel tree barrier feature map.
[0075] In this embodiment, features of the image at different scales are extracted by the first feature extraction module, the multidimensional convolution module, and the second feature extraction module to obtain the power transmission channel feature map. This enables the model to capture detailed information in the image, thereby improving the accuracy of small target detection.
[0076] To improve detection accuracy, in an exemplary embodiment, S220 includes S222 to S224. Wherein:
[0077] S222 performs convolution operations on the first feature map using convolution kernels of different dimensions in the multidimensional convolution module to obtain the global feature map and the local feature map.
[0078] S224, perform feature fusion on the global feature map and the local feature map to obtain the first feature fusion map, and process the first feature fusion map based on the activation function in the multidimensional convolution module to obtain the second feature map.
[0079] The global feature map can be a feature map that contains deep feature information of the first feature map. The local feature map can be a feature map that contains edge information and local details of the first feature map.
[0080] Considering the varying sizes and shapes of tree barriers in remote sensing images, single-scale convolution is insufficient to capture key information at different scales. Therefore, a multi-dimensional convolution module, AMConv, was designed, incorporating multi-dimensional convolutions. For example... Figure 4 As shown, it utilizes a combination of 1D, 2D, and 3D convolutions to extract spatial features at different levels, thereby improving the model's robustness in detecting both small and large tree obstacles. Specifically, 3D convolutions can capture deep-level features in spatial structures, such as the three-dimensional relationship between tree obstacles and the background in complex terrain. 1D and 2D convolutions are used to enhance edge information and local details, respectively, enabling the model to more acutely perceive subtle differences between branches, leaves, and cables.
[0081] In particular, directly using large convolutional kernels or deep convolutional networks can lead to excessively high computational costs. The AMConv module obtains rich feature representations with lower computational overhead by progressively reducing and recombining the input feature maps. This design ensures that detection speed is not affected when efficiently processing large-scale remote sensing data. Meanwhile, remote sensing images are often affected by noise, buildings, and other natural landscapes, which can easily cause feature confusion. By combining convolutional kernels of different scales in the AMConv module, it ensures that both global features of distant trees are captured and close-up details are not ignored, reducing the probability of missed and false detections.
[0082] In practical applications, such as Figure 3 As shown, in the AMConv module, the first feature map has C input channels. The first feature map is processed by a three-dimensional convolution kernel. Performing a Conv3D (3D convolution) operation yields a feature map with C / 4 channels. Using two-dimensional convolution kernels Performing a Conv2D (2D convolution) operation yields a local feature map with C / 4 channels. At the same time, through one-dimensional convolution kernels Performing a Conv1D (1D convolution) operation yields a local feature map with C / 4 channels. .
[0083] For the first feature map Perform a Conv2D operation to obtain a feature map with C / 4 channels. Meanwhile, for the first feature map Performing a Conv1D operation yields a feature map with C / 4 channels. For feature maps and feature map Perform a Concat (feature concatenation) operation, then perform a Conv3D operation on the concatenated features to obtain a global feature map with C / 2 channels. For local feature maps Local feature map Global feature map Perform a Concat operation to obtain the first feature fusion map with C channels. .
[0084] Fusion image of the first feature Activation processing via the Scelu activation function:
[0085]
[0086] In the formula, This is a scaling parameter, usually a positive number. , For adaptive parameters, where It can be adjusted according to the training effect. , Size, Given the input feature map, This is the feature map after processing with the Scelu activation function. The Scelu activation function, through its non-linear form, introduces stronger non-linear representation capabilities to the network. This enables the model to better handle complex power transmission channel tree barrier images, capturing key features in the images, thereby improving the accuracy and robustness of recognition.
[0087] Specifically, a scaling parameter is introduced into the Scelu activation function of the multidimensional convolution module to make the output distribution between layers more consistent, reducing gradient explosion and oscillation phenomena and ensuring faster model convergence. Tree obstruction detection scenarios in power transmission lines often exhibit data class imbalance, such as most pixels in remote sensing images belonging to the background and only a small number corresponding to tree obstruction areas. The Scelu activation function allows the negative parts of the output to be retained, enhancing the model's learning ability under imbalanced data and enabling the model to more accurately identify tree obstructions within small areas. Simultaneously, in monitoring tree obstruction hazards in power transmission channels, the model needs to handle complex scenarios, such as overlapping areas between branches and cables. The Scelu activation function allows for more detailed modeling of these non-linear edges, enabling the model to retain more details during segmentation and detection, improving the accurate distinction between tree obstructions and power transmission lines. The output of the AMConv module, obtained through the activation function processing, serves as the second feature map. .
[0088] In this embodiment, a multidimensional convolution module containing convolution kernels of different dimensions was designed to enhance the feature extraction capability of the initial power transmission channel tree obstruction hazard detection model. Through multi-scale convolution and flexible channel operations of the multidimensional convolution module, the features of the tree obstruction area at different spatial resolutions are accurately captured, solving the detection problem caused by complex background interference in remote sensing images.
[0089] In an exemplary embodiment, the number of multidimensional convolutional modules and second feature extraction modules is multiple, and S240 includes S242 to S248. Wherein:
[0090] S242 connects the output of each multidimensional convolution module to the input of each second feature extraction module to obtain the first feature extraction combination module, the second feature extraction combination module and the third feature extraction combination module.
[0091] S244, the features of the third feature map are extracted through the first feature extraction combination module to obtain the first scale feature map.
[0092] S246, the features of the first scale feature map are extracted by the second feature extraction combination module to obtain the second scale feature map.
[0093] S248, the features of the second-scale feature map are extracted through the third feature extraction combination module to obtain the tree barrier feature map of the power transmission channel.
[0094] In practical applications, such as Figure 3 As shown, in the initial power transmission channel tree obstacle hazard detection module, the output end of the multidimensional convolution module is connected to the input end of the second feature extraction module. The multidimensional convolution module and the second feature extraction module are stacked three times to obtain the first feature extraction combination module, the second feature extraction combination module and the third feature extraction combination module, respectively.
[0095] The input is the third feature map ( Figure 3 Feature map in Feature maps are extracted through the multidimensional convolution module in the first feature extraction combination module. Features, output feature map The feature map is processed by the second feature extraction module in the first feature extraction combination module. Feature extraction is performed to obtain the first-scale feature map. .
[0096] The first-scale feature map is input into the second feature extraction and combination module. Through multi-layer convolution operations of the multi-dimensional convolution module and the second feature extraction module, features are extracted from the first-scale feature map to reduce the spatial dimensions (height and width), resulting in feature maps. Second-scale feature map .
[0097] The second-scale feature map In the third feature extraction module, features are extracted from the second-scale feature map through multi-layer convolution operations of the multi-dimensional convolution module and the second feature extraction module, reducing the spatial dimensions (height and width) to obtain the feature maps. Tree barrier feature map of power transmission channels .
[0098] In this embodiment, the feature extraction combination module, which consists of a multidimensional convolution module and a second feature extraction module, gradually reduces the spatial dimension of the feature map and captures information at different levels. This helps the model detect targets of different sizes, while also reducing the amount of computation and improving the detection speed.
[0099] In one exemplary embodiment, such as Figure 5 As shown, the channel spatial attention fusion module performs a weighted operation on the attention of the transmission channel tree barrier feature map in both the channel dimension and the spatial dimension, resulting in the enhanced transmission channel tree barrier feature map, including S262 to S268. Wherein:
[0100] S262, the first transmission channel tree barrier feature map is obtained by performing a convolution operation on the convolutional layer in the channel spatial attention fusion module.
[0101] S264, the tree barrier feature map of the first transmission channel is processed by the activation function in the channel spatial attention fusion module to obtain the tree barrier feature map of the second transmission channel.
[0102] S266 uses the convolutional layer in the channel spatial attention fusion module to perform convolution operations on the tree barrier feature map of the power transmission channel to obtain a spatial weight map.
[0103] S268 performs a spatial weighting operation on the spatial weight map and the tree barrier feature map of the transmission channel to obtain the enhanced tree barrier feature map of the transmission channel.
[0104] In tree barrier monitoring tasks, the acquired remote sensing images often contain large areas of background (such as mountains, grasslands, and buildings), while tree barriers typically occupy only a small portion of the image. To highlight target features and suppress background noise, reducing the likelihood of missed and false detections, a channel spatial attention fusion module—CHAttention—is designed, such as... Figure 6 As shown, the feature map of the power transmission channel tree barrier is first processed by the convolutional layer in the channel spatial attention fusion module. A convolution operation is performed with a kernel size of 1×1 and a kernel count of C / r, where r is the channel compression ratio, resulting in a tree barrier feature map of the first transmission channel with a channel count of C / r. .
[0105] Secondly, the tree barrier feature map of the first transmission channel is analyzed using the Scelu activation function. Activation processing was performed to obtain the tree barrier feature map of the second transmission channel. In this embodiment, the activation process can refer to the above embodiment, where the Scelu activation function is used to fuse the first feature map. The activation process will not be described in detail here.
[0106] Tree obstacle feature map of power transmission channel Perform a convolution operation with a 1x1 kernel to obtain a spatial weight map with 1 channel. .
[0107] After obtaining the spatial weight map Then, through the spatial weighting graph Tree barrier feature map of power transmission channels Spatial multiplication is performed to obtain the output of the CHAttention module as the enhanced feature map of the power transmission channel tree barrier. Specifically, for the spatial weighting graph with channel number 1... and the number of channels is Spatial weighting operation of the tree barrier feature map of the power transmission channel: First, the spatial weight map is... Copy to tree barrier feature map of power transmission channel Generate a channel with a number of channels on each channel. Feature map Then the feature map Tree barrier feature map of power transmission channel Element-wise multiplication yields the enhanced feature map of tree barriers in the power transmission channel. The CHAttention module uses channel-level and spatial-level attention weighting operations to automatically focus the model on key regions and features, reducing attention to irrelevant information. In convolutional neural networks, the channel dimension represents different types of features (such as edge information and texture). The CHAttention module can discover potential correlations between multiple feature channels, enabling the model to more accurately combine features from different channels, thereby improving overall detection performance. For power transmission line scenarios, the background can be very complex, containing various elements such as leaves, cables, buildings, and clouds. The CHAttention module can dynamically adjust attention weights to highlight target features and suppress background noise, reducing the possibility of missed and false detections.
[0108] In this implementation, the channel-space attention fusion module effectively improves the model's sensitivity to tree obstruction hazards by fusing attention from both the channel and spatial dimensions. This enhances the accuracy of tree obstruction detection in remote sensing images containing complex backgrounds and detailed noise, while maintaining computational efficiency.
[0109] In an exemplary embodiment, based on the enhanced feature map of the power transmission channel tree barrier and features at different levels, the category, location information, and confidence level of the prediction box are determined, including steps S282 to S284. Wherein:
[0110] S282, by using the feature fusion module and multidimensional convolution module in the initial power transmission channel tree obstacle hazard detection model to fuse and extract features from the first-scale feature map, the second-scale feature map, and the power transmission channel tree obstacle feature enhancement map, the first-scale feature fusion map, the second-scale feature fusion map, and the third-scale feature fusion map are obtained.
[0111] The first-scale feature fusion map, the second-scale feature fusion map, and the third-scale feature fusion map are all different in size.
[0112] In practical applications, such as Figure 3 As shown, the enhanced image of tree barrier features along the power transmission corridor. The SPPF pooling layer (Spatial Pyramid Pooling - Fast) in the initial power transmission corridor tree obstacle hazard detection model is used to enhance the tree obstacle feature map of the power transmission corridor. Perform fast pooling operation and concatenate the outputs of the pooling operation to obtain the feature map. .
[0113] For feature maps Perform upsampling operation to increase feature map The size of the feature map allows the model to capture the target's features more precisely, and the feature map output after the upsampling operation is... With second-scale feature map Feature fusion is performed to obtain feature maps. . Feature map The input is processed in the second feature extraction module to extract features, resulting in... For feature maps Perform upsampling to obtain the feature map. For feature maps and first-scale feature map Feature fusion is performed to obtain feature maps. Feature maps are extracted through the second feature extraction module. The features are used to obtain the first-scale feature fusion map. .
[0114] The first-scale feature fusion map is extracted using a multidimensional convolution module. The features are used to obtain the feature map. For feature maps and feature map Feature fusion is performed to obtain feature maps. Feature maps are extracted through the second feature extraction module. The features are used to obtain a second-scale feature fusion map. .
[0115] Second-scale feature fusion map is extracted using a multidimensional convolution module. The features are used to obtain the feature map. For feature maps and feature map Perform feature fusion and output feature maps. Feature maps are extracted through the second feature extraction module. The features are used to obtain a third-scale feature fusion map. .
[0116] S284: Input the first-scale feature fusion map, the second-scale feature fusion map, and the third-scale feature fusion map into the target prediction head of the initial power transmission channel tree obstacle hazard detection model to generate multiple prediction boxes, and output the category, location information, and confidence level of each prediction box.
[0117] In practical applications, the first-scale feature fusion map, the second-scale feature fusion map, and the third-scale feature fusion map are respectively input into the target prediction head of the initial power transmission channel tree obstacle hazard detection model. Multiple prediction boxes for identifying tree obstacle areas are generated through the target prediction head. The category of each prediction box is predicted, and the category, location information, and confidence level of the prediction box are output.
[0118] In this embodiment, by combining the feature fusion module and the multi-dimensional convolution module to gradually reduce dimensionality and optimize the computation path, the first feature map, the second feature map, and the power transmission channel tree barrier feature enhancement map are fused and feature extracted to obtain a first-scale feature map, a second-scale feature map, and a third-scale feature map. Based on the first-scale feature map, the second-scale feature map, and the third-scale feature map, the category, location information, and confidence of the prediction box are output, which improves the detection accuracy and reduces the computational cost of the model.
[0119] To measure the quality of model predictions, in an exemplary embodiment, S300 includes S310 to S350. Wherein:
[0120] S310, Based on the location information of the ground truth bounding boxes and the location information of the predicted bounding boxes, determine the intersection-union ratio between the ground truth bounding boxes and the predicted bounding boxes.
[0121] In practical applications, the intersection-union ratio (IUR) of the ground truth bounding boxes and the predicted bounding boxes is calculated based on their location information to measure the degree of overlap between them. The IUR is the ratio of the intersection area to the union area of the ground truth and predicted bounding boxes; a higher IUR indicates a greater degree of overlap.
[0122] S320, based on the cross-union ratio, determines the predicted box loss value between the ground truth box and the predicted box.
[0123] Among them, the predicted box loss value represents the positional difference between the predicted box and the ground truth box.
[0124] In practical applications, the predicted bounding box loss value between the ground truth bounding box and the predicted bounding box can be obtained based on a preset loss function and cross-union ratio (CUI). Preset loss functions include, but are not limited to, mean squared error loss function, cross-entropy loss function, and smoothed L1 loss function.
[0125] S330: Determine the class loss value between the ground truth bounding box and the predicted bounding box based on the class label of the ground truth bounding box, the class of the predicted bounding box, and the preset loss function.
[0126] Among them, the category loss value is used to measure the difference between the predicted box category distribution and the actual category.
[0127] In practical applications, obtaining the class labels of the ground truth boxes and the class probability distribution of the predicted boxes can be achieved by using a sigmoid function combined with a binary cross-entropy loss function to determine the class loss value between the ground truth boxes and the predicted boxes.
[0128] S340, determine the confidence loss value between the ground truth box and the predicted box based on the intersection-union ratio of the ground truth box and the predicted box, and the confidence of the predicted box.
[0129] The confidence loss value is used to measure the model's prediction error regarding the presence of tree-block regions in the prediction frame.
[0130] In practical applications, the intersection-union ratio of the ground truth bounding box and the predicted bounding box can be used as the true confidence level. The confidence loss value between the ground truth bounding box and the predicted bounding box can be determined based on the cross-entropy loss function, the true confidence level, and the confidence level of the predicted bounding box.
[0131] S350 determines the error between the predicted box and the true box based on the predicted box loss value, the category loss value, and the confidence loss value.
[0132] In practical applications, weights can be assigned to the predicted box loss value, the category loss value, and the confidence loss value respectively, and the loss value (error) between the predicted box and the ground truth box can be obtained by weighted summation.
[0133] In this embodiment, the error between the model's prediction result and the true label is determined by the predicted box loss value, class loss value, and confidence loss value between the ground truth box and the predicted box. This helps to guide the adjustment of model parameters based on the error to minimize the error.
[0134] To improve the accuracy of the model's calculation of the difference between the predicted bounding box and the ground truth bounding box, in an exemplary embodiment, such as Figure 7 As shown, S400 includes S420 to S460. Wherein:
[0135] S420 determines the minimum bounding box between the ground truth box and the predicted box.
[0136] In practical applications, the smallest bounding rectangle containing both the ground truth bounding box and the predicted bounding box is defined as the minimum bounding box.
[0137] S440 determines the cross-union ratio loss value between the ground truth box and the predicted box based on the minimum bounding box, the size of the ground truth box and the predicted box, and the cross-union ratio.
[0138] In images obtained during power line inspections, tree-lined areas typically constitute a small portion of the image, while the background occupies a large portion. Traditional loss functions (such as IoU loss or cross-entropy loss) are easily affected by background pixels, causing the model to ignore sparse positive samples. This application addresses the problem of traditional loss functions neglecting the edges of small targets and objects in complex scenes (such as branches and leaves on power lines) by designing an improved Cross-Union Loss Function— The loss function considers the overall overlapping area of the objects and gives higher weights to edge regions so that the model can retain more edge details during segmentation.
[0139] The loss function is defined as follows:
[0140]
[0141] in, This represents the intersection-union ratio (IoU) between the predicted bounding box and the ground truth bounding box. , and These represent the predicted bounding box and the ground truth bounding box, respectively. and These represent the center points of the predicted bounding box and the ground truth bounding box, respectively. This represents the Euclidean distance between two points; and These represent the width and height of the smallest bounding box composed of the predicted box and the ground truth box, respectively; Represents the diagonal of the minimum bounding box; and These represent the width and height of the actual bounding box, respectively. and These represent the width and height of the prediction box, respectively.
[0142] In practical applications, based on the dimensions of the minimum bounding box, the ground truth box, and the predicted box, as well as the intersection-union ratio (IU), the IU loss value between the ground truth box and the predicted box is determined using the improved IU loss function described above. .
[0143] S460, based on the preset upper limit threshold and the preset lower limit threshold of cross-union ratio, converts the cross-union ratio into cross-union ratio loss weight through linear interval mapping, and obtains the predicted box loss value between the ground truth box and the predicted box according to the cross-union ratio loss value and the cross-union ratio loss weight.
[0144] Among them, the intersection-union ratio loss weights characterize the importance of different types of samples.
[0145] exist Based on this, a linear interval mapping is used to focus on different regression samples, and a loss value for predicting bounding boxes is designed to determine the difference between the ground truth bounding boxes and the predicted bounding boxes. Loss function.
[0146] The loss function is defined as follows:
[0147]
[0148] Among them, the linear interval mapping method is used to reconstruct Loss, allowing for improved marginal regression, yields .
[0149]
[0150] Set the lower limit threshold for intersection-union ratio. The upper limit threshold of the intersection and union ratio , By adjusting and The value can make Focusing on different regression samples. When Less than the lower threshold of intersection-union ratio hour, A value of 0 indicates that the predicted bounding box is either background or a negative sample; when Greater than the upper limit threshold of intersection-union ratio hour, A value of 1 indicates that the predicted bounding box is a positive sample; while when At the lower threshold of the intersection-union ratio The upper limit threshold of the intersection and union ratio In between, It is based on The cross-union ratio (CUI) loss weights of these samples are dynamically adjusted using a linear interval mapping method, so that the CUI loss weights change linearly with the size of the CUI.
[0151] In practical applications, based on the above formula, the intersection-union ratio (IUR) between the ground truth bounding boxes and the predicted bounding boxes is converted into IUR loss weights. Based on the cross-union loss value and the cross-union loss weight, the prediction box loss value is obtained. .
[0152] The method described above for determining the loss value between the ground truth bounding box and the predicted bounding box can better handle the bounding box regression problem in object detection, and the influence of different samples on the training process can be dynamically controlled by adjusting the thresholds. Specifically, the importance of different samples to the training process can be flexibly controlled by adjusting the upper and lower thresholds of the Intersection over Union (IoU). Lowering the lower threshold allows the model to treat predicted boxes that have almost no overlap more strictly, reducing false positives. Increasing the upper threshold allows the model to focus on predicted boxes that are already very close to the ground truth bounding boxes, further improving accuracy.
[0153] In this embodiment, an improved method for calculating the prediction box loss value is used in the training process of the initial power transmission channel tree obstacle hazard detection model, which improves the accuracy of calculating the prediction box loss value and thus improves the detection accuracy of the model.
[0154] To provide a clearer explanation of the training method for the power transmission channel tree obstruction hazard detection model provided in this application, a specific embodiment is described below, which includes the following steps:
[0155] S1. Acquire historical remote sensing images of power transmission channels. These images include category labels and location information of the ground truth bounding boxes of tree-blocked areas.
[0156] S2, taking historical remote sensing images of power transmission channels as input, calls the pre-constructed initial power transmission channel tree obstacle hazard detection model, extracts features from the historical remote sensing images of power transmission channels through the first feature extraction module to obtain a first feature map, performs convolution operations on the first feature map through convolution kernels of different dimensions in the multidimensional convolution module to obtain a global feature map and a local feature map, fuses the global feature map and the local feature map to obtain a first feature fusion map, processes the first feature fusion map based on the activation function in the multidimensional convolution module to obtain a second feature map, and extracts features from the second feature map through the second feature extraction module to obtain a third feature map.
[0157] S3 connects the output of each multidimensional convolution module to the input of each second feature extraction module to obtain a first feature extraction combination module, a second feature extraction combination module, and a third feature extraction combination module. The first feature extraction combination module extracts features from the third feature map to obtain a first-scale feature map. The second feature extraction combination module extracts features from the first-scale feature map to obtain a second-scale feature map. The third feature extraction combination module extracts features from the second-scale feature map to obtain a power transmission channel tree barrier feature map.
[0158] S4. The transmission channel tree barrier feature map is convolved by the convolutional layer in the channel spatial attention fusion module to obtain the first transmission channel tree barrier feature map. The first transmission channel tree barrier feature map is processed by the activation function in the channel spatial attention fusion module to obtain the second transmission channel tree barrier feature map. The transmission channel tree barrier feature map is convolved by the convolutional layer in the channel spatial attention fusion module to obtain the spatial weight map. The spatial weight map and the transmission channel tree barrier feature map are spatially weighted to obtain the transmission channel tree barrier feature enhancement map.
[0159] S5, through the feature fusion module and multi-dimensional convolution module in the initial power transmission channel tree obstacle hazard detection model, the first-scale feature map, the second-scale feature map, and the power transmission channel tree obstacle feature enhancement map are fused and extracted respectively to obtain the first-scale fused feature map, the second-scale fused feature map, and the third-scale fused feature map. The first-scale fused feature map, the second-scale fused feature map, and the third-scale fused feature map are input into the target prediction head of the initial power transmission channel tree obstacle hazard detection model to generate multiple prediction boxes. The category, location information, and confidence of each prediction box are output.
[0160] S6. Based on the location information of the ground truth boxes and the location information of the predicted boxes, determine the intersection-union ratio (CUP) between the ground truth boxes and the predicted boxes, determine the minimum bounding box between the ground truth boxes and the predicted boxes, determine the CUP loss value between the ground truth boxes and the predicted boxes based on the minimum bounding box, the size of the ground truth boxes and the predicted boxes, and the CUP, and convert the CUP loss into CUP loss weights through linear interval mapping based on the preset upper CUP threshold and the preset lower CUP threshold, and obtain the predicted box loss value between the ground truth boxes and the predicted boxes based on the CUP loss value and the CUP loss weights.
[0161] S7. Based on the class labels of the ground truth boxes, the class of the predicted boxes, and the preset loss function, determine the class loss value between the ground truth boxes and the predicted boxes. Based on the intersection-union ratio (IU) of the ground truth boxes and the predicted boxes, and the confidence level of the predicted boxes, determine the confidence loss value between the ground truth boxes and the predicted boxes. Based on the predicted box loss value, the class loss value, and the confidence loss value, determine the error between the predicted boxes and the ground truth boxes.
[0162] In practical applications, the feature map size is set to H×W×C, where H is the height of the feature map, W is the width of the feature map, and C is the number of channels in the feature map.
[0163] like Figure 3 As shown, a 512×512×3 historical remote sensing image of tree obstructions along a power transmission corridor is displayed. The data is first input into the initial power transmission channel tree obstacle hazard detection model. After passing through the Conv_BN_SiLU module, a feature map with 64 channels is obtained. The size is 256×256×64; the feature map Inputting the data into the AMConv module yields a feature map with 128 channels. The size is 128×128×128; Inputting the data into the C3K2 module yields a feature map with 256 channels. The size is 128×128×256; by stacking AMConv and C3K2 modules three times in sequence, feature maps of size 64×64×512 can be obtained respectively. Feature map with size 64×64×512 Feature map with size 32×32×512 Feature map with size 32×32×512 Feature map with size 16×16×512 A feature map of tree obstacles along a power transmission corridor, measuring 16×16×512 pixels. ;Will After being input into the CHAttention module, a feature map of size 16×16×512 is obtained. Then The input is fed into the SPPF pooling module to obtain a feature map of size 16×16×512. ;right Upsampling was performed to obtain a feature map of size 32×32×512. ;Will and feature map Performing the concat operation yields a feature map of size 32×32×1024. ;Will Inputting the data into the C3K2 module yields a feature map of size 32×32×512. ;right Upsampling was performed to obtain a feature map of size 64×64×512. ;Will and feature map Performing the concat operation yields a feature map of size 64×64×1024. ;Will Inputting the data into the C3K2 module yields a feature map of size 64×64×256. ;Will Inputting the data into the AMConv module yields a feature map of size 32×32×256. ;Will and feature map Performing the concat operation yields a feature map of size 32×32×768. ;Will Inputting the data into the C3K2 module yields a feature map of size 32×32×512. ;Will Inputting the data into the AMConv module yields a feature map of size 16×16×512. ;Will and Performing the concat operation yields a feature map of size 16×16×1024. ;Will Inputting the data into the C3K2 module yields a feature map of size 16×16×512. ;Will , , Each input is placed into the target prediction header, and the output is a tensor containing prediction information. Each line corresponds to a prediction, including bounding box coordinates, class label, and confidence score.
[0164] S8. Based on the error, iteratively update the parameters of the initial power transmission channel tree obstacle hazard detection model until the preset training termination condition is met, and obtain the trained power transmission channel tree obstacle hazard detection model.
[0165] On one hand, this application designs an AMConv module. Through multi-scale convolution and feature fusion, the AMConv module enables the model to maintain high-precision detection even when facing tree obstacles of different sizes and shapes. Simultaneously, its design reduces the impact of background interference in remote sensing images, improving overall detection performance. The AMConv module reduces the model's computational cost through progressive dimensionality reduction and optimized computational paths. This is particularly crucial for real-time monitoring, as power system inspections require rapid response and timely detection of potential hazards.
[0166] On the other hand, this application designs a CHAttention module. In tree obstacle monitoring tasks, the CHAttention module ensures that the model focuses on tree obstacle features while ignoring interfering information such as the sky and buildings, thus improving detection accuracy. Some features in remote sensing images are very subtle (such as fine branches and tangled cables). The CHAttention module, through dual channel and spatial attention, maximizes the preservation of detailed information and reduces feature loss during extraction. Whether in mountainous environments or urban scenes, the CHAttention module can flexibly adjust its attention weights to ensure high accuracy in various complex scenarios.
[0167] Furthermore, this application proposes a Focaler-KIoU loss function. The Focaler mechanism mitigates the background-dominant problem by dynamically adjusting the loss weights, allowing the model to focus on samples that are difficult to predict. The edges of small targets and objects in complex scenes (such as branches on power lines) are very important but are easily ignored by traditional loss functions. KIoU not only considers the overall overlapping area of objects but also assigns higher weights to edge regions, enabling the model to preserve more edge details during segmentation.
[0168] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.
[0169] The method for detecting tree obstruction hazards in power transmission channels provided in this application embodiment can be applied to, for example... Figure 1In the application environment shown, terminal 102 communicates with server 104 via a network. A data storage system can store the data that server 104 needs to process. The data storage system can be integrated onto server 104, or it can be located in the cloud or on another network server.
[0170] Specifically, the operator can send a tree obstruction hazard detection message to the server 104 via a terminal. The server receives the message, then acquires a remote sensing image of the power transmission channel. Using the remote sensing image as input, the server calls the trained tree obstruction hazard detection model to obtain the tree obstruction hazard detection result and issues an early warning based on the result.
[0171] In one example embodiment, this application also provides a method for detecting tree obstruction hazards in power transmission channels, such as... Figure 8 As shown, it includes the following S500 to S700. Wherein:
[0172] S500 acquires remote sensing images of power transmission channels.
[0173] Among them, the remote sensing image of the power transmission channel can be an image obtained by acquiring images of the power transmission channel.
[0174] In practical applications, this can be done by periodically inspecting power transmission lines during power grid operations and acquiring remote sensing images of the transmission lines using drones and satellites.
[0175] S600 takes remote sensing images of the power transmission channel as input, calls the trained power transmission channel tree obstacle hazard detection model, and obtains the tree obstacle hazard detection results. The power transmission channel tree obstacle hazard detection model is trained based on the above-mentioned power transmission channel tree obstacle hazard detection model training method.
[0176] The results of tree obstacle hazard detection can include the detection frame and category label for the tree obstacle area.
[0177] In practical applications, during the inspection and acquisition of remote sensing images of power transmission channels, the acquired images are input into a trained model obtained through the aforementioned training method for detecting tree obstructions in power transmission channels. This model detects tree obstruction areas in the remote sensing images, yielding the tree obstruction hazard detection results. The tree obstruction hazard detection model for power transmission channels is trained using the steps outlined in any of the above-mentioned training methods. The specific model training process will not be elaborated upon here.
[0178] S700 provides early warnings based on the results of tree obstacle hazard detection.
[0179] In practical applications, characterizing the detected tree obstruction area in the tree obstruction hazard detection results can be achieved by obtaining the tree obstruction area from remote sensing images of the power transmission channel where the tree obstruction area is located, obtaining the specific location information of the power transmission channel where the tree obstruction area is located based on the source of the remote sensing image, integrating the specific location information of the tree obstruction area and the time of detection to obtain early warning information, and then pushing the early warning information. Methods for pushing early warning information can include pushing alarm information in the notification bar, displaying alarm information in a full-screen or half-screen pop-up window, providing alarm prompts through specific sound or vibration patterns, and providing visual alarm prompts through flashing indicator lights, etc. It is understood that the method for pushing alarm information can be any one of the aforementioned methods or any combination of multiple methods, and is not limited here.
[0180] In this embodiment, remote sensing images of the power transmission channel are acquired and input into a trained power transmission channel tree obstacle detection model obtained through the aforementioned training method. Tree obstacle detection results are then obtained, and early warnings are issued based on these results. On the one hand, model-based detection improves the accuracy and efficiency of tree obstacle detection; on the other hand, early warnings based on the model's rapid and accurate detection results help to promptly identify potential hazards in the power system, enabling corresponding measures to be taken to reduce the likelihood of accidents and improve the stability and safety of power system operation.
[0181] In one exemplary embodiment, such as Figure 9 As shown, a power transmission corridor tree obstruction hazard detection model training device 600 is provided, including: an image acquisition module 610, a model training module 620, an error determination module 630, and a parameter update module 640, wherein:
[0182] The image acquisition module 610 is used to acquire remote sensing images of historical power transmission channels, which include category labels and location information of the true bounding boxes of tree-block areas.
[0183] The model training module 620 is used to take historical remote sensing images of power transmission channels as input and call the pre-built initial power transmission channel tree obstacle detection model. The initial power transmission channel tree obstacle detection model captures features at different levels of the historical power transmission channel remote sensing images through convolutional kernels of different dimensions in the multidimensional convolution module. Based on the features at different levels, a power transmission channel tree obstacle feature map is generated. The power transmission channel tree obstacle feature map is input to the channel spatial attention fusion module. The channel spatial attention fusion module performs a weighted operation on the attention of the power transmission channel tree obstacle feature map in the channel dimension and spatial dimension to obtain a power transmission channel tree obstacle feature enhancement map. Based on the power transmission channel tree obstacle feature enhancement map and features at different levels, the category, location information and confidence of the prediction box are determined. The prediction box is used to identify the tree obstacle area in the historical power transmission channel remote sensing image. The features at different levels include global features and local features of the historical power transmission channel remote sensing image. The initial power transmission channel tree obstacle detection model includes a multidimensional convolution module and a channel spatial attention fusion module.
[0184] The error determination module 630 is used to determine the error between the predicted box and the real box based on the category label and location information of the ground truth box, as well as the category, location information and confidence level of the predicted box.
[0185] The parameter update module 640 is used to iteratively update the parameters of the initial transmission channel tree obstacle hazard detection model based on the error until the preset training end condition is met, so as to obtain the trained transmission channel tree obstacle hazard detection model.
[0186] In an exemplary embodiment, the model training module 620 is further configured to extract features from the remote sensing images of the historical power transmission channel through the first feature extraction module to obtain a first feature map; capture features at different levels of the first feature map based on convolution kernels of different dimensions in the multidimensional convolution module to obtain a second feature map; extract features from the second feature map through the second feature extraction module to obtain a third feature map; and extract features from the third feature map at different scales based on the second feature extraction module and the multidimensional convolution module to obtain a tree barrier feature map of the power transmission channel.
[0187] In an exemplary embodiment, the model training module 620 is further configured to perform convolution operations on the first feature map using convolution kernels of different dimensions in the multidimensional convolution module to obtain a global feature map and a local feature map; perform feature fusion on the global feature map and the local feature map to obtain a first feature fusion map; and process the first feature fusion map based on the activation function in the multidimensional convolution module to obtain a second feature map.
[0188] In an exemplary embodiment, the model training module 620 is further configured to connect the output of each multidimensional convolution module to the input of each second feature extraction module to obtain a first feature extraction combination module, a second feature extraction combination module, and a third feature extraction combination module; extract features of the third feature map through the first feature extraction combination module to obtain a first-scale feature map; extract features of the first-scale feature map through the second feature extraction combination module to obtain a second-scale feature map; and extract features of the second-scale feature map through the third feature extraction combination module to obtain a power transmission channel tree barrier feature map.
[0189] In an exemplary embodiment, the model training module 620 is further configured to perform a convolution operation on the transmission channel tree barrier feature map through the convolutional layer in the channel spatial attention fusion module to obtain a first transmission channel tree barrier feature map; process the first transmission channel tree barrier feature map through the activation function in the channel spatial attention fusion module to obtain a second transmission channel tree barrier feature map; perform a convolution operation on the transmission channel tree barrier feature map through the convolutional layer in the channel spatial attention fusion module to obtain a spatial weight map; and perform a spatial weighting operation on the spatial weight map and the transmission channel tree barrier feature map to obtain a transmission channel tree barrier feature enhancement map.
[0190] In an exemplary embodiment, the parameter update module 640 is further configured to fuse and extract features from the first-scale feature map, the second-scale feature map, and the enhanced feature map of the power transmission channel tree obstruction through the feature fusion module and the multi-dimensional convolution module in the initial power transmission channel tree obstruction hazard detection model, respectively, to obtain a first-scale feature fusion map, a second-scale feature fusion map, and a third-scale feature fusion map; input the first-scale feature fusion map, the second-scale feature fusion map, and the third-scale feature fusion map into the target prediction head of the initial power transmission channel tree obstruction hazard detection model to generate multiple prediction boxes, and output the category, location information, and confidence level of each prediction box.
[0191] In an exemplary embodiment, the error determination module 630 is further configured to: determine the intersection-union ratio (IU) between the ground truth bounding box and the predicted bounding box based on the location information of the ground truth bounding box and the location information of the predicted bounding box; determine the predicted bounding box loss value between the ground truth bounding box and the predicted bounding box based on the IU of the ground truth bounding box, the category of the predicted bounding box, and a preset loss function; determine the confidence loss value between the ground truth bounding box and the predicted bounding box based on the IU of the ground truth bounding box and the confidence level of the predicted bounding box; and determine the error between the predicted bounding box and the ground truth bounding box based on the predicted bounding box loss value, the category loss value, and the confidence loss value.
[0192] In an exemplary embodiment, the error determination module 630 is further configured to: determine the minimum bounding box of the ground truth box and the predicted box; determine the cross-union ratio (CUP) loss value between the ground truth box and the predicted box based on the minimum bounding box, the size of the ground truth box and the predicted box, and the CUP; convert the CUP into a CUP loss weight through a linear interval mapping based on a preset upper CUP threshold and a preset lower CUP threshold; and obtain the predicted box loss value between the ground truth box and the predicted box based on the CUP loss value and the CUP loss weight.
[0193] Each module in the aforementioned power transmission channel tree obstruction hazard detection model training device 600 can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in the processor of a computer device in hardware form or independent of it, or stored in the memory of a computer device in software form, so that the processor can call and execute the corresponding operations of each module.
[0194] In one exemplary embodiment, such as Figure 10 As shown, a tree obstruction hazard detection device 700 for power transmission channels is provided, including: a remote sensing image acquisition module 710, a tree obstruction hazard detection module 720, and an early warning module 730, wherein:
[0195] The remote sensing image acquisition module 710 is used to acquire remote sensing images of the power transmission channel;
[0196] The tree obstruction hazard detection module 720 is used to take a remote sensing image of the power transmission channel as input, call a trained power transmission channel tree obstruction hazard detection model, and obtain the tree obstruction hazard detection result. The power transmission channel tree obstruction hazard detection model is trained based on the training method of the power transmission channel tree obstruction hazard detection model described in the above claims.
[0197] The early warning module 730 is used to issue early warnings based on the results of tree obstacle hazard detection.
[0198] In one exemplary embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 11As shown, the computer device includes a processor, memory, input / output (I / O) interfaces, and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The database stores data. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communicating with external terminals via a network. When the computer program is executed by the processor, it implements a method for training a power transmission channel tree obstruction hazard detection model, and the steps in an embodiment of the power transmission channel tree obstruction hazard detection method.
[0199] Those skilled in the art will understand that Figure 11 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0200] In one exemplary embodiment, a computer device is provided, including a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the steps in any of the above embodiments of the power transmission channel tree obstacle hazard detection model training method and the steps in the power transmission channel tree obstacle hazard detection method.
[0201] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, which, when executed by a processor, implements the steps in any of the above embodiments of the method for training a power transmission channel tree obstruction hazard detection model, and the steps in the method for detecting power transmission channel tree obstruction hazard detection.
[0202] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in any of the above embodiments of the transmission channel tree obstacle hazard detection model training method and the steps in the transmission channel tree obstacle hazard detection method.
[0203] It should be noted that the data involved in this application (including but not limited to data used for analysis, data stored, data displayed, etc.) are all data that have been fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.
[0204] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the methods described above. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, phase-change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM), etc. The processors involved in the various embodiments provided in this application may be general-purpose processors, central processing units, graphics processors, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited thereto.
[0205] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0206] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.
Claims
1. A training method for a tree obstruction hazard detection model in power transmission channels, characterized in that, The method includes: Acquire historical remote sensing images of power transmission channels, wherein the historical remote sensing images of power transmission channels include category labels and location information of the ground truth bounding boxes of tree-blocked areas; Using the historical remote sensing image of the power transmission channel as input, an initial power transmission channel tree obstruction hazard detection model is invoked. This model extracts features from the historical remote sensing image of the power transmission channel through a first feature extraction module to obtain a first feature map. Based on convolutional kernels of different dimensions in a multidimensional convolution module, features at different levels of the first feature map are captured to obtain a second feature map. Features from the second feature map are then extracted through a second feature extraction module to obtain a third feature map. The number of multidimensional convolution modules and second feature extraction modules is multiple. The outputs of each multidimensional convolutional module are connected to the inputs of each second feature extraction module to obtain a first feature extraction combination module, a second feature extraction combination module, and a third feature extraction combination module. Features of the third feature map are extracted using the first feature extraction combination module to obtain a first-scale feature map. Features of the first-scale feature map are extracted using the second feature extraction combination module to obtain a second-scale feature map. Features of the second-scale feature map are extracted using the third feature extraction combination module to obtain a power transmission channel tree barrier feature map. The tree barrier feature map of the power transmission channel is input into the channel spatial attention fusion module. The channel spatial attention fusion module performs a weighted operation on the attention of the tree barrier feature map in the channel dimension and spatial dimension to obtain the enhanced tree barrier feature map of the power transmission channel. The feature fusion module and the multi-dimensional convolution module in the initial power transmission channel tree barrier hazard detection model respectively perform feature fusion and feature extraction on the first scale feature map, the second scale feature map, and the enhanced tree barrier feature map of the power transmission channel to obtain the first scale feature fusion map, the second scale feature fusion map, and the third scale feature fusion map. The first scale feature fusion map, the second scale feature fusion map, and the third scale feature fusion map are input into the target prediction head of the initial power transmission channel tree barrier hazard detection model to generate multiple prediction boxes. The category, location information, and confidence of each prediction box are output. The prediction boxes are used to identify the tree barrier area in the historical power transmission channel remote sensing image. The features at different levels include global features and local features of the historical power transmission channel remote sensing image. The initial power transmission channel tree barrier hazard detection model includes a multi-dimensional convolution module and a channel spatial attention fusion module. Based on the category label and location information of the ground truth bounding box, and the category, location information and confidence level of the predicted bounding box, the error between the predicted bounding box and the ground truth bounding box is determined; Based on the error, the parameters of the initial power transmission channel tree obstacle hazard detection model are iteratively updated until the preset training termination condition is met, thus obtaining the trained power transmission channel tree obstacle hazard detection model.
2. The method according to claim 1, characterized in that, The second feature map is obtained by capturing features at different levels of the first feature map using convolutional kernels of different dimensions in the multidimensional convolutional module, including: The first feature map is convolved using convolution kernels of different dimensions in the multidimensional convolution module to obtain a global feature map and a local feature map. The global feature map and the local feature map are fused to obtain a first feature fusion map. The first feature fusion map is then processed based on the activation function in the multidimensional convolution module to obtain a second feature map.
3. The method according to claim 1, characterized in that, The channel spatial attention fusion module performs a weighted operation on the attention of the transmission channel tree barrier feature map in the channel dimension and spatial dimension to obtain an enhanced transmission channel tree barrier feature map, including: The first transmission channel tree barrier feature map is obtained by performing a convolution operation on the convolutional layer in the channel spatial attention fusion module. The tree barrier feature map of the first power transmission channel is processed by the activation function in the channel spatial attention fusion module to obtain the tree barrier feature map of the second power transmission channel; The spatial weight map is obtained by performing a convolution operation on the tree barrier feature map of the power transmission channel through the convolutional layer in the channel spatial attention fusion module. A spatial weighting operation is performed on the spatial weight map and the tree barrier feature map of the power transmission channel to obtain an enhanced tree barrier feature map of the power transmission channel.
4. The method according to claim 1, characterized in that, The step of determining the error between the predicted bounding box and the ground truth bounding box based on the category label and location information of the ground truth bounding box, and the category, location information, and confidence level of the predicted bounding box, includes: Based on the location information of the ground truth bounding box and the location information of the predicted bounding box, the intersection-union ratio (IUU) between the ground truth bounding box and the predicted bounding box is determined; Based on the intersection-union ratio, determine the predicted box loss value between the ground truth box and the predicted box; Based on the category label of the ground truth bounding box, the category of the predicted bounding box, and a preset loss function, determine the category loss value between the ground truth bounding box and the predicted bounding box; Based on the intersection-union ratio of the ground truth bounding box and the predicted bounding box, and the confidence level of the predicted bounding box, determine the confidence loss value between the ground truth bounding box and the predicted bounding box; The error between the predicted box and the ground truth box is determined based on the predicted box loss value, the category loss value, and the confidence loss value.
5. The method according to claim 4, characterized in that, Determining the predicted bounding box loss value between the ground truth bounding box and the predicted bounding box based on the intersection-union ratio includes: Determine the minimum bounding box between the ground truth bounding box and the predicted bounding box; Based on the dimensions of the minimum bounding box, the ground truth box, and the predicted box, and the intersection-union ratio (IU), the IU loss value between the ground truth box and the predicted box is determined; Based on a preset upper limit threshold and a preset lower limit threshold for the cross-union ratio (CUP), the CUP is converted into a CUP loss weight through linear interval mapping. Based on the CUP loss value and the CUP loss weight, the predicted box loss value between the ground truth box and the predicted box is obtained.
6. A method for detecting tree obstruction hazards in power transmission corridors, characterized in that, The method includes: Acquire remote sensing images of power transmission channels; Using the remote sensing image of the power transmission channel as input, the trained power transmission channel tree obstacle hazard detection model is called to obtain the tree obstacle hazard detection result. The power transmission channel tree obstacle hazard detection model is trained based on the power transmission channel tree obstacle hazard detection model training method according to any one of claims 1 to 5. Early warnings are issued based on the results of the tree obstacle hazard detection.
7. A training device for detecting tree obstruction hazards in power transmission channels, characterized in that, The device includes: The image acquisition module is used to acquire remote sensing images of historical power transmission channels, which include category labels and location information of the ground truth bounding boxes of tree-block areas; The model training module is used to take the historical remote sensing image of the power transmission channel as input and call the pre-constructed initial power transmission channel tree obstacle hazard detection model. The initial model extracts features from the historical remote sensing image of the power transmission channel through a first feature extraction module to obtain a first feature map. Based on convolutional kernels of different dimensions in a multi-dimensional convolution module, it captures features at different levels of the first feature map to obtain a second feature map. The second feature extraction module extracts features from the second feature map to obtain a third feature map. There are multiple multi-dimensional convolution modules and second feature extraction modules. The output of each multi-dimensional convolution module is connected to the input of each second feature extraction module to obtain a first feature extraction combination module, a second feature extraction combination module, and a third feature extraction combination module. The first feature extraction combination module extracts features from the third feature map to obtain a first-scale feature map. The second feature extraction combination module extracts features from the first-scale feature map to obtain a second-scale feature map. The third feature extraction combination module extracts features from the second-scale feature map to obtain the power transmission channel tree obstacle feature map. The tree barrier feature map of the power transmission channel is input into the channel spatial attention fusion module. The channel spatial attention fusion module performs a weighted operation on the attention of the tree barrier feature map in the channel dimension and spatial dimension to obtain the enhanced tree barrier feature map of the power transmission channel. The feature fusion module and the multi-dimensional convolution module in the initial power transmission channel tree barrier hazard detection model respectively perform feature fusion and feature extraction on the first scale feature map, the second scale feature map, and the enhanced tree barrier feature map of the power transmission channel to obtain the first scale feature fusion map, the second scale feature fusion map, and the third scale feature fusion map. The first scale feature fusion map, the second scale feature fusion map, and the third scale feature fusion map are input into the target prediction head of the initial power transmission channel tree barrier hazard detection model to generate multiple prediction boxes. The category, location information, and confidence of each prediction box are output. The prediction boxes are used to identify the tree barrier area in the historical power transmission channel remote sensing image. The features at different levels include global features and local features of the historical power transmission channel remote sensing image. The initial power transmission channel tree barrier hazard detection model includes a multi-dimensional convolution module and a channel spatial attention fusion module. An error determination module is used to determine the error between the predicted box and the real box based on the category label and location information of the ground truth box, as well as the category, location information and confidence level of the predicted box. The parameter update module is used to iteratively update the parameters of the initial power transmission channel tree obstacle hazard detection model based on the error until the preset training termination condition is met, thereby obtaining the trained power transmission channel tree obstacle hazard detection model.
8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.
10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.
Citation Information
Patent Citations
YOLOV4 remote sensing target detection method fusing feature transfer and attention mechanism
CN115497005A
Power transmission line pin state identification method based on improved YOLOv5 model
CN116778297A