Unmanned aerial vehicle electric power inspection image compression method and system based on directional bounding box, and medium

By using directional bounding box technology to perform region separation and compression on UAV power line inspection images, the problems of long image compression time and insufficient quality in existing technologies are solved, achieving efficient and clear power equipment image compression to meet the requirements of different inspection tasks.

CN121120808AActive Publication Date: 2025-12-12SICHUAN SIJI TECHNOLOGY CO LTD +3
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202511648668.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-12
Publication Date
2025-12-12
Estimated Expiration
2045-11-12

AI Technical Summary

Technical Problem

Existing UAV power grid inspection image compression methods are time-consuming due to hardware limitations, and the compressed images are blurry and lose key defect features, making it difficult to meet the high-efficiency and high-quality requirements of power grid inspection.

Method used

An image compression method based on directional bounding boxes is adopted. By identifying power equipment targets, directional bounding boxes that fit the equipment contour are generated. The calibrated image region and background region are compressed separately. The compression process is adjusted according to the compression ratio and recovery status, and a compressed image that meets the requirements is output.

Benefits of technology

It significantly improves compression ratio and image quality, ensuring clarity and completeness of power defect identification, enhancing the efficiency and reliability of UAV inspections, and reducing storage and transmission costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121120808A_ABST
    Figure CN121120808A_ABST
Patent Text Reader

Abstract

The invention discloses an unmanned aerial vehicle electric power inspection image compression method and system based on a directional bounding box, and a medium, and relates to the technical field of image processing. An image compression method is improved on the basis of the prior art, a directed bounding box attached to a target contour of power equipment is generated based on feature parameters of an unmanned aerial vehicle power inspection image, and first compression and second compression are performed on a calibration image area and a background area outside the calibration image. Finally, the compression process is adjusted according to the compression rate and the recovery condition, an unmanned aerial vehicle electric power inspection compressed image meeting the requirements of the compression rate and the recovery condition is output, image enhancement processing is carried out in the recovery process, and the recovery rate of the unmanned aerial vehicle electric power inspection compressed image is improved. And the processed image is ensured to meet the requirement of power defect identification on image quality in power grid inspection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image processing technology, and more specifically to a method, system, and medium for compressing images of UAV power line inspection based on directional bounding boxes. Background Technology

[0002] With the continuous advancement and deepening of power grid digitalization, power supply companies are increasingly demanding higher efficiency and intelligence in operation and maintenance. Unmanned aerial vehicle (UAV) technology, with its advantages of high flexibility, wide coverage, and adaptability to complex terrain, has been widely applied in key aspects of power grid operation and maintenance, such as pole defect detection, line corridor inspection, and equipment status monitoring, becoming an important technical means to improve the efficiency and safety of power grid operation and maintenance.

[0003] From the current state of industry development, the number of drones used for power grid operation and maintenance continues to grow, covering various types such as multi-rotor, fixed-wing, and vertical take-off and landing fixed-wing drones, which can adapt to different inspection scenarios. At the same time, the autonomous power grid inspection technology system of drones is constantly improving. From autonomous route planning and automatic take-off and landing to real-time acquisition of inspection images and preliminary defect identification, a relatively complete technology chain has been formed, and it has initially achieved the ability to be applied on a large scale, effectively reducing the workload and safety risks of manual inspection.

[0004] However, the challenge of processing massive amounts of image data during drone inspections is becoming increasingly prominent. Taking a conventional multi-rotor drone as an example, its high-definition camera can generate image data with a resolution of 4K or even higher in a single inspection. If calculated based on inspecting 100 kilometers of route per day and collecting 200 images per kilometer, the daily data volume can reach tens or even hundreds of gigabytes. Such a large amount of image data will significantly increase the pressure on data transmission. Whether it is real-time transmission back to the ground command center or batch uploading after the inspection, it will consume high communication traffic costs. Especially in remote mountainous areas with weak network signals, problems such as transmission delays and data loss may occur. On the other hand, massive amounts of data place higher demands on the capacity and read / write speed of storage devices. It is necessary not only to invest more money in purchasing high-performance storage hardware, but also to bear the long-term storage maintenance costs.

[0005] If image data is used directly for subsequent processing without effective compression, it will increase the computational burden on the power defect identification process. In existing power grid operation and maintenance systems, defect identification largely relies on computer vision algorithms. Excessive data volume can slow down algorithm processing speed and even reduce identification accuracy, affecting the overall efficiency of inspection work. Therefore, exploring efficient compression methods for power grid inspection images taken by drones can not only reduce data communication and storage costs but also provide lightweight, high-quality image data support for subsequent power defect identification. This has significant practical and technical value for promoting the in-depth application of drone inspection technology in the field of power grid operation and maintenance.

