A visual image analysis method for the aging degree of aircraft cable protective layer
By performing dynamic brightness enhancement processing on the visual image of the cable protective layer, the problem of improper enhancement in traditional methods is solved, and higher analysis accuracy and safety are achieved.
Patent Information
- Application Number
- CN202510180207.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-19
- Publication Date
- 2025-05-13
- Estimated Expiration
- 2045-02-19
AI Technical Summary
When the traditional Laplace sharpening processing algorithm enhances the brightness of the cable protective layer visual image, it uses a fixed coefficient, which leads to under-enhancement or over-enhancement of the enhanced image, reducing the accuracy of the aging degree of cable protective layer analysis.
By collecting the visual image of the cable protection layer, the probability value of the target pixel point is calculated based on the brightness distribution within the preset area, and the image segmentation is performed to obtain the visual image of the light and dark transition area, the high bright area and the low bright area. Then, based on the brightness enhancement coefficient and probability values of these areas, the dynamic brightness enhancement coefficient is calculated and the image is subjected to Laplace sharpening.
By dynamically adjusting the brightness enhancement coefficient, we ensure that the contrast and detail characteristics of the light and dark transition areas and other areas are appropriately enhanced, which improves the accuracy and safety of the aging degree analysis of the cable protective layer.
Smart Images