[0006] In the key technology of UAV inspection image compression, numerous scholars both domestically and internationally have conducted extensive and systematic research around the core objective of "improving compression efficiency and adapting to inspection scenarios," resulting in several representative technical solutions. Among these, one approach focuses on feature fusion technology. A biconical feature fusion image compression method fuses and optimizes multi-dimensional features such as texture and edges of the image before compression, effectively enhancing the retention of key information and thus improving compression ratio. Another approach is an adaptive weighted image compression method based on data dimensionality reduction. This method uses K-singular value decomposition to reduce the dimensionality of inspection image data, decreasing data redundancy and achieving efficient compression. A third approach focuses on network structure design. An image compression method based on residual feature aggregation uses a reconstructed subnetwork to aggregate the residual features of UAV inspection images, achieving a balance between compression efficiency and image quality to some extent while completing image compression.

[0007] Current UAV inspection image compression methods have adopted diverse technical approaches, including semantic coding, feature fusion, network reconstruction, and data dimensionality reduction, all of which have achieved certain results in improving compression rates. However, in-depth analysis of practical application scenarios reveals that these methods all rely on complex computational logic, placing high demands on the performance of the graphics processors on the UAVs. Existing UAVs, limited by hardware size, power consumption, and cost, generally have insufficient image processing computing power, directly leading to long image compression times and issues such as blurred details and loss of key defect features in compressed images. Ultimately, these methods fail to meet the stringent requirements for image clarity and integrity in power grid defect identification during power grid inspections, making them unsuitable for the efficient execution of actual inspection work. Summary of the Invention

[0008] Existing drones are limited by factors such as hardware size, power consumption, and cost, resulting in insufficient image processing computing power. This leads to long image compression times and problems such as blurred details and loss of key defect features in compressed images during actual inspection work. The purpose of this invention is to provide a drone power grid inspection image compression method, system, and medium based on directional bounding boxes. It improves the image compression method based on existing technologies by generating directional bounding boxes that fit the outline of power equipment targets based on the feature parameters of the drone power grid inspection image. First compression and second compression are performed on the calibration image area and the background area outside the calibration image, respectively, to minimize the loss of details during the compression process and significantly improve the overall compression ratio. Finally, the compression process is adjusted according to the compression ratio and recovery status to output a drone power grid inspection compressed image that meets the requirements of compression ratio and recovery status. Image enhancement processing is performed during the recovery process to ensure that the processed image meets the image quality requirements for power defect identification in power grid inspection.

[0009] The above-mentioned technical objective of the present invention is achieved through the following technical solution:

[0010] This solution provides a method for compressing UAV power line inspection images based on oriented bounding boxes. The method includes:

[0011] Step 1: Identify power equipment targets from UAV power inspection images and extract the feature parameters of the power equipment targets;

[0012] Step 2: Generate a directed bounding box that fits the outline of the power equipment target based on the feature parameters, and calibrate the directed bounding box to obtain a calibration image;

[0013] Step 3: Perform first compression and second compression on the calibration image area and the background area outside the calibration image, respectively;

[0014] Step 4: Adjust the compression process according to the compression ratio and recovery status, and output compressed images of UAV power line inspection that meet the requirements of compression ratio and recovery status.

[0015] A further optimized solution involves identifying power equipment targets from UAV power inspection images and extracting the characteristic parameters of these targets; including the following method:

[0016] A Faster R-CNN network integrating two region proposal networks is constructed to perform target detection on UAV power line inspection images and identify the initial bounding boxes of power equipment targets.

[0017] The angular distribution of the power equipment edge is extracted within the initial bounding box based on a directional filter.

[0018] Edge gradients are calculated based on the aforementioned angle distribution, and the edge orientation angles of the power equipment target are determined based on the edge gradient calculation results.

[0019] The edge orientation angles of all edge pixels are counted, and the edge orientation angle with the highest recurrence frequency is taken as the main orientation angle of the power equipment target.

[0020] The complete attitude parameters of the power equipment target are determined based on the main orientation angle.

[0021] A further optimization scheme is that the edge gradient calculation based on the angle distribution includes the following method:

[0022] For any pixel (x, y) within the target edge region, calculate the gradient components of pixel (x, y) in the x and y directions using the Sobel operator:

[0023] G x (x,y)=I(x+1,y)−I(x−1,y);

[0024] G y (x, y)=I(x, y+1)−I(x, y−1);

[0025] Among them, G x (x, y) represents the gradient component of pixel (x, y) in the x-direction; G y (x, y) represents the gradient component of pixel (x, y) in the y direction; I(x+1, y) represents the gray value of pixel (x+1, y); I(x−1, y) represents the gray value of pixel (x−1, y); I(x, y+1) represents the gray value of pixel (x, y+1); I(x, y−1) represents the gray value of pixel (x, y−1).

[0026] A further optimized solution involves determining the edge orientation angle of the power equipment target based on the edge gradient calculation results; including the following method:

[0027] The edge orientation angle α(x, y) of pixel (x, y) is calculated according to the following formula:

[0028] ;

[0029] Here, arctan() represents the arctangent function.

[0030] A further optimized solution involves determining the complete attitude parameters of the power equipment target based on the principal orientation angle; including the following method:

[0031] The main orientation angle of the power equipment target is used as the attitude rotation angle;

[0032] The maximum span of the target edge region is calculated along the direction of the attitude rotation angle and taken as the major axis length L; the maximum span of the target edge region is calculated along the direction perpendicular to the attitude rotation angle and taken as the minor axis length W.

[0033] L=u max -u min ;

[0034] W=v max -v min ;

[0035] u=(x−x c )cosθ+(y−y c sinθ;

[0036] v=−(x−x c )sinθ+(y−y c cosθ;

[0037] x c =2x min +x max ;

[0038] y c =2y min +y max ;

[0039] Among them, u max This represents the farthest point on the line of maximum span along the attitude rotation angle direction of the target edge region; u min This represents the nearest point on the line of maximum span along the attitude rotation angle direction of the target edge region; v max This represents the farthest point on the maximum span line of the target edge region along a direction perpendicular to the attitude rotation angle; v min This represents the farthest point on the maximum span line of the target edge region along a direction perpendicular to the attitude rotation angle; (x c y c () represents the center coordinates of the target's edge region; x min This represents the minimum x-coordinate of the target edge region; y min This represents the minimum ordinate of the target edge region; y max Indicates the maximum value of the ordinate of the target edge region; x max This represents the maximum x-coordinate of the target edge region.

[0040] A further optimized solution involves generating a directed bounding box that fits the target contour of the power equipment based on the feature parameters, and calibrating the directed bounding box to obtain a calibration image; including the following method:

[0041] In a local coordinate system with the center of the target edge region as the origin and the u-axis as the principal direction, the coordinates of the four vertices of a directed bounding box are generated based on feature parameters. These vertex coordinates are then transformed to the image coordinate system through rotation and translation transformations.

[0042] The calibration image is obtained by marking the top left vertex, rotation angle, major axis length, and minor axis length within the directed bounding box. The top left vertex is the vertex with the smallest y and x coordinates among the four vertices of the directed bounding box.

[0043] A further optimization scheme involves performing a first compression and a second compression on the calibration image region and the background region outside the calibration image, respectively; including the following methods:

[0044] After discrete cosine transform of the calibration image region, the difference in quantization DC coefficients between adjacent image blocks is encoded using differential pulse code modulation to obtain the compressed calibration image D. OBBZ :

[0045] ;

[0046] Where, d e Indicates the currently calibrated image region; df Indicates the adjacent images of the currently calibrated image region;

[0047] The compressed background is obtained by encoding the background region based on Discrete Wavelet Transform (DWT), and the information entropy D of the compressed background is... H for:

[0048] ;

[0049] Where, p i This represents the probability distribution of the quantization coefficients.

[0050] A further optimization scheme involves adjusting the compression process based on the compression ratio and recovery status to output compressed images of UAV power line inspection that meet the requirements of both compression ratio and recovery status; including the following method:

[0051] T41: After the first and second compressions are completed, the initial compressed image is obtained. The compression ratio is calculated. If the compression ratio does not reach the preset compression ratio, return to step two. If the compression ratio reaches the preset compression ratio, proceed to step T42.

[0052] T42, restore the initial compressed image, and determine whether the restored image is consistent with the UAV power line inspection image. If so, output the initial compressed image; otherwise, return to step two.

[0053] This solution also provides a UAV power line inspection image compression system based on oriented bounding boxes, used to implement the aforementioned UAV power line inspection image compression method based on oriented bounding boxes. The system includes:

[0054] The identification and extraction module is used to identify power equipment targets from UAV power inspection images and extract the feature parameters of the power equipment targets;

[0055] A calibration generation module is used to generate a directed bounding box that fits the target contour of the power equipment based on the feature parameters, and to calibrate the directed bounding box to obtain a calibration image.

[0056] The compression module is used to perform first compression and second compression on the calibration image area and the background area outside the calibration image, respectively.

[0057] The output module is used to adjust the compression process according to the compression ratio and recovery status, and output compressed images of UAV power line inspection that meet the requirements of compression ratio and recovery status.

[0058] This solution also provides a computer-readable medium having a computer program stored thereon, which, when executed by a processor, can implement the above-described method for compressing UAV power line inspection images based on directional bounding boxes.

[0059] Compared with the prior art, the present invention has the following beneficial effects:

[0060] 1. The purpose of this invention is to provide a method, system, and medium for compressing UAV power line inspection images based on directional bounding boxes. It improves upon existing image compression methods by generating directional bounding boxes that fit the outline of power equipment targets based on feature parameters of the UAV power line inspection image. First compression and second compression are performed on the calibrated image area and the background area outside the calibrated image, respectively, minimizing detail loss during compression and significantly improving the overall compression ratio. Finally, the compression process is adjusted according to the compression ratio and recovery status to output a UAV power line inspection compressed image that meets the requirements of both compression ratio and recovery status. Image enhancement processing is performed during the recovery process to ensure that the processed image meets the image quality requirements for power defect identification in power grid inspection.

[0061] 2. The purpose of this invention is to provide a method, system and medium for compressing images of UAV power line inspection based on directional bounding boxes. The method performs first compression and second compression on the calibrated image area and the background area outside the calibrated image respectively, realizing intelligent allocation of resources. The limited computing resources of the UAV are prioritized to ensure the clarity and analyzability of the power equipment target, rather than being wasted on irrelevant background areas.

[0062] 3. The purpose of this invention is to provide a method, system, and medium for compressing UAV power line inspection images based on directional bounding boxes. By using directional bounding boxes, the outline of the power equipment (such as insulators, transformers, and inclined wires) is closely matched, greatly reducing the background pixels contained within the box. This avoids unnecessary storage costs for redundant background information when performing high-fidelity compression on equipment areas, further improving the accuracy and efficiency of compression. Through the core technologies of precise calibration of directional bounding boxes and differentiated compression by region, the inherent contradiction between preserving key target details and overall compression efficiency in the compression process of UAV power line inspection images is resolved. This not only significantly improves the compression efficiency of images and the economy of data transmission and storage, but more importantly, by ensuring high-quality preservation of power equipment areas, a reliable data foundation is provided for subsequent intelligent diagnosis and analysis, greatly enhancing the practicality, reliability, and intelligence level of UAV power line inspection technology.

[0063] 4. The purpose of this invention is to provide a method, system, and medium for compressing images of UAV power line inspection based on directional bounding boxes. The mechanism for adjusting the entire compression process according to the compression ratio and recovery status constitutes a closed-loop control system that can evaluate the output quality in real time. If the recovery status is not up to standard, the compression process can be automatically adjusted to ensure that the output results always meet the requirements. It can adapt to different power line inspection tasks (such as daily surveys requiring high compression ratios and detailed fault investigations requiring high fidelity). Attached Figure Description

[0064] To more clearly illustrate the technical solutions of the exemplary embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly described below. It should be understood that the following drawings only show some embodiments of the present invention and should not be considered as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort. In the drawings:

[0065] Figure 1 This is a flowchart of a UAV power line inspection image compression method based on directional bounding boxes.

[0066] Figure 2 This is a schematic diagram of the image compression method for UAV power line inspection based on directional bounding boxes.

[0067] Figure 3 This is a schematic diagram of the structure of a UAV power line inspection image compression system based on directional bounding boxes. Detailed Implementation

[0068] To make the objectives, technical solutions, and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the embodiments and accompanying drawings. The illustrative embodiments and descriptions of the present invention are only used to explain the present invention and are not intended to limit the present invention.

[0069] Existing drones are limited by factors such as hardware size, power consumption, and cost, resulting in insufficient image processing computing power. This leads to a long image compression process and, in actual inspection work, problems such as blurred details and loss of key defect features in compressed images are easily encountered. In view of this, this solution provides the following embodiments to solve the above-mentioned technical problems:

[0070] Example 1

[0071] This embodiment provides a method for compressing UAV power line inspection images based on oriented bounding boxes, such as... Figure 1 and Figure 2 As shown, the method includes:

[0072] Step one involves identifying power equipment targets from UAV power line inspection images and extracting their feature parameters. This step specifically includes the following methods:

[0073] S11, Construct a Faster R-CNN network that integrates two region proposal networks to perform target detection on UAV power line inspection images and identify the initial bounding boxes of power equipment targets. Power equipment targets in this scheme include insulators, surge arresters, and other power equipment. The Faster R-CNN network ultimately outputs the initial bounding box coordinates of the power equipment targets, used to locate the approximate position of the equipment in the image. Let the coordinate system of the UAV power line inspection image be O−xy (origin O is the upper left corner of the UAV power line inspection image, x-axis is horizontal to the right, y-axis is vertical downwards), then the coordinates of the four vertices of the initial bounding box of a single target device are represented as follows: ;where x min and y min x and y coordinates of the top-left vertex of the initial bounding box; max and y max The x and y coordinates are the lower right corner vertex of the initial bounding box; this initial bounding box covers the entire area of ​​the power equipment target, defining the range for subsequent attitude feature extraction.

[0074] S12, based on the directional filter, extracts the angular distribution of the power equipment edge within the initial bounding box; Gaussian directional filter or Sobel directional operator can be used for extraction. The core is to calculate the gradient direction of the edge pixels, and then determine the main direction of the power equipment; such as the tilt direction of the insulator string and the installation direction of the surge arrester;

[0075] S13, perform edge gradient calculation based on the angle distribution, and determine the edge orientation angle of the power equipment target based on the edge gradient calculation result;

[0076] This step involves calculating the edge gradient based on the stated angle distribution, including the following methods:

[0077] For any pixel (x, y) within the target edge region, calculate the gradient components of pixel (x, y) in the x and y directions using the Sobel operator:

[0078] G x (x,y)=I(x+1,y)−I(x−1,y);

[0079] G y (x, y)=I(x, y+1)−I(x, y−1);

[0080] Among them, G x (x, y) represents the gradient component of pixel (x, y) in the x-direction; G y(x, y) represents the gradient component of pixel (x, y) in the y direction; I(x+1, y) represents the gray value of pixel (x+1, y); I(x−1, y) represents the gray value of pixel (x−1, y); I(x, y+1) represents the gray value of pixel (x, y+1); I(x, y−1) represents the gray value of pixel (x, y−1).

[0081] The method for determining the edge orientation angle of the power equipment target based on the edge gradient calculation results includes:

[0082] The edge orientation angle α(x, y) of pixel (x, y) is calculated according to the following formula:

[0083] ;

[0084] Here, arctan() represents the arctangent function.

[0085] S14: Calculate the edge orientation angles of all edge pixels, and take the edge orientation angle with the highest recurrence frequency as the main orientation angle of the power equipment target; Histogram statistics can be performed on the edge orientation angles of all edge pixels;

[0086] S15, determine the complete attitude parameters of the power equipment target based on the main direction angle.

[0087] This step specifically includes the following methods:

[0088] The main orientation angle of the power equipment target is used as the attitude rotation angle;

[0089] The maximum span of the target edge region is calculated along the direction of the attitude rotation angle and taken as the major axis length L; the maximum span of the target edge region is calculated along the direction perpendicular to the attitude rotation angle and taken as the minor axis length W.

[0090] L=u max -u min ;

[0091] W=v max -v min ;

[0092] u=(x−x c )cosθ+(y−y c sinθ;

[0093] v=−(x−x c )sinθ+(y−y c cosθ;

[0094] x c =2x min +x max ;

[0095] y c =2y min +y max ;

[0096] Among them, u max This represents the farthest point on the line of maximum span along the attitude rotation angle direction of the target edge region; u min This represents the nearest point on the line of maximum span along the attitude rotation angle direction of the target edge region; v max This represents the farthest point on the maximum span line of the target edge region along a direction perpendicular to the attitude rotation angle; v min This represents the farthest point on the maximum span line of the target edge region along a direction perpendicular to the attitude rotation angle; (x c y c () represents the center coordinates of the target's edge region; x min This represents the minimum x-coordinate of the target edge region; y min This represents the minimum ordinate of the target edge region; y max Indicates the maximum value of the ordinate of the target edge region; x max This represents the maximum x-coordinate of the target edge region.

[0097] Step two involves generating a directed bounding box that fits the outline of the power equipment target based on feature parameters, and then calibrating the directed bounding box to obtain a calibration image (OBB). This step specifically includes the following methods:

[0098] S21, in a local coordinate system with the center of the target edge region as the origin and the main direction as the u-axis, the coordinates of the four vertices of the directed bounding box are generated based on the feature parameters, and the vertex coordinates are transformed to the image coordinate system through rotation and translation transformations; the directed bounding box fits the device outline to ensure that it only contains the main body of the power equipment and necessary connecting parts.

[0099] This solution achieves accurate bounding box selection of the power equipment body and necessary connecting components through a combination of "multi-step feature extraction + directional bounding box generation". First, a Faster R-CNN network integrating a dual-region proposal network is constructed to perform target detection on UAV inspection images. This network, using a pre-trained power equipment feature library, can identify power equipment targets from complex backgrounds such as the sky, trees, and mountains, outputting an initial bounding box covering the entire area of ​​the equipment and initially eliminating a large number of irrelevant background pixels. Second, based on directional filters, the angular distribution of the power equipment edges is extracted within the initial bounding box, focusing on the contour features of the equipment body. Finally, a local coordinate system is established with the center of the equipment edge region as the origin and the main direction as the u-axis, generating a bounding box that fits the equipment contour.

[0100] Necessary connecting components refer to connecting / auxiliary structures that are directly attached to the main body of the power equipment and are of great significance for determining the equipment's function or detecting defects. The judgment logic revolves around "equipment functional relevance + necessity for defect identification." If a component has a direct mechanical or electrical connection to the main body of the equipment, and the absence of the component would cause the equipment to malfunction, then it is considered a necessary connecting component; conversely, components that are not directly functionally related to the equipment are excluded.

[0101] The coordinates of the four vertices (P1, P2, P3, P4) of the directed bounding box are:

[0102] ;

[0103] Transform the vertex coordinates to the image coordinate system using the following formula:

[0104] ;

[0105] S22, mark the top left vertex, rotation angle, major axis length and minor axis length in the directed bounding box to obtain the calibration image, where the top left vertex is the vertex with the smallest y coordinate and x coordinate among the four vertices of the directed bounding box.

[0106] Obtain the directed bounding box calibration image D that fits the device contour. OBB :

[0107] ;

[0108] Step 3: Perform first compression and second compression on the OBB region of the calibration image and the background region outside the calibration image, respectively; this step specifically includes the following methods:

[0109] For directed bounding box regions, the smallest 8×8 pixel unit in power line inspection images exhibits a relatively large DC coefficient (DC) value after Discrete Cosine Transform (DCT). Simultaneously, the DC coefficient (DC) values ​​of adjacent pixel units show minimal variation. Therefore, this characteristic can be utilized to encode the difference (DF) in the DC coefficient (DC) between adjacent image blocks using Differential Pulse Code Modulation (DPCM). Specifically, after the calibration image region undergoes Discrete Cosine Transform, the difference in quantized DC coefficients between adjacent image blocks is encoded using Differential Pulse Code Modulation to obtain the compressed calibration image D. OBBZ :

[0110] ;

[0111] Where, d e Indicates the currently calibrated image region; d f This represents the adjacent images of the currently calibrated image region; in this scheme, it represents the background region image.

[0112] The compressed background is obtained by encoding the background region based on the Discrete Wavelet Transform (DWT) compression method. The information entropy D of the compressed background is... H for:

[0113] ;

[0114] Where, p i This represents the probability distribution of the quantization coefficients.

[0115] Quantization coefficients are discrete values ​​obtained by approximating the continuous transform coefficients of the background region image after discrete wavelet transform using a preset quantization matrix. Essentially, they simplify the representation of high-frequency and low-frequency components of the image, aiming to reduce data redundancy and provide efficiently processed foundational data for subsequent encoding and compression. Quantization coefficients directly originate from the image data of the background region and are the core processing object for background region compression. As the part of the background region outside the power equipment target in UAV inspection images, its information importance is relatively low; therefore, high compression rates can be achieved by adjusting the quantization coefficients.

[0116] Step 4: Adjust the compression process according to the compression ratio and recovery status, and output compressed images of UAV power line inspection that meet the requirements of compression ratio and recovery status.

[0117] This step specifically includes the following methods:

[0118] T41: After the first and second compressions are completed, the initial compressed image is obtained. The compression ratio is calculated. If the compression ratio does not reach the preset compression ratio, return to step two. If the compression ratio reaches the preset compression ratio, proceed to step T42.

[0119] T42, restore the initial compressed image, and determine whether the restored image is consistent with the UAV power line inspection image. If so, output the initial compressed image as the UAV inspection compressed image; otherwise, return to step two.

[0120] In the process of restoring images from UAV power line inspections, the image is first decoded according to the rules of the compression stage. Then, the decompressed image is optimized using image enhancement technology to provide a clearer image basis for subsequent defect identification.

[0121] Image enhancement is a technique that highlights useful information related to defect identification (such as equipment edges and abnormal areas) in inspection images while removing or weakening useless information such as background noise and redundant details. Its core purpose is to make the processed image more consistent with human visual perception characteristics or easier for machines to extract key features to improve recognition accuracy. Therefore, this solution uses image enhancement technology to specifically improve the quality of decompressed inspection images. Spatial filtering is one of the core methods of image enhancement. Its principle is to perform neighborhood operations on the image within the spatial domain of the inspection image using a preset template. In specific operations, the template is moved point by point on the image to be processed. The response value of the filter at each pixel is calculated from the predefined template coefficients and the gray value of the corresponding pixel within the template's coverage area. Through this process, noise in the decompressed image can be effectively suppressed, equipment outlines strengthened, and image quality further improved. The output result of spatial filtering is D. r It can be represented as:

[0122] ;

[0123] Where, m s Indicates the minimum number of processing units for UAV power line inspection images; l represents the spatial filter for UAV power line images; D OBBZ.j D represents the j-th smallest processing unit of the calibrated image region. H.j This represents the j-th smallest electrical processing unit in the background region.

[0124] Example 2

[0125] This embodiment provides a UAV power line inspection image compression system based on directional bounding boxes, used to implement the UAV power line inspection image compression method based on directional bounding boxes described in Embodiment 1, such as... Figure 3 As shown, the system includes:

[0126] The identification and extraction module is used to identify power equipment targets from UAV power inspection images and extract the feature parameters of the power equipment targets;

[0127] A calibration generation module is used to generate a directed bounding box that fits the target contour of the power equipment based on the feature parameters, and to calibrate the directed bounding box to obtain a calibration image.

[0128] The compression module is used to perform first compression and second compression on the calibration image area and the background area outside the calibration image, respectively.

[0129] The output module is used to adjust the compression process according to the compression ratio and recovery status, and output compressed images of UAV power line inspection that meet the requirements of compression ratio and recovery status.

[0130] Example 3

[0131] This embodiment provides a computer-readable medium storing a computer program, which, when executed by a processor, implements the UAV power line inspection image compression method based on directional bounding boxes as described in Embodiment 1; specifically, it performs the following steps:

[0132] Step 1: Identify power equipment targets from UAV power inspection images and extract the feature parameters of the power equipment targets;

[0133] Step 2: Generate a directed bounding box that fits the outline of the power equipment target based on the feature parameters, and calibrate the directed bounding box to obtain a calibration image;

[0134] Step 3: Perform first compression and second compression on the calibration image area and the background area outside the calibration image, respectively;

[0135] Step 4: Adjust the compression process according to the compression ratio and recovery status, and output compressed images of UAV power line inspection that meet the requirements of compression ratio and recovery status.

[0136] The specific embodiments described above further illustrate the purpose, technical solution, and beneficial effects of the present invention. It should be understood that the above description is only a specific embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

Claims

1. A method for compressing UAV power line inspection images based on directional bounding boxes, characterized in that, The methods include: Step 1: Identify power equipment targets from UAV power inspection images and extract the feature parameters of the power equipment targets; Step 2: Generate a directed bounding box that fits the outline of the power equipment target based on the feature parameters, and calibrate the directed bounding box to obtain a calibration image; Step 3: Perform first compression and second compression on the calibration image area and the background area outside the calibration image, respectively; Step 4: Adjust the compression process according to the compression ratio and recovery status, and output compressed images of UAV power line inspection that meet the requirements of compression ratio and recovery status.

2. The UAV power line inspection image compression method based on directional bounding boxes according to claim 1, characterized in that, The process involves identifying power equipment targets from UAV power inspection images and extracting the characteristic parameters of the power equipment targets. Including methods: A Faster R-CNN network integrating two region proposal networks is constructed to perform target detection on UAV power line inspection images and identify the initial bounding boxes of power equipment targets. The angular distribution of the power equipment edge is extracted within the initial bounding box based on a directional filter. Edge gradients are calculated based on the aforementioned angle distribution, and the edge orientation angles of the power equipment target are determined based on the edge gradient calculation results. The edge orientation angles of all edge pixels are counted, and the edge orientation angle with the highest recurrence frequency is taken as the main orientation angle of the power equipment target. The complete attitude parameters of the power equipment target are determined based on the main orientation angle.

3. The UAV power line inspection image compression method based on directional bounding boxes according to claim 2, characterized in that, The method for calculating edge gradients based on the angle distribution includes: For any pixel (x, y) within the target edge region, calculate the gradient components of pixel (x, y) in the x and y directions using the Sobel operator: G x (x, y) = I(x + 1, y) - I(x - 1, y); G y (x, y) = I(x, y + 1) - I(x, y - 1); Among them, G x (x, y) represents the gradient component of pixel (x, y) in the x-direction; G y (x, y) represents the gradient component of pixel (x, y) in the y direction; I(x+1, y) represents the gray value of pixel (x+1, y); I(x−1, y) represents the gray value of pixel (x−1, y); I(x, y+1) represents the gray value of pixel (x, y+1); I(x, y−1) represents the gray value of pixel (x, y−1).

4. The UAV power line inspection image compression method based on directional bounding boxes according to claim 3, characterized in that, The method for determining the edge orientation angle of the power equipment target based on the edge gradient calculation results includes: The edge orientation angle α(x, y) of pixel (x, y) is calculated according to the following formula: ; Here, arctan() represents the arctangent function.

5. The UAV power line inspection image compression method based on directional bounding boxes according to claim 4, characterized in that, The complete attitude parameters of the power equipment target are determined based on the principal orientation angle; including method: The main orientation angle of the power equipment target is used as the attitude rotation angle; The maximum span of the target edge region is calculated along the direction of the attitude rotation angle and taken as the major axis length L; the maximum span of the target edge region is calculated along the direction perpendicular to the attitude rotation angle and taken as the minor axis length W. L=u max −and min ; W=v max −v min ; u=(x−x c )cosθ+(y−y c )sinθ; v=−(x−x c )sinθ+(y−y c )cosθ; x c =2x min +x max ; and c =2y min +and max ; Among them, u max This represents the farthest point on the line of maximum span along the attitude rotation angle direction of the target edge region; u min This represents the nearest point on the line of maximum span along the attitude rotation angle direction of the target edge region; v max This represents the farthest point on the maximum span line of the target edge region along a direction perpendicular to the attitude rotation angle; v min This represents the farthest point on the maximum span line of the target edge region along a direction perpendicular to the attitude rotation angle; (x c y c () represents the center coordinates of the target's edge region; x min This represents the minimum x-coordinate of the target edge region; y min This represents the minimum value of the ordinate of the target edge region; y max Indicates the maximum value of the ordinate of the target edge region; x max This represents the maximum x-coordinate of the target edge region.

6. The UAV power line inspection image compression method based on directional bounding boxes according to claim 5, characterized in that, Based on the feature parameters, a directed bounding box that fits the target contour of the power equipment is generated, and the directed bounding box is calibrated to obtain a calibration image. Including methods: In a local coordinate system with the center of the target edge region as the origin and the main direction as the u-axis, the coordinates of the four vertices of the directed bounding box are generated based on the feature parameters, and the vertex coordinates are transformed to the image coordinate system through rotation and translation transformations. The calibration image is obtained by marking the top left vertex, rotation angle, major axis length, and minor axis length within the directed bounding box. The top left vertex is the vertex with the smallest y and x coordinates among the four vertices of the directed bounding box.

7. The UAV power line inspection image compression method based on directional bounding boxes according to claim 6, characterized in that, The first compression and the second compression are performed on the calibration image region and the background region outside the calibration image, respectively; including... method: After discrete cosine transform of the calibration image region, the difference in quantization DC coefficients between adjacent image blocks is encoded using differential pulse code modulation to obtain the compressed calibration image D. OBBZ : ; Where, d e Indicates the currently calibrated image region; d f Indicates the adjacent images of the currently calibrated image region; The compressed background is obtained by encoding the background region based on Discrete Wavelet Transform (DWT), and the information entropy D of the compressed background is... H for: ; Where, p i This represents the probability distribution of the quantization coefficients.

8. The UAV power line inspection image compression method based on directional bounding boxes according to claim 1, characterized in that, The compression process is adjusted according to the compression ratio and recovery status to output compressed images of UAV power line inspection that meet the requirements of compression ratio and recovery status. Including methods: T41: After the first and second compressions are completed, the initial compressed image is obtained. The compression ratio is calculated. If the compression ratio does not reach the preset compression ratio, return to step two. If the compression ratio reaches the preset compression ratio, proceed to step T42. T42, restore the initial compressed image, and determine whether the restored image is consistent with the UAV power line inspection image. If so, output the initial compressed image. Otherwise, return to step two.

9. An image compression system for UAV power line inspection based on directional bounding boxes, characterized in that, The system is used to implement the UAV power line inspection image compression method based on directional bounding boxes as described in any one of claims 1-8, the system comprising: The identification and extraction module is used to identify power equipment targets from UAV power inspection images and extract the feature parameters of the power equipment targets; A calibration generation module is used to generate a directed bounding box that fits the target contour of the power equipment based on the feature parameters, and to calibrate the directed bounding box to obtain a calibration image. The compression module is used to perform first compression and second compression on the calibration image area and the background area outside the calibration image, respectively. The output module is used to adjust the compression process according to the compression ratio and recovery status, and output compressed images of UAV power line inspection that meet the requirements of compression ratio and recovery status.

10. A computer-readable medium having a computer program stored thereon, characterized in that, The computer program, when executed by a processor, can implement the UAV power line inspection image compression method based on directional bounding boxes as described in any one of claims 1-8.

Citation Information

Patent Citations

  • Rotary ship target detection model training method and training device and storage medium

    CN114419467A

  • Data compression coding technology for power transmission operation and maintenance scene

    CN116896638A

  • Spacer image compression method and system for electric power inspection based on graph segmentation technology

    CN117560511A

  • Directed bounding box-based suspension clamp offset fault detection method and device

    CN118823615A

  • Data compression transmission method and system applied to ferry inspection images

    CN120475170A