Figure CN119671917B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of visual image data processing, and in particular to a visual image analysis method for the aging degree of a protective layer of an aircraft cable. Background Art
[0002] The main function of the cable protective layer is to ensure that the conductive material in the cable is well insulated from the external environment or adjacent conductive materials. When the cable protective layer is aged or damaged, it may cause leakage of the cable, resulting in increased power consumption. In more serious cases, if the protective layer is broken, it may cause the cable to explode or even catch fire, which will pose a great threat to the safety of equipment and personnel using the cable. Therefore, in order to ensure the safety of cable use, it is crucial to conduct efficient and accurate analysis of the cable protective layer. Given that outdoor cables are usually equipped with an insulating protective layer, we can use protective layer visual imaging technology to evaluate the degree of aging of the cable protective layer to ensure the safe use of the cable.
[0003] With the rise of low-altitude economy, various types of drones have entered all aspects of society and life. Considering the cost, many cargo drones may use traditional cables for power supply and signal transmission. These traditional cables may be easily aged by the sun and rain in the air during long-term use, thus causing safety hazards. Therefore, it is very important to detect the cable protective layer after unmanned flight missions for a long time. However, in actual detection, we found that the visual images of the cable protective layer often have problems such as low contrast and insufficient detail resolution, which will seriously affect the subsequent analysis of the cable aging degree. In order to improve this situation, it is necessary to enhance the extracted visual image of the protective layer. However, the traditional Laplace sharpening algorithm usually uses a fixed coefficient of 1 for brightness enhancement. This approach is not always applicable to the visual images of cable protective layers with different characteristics. Because the fixed brightness enhancement coefficient may cause the enhanced visual image to be under-enhanced or over-enhanced, which will reduce the accuracy of the analysis results of the cable protective layer aging degree, thereby increasing the safety hazards of cable use. Therefore, it is of great significance to develop an image enhancement algorithm that can adapt to the visual images of cable protective layers with different characteristics to improve the accuracy and safety of cable protective layer analysis. Summary of the invention
[0004] In order to solve the technical problem that the effect of the above-mentioned protective layer visual image enhancement processing of the cable protective layer aging degree is not good, resulting in reduced analysis accuracy, the purpose of the present invention is to provide a visual image analysis method for the aging degree of the aircraft cable protective layer, and the technical solution adopted is as follows:
[0005] Collect a visual image of the protective layer of the cable, and obtain a probability value of the target pixel being in a light-dark transition area according to the brightness distribution of the target pixel in the protective layer visual image within a preset area; segment the protective layer visual image according to the probability value of each pixel in the protective layer visual image to obtain a visual image of the light-dark transition area; segment other areas of the protective layer visual image according to the brightness mean value of the visual image of the light-dark transition area to obtain a visual image of a high-brightness area and a visual image of a low-brightness area;
[0006] Selecting one of the light-dark transition area visual image, the highlight area visual image and the low-brightness area visual image as the target visual image, and obtaining a brightness enhancement coefficient corresponding to the target visual image according to the brightness value of the pixel point and the peak value of the brightness histogram in the target visual image;
[0007] Obtaining a dynamic brightness enhancement coefficient of the protection layer visual image according to the brightness enhancement coefficients of different areas in the protection layer visual image and the probability values of the pixel points in the corresponding areas; performing Laplace sharpening processing on the protection layer visual image according to the dynamic brightness enhancement coefficient to obtain an enhanced visual image of the protection layer visual image;
[0008] The enhanced visual image is segmented to obtain a highlight enhancement area and a low-brightness enhancement area; and whether the cable protective layer is aged is analyzed based on the difference in brightness between the highlight enhancement area and the low-brightness enhancement area.
[0009] Furthermore, the step of extracting the probability value of the target pixel being in the light-dark transition area includes:
[0010] Extract the pixel brightness level value of the target pixel within the preset area and normalize it; calculate the difference between the maximum and minimum pixel brightness values of the target pixel within the preset area to obtain the maximum brightness difference of the target pixel; and obtain the probability value of the target pixel based on the product of the brightness level value of the target pixel after normalization and the maximum brightness difference of the target pixel.
[0011] Furthermore, the step of segmenting the visual image of the protective layer according to the probability value of each pixel point in the visual image of the protective layer to obtain the visual image of the light-dark transition area includes:
[0012] Replacing the brightness value of a pixel at each position in the protection layer visual image with the probability value of the corresponding pixel to obtain a probabilistic visual image of the protection layer visual image;
[0013] According to the probability values of different pixels in the probability visual image, the pixels are clustered into two clusters using the K-means clustering algorithm. According to the clustering results, the probability visual image is divided into two categories to obtain different probability area visual images.
[0014] The pixel point in the visual image of the probability area with the largest probability value is used as the pixel point of the visual image of the light-dark transition area to obtain the visual image of the light-dark transition area.
[0015] Furthermore, the step of extracting the highlight area visual image and the low-brightness area visual image comprises:
[0016] The average brightness of the pixels in the visual image of the light-dark transition area is calculated as the first segmentation critical value, and the other areas of the protective layer visual image except the light-dark transition area are segmented according to the first segmentation critical value. The areas where the pixel brightness values are greater than or equal to the first segmentation critical value are segmented into the high-brightness area visual image; the areas where the pixel brightness values are less than the first segmentation critical value are segmented into the low-brightness area visual image.
[0017] Furthermore, the step of extracting the brightness enhancement coefficient of the target visual image includes:
[0018] Calculate the difference between the maximum and minimum brightness values in the target visual image as the extreme brightness difference of the target visual image; calculate the product of the brightness mean value and the maximum brightness difference of the target visual image; calculate the ratio of the peak value of the brightness histogram of the target visual image and the product of the brightness mean value and the maximum brightness difference of the corresponding visual image as the first ratio;
[0019] Calculate the mean difference between the target pixel point in the target visual image and other pixels in the corresponding preset area as the Laplace operator of the target pixel point, and perform negative correlation normalization on the absolute value of the Laplace operator of the target pixel point; calculate the brightness variance of the target pixel point in the target visual image and the pixels in the corresponding preset area as the correction coefficient of the target pixel point; calculate the average value of the product of the Laplace operator after negative correlation normalization of all pixels in the target visual image and the correction coefficient of the corresponding pixel point as the first product mean;
[0020] The product of the first ratio and the first product mean is calculated to obtain a brightness enhancement coefficient of the target visual image.
[0021] Furthermore, the step of extracting the dynamic brightness enhancement coefficient of the protection layer visual image includes:
[0022] Calculate the mean probability value of each pixel in the visual image of the light-dark transition area being in the light-dark transition area as the first mean probability value; calculate the mean probability value of each pixel in other areas of the visual image of the protection layer except the light-dark transition area being in the light-dark transition area as the second mean probability value; calculate the sum of the first mean probability value and the second mean probability value as the third probability value;
[0023] Calculate the ratio of the first probability value mean to the third probability value as the first weight coefficient of the visual image in the light-dark transition area; calculate the product of the first weight coefficient of the light-dark transition area and the brightness enhancement coefficient of the visual image in the corresponding light-dark transition area as the brightness enhancement of the visual image in the light-dark transition area;
[0024] Calculate the ratio of the mean value of the second probability value to the third probability value as the second weight coefficient of the visual images of other areas of the protection layer visual image except the light-dark transition area, calculate the product of the average value of the brightness enhancement coefficients of the visual images of the high-brightness area and the low-brightness area of the visual image of the protection layer except the light-dark transition area and the corresponding second weight coefficient as the brightness enhancement of the visual images of other areas of the protection layer visual image except the light-dark transition area;
[0025] The brightness enhancement of the visual image in the light-dark transition area and the brightness enhancement of the visual images in other areas of the protective layer visual image except the light-dark transition area are calculated and normalized to obtain the dynamic brightness enhancement of the protective layer visual image. The product of the dynamic brightness enhancement of the protective layer visual image and the preset maximum enhancement coefficient is calculated to obtain the dynamic enhancement degree coefficient of the protective layer visual image.
[0026] Furthermore, the step of extracting the enhanced visual image of the protection layer visual image comprises:
[0027] The product of the Laplace operator of the target pixel in the protection layer visual image and the dynamic brightness enhancement coefficient is calculated as the second product, the brightness values of all pixels in the protection layer visual image and the second product of the corresponding pixels are calculated as the enhanced pixel brightness value, and the enhanced visual image of the protection layer visual image is obtained according to the enhanced pixel brightness value.
[0028] The step of extracting the highlight enhancement area and the low-brightness enhancement area comprises:
[0029] The second segmentation critical value of the enhanced visual image is calculated by the Otsu method, and the area in the enhanced visual image where the pixel brightness value is greater than the second segmentation critical value is segmented into a highlight enhancement area; the area in the enhanced visual image where the pixel brightness value is less than or equal to the second segmentation critical value is segmented into a low brightness enhancement area.
[0030] Furthermore, the step of analyzing whether the cable protective layer is aged includes:
[0031] First, at least two normal cable protective layer visual images and two aged cable protective layer visual images are selected respectively, and the difference between the brightness mean values of the highlight enhancement area and the low brightness enhancement area of each visual image is calculated as the first difference value, and the first difference average value of all selected protective layer visual images is calculated as the judgment critical value;
[0032] The enhanced visual image of the newly extracted protective layer visual image is segmented, and the difference between the brightness means of the segmented highlight enhancement area and the low brightness enhancement area is calculated. When the difference between the brightness means of the segmented highlight enhancement area and the low brightness enhancement area is greater than or equal to the judgment critical value, it is judged that the newly extracted cable protective layer visual image is aged and the corresponding cable protective layer area is aged; when the difference between the brightness means of the segmented highlight enhancement area and the low brightness enhancement area is less than the judgment critical value, it is judged that the newly extracted cable protective layer visual image is normal and the corresponding cable protective layer area is normal.
[0033] The present invention has the following beneficial effects:
[0034] In the embodiment of the present invention, because the brightness distribution of the target pixel within the preset area can reflect the local light and dark difference change characteristics of the target pixel, the probability value of the pixel being in the light and dark transition area can be obtained. The protective layer visual image is segmented according to the probability value, and the light and dark transition area image and the visual image of other areas can be accurately obtained according to the light and dark difference change. According to the brightness mean of the visual image of the light and dark transition area, the other areas of the protective layer visual image except the light and dark transition area can be simply and accurately segmented to obtain the high-brightness area visual image and the low-brightness area visual image. The brightness enhancement coefficient of the target visual image is obtained according to the pixel brightness value and the brightness histogram peak of the target visual image. The enhancement degree coefficient of the target visual image can be obtained by taking into account the overall contrast characteristics of the target visual image area and the local detail characteristics of each pixel in the target visual image, so that the brightness enhancement coefficient result of the target visual image can be based on the characteristic of the target visual image, and the visual image enhancement quality of the target visual image can be improved in the subsequent enhancement process. The probability value and the brightness enhancement coefficient are analyzed together to obtain the dynamic enhancement degree coefficient, which can dynamically adjust the brightness enhancement coefficient in combination with the category distribution of different areas in the protective layer visual image, ensure the enhancement effect of the contrast and detail features of the light-dark transition area, and improve the subsequent segmentation accuracy of the protective layer visual image. The protective layer visual image is Laplace sharpened according to the dynamic brightness enhancement coefficient to obtain an enhanced visual image of the protective layer visual image; it can dynamically enhance the visual image based on the visual image characteristics of the protective layer visual image itself, reduce under-enhancement or over-enhancement, improve the quality of the enhanced visual image, and ultimately improve the accuracy of the analysis of the aging degree of the cable protective layer. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] In order to more clearly illustrate the technical solutions and advantages in the embodiments of the present invention or the prior art, the drawings required for use in the embodiments or the prior art descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0036] Figure 1 A flow chart of a visual image analysis method for the aging degree of a protective layer of an aircraft cable provided by an embodiment of the present invention;
[0037] Figure 2 A visual image of a normal protective layer of an aircraft cable protective layer provided by an embodiment of the present invention;
[0038] Figure 3 A visual image of an aging protective layer of an aircraft cable provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0039] In order to further explain the technical means and effects adopted by the present invention to achieve the predetermined invention purpose, the following is a detailed description of the visual image analysis method for the aging degree of the protective layer of aircraft cables proposed by the present invention, its specific implementation method, structure, features and effects, in combination with the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" does not necessarily refer to the same embodiment. In addition, specific features, structures or characteristics in one or more embodiments may be combined in any suitable form.
[0040] Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.
[0041] The following is a detailed description of a specific scheme of a visual image analysis method for the aging degree of a protective layer of an aircraft cable provided by the present invention in conjunction with the accompanying drawings.
[0042] See also Figure 1 , which shows a flow chart of a visual image analysis method for the aging degree of a protective layer of an aircraft cable provided by an embodiment of the present invention, the method comprising the following steps:
[0043] Step S1:
[0044] The visual image of the protective layer of the cable is collected, and the probability value of the target pixel point being in the light-dark transition area is obtained according to the brightness distribution of the target pixel point in the protective layer visual image within a preset area; the visual image of the protective layer is segmented according to the probability value of each pixel point in the protective layer visual image to obtain the visual image of the light-dark transition area; the other areas of the visual image of the protective layer are segmented according to the brightness mean value of the visual image of the light-dark transition area to obtain the visual image of the high-brightness area and the visual image of the low-brightness area.
[0045] In an embodiment of the present invention, the implementation scenario is an aging analysis of the aging degree of the protective layer of cables installed at low altitudes. Since cables in many old residential areas are installed at low altitudes or fixed on walls, protective layer imaging technology is required to extract the visual image of the cables. Therefore, an intelligent inspection robot equipped with a protective layer imager collects the visual image of the cable protective layer and performs image brightness analysis and processing. In the protective layer visual image, for places where the cable protective layer is damaged, the brightness of the cable varies too much, and the protective layer visual image of the damaged place will have a uniform light and dark area, which is different from the normal protective layer visual image of the cable protective layer. The difference is as follows: Figure 2 and Figure 3 As shown, Figure 2 This is a visual image of the protective layer of a normal cable; Figure 3 The visual image of the protective layer is that there is damage to the protective layer.
[0046] However, the contrast of the protective layer visual image is low, the ability to distinguish details in the visual image is poor, and the edges of the visual image are blurred, which affects the subsequent aging analysis of the cable protective layer. Therefore, it is necessary to enhance the visual image of the cable protective layer extracted to show the aging degree of the cable protective layer. The purpose of visual image enhancement is to enhance the brightness difference and detail information between the cable highlight area and the low-brightness area, facilitate the subsequent accurate segmentation of the highlight area, and improve the accuracy of the cable protective layer aging analysis. The Laplace sharpening algorithm can be used for visual image enhancement. The brightness enhancement coefficient in the traditional Laplace sharpening algorithm is generally 1. For visual images of protective layers with different characteristics, it is easy to cause the enhanced visual image to be under-enhanced or over-enhanced, reducing the accuracy of aging analysis.
[0047] In order to improve the accuracy of analyzing the aging of the cable protective layer, it is necessary to improve the brightness enhancement coefficient in the Laplace sharpening algorithm. By improving the brightness enhancement coefficient, it can be dynamically adjusted according to the visual image of the cable protective layer with different characteristics, ensuring the enhancement effect of the contrast and detail features of important areas in the visual image, and making the brightness difference between the aging area and the normal area of the cable protective layer obvious.
[0048] First, in the embodiment of the present invention, the purpose of visual image enhancement is to enhance the brightness difference and detail information between the highlight area and the low-brightness area of the cable, so as to facilitate the subsequent accurate segmentation of the highlight area. Therefore, it is necessary to segment the light-dark transition area between the highlight area and the low-brightness area in the visual image of the protective layer, and then extract the dynamic brightness enhancement coefficient of the Laplace sharpening algorithm based on the characteristics of the light-dark transition area and other areas. Because the light-dark conduction in the visual image of the protective layer is directional, that is, high temperature is conducted to low brightness, the light-dark transition area in the visual image of the protective layer refers to the area with a large change in light-dark difference, that is, the surrounding area of the damaged highlight of the cable protective layer. The light-darkness of other areas in the visual image of the protective layer except the light-dark transition area is relatively stable.
[0049] Because we need to find the light-dark transition area in the visual image of the protective layer, we need to calculate the probability of each pixel in the visual image of the protective layer being in the light-dark transition area. Combined with the definition or characteristics of the light-dark transition area, the probability value of the target pixel being in the light-dark transition area can be obtained based on the brightness distribution of the target pixel in the visual image of the protective layer within the preset area. Specifically, it includes: extracting the brightness level value of the pixel within the preset area of the target pixel and normalizing it. The target pixel refers to any pixel in the visual image of the protective layer; calculating the difference between the maximum and minimum brightness values of the pixel within the preset area of the target pixel to obtain the maximum brightness difference of the target pixel; obtaining the probability value of the target pixel being in the light-dark transition area based on the product of the brightness level value of the target pixel after normalization and the maximum brightness difference of the target pixel. The specific formula for calculating the probability value of the target pixel being in the light-dark transition area is:
[0050] Ai = (Bi / X) * (imax - imin)
[0051] In the above formula, Ai represents the probability value of the i-th target pixel in the visual image of the protective layer being in the light-dark transition area, and represents the brightness level value of the pixel of the i-th target pixel within the preset area; X represents the preset area range value of the target pixel. In the embodiment of the present invention, the preset area range refers to the target pixel and the range of the corresponding eight area pixels, then X is 9; imax represents the maximum brightness of the pixel of the i-th target pixel within the preset area; imin represents the minimum brightness of the pixel of the i-th target pixel within the preset area. Because the maximum value of Bi is X, Bi / X represents the normalization of Bi; (imax - imin) represents the maximum difference in brightness of the target pixel.
[0052] Bi / X can represent the change of brightness difference of the target pixel in the preset area. The more Bi brightness levels, that is, the more different brightness values, the more the brightness difference of the target pixel in the preset area changes.
[0053] (imax - imin) can represent the difference in brightness and darkness. The larger the maximum brightness difference of the target pixel, the greater the brightness difference of the target pixel in the preset area. Because the brightness difference in the light-dark transition area varies greatly, the larger the value of Bi / X and (imax - imin), the greater the probability that the position of the target pixel i is in the light-dark transition area. Therefore, the larger the product of Bi / X and (imax - imin), the greater the probability that the position of the target pixel is in the light-dark transition area, that is, the larger the Ai value.
[0054] At this point, the probability values of all pixel positions of the protective layer visual image of the cable protective layer aging degree being in the light-dark transition area are obtained; then the protective layer visual image is segmented according to the probability values of each pixel in the protective layer visual image to obtain the light-dark transition area image, and the specific steps are: replace the brightness value of the pixel at each position in the protective layer visual image with the probability value of the corresponding pixel being in the light-dark transition area to obtain the probabilistic visual image of the protective layer visual image. Based on the probability values of different pixels in the probabilistic visual image, the K-means clustering algorithm is used to cluster the pixels into two clusters, and the probabilistic visual image is segmented into two categories according to the clustering results to obtain different probability area visual images; the pixel in the probability area visual image with the largest probability value is used as the pixel of the light-dark transition area visual image to obtain the light-dark transition area visual image. It should be noted that the K-means clustering algorithm belongs to the prior art, and the specific clustering steps will not be repeated.
[0055] Because the probability value of the pixel point in the protective layer visual image being in the light-dark transition area can reflect the probability of whether the pixel point position is in the light-dark transition area, in the probability visual image obtained by the probability value, the probability value of the pixel point in the light-dark transition area is large, while the probability value of other areas is small; therefore, the clustering algorithm can be used to set the clustering into two clusters, clustering the pixels with high probability values into one cluster, and clustering the pixels with low probability values into another cluster; according to the clustering results, the probability visual image is divided into two categories to obtain different probability area visual images. The pixel point in the probability area visual image with the largest probability value is used as the pixel point of the light-dark transition area visual image, and the light-dark transition area visual image is obtained, and the light-dark transition area visual image in the protective layer visual image is obtained.
[0056] Furthermore, after obtaining the light-dark transition area of the protective layer visual image, other areas also include high-brightness areas and low-temperature areas. In order to accurately calculate the dynamic brightness enhancement coefficient of the protective layer visual image, it is also necessary to segment the high-brightness areas and low-brightness areas in other areas of the protective layer visual image. Segmenting other areas of the protective layer image according to the brightness mean of the visual image of the light-dark transition area to obtain the high-brightness area visual image and the low-brightness area visual image specifically includes:
[0057] The average brightness of the pixels in the visual image of the light-dark transition area is calculated as the first segmentation critical value. The first segmentation critical value is used to segment the other areas of the protective layer visual image except the light-dark transition area. The area where the pixel brightness value is greater than or equal to the first segmentation critical value is segmented into the high-brightness area visual image; the area where the pixel brightness value is less than the first segmentation critical value is segmented into the low-brightness area visual image. Because the brightness value of the high-brightness area is large and the brightness value of the low-brightness area is small, the high-brightness area visual image and the low-brightness area visual image can be obtained by segmenting according to the average brightness value of the light-dark transition area.
[0058] At this point, after obtaining the light-dark transition area visual image, the highlight area visual image and the low-brightness area image of the cable protective layer visual image, in order to obtain a more accurate dynamic brightness enhancement coefficient of the protective layer visual image, it is necessary to calculate the enhancement degree coefficients of different areas respectively.
[0059] Step S2:
[0060] Select any one of the visual images in the light-dark transition area, the visual image in the highlight area, and the visual image in the low-brightness area as the target visual image, and obtain the brightness enhancement coefficient of the corresponding target visual image according to the brightness value of the pixel points in the target visual image and the peak value of the brightness histogram.
[0061] Because calculating the brightness enhancement coefficient of visual images in different regions requires analysis based on the characteristics of the corresponding regions, the brightness value of each pixel in the regional visual image and the brightness distribution range, that is, the peak value of the brightness histogram, can reflect the overall contrast characteristics of the regional visual image and the local detail characteristics of each pixel. Therefore, the brightness enhancement coefficient of the corresponding visual image can be obtained based on the brightness value of the pixel in the visual image and the peak value of the brightness histogram.
[0062] Because the steps for calculating the brightness enhancement coefficient of the corresponding area in different regional visual images are the same, in the embodiment of the present invention, one of the light-dark transition area visual image, the highlight area visual image and the low-brightness area visual image is selected as the target visual image, and the brightness enhancement coefficient of the corresponding target visual image is obtained according to the brightness value of the pixel point and the peak value of the brightness histogram in the target visual image, and the calculation steps of the brightness enhancement coefficient of the visual images of different regions are no longer repeated. The steps for extracting the brightness enhancement coefficient of the target visual image specifically include:
[0063] Calculate the difference between the maximum and minimum brightness values in the target visual image as the maximum brightness difference of the target visual image; calculate the product of the brightness mean of the target visual image and the maximum brightness difference; calculate the ratio of the peak value of the brightness histogram of the target visual image and the product of the corresponding image brightness mean and the maximum brightness difference as the first ratio.
[0064] Calculate the mean difference between the target pixel in the target visual image and other pixels in the corresponding preset area as the Laplace operator of the target pixel, and perform negative correlation normalization on the absolute value of the Laplace operator of the target pixel; calculate the pixel brightness variance of the target pixel in the target visual image within the preset area as the correction coefficient of the target pixel; calculate the average value of the product of the Laplace operator after negative correlation normalization of all pixels in the target visual image and the correction coefficient of the corresponding pixel as the first product mean; calculate the product of the first ratio and the first product mean to obtain the brightness enhancement coefficient of the target visual image. The specific formula for extracting the brightness enhancement coefficient of the target visual image is:
[0065]
[0066] In the above formula, C represents the brightness enhancement coefficient of the target visual image, E represents the peak value of the brightness histogram of the pixel points of the target visual image, that is, the steepness of the brightness histogram distribution; Dmax represents the maximum brightness value of the target visual image, Dmin represents the minimum brightness value of the target visual image, Davg represents the mean brightness value of the target visual image; n represents the pixel value of the target visual image, Vj represents the pixel brightness variance of the jth pixel point in the target visual image within the preset area, and exp() represents an exponential function with a natural constant as the base; ▽ 2 fj represents the jth pixel in the target visual image ▽ 2 The Laplace operator of fj, in the embodiment of the present invention, is the difference between the brightness value of the j-th pixel and the average brightness values of the pixels in the other eight regions within the preset region.
[0067] The meaning of calculating the brightness enhancement coefficient of the target visual image includes: taking the visual image of the light-dark transition area as an example, when the brightness value of the light-dark transition area in the visual image of the cable protective layer is smaller, the brightness range is smaller, and a large number of pixels are concentrated on a small amount of brightness, the light-dark transition area is more blurred and the contrast is lower, and a greater degree of enhancement is required. The Laplace sharpening algorithm is that when the brightness of the target pixel is lower than the average brightness of other pixels within its preset area, the brightness of the target pixel should be further reduced; when the brightness of the target pixel is higher than the average brightness of other pixels within its preset area, the brightness of the target pixel should be further increased.
[0068] However, due to the directionality of light-dark conduction, the other pixels in the preset area of the target pixel in the light-dark transition area are along the direction of light-dark decline, and the brightness of some other pixels in the preset area of the target pixel is greater than the brightness of the target pixel, while the brightness of some other pixels is less than the brightness of the target pixel. Therefore, it is easy to cause the brightness of the target pixel to be slightly different from the average brightness of other pixels in its preset area, that is, the Laplace operator ▽ 2 The absolute value of fj is small, and the enhancement effect on the light-dark transition area is poor; but the brightness variance of the target pixel point within the preset area is large. Therefore, the brightness variance Vj of the target pixel point within the preset area is used to correct the Laplace operator, and the brightness variance Vj of the target pixel point within the preset area is used as the correction coefficient to improve the accuracy of the enhancement degree coefficient of the light-dark transition area.
[0069] Taking the visual image in the light-dark transition area as an example, E / (Dmax - Dmin)* Davg represents the brightness enhancement extracted based on the overall contrast feature of the light-dark transition area. When the average brightness of the light-dark transition area, i.e., Davg, is lower, a larger brightness enhancement is required to make the details of the low-brightness visual image obvious; when the brightness range (Dmax - Dmin) of the light-dark transition area is smaller and the peak value E of the brightness histogram is larger, the brightness histogram is steeper, indicating that a large number of pixels in the light-dark transition area are distributed on a small number of brightness levels, and the brightness levels are relatively concentrated, the contrast of the light-dark transition area is low, and a larger brightness enhancement is required to improve the contrast.
[0070]
[0071] It indicates the brightness enhancement obtained based on the detail features and enhancement effect of each pixel in the light-dark transition area. The larger the brightness variance Vj of the target pixel within the preset area, that is, the more local detail features there are at the target pixel, the greater the brightness enhancement required. When the absolute value of the Laplace operator ▽2fj is small, it means that the brightness of the target pixel is slightly different from the average brightness of other pixels within its preset area, so a larger enhancement coefficient is required to enhance the visual image details; when the Laplace operator ▽ 2 The larger the absolute value of fj is, the higher the brightness enhancement is. To avoid over-enhancement, the brightness enhancement coefficient needs to be reduced. Therefore, exp(-|▽ 2 fj|) constrains the Laplace operator. When the absolute value of the Laplace operator is smaller, exp(-|▽ 2 fj|) is closer to 1; when the absolute value of the Laplace operator is larger, exp(-|▽ 2 The closer fj|) is to 0.
[0072] Therefore, use
[0073]
[0074] The product of represents the brightness enhancement coefficient required for the light-dark transition area, which improves the contrast and detail feature enhancement effect of the light-dark transition area.
[0075] At this point, for the light-dark transition areas, highlight areas and low-brightness areas in the protective layer visual image, the brightness enhancement coefficients of the corresponding areas have been calculated; in order to improve the overall enhancement effect of the protective layer visual image, it is necessary to perform weighted calculation based on the brightness enhancement coefficients of different areas to obtain the dynamic brightness enhancement coefficient of the protective layer visual image.
[0076] Step S3:
[0077] The dynamic brightness enhancement coefficient of the protection layer visual image is obtained according to the brightness enhancement coefficients of different areas in the protection layer visual image and the probability values of the pixels in the corresponding areas; the protection layer visual image is subjected to Laplace sharpening processing according to the dynamic brightness enhancement coefficient to obtain an enhanced visual image of the protection layer visual image.
[0078] The dynamic brightness enhancement coefficient of the protection layer image is obtained by combining the brightness enhancement coefficient of the region and the probability value of the pixel points in the corresponding region. The brightness enhancement coefficient can be dynamically adjusted according to the category distribution and feature conditions of different regions in the protection layer visual image to ensure the enhancement effect of the contrast and detail features of the light and dark transition areas, thereby improving the quality of visual image enhancement.
[0079] Firstly, the dynamic brightness enhancement coefficient of the protective layer visual image is obtained according to the brightness enhancement coefficients of different areas in the protective layer visual image and the probability values of the pixels in the corresponding areas, specifically including: calculating the mean probability value of each pixel in the visual image of the light-dark transition area being in the light-dark transition area as the first mean probability value; calculating the mean probability value of each pixel in other areas of the protective layer visual image except the light-dark transition area being in the light-dark transition area as the second mean probability value; calculating the sum of the first mean probability value and the second mean probability value as the third probability value.
[0080] Calculate the ratio of the mean of the first probability value and the third probability value as the first weight coefficient of the visual image in the light-dark transition area, and calculate the product of the first weight coefficient of the light-dark transition area and the brightness enhancement coefficient of the visual image in the corresponding light-dark transition area; as the first brightness enhancement of the visual image in the light-dark transition area.
[0081] Calculate the ratio of the mean value of the second probability value to the third probability value as the second weight coefficient of the visual images in other areas of the protection layer visual image except the light-dark transition area, and calculate the product of the average value of the brightness enhancement coefficients of the visual images in the high-brightness area and the low-brightness area of the visual image in the protection layer visual image except the light-dark transition area and the corresponding second weight coefficient as the second brightness enhancement of the visual images in other areas of the protection layer visual image except the light-dark transition area.
[0082] The first brightness enhancement of the visual image in the light-dark transition area and the second brightness enhancement of the visual image in other areas of the protective layer visual image except the light-dark transition area are calculated and normalized to obtain the dynamic brightness enhancement of the protective layer visual image, and the dynamic brightness enhancement of the visual image is calculated and multiplied by the preset maximum enhancement coefficient to obtain the dynamic enhancement degree coefficient of the protective layer visual image. The specific formula for calculating the dynamic brightness enhancement coefficient of the protective layer visual image includes:
[0083] K=Norm[(Aavg1 / Aavg ) * C1 + (Aavg2 / Aavg )* C2] * R
[0084] In the above formula, k is the dynamic brightness enhancement coefficient of the visual image of the protection layer, Norm() represents normalization processing, Aavg1 represents the average probability value of each pixel in the visual image of the light-dark transition area being in the light-dark transition area, as the first probability value average, Aavg2 represents the average probability value of each pixel in other areas of the visual image of the protection layer except the light-dark transition area being in the light-dark transition area, as the second probability value average; Aavg represents the sum of the first probability value average and the second probability value average, as the third probability value; C1 represents the brightness enhancement coefficient of the visual image of the light-dark transition area, C2 represents the average brightness enhancement coefficient of the visual image of the high-brightness area and the low-brightness area of the visual image of the protection layer except the light-dark transition area; R represents the preset maximum brightness enhancement coefficient. In the embodiment of the present invention, the preset maximum brightness enhancement coefficient is 1.5, and the implementer can set it according to the implementation scenario.
[0085] Aavg1 / Aavg is the first weight coefficient of the visual image in the light-dark transition area, and Aavg2 / Aavg is the second weight coefficient of the visual image of the protective layer except the light-dark transition area. Because the purpose of enhancing the visual image of the protective layer is to accurately segment the highlight area, it is mainly necessary to improve the contrast and detail characteristics of the light-dark transition area. Therefore, the weight is calculated based on the probability value of different pixels in the light-dark transition area, and the ratio of the mean of the first probability value to the third probability value and the ratio of the mean of the second probability value to the third probability value are used as weights, so that the first weight coefficient of the light-dark transition area is larger than the second weight coefficient of other areas; finally, the dynamic brightness enhancement coefficient value of the protective layer visual image is more biased towards the brightness enhancement coefficient of the light-dark transition area.
[0086] Because the brightness enhancement coefficient in the traditional Laplace sharpening algorithm is generally 1, and for images with different characteristics, it is easy to cause the enhanced visual image to be under-enhanced or over-enhanced, therefore, in the embodiment of the present invention, by segmenting the visual image, analyzing and calculating the brightness histogram features, local details and enhancement effects of each segmented area, the brightness enhancement coefficient required for different areas is extracted; then, a larger weight is given to the light and dark transition area in the protection layer visual image, and the dynamic brightness enhancement coefficient required for the protection layer visual image is extracted by weighted summation; different dynamic brightness enhancement coefficients can be obtained for protection layer visual images with different characteristics, so as to ensure the contrast and detail feature enhancement effect of the light and dark transition area in the protection layer visual image, and provide high-quality visual images for subsequent segmentation of the protection layer visual image.
[0087] Furthermore, after obtaining the dynamic brightness enhancement coefficient of the protection layer visual image, it is necessary to perform visual image enhancement on the protection layer visual image according to the dynamic enhancement degree coefficient, specifically including: calculating the product of the Laplace operator of the target pixel in the protection layer visual image and the dynamic brightness enhancement coefficient as the second product, calculating the second product of the brightness value of all pixels in the protection layer visual image and the corresponding pixel as the enhanced pixel brightness value, and obtaining the enhanced visual image of the protection layer visual image according to the enhanced pixel brightness value. The calculation formula for the enhanced pixel brightness value in the protection layer visual image is:
[0088] Gi = fi + K * ▽ 2 fi
[0089] In the above formula, Gi represents the brightness value of the i-th pixel in the visual image of the protective layer after enhancement, and f represents the brightness value of the i-th pixel in the visual image of the protective layer. 2 fi is the Laplace operator of the pixel in the visual image of the protection layer. In the embodiment of the present invention, ▽ 2 fi is the difference between the brightness value of the ith pixel and the average brightness values of the pixels in the other eight regions within the preset region. It should be noted that the Laplace sharpening algorithm belongs to public technology, and the specific sharpening steps will not be repeated.
[0090] At this point, the enhancement processing of the cable protective layer visual image is completed, and a high-quality enhanced visual image of the protective layer visual image is obtained. Then, it is necessary to analyze whether the cable protective layer is damaged or aged.
[0091] Step S4:
[0092] The enhanced visual image is segmented to obtain a highlight enhancement area and a low-brightness enhancement area; based on the difference in brightness between the highlight enhancement area and the low-brightness enhancement area, whether the cable protective layer is aged is analyzed.
[0093] First, before analyzing whether the cable protective layer is aged, it is necessary to segment the enhanced visual image of the cable protective layer visual image to obtain the highlight enhancement area and the low brightness enhancement area of the enhanced visual image; specifically, the second segmentation critical value of the enhanced visual image is calculated by the Otsu method, and the area where the pixel brightness value in the enhanced visual image is greater than the second segmentation critical value is segmented as the highlight enhancement area; the area where the pixel brightness value in the enhanced visual image is less than or equal to the second segmentation critical value is segmented as the low brightness enhancement area. It should be noted that the Otsu method belongs to the public technology, and the specific segmentation steps are not repeated.
[0094] Furthermore, after obtaining the highlight enhancement area and the low-brightness enhancement area of the enhanced visual image, the cable protective layer aging analysis can be performed. Before the analysis, at least two normal cable protective layer visual images and two aged cable protective layer visual images are selected respectively, and the difference between the brightness means of the highlight enhancement area and the low-brightness enhancement area of each visual image is calculated as the first difference, and the first difference average of all the selected normal and aged protective layer visual images is calculated as the judgment critical value. In the embodiment of the present invention, 10 normal cable protective layer visual images and 10 aged cable protective layer visual images are selected respectively, and the implementer can select the value of the protective layer visual image according to the implementation scenario.
[0095] The enhanced visual image of the newly extracted protective layer visual image is segmented, and the difference between the brightness mean of the segmented highlight enhancement area and the low brightness enhancement area is calculated. Because when the cable protective layer is damaged and aged, the brightness nearby is higher than that of the normal insulation layer. Therefore, when the difference between the brightness mean of the segmented highlight enhancement area and the low brightness enhancement area is greater than or equal to the judgment boundary value, the newly extracted cable protective layer visual image is judged to be aged, and the corresponding cable protective layer area is aged; when the difference between the brightness mean of the segmented highlight enhancement area and the low brightness enhancement area is less than the judgment critical value, the newly extracted cable protective layer visual image is judged to be normal, and the corresponding cable protective layer area is normal.
[0096] In summary, an embodiment of the present invention provides a visual image analysis method for the aging degree of a protective layer of an aircraft cable. First, a visual image of the protective layer of the cable is extracted, and the visual image of the protective layer is segmented according to the light and dark difference change characteristics of different regions of the visual image of the protective layer to obtain images of different regions. The brightness enhancement coefficient of the visual image of the corresponding region is obtained according to the brightness characteristics of the pixels in the region; the dynamic brightness enhancement coefficient of the visual image of the protective layer is obtained according to the enhancement degree coefficient of the different regions and the weight coefficient of the corresponding region; the visual image of the protective layer is visually enhanced according to the improved dynamic brightness enhancement coefficient, and the cable protective layer is analyzed according to the visual image of the protective layer after the visual image enhancement, so as to improve the accuracy of the aging analysis of the cable protective layer.
[0097] It should be noted that the sequence of the above embodiments of the present invention is only for description and does not represent the advantages and disadvantages of the embodiments. The processes depicted in the accompanying drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0098] The various embodiments in this specification are described in a progressive manner, and the same or similar parts between the various embodiments can be referenced to each other, and each embodiment focuses on the differences from other embodiments.
Claims
1. A visual image analysis method for the aging degree of aircraft cable protective layer, characterized in that: The method comprises the following steps: Collect a visual image of the protective layer of the cable, and obtain a probability value of the target pixel being in a light-dark transition area according to the brightness distribution of the target pixel in the protective layer visual image within a preset area; segment the protective layer visual image according to the probability value of each pixel in the protective layer visual image to obtain a visual image of the light-dark transition area; segment other areas of the protective layer visual image according to the brightness mean value of the visual image of the light-dark transition area to obtain a visual image of a high-brightness area and a visual image of a low-brightness area; Selecting one of the light-dark transition area visual image, the highlight area visual image and the low-brightness area visual image as the target visual image, and obtaining a brightness enhancement coefficient corresponding to the target visual image according to the brightness value of the pixel point and the peak value of the brightness histogram in the target visual image; Obtaining a dynamic brightness enhancement coefficient of the protection layer visual image according to the brightness enhancement coefficients of different areas in the protection layer visual image and the probability values of the pixel points in the corresponding areas; performing Laplace sharpening processing on the protection layer visual image according to the dynamic brightness enhancement coefficient to obtain an enhanced visual image of the protection layer visual image; Segmenting the enhanced visual image to obtain a highlight enhancement area and a low-brightness enhancement area; analyzing whether the cable protective layer is aged according to the difference in brightness between the highlight enhancement area and the low-brightness enhancement area; The above-mentioned step of extracting the dynamic brightness enhancement coefficient of the protection layer image includes: Calculate the mean probability value of each pixel in the visual image of the light-dark transition area being in the light-dark transition area as the first mean probability value; calculate the mean probability value of each pixel in other areas of the visual image of the protection layer except the light-dark transition area being in the light-dark transition area as the second mean probability value; calculate the sum of the first mean probability value and the second mean probability value as the third probability value; Calculate the ratio of the first probability value mean to the third probability value as the first weight coefficient of the visual image in the light-dark transition area; calculate the product of the first weight coefficient of the light-dark transition area and the brightness enhancement coefficient of the visual image in the corresponding light-dark transition area as the brightness enhancement of the visual image in the light-dark transition area; Calculate the ratio of the mean value of the second probability value to the third probability value as the second weight coefficient of the visual images of other areas of the protection layer visual image except the light-dark transition area, calculate the product of the average value of the brightness enhancement coefficients of the visual images of the high-brightness area and the low-brightness area of the visual image of the protection layer except the light-dark transition area and the corresponding second weight coefficient as the brightness enhancement of the visual images of other areas of the protection layer visual image except the light-dark transition area; The brightness enhancement of the visual image in the light-dark transition area and the enhancement degree of the visual images of the protection layer visual image in other areas except the light-dark transition area are calculated and normalized to obtain the dynamic brightness enhancement of the protection layer visual image; the product of the dynamic brightness enhancement of the protection layer visual image and the preset maximum enhancement coefficient is calculated to obtain the dynamic brightness enhancement coefficient of the protection layer visual image.
2. The visual image analysis method for the aging degree of the protective layer of aircraft cables according to claim 1 is characterized in that: The step of extracting the probability value of the target pixel being in the light-dark transition area comprises: Extract the pixel brightness level value of the target pixel within the preset area and normalize it; calculate the difference between the maximum and minimum pixel brightness values of the target pixel within the preset area to obtain the maximum brightness difference of the target pixel; and obtain the probability value of the target pixel based on the product of the brightness level value of the target pixel after normalization and the maximum brightness difference of the target pixel.
3. The visual image analysis method for the aging degree of the protective layer of aircraft cables according to claim 1 is characterized in that: The step of segmenting the visual image of the protective layer according to the probability value of each pixel point in the visual image of the protective layer to obtain the visual image of the light-dark transition area comprises: Replacing the brightness value of a pixel at each position in the protection layer visual image with the probability value of the corresponding pixel to obtain a probabilistic visual image of the protection layer visual image; According to the probability values of different pixels in the probability visual image, the pixels are clustered into two clusters using the K-means clustering algorithm. According to the clustering results, the probability visual image is divided into two categories to obtain different probability area visual images. The pixel point in the visual image of the probability area with the largest probability value is used as the pixel point of the visual image of the light-dark transition area to obtain the visual image of the light-dark transition area.
4. The visual image analysis method for the aging degree of the protective layer of aircraft cables according to claim 1 is characterized in that: The step of extracting the high-brightness area visual image and the low-brightness area visual image comprises: The average brightness of the pixels in the visual image of the light-dark transition area is calculated as the first segmentation critical value, and the other areas of the protective layer visual image except the light-dark transition area are segmented according to the first segmentation critical value. The areas where the pixel brightness values are greater than or equal to the first segmentation critical value are segmented into the high-brightness area visual image; the areas where the pixel brightness values are less than the first segmentation critical value are segmented into the low-brightness area visual image.
5. The visual image analysis method for the aging degree of the protective layer of aircraft cables according to claim 1 is characterized in that: The step of extracting the brightness enhancement coefficient of the target visual image comprises: Calculate the difference between the maximum and minimum brightness values in the target visual image as the maximum brightness difference of the target visual image; calculate the product of the brightness mean value and the maximum brightness difference of the target visual image; calculate the ratio of the peak value of the brightness histogram of the target visual image and the product of the brightness mean value and the maximum brightness difference of the corresponding visual image as the first ratio; Calculate the mean difference between the target pixel point in the target visual image and other pixels in the corresponding preset area as the Laplace operator of the target pixel point, and perform negative correlation normalization processing on the absolute value of the Laplace operator of the target pixel point; calculate the brightness variance of the target pixel point in the target visual image and the pixels in the corresponding preset area as the correction coefficient of the target pixel point; calculate the average value of the product of the Laplace operator after negative correlation normalization processing of all pixels in the target visual image and the correction coefficient of the corresponding pixel point as the first product mean; The product of the first ratio and the first product mean is calculated to obtain a brightness enhancement coefficient of the target visual image.
6. The visual image analysis method for the aging degree of the protective layer of aircraft cables according to claim 1 is characterized in that: The step of extracting the enhanced visual image of the protection layer image comprises: The product of the Laplace operator of the target pixel in the protection layer visual image and the dynamic brightness enhancement coefficient is calculated as the second product, the brightness values of all pixels in the protection layer visual image and the second product of the corresponding pixels are calculated as the enhanced pixel brightness value, and the enhanced visual image of the protection layer visual image is obtained according to the enhanced pixel brightness value.
7. The visual image analysis method for the aging degree of the protective layer of aircraft cables according to claim 1 is characterized in that: The step of extracting the highlight enhancement area and the low-brightness enhancement area comprises: The second segmentation critical value of the enhanced visual image is calculated by the Otsu method, and the area in the enhanced visual image where the pixel brightness value is greater than the second segmentation critical value is segmented into a highlight enhancement area; the area in the enhanced visual image where the pixel brightness value is less than or equal to the second segmentation critical value is segmented into a low brightness enhancement area.
8. The visual image analysis method for the aging degree of the protective layer of aircraft cables according to claim 1 is characterized in that: The step of analyzing whether the cable protective layer is aged comprises: First, at least two normal cable protective layer visual images and two aged cable protective layer visual images are selected respectively, and the difference between the brightness mean values of the highlight enhancement area and the low brightness enhancement area of each visual image is calculated as the first difference value, and the first difference average value of all selected protective layer visual images is calculated as the judgment critical value; The enhanced visual image of the newly extracted protective layer visual image is segmented, and the difference between the brightness means of the segmented highlight enhancement area and the low brightness enhancement area is calculated. When the difference between the brightness means of the segmented highlight enhancement area and the low brightness enhancement area is greater than or equal to the judgment critical value, it is judged that the newly extracted cable protective layer visual image is aged and the corresponding cable protective layer area is aged; when the difference between the brightness means of the segmented highlight enhancement area and the low brightness enhancement area is less than the judgment critical value, it is judged that the newly extracted cable protective layer visual image is normal and the corresponding cable protective layer area is normal.
Citation Information
Patent Citations
Adaptive low-illumination image enhancement method and system based on MSRCR
CN113256533A
Image detection method for cable insulation layer
CN116543238A