A method and system for denoising cable lead seal ultrasonic fan scan images

By combining jump regression model and adaptive elliptical neighborhood kernel regression with multi-resolution local clustering, the problems of noise suppression and defect reconstruction in ultrasonic sector scan images are solved, and high-precision cable lead seal detection is achieved.

CN122367783APending Publication Date: 2026-07-10STATE GRID SHANDONG ELECTRIC POWER CO
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610431250.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-04-02
Publication Date
2026-07-10

AI Technical Summary

Technical Problem

Existing technologies cannot effectively suppress speckle noise in ultrasonic sector scan images, while accurately restoring the geometric morphology of internal defects in cable seals, resulting in low detection accuracy and efficiency.

Method used

A jump regression model is used for edge pixel detection. Combined with adaptive elliptical neighborhood kernel regression and multi-resolution local clustering, the smoothing parameters are dynamically adjusted to identify and extract the edge pixel set of lead seal defects. Noise is suppressed by adaptive elliptical neighborhood kernel regression, and defect features are preserved by local clustering.

Benefits of technology

It achieves precise partitioning of ultrasonic sector scan images, reduces noise interference, improves the accuracy and efficiency of identifying internal defects in lead seals, and enhances the precision and efficiency of detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122367783A_ABST
    Figure CN122367783A_ABST
Patent Text Reader

Abstract

The application provides a cable lead seal ultrasonic fan scanning image denoising method and system, and relates to the technical field of power cable detection. The method comprises the following steps: S1, obtaining an original ultrasonic fan scanning image of a cable lead seal defect, and converting the original ultrasonic fan scanning image into a two-dimensional rectangular coordinate pixel matrix; S2, performing edge pixel detection: estimating a local intensity gradient through least square plane fitting, and extracting an edge pixel set of the lead seal defect; S3, calculating the distance from a pixel point to be processed to the nearest edge point in the edge pixel set; S4, if the distance is greater than a threshold parameter, constructing an adaptive elliptical neighborhood that does not cross the edge, and calculating the pixel intensity after denoising; and S5, if the distance is less than or equal to the threshold parameter, based on the dynamic clustering of the pixel intensity, dividing the neighborhood into different connected regions, and performing weighted average denoising. The method reduces the global noise, improves the accuracy of extracting boundary features, and improves the accuracy and efficiency of cable lead seal defect identification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of power cable testing technology, and in particular to a method and system for denoising ultrasonic sector scan images of cable lead seals. Background Technology

[0002] Non-destructive testing of high-voltage cable lead seals is a key step in assessing the operational reliability of cable terminals and joints. Ultrasonic imaging technology is the mainstream method for detecting defects such as cracks, pores, and delamination inside the lead seals. However, due to the strong acoustic wave scattering characteristics of lead materials and the inherent coherence characteristics of ultrasonic imaging, the generated ultrasonic sector scan images have severe speckle noise, which greatly interferes with the accuracy of defect identification.

[0003] Traditional denoising techniques (median filtering, Gaussian smoothing, etc.) cannot dynamically adjust smoothing parameters according to the local structure of the image, resulting in insufficient protection of the edges of minute defects. They are prone to mistakenly erasing fine crack signals, reducing defect contrast, increasing the difficulty of manual interpretation, and even causing missed detection of critical safety hazards. Existing specialized technologies also have technical bottlenecks: First, the jump regression method is only applicable to linear edge processing and is difficult to capture the complex nonlinear topology and fine details of minute cracks in cable seal defects. Second, local clustering smoothing technology lacks spatial neighborhood adaptive constraints, and is prone to oversmoothing and clustering errors when facing strong ultrasonic coherent noise. It also has high computational costs and cannot be adapted to real-time monitoring scenarios. Third, when processing ultrasonic sector-scan variable resolution images, a fixed window is used, which is difficult to adapt to changes in image statistical characteristics caused by beam divergence and energy attenuation. At the same time, it lacks the ability to dynamically perceive the acoustic impedance jumps at the seal interface and cannot construct a matching asymmetric smoothing neighborhood.

[0004] In summary, existing technologies cannot effectively suppress severe speckle noise in ultrasonic sector scan images while accurately restoring the geometric morphology of internal defects in lead seals. This has become a core technical challenge restricting the improvement of the accuracy of cable lead seal inspection. There is an urgent need to develop an adaptive denoising method that balances noise suppression, edge fidelity, and computational efficiency. Summary of the Invention

[0005] The main objective of this invention is to provide a method and system for denoising ultrasonic sector scan images of cable lead seals, which solves the problems of low recognition accuracy, missing edge features, and low detection precision and efficiency.

[0006] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is: a method for denoising ultrasonic sector scan images of cable lead seals, comprising the following steps: S1: Obtain the original ultrasonic sector scan image of the cable lead seal defect, transform it into a two-dimensional rectangular coordinate pixel matrix through coordinate transformation, and construct a jump regression model based on the superposition of observation intensity and random noise. S2: Perform edge pixel detection: Estimate the local intensity gradient in the preset neighborhood of each pixel by least squares plane fitting, and identify and extract the set of edge pixels of the lead seal defect based on the significance of the gradient change; S3: Calculate the distance from the pixel to be processed to the nearest edge point in the set of edge pixels, and set the threshold parameter for classification processing; S4: Perform adaptive smoothing processing: If the distance is greater than the threshold parameter, construct an adaptive elliptical neighborhood that does not cross the edge based on the reflection information of the nearest edge point on the pixel to be processed, and calculate the denoised pixel intensity within the neighborhood using the kernel regression algorithm. S5: Perform multi-resolution local clustering processing: If the distance is less than or equal to the threshold parameter, then perform dynamic clustering based on pixel intensity in the neighborhood of the pixel to be processed, divide the neighborhood into different connected regions, and only use the sampling points belonging to the same pixel cluster as the pixel to be processed for weighted average denoising.

[0007] In the preferred embodiment, the method further includes the following after step S5: Step S6: Image reconstruction, remapping the processed Cartesian coordinate pixel array back to the fan-shaped scanning space, and performing global grayscale nonlinear stretching to enhance the contrast between the lead seal crack and the metal substrate. The image reconstruction process employs a multi-core parallel computing approach, with kernel regression processing in the smooth region and clustering processing in the structural region executed independently for each pixel. The noise suppression level is assessed by calculating the signal-to-noise ratio (SNR) and root mean square error (RMSE), and the fidelity of defect edges is measured by the structural similarity index (SSIM).

[0008] In the preferred embodiment, the edge detection process in step S2 includes: Calculate the gradient vector of each pixel in the horizontal and vertical directions, and select reference points in adjacent regions that do not overlap along the gradient direction for difference comparison. When the difference value exceeds the preset significance level, mark the current pixel as a defect edge pixel.

[0009] In the preferred embodiment, the specific process of constructing the adaptive elliptical neighborhood in step S4 includes: Using the pixel to be processed as a reference, locate its nearest edge point; Calculate the center-symmetric reflection point of the nearest edge point relative to the pixel to be processed; Define a strip-shaped search area in the direction perpendicular to the line connecting the nearest edge point and the reflection point; Within the strip-shaped search area, find the second edge point that is closest to the pixel to be processed; The distance reduction values ​​from the pixel to be processed to the second edge point and the first edge point are used as the major axis radius and minor axis radius of the ellipse, respectively, to generate a dynamically evolving denoised neighborhood.

[0010] In the preferred embodiment, the axis length adjustment mechanism of the elliptical neighborhood ensures that there are no intersections between the interior region of the ellipse and the edge pixel set, thereby guaranteeing that the image intensity function within the coverage area of ​​the ellipse has first-order continuous differentiability.

[0011] In the preferred embodiment, the kernel regression algorithm in step S4 estimates the optimal predicted value of the pixel to be processed by performing a Taylor series expansion on the local intensity function and combining it with the weighted least squares method with the center of the ellipse as the weight core.

[0012] In the preferred embodiment, the dynamic clustering process in step S5 adopts a statistical discrimination criterion, and iteratively finds the optimal gray-level segmentation threshold so that the ratio of the inter-group variance to the intra-group variance between the segmented defect pixel clusters and the background pixel clusters is maximized.

[0013] In the preferred embodiment, the weighted average denoising process in step S5 uses a similarity weighting factor. The similarity weighting factor is calculated by exponentially attenuating based on the sum of squared Euclidean distances between the neighborhood of the pixel to be processed and the neighborhood of the surrounding sampling points, so as to achieve edge protection of the defective microstructure.

[0014] In a preferred embodiment, considering the radial divergence characteristics of ultrasonic imaging, the window size for edge detection and clustering increases linearly with the increase of ultrasonic detection depth to compensate for noise interference caused by the reduction in far-field resolution.

[0015] Secondly, the present invention provides a cable lead seal ultrasonic sector scan image denoising system, applicable to the aforementioned cable lead seal ultrasonic sector scan image denoising method, comprising: The data acquisition and processing module is used to acquire the original ultrasonic sector scan image of the cable lead seal defect, transform it into a two-dimensional rectangular coordinate pixel matrix through coordinate transformation, and construct a jump regression model based on the superposition of observation intensity and random noise. The edge pixel detection module is used to perform edge pixel detection: estimate the local intensity gradient in the preset neighborhood of each pixel by least squares plane fitting, and identify and extract the set of edge pixels of the lead seal defect based on the significance of the gradient change. The edge pixel calculation module is used to calculate the distance from the pixel to be processed to the nearest edge point in the edge pixel set, and to set the threshold parameter for classification processing; The smoothing module is used to perform adaptive smoothing: if the distance is greater than the threshold parameter, an adaptive elliptical neighborhood that does not cross the edge is constructed based on the reflection information of the nearest edge point on the pixel to be processed, and the pixel intensity after denoising is calculated in the neighborhood using the kernel regression algorithm. The clustering processing module is used to perform multi-resolution local clustering processing: if the distance is less than or equal to the threshold parameter, dynamic clustering based on pixel intensity is implemented in the neighborhood of the pixel to be processed, dividing the neighborhood into different connected regions, and using only the sampling points belonging to the same pixel cluster as the pixel to be processed for weighted average denoising.

[0016] This invention provides a method and system for denoising ultrasonic sector scan images of cable seals. By acquiring ultrasonic sector scan images and performing coordinate transformation, a jump regression model based on the superposition of observed intensity and random noise is constructed. Then, the edge pixel set of the seal defect is extracted, generating a binarized edge pixel mask matrix. The Euclidean distance between the nearest edge points of each edge pixel is calculated. After pixel partitioning, adaptive smoothing processing of the partitions is performed, followed by multi-resolution local clustering processing and image reconstruction. This achieves precise partitioning of the ultrasonic sector scan image. Smooth regions far from the edges suppress speckle noise through adaptive elliptical neighborhood kernel regression, while structural regions near the edges achieve precise separation of defect pixels from background pixels through local clustering. This reduces global noise and improves the accuracy of extracting boundary features of fine cracks and layered defects inside the seal, thereby enhancing the accuracy and efficiency of cable seal defect identification. Attached Figure Description

[0017] The present invention will be further described below with reference to the accompanying drawings and embodiments: Figure 1 This is a schematic diagram of the method flow of the present invention; Figure 2 This is a schematic diagram of the adaptive elliptical neighborhood geometry construction of the present invention. Detailed Implementation

[0018] Example 1 like Figure 1-2 As shown, a method for denoising ultrasonic sector scan images of cable lead seals includes the following steps: S1: Obtain the original ultrasonic sector scan image of the cable lead seal defect, convert the ultrasonic sector scan data in polar coordinate system into a two-dimensional rectangular coordinate pixel matrix, and construct a jump regression model based on the superposition of observation intensity and random noise.

[0019] S2: Perform least-squares plane fitting on the preset neighborhood of each pixel to estimate the local intensity gradient, identify and extract the edge pixel set of the lead seal defect by the significance test of gradient change, and generate a binarized edge pixel mask matrix.

[0020] S3: Calculate the Euclidean distance from the pixel to be processed to the nearest edge point in the edge pixel set, set a distance threshold parameter, and divide the image pixels into a smooth region pixel set far from the edge and a structural region pixel set close to the edge based on the comparison result of the distance and the threshold parameter.

[0021] S4: Perform adaptive smoothing processing on pixels in the smooth area: locate the nearest edge point based on the pixel to be processed, determine the next nearest edge point through geometric transformation and strip region search, construct an adaptive elliptical neighborhood that does not cross the acoustic interface, and calculate the denoised pixel intensity within the elliptical neighborhood using the kernel regression algorithm.

[0022] S5: Perform multi-resolution local clustering processing on pixels in the structural region: Implement dynamic clustering based on pixel intensity in the neighborhood of the pixel to be processed, solve the optimal gray level division threshold by maximizing the variance ratio between groups and within groups, divide the neighborhood into defect pixel clusters and background pixel clusters, and use only the sampling points belonging to the same pixel cluster as the pixel to be processed to perform weighted average denoising through similarity weight factor.

[0023] S6: Integrates the denoised pixel data of the smooth area and the structure area, maps it back to the original size of the rectangular coordinate matrix according to the coordinate index to complete the image reconstruction, and performs global grayscale nonlinear stretching on the reconstructed image to enhance the contrast between the lead seal crack and the metal substrate.

[0024] In this embodiment, by acquiring ultrasonic sector scan images and performing coordinate transformation, a jump regression model based on the superposition of observed intensity and random noise is constructed. Then, the edge pixel set of the lead seal defect is extracted, a binary edge pixel mask matrix is ​​generated, and the Euclidean distance between the nearest edge points of the edge pixels is calculated. After pixel division, adaptive smoothing processing of the partition is performed, followed by multi-resolution local clustering processing, and then image reconstruction is performed. This achieves accurate partitioning processing of ultrasonic sector scan images. Smooth regions far from the edge suppress speckle noise through adaptive elliptical neighborhood kernel regression, while structural regions close to the edge achieve accurate separation of defect pixels from background pixels through local clustering. This reduces global noise and improves the accuracy of extracting boundary features of fine cracks and layered defects inside the lead seal, thereby improving the accuracy and efficiency of cable lead seal defect identification.

[0025] In existing technologies, ultrasonic non-destructive testing of cable lead seals commonly uses a two-dimensional phased array probe to emit ultrasonic waves and receive the echoes, obtaining an ultrasonic sector scan image of the target area through beamforming algorithms. However, due to the grain scattering characteristics of lead itself, ultrasonic waves generate severe coherent interference during propagation, manifesting as high-intensity multiplicative or additive speckle noise in the image. Traditional denoising algorithms (such as isotropic diffusion and median filtering) inevitably blur the micro-cracks, pores, and debonding interfaces inside the lead seal when smoothing out this noise.

[0026] like Figure 1 As shown, to address the above technical issues, this embodiment first utilizes edge detection with local weighted least squares estimation and significance testing operators to accurately identify and locate the jump location curve (JLC) caused by abrupt changes in acoustic impedance across the entire domain. Subsequently, a routing allocation mechanism based on Euclidean distance transformation is introduced. A processing splitter is dynamically constructed according to the geometric distance function d from each pixel to the nearest edge point, adaptively dividing the image space into a continuous smooth region and a nearest neighbor structure region. This achieves deep coupling between processing intensity and local feature complexity at the algorithm level.

[0027] For the heterogeneous regions after the splitting, an asymmetric processing strategy was adopted: 1) In the continuous region far from the edge, by constructing an asymmetric elliptical neighborhood whose principal axis direction is adaptively twisted with the defect direction, a higher-order kernel regression operator is used to maximize the suppression of background noise without crossing the acoustic fault.

[0028] 2) In structural regions containing fine morphology, a multi-resolution local clustering mechanism is introduced to achieve statistical separation of defect feature clusters and matrix clusters by maximizing the inter-class variance ratio, and only pixel components belonging to similar clusters are extracted for weighted repair.

[0029] This embodiment completely decouples the technical contradiction between noise cancellation and edge fidelity at the physical level, improving the detection sensitivity and characterization accuracy of minute defects in complex media such as high-voltage cable lead seals.

[0030] Step S1: Acquisition, preprocessing, and skip regression modeling of ultrasound signals S101: Input Signal Acquisition: The initial input signal is the original analog ultrasonic radio frequency echo signal. In actual engineering, a two-dimensional phased array ultrasonic probe is attached to the outer surface of the high-voltage cable lead seal, emitting ultrasonic beams according to a set delay rule, and receiving acoustic echo signals reflected from the internal grains, micropores, cracks, and the physical interface between the lead seal and the cable insulation layer. These analog signals are sampled by an analog-to-digital converter to form a time-amplitude one-dimensional A-scan signal, which is then combined to form the original digital matrix of the ultrasonic sector scan in polar coordinates.

[0031] S102: Data preprocessing: First, the ultrasonic sector scan data in polar coordinates is converted into a digital grayscale image matrix in two-dimensional rectangular coordinates using a bilinear interpolation algorithm.

[0032] A jump regression analysis framework is used to describe this digital image matrix. Assuming the observed image pixels are distributed on an equally spaced design grid, the design point set is defined as: ; The following jump regression model is established for the received ultrasound digital signal (i.e., image grayscale value) at each grid node: ; The specific meanings and physical correspondences of the variables are as follows: The intensity of the observed signal is the grayscale value of the ultrasound image pixels, which includes speckle noise. Let be the function representing the true ultrasonic reflection intensity that the system attempts to recover. Within a lead-sealed, homogeneous metallic matrix, the acoustic impedance is uniform, and this function... It is continuous and smooth; however, when encountering defect boundaries such as cracks and pinholes, due to the sharp mismatch in acoustic impedance (such as at a lead-air interface), the function... A step change can occur. This invention mathematically defines these physical boundaries that produce abrupt changes as jump position curves.

[0033] This refers to the inherent speckle noise in ultrasound imaging. This model assumes that in logarithmic space, it approximately follows a mean of 0 and a variance of... .

[0034] S103: Output signal: A two-dimensional discrete ultrasound image matrix and its corresponding coordinate index system for constructing a jump regression mathematical model. This matrix not only contains the original grayscale information, but is also theoretically decomposed into continuous real signal components, jump defect boundary components, and high-frequency random noise components.

[0035] This embodiment, through the above steps, rigorously transforms the complex ultrasonic acoustic physics problem into a purely mathematical problem of solving a two-dimensional surface fitting and noise separation with discontinuous boundaries within a bounded closed region [0,1]×[0,1].

[0036] Step S2: Local gradient estimation and explicit detection of defect edge pixels.

[0037] In the preferred embodiment, the edge detection process in step S2 includes: Calculate the gradient vector of each pixel in the horizontal and vertical directions, and select reference points in adjacent regions that do not overlap along the gradient direction for difference comparison. When the difference value exceeds the preset significance level, the pixel is marked as a defect edge pixel.

[0038] S201: Obtain the two-dimensional discrete ultrasound image matrix with strong speckle noise output from step S1. .

[0039] S202: Processing and Derivation: In order to remove noise without destroying the crack morphology, the specific location of the crack (i.e., the edge) must first be known.

[0040] If traditional Sobel or Canny operators are used directly, a large number of pseudo-edges will be generated under strong coherent noise. This embodiment adopts a local least squares plane fitting technique based on a jump regression framework, specifically: For any pixel to be examined in the image Select a square local neighborhood window with a side length of (2k+1). : ; Within this local window, the spatial distribution of ultrasonic intensity is approximated as a tilted two-dimensional plane, as shown in the following model: .

[0041] Solve for the coefficient matrix using the ordinary least squares method.

[0042] The obtained coefficients and These represent the optimal ultrasonic intensity gradient estimates for this pixel in the horizontal and vertical directions, respectively. Let the intensity gradient vector for this point be: Then, determine the salience of the edge.

[0043] The algorithm follows the gradient Two distances are selected in the direction (i.e., the direction of the most drastic change in acoustic impedance). The most recent and its neighborhood is not in the current window The reference pixels that exhibit geometric overlap are denoted as B1 and B2, respectively.

[0044] Define edge detection discriminant statistics The minimum difference between the current point's gradient and the adjacent background gradient: .

[0045] According to the above formula, if: Even if it's just a pseudo-mutation point caused by ultrasonic noise, the gradient fluctuation in its surrounding area will be significant. The value will tend to be extremely small; the central gradient will produce a significant discontinuity with the gradients of the pure metallic background on both sides if and only if the point is located at the edge of a true lead seal crack or pore. The maxima system sets a threshold based on a preset statistical confidence interval, and the judgment condition is as follows: ; in The quantiles of the chi-square distribution. If the variance of the local X-coordinate samples is used, then the pixel is determined to be a true defect edge point.

[0046] S203: The output signal is a binary edge mask matrix, or a set of jump position curves. In this matrix, pixels belonging to the defect contour are marked as 1 (valid edge), while pure metal backgrounds and pure noise areas are marked as 0.

[0047] Through the above steps, the true geometric contours of fatigue cracks and pinholes hidden inside the lead seal were accurately extracted from the chaotic speckle noise.

[0048] Step S3: Geometric distance assessment and processing strategy.

[0049] S301: The input signal includes two parts: one is the original two-dimensional ultrasound image matrix. Second, the binarized edge pixel mask matrix output in step two. .

[0050] S302: Processing steps and logical judgments: For each pixel in the image to be denoised... The algorithm first applies to the edge mask matrix. The algorithm uses a fast nearest neighbor search to calculate the Euclidean distance from the nearest valid edge pixel P1. .

[0051] Subsequently, the system introduces a crucial adjustment threshold parameter. (Typically, a value of 2-5 pixels is usually chosen, depending on the probe frequency and imaging resolution.) The system will perform strict routing checks: ① Branch decision A (smooth region far from the edge) If: This indicates that the current pixel P is located inside a well-sealed pure metal substrate, with sufficient safety buffer distance from any defect boundaries that could cause signal abrupt changes. At this point, the control flow imports the pixel and its neighborhood data into step four (adaptive geometric neighborhood kernel regression processing).

[0052] ② Branch judgment B (structural region near the edge): If: This indicates that the current pixel P is extremely close to the defect boundary (e.g., located directly at the crack tip or inside the pore). Due to the extremely close proximity, any linear smoothing across the space will inevitably mix the bright metal signal with the dark defect signal, causing the crack features to be completely erased. At this point, the control flow guides this pixel into step five (multi-resolution local clustering processing).

[0053] S303: The output signal is a sequence of split pixel coordinate indices. All pixels in the image are strictly divided into two mutually exclusive sets: the smooth region pixel set and the structure region pixel set.

[0054] Through the above steps, a region-adaptive processing mechanism is introduced, enabling the denoising system to dynamically adjust based on local image features. This method applies significant filtering intensity to smooth regions far from edges, reducing noise in a uniform background; simultaneously, in textured and edge regions, a highly conservative strategy is adopted to improve the integrity of key structural details such as cracks; and it avoids performing highly complex clustering calculations in smooth regions that occupy the main body of the image, thereby significantly reducing the overall computational complexity of the algorithm and improving its operating efficiency.

[0055] Step S4: Smooth region adaptive dynamic ellipse construction and kernel regression.

[0056] In the preferred embodiment, the specific process of constructing the adaptive elliptical neighborhood in step S4 includes: S401: Using the pixel to be processed as a reference, locate its nearest edge point; where the input signal is the coordinate index of the smooth region pixel set, the original image grayscale matrix, and the edge pixel set. .

[0057] For any pixel P imported into this module, a highly flexible adaptive ellipse construction mechanism is used to construct a dynamic geometric neighborhood E that is large enough to smooth out noise, but absolutely does not contain any defective edge pixels.

[0058] S402: ① Locate the symmetrical anchor point: Calculate the center symmetrical reflection point of the nearest edge point relative to the pixel to be processed, i.e.: Given that point P is closest to its edge point P1. With point P as the geometric center of symmetry, find the reflection center point M of P1 in space (i.e., P is the midpoint of line segment P1M).

[0059] ② Directional Strip Search: Within the strip search area, find the second edge point closest to the pixel to be processed. That is, define a strip search area perpendicular to the line connecting the nearest edge point and the reflection point. On the two-dimensional plane, construct a virtual straight line perpendicular to line segment P1M, and extend it to both sides along this vertical direction to form a strip of finite width. The system searches again for the edge pixel closest to point P within this strip area and marks it as the second nearest edge point P2.

[0060] ③ Construct a smooth ellipse E with P as the geometric center, the direction of line segment PP2 as the principal axis of the ellipse, and the direction of line segment PP1 as the secondary axis. To reserve an absolutely safe anti-blur buffer, the system forcibly reduces the half-length of the principal axis of the ellipse to: The secondary axis half length is reduced to Figure 2 This is a schematic diagram of the adaptive elliptical neighborhood geometry construction, as shown below. Figure 2As shown, this demonstrates the core characteristics of the elliptical neighborhood, which is centered at P, dynamically generated based on the geometric constraints of the edge points, and does not cross the acoustic interface.

[0061] S403: Using the distance reduction values ​​from the pixel to be processed to the second edge point and the first edge point as the major axis radius and minor axis radius of the ellipse respectively, a dynamically evolving denoised neighborhood is generated.

[0062] In the preferred embodiment, the axis length adjustment mechanism of the elliptical neighborhood ensures that there are no intersections between the interior region of the ellipse and the edge pixel set, thereby guaranteeing that the image intensity function within the coverage area of ​​the ellipse has first-order continuous differentiability.

[0063] Under this construction, based on the rigorous triangle inequality theorem, it can be mathematically proven that the interior of the ellipse E and its outward extension are both possible. Within this distance range, there are absolutely no edge points (i.e., no JLC exists). Therefore, it can be concluded that the ellipse E is completely enclosed within the continuous acoustic medium of elemental lead metal, and the true intensity function f(x,y) is highly continuously differentiable in this region.

[0064] S404: After confirming the continuous region, perform kernel regression smoothing.

[0065] In the preferred scheme, the kernel regression algorithm estimates the optimal predicted value of the pixel to be processed by performing a Taylor series expansion on the local intensity function and combining it with the weighted least squares method with the center of the ellipse as the weight core.

[0066] Assume the coordinates of any sampling point inside the ellipse are The coordinates of the target center point are The real signal is approximated by a second-order expansion using a multivariate Taylor series: ; Convert to coefficient form: ; Among them, the constant term to be solved This is exactly the true pixel intensity we expect to obtain after filtering out noise.

[0067] For the first-order gradient, It contains information about the second-order partial derivatives of the Hessian matrix. vech is the vectorization operator for lower triangular matrices.

[0068] These parameters are estimated by solving the following weighted least squares cost function with a spatial weight kernel: ; In the formula, Np is the total number of pixels contained within the dynamic ellipse E, the scope of the kernel function K() is strictly limited to the interior of the ellipse (exterior weights are 0), and h is the smoothing bandwidth. The optimal estimate h obtained is the denoised output at that point. .

[0069] S405: The output signal is a high-precision grayscale value sequence of all pixels in the smooth area after ultrasonic speckle noise has been filtered out.

[0070] Through the above steps, an adaptive, edge-aware anisotropic smoothing mechanism is achieved. When performing iterative denoising within the lead-sealed substrate, the algorithm dynamically identifies and responds to the presence of crack edges: when the filtering window detects edge features, its diffusion behavior is suppressed in the direction perpendicular to the edge, and instead continues to extend in the direction parallel to the edge. This ensures that even under strong smoothing conditions, the low-contrast signals corresponding to defects such as cracks are not weakened or contaminated by filtering operations in neighboring areas, thus achieving accurate edge preservation and detail protection.

[0071] Step S5: Multi-resolution local clustering and weighted repair of structural regions S501: Obtain the coordinate index of the pixel set in the structural region (points near the edge of the defect) and the grayscale matrix of the original image.

[0072] S502: Clustering and Weighted Repair: When pixel Distance from the edge is less than (For example, if a pixel happens to be located on a tiny lead seal crack), any continuous smoothness of geometry will mix the signals from the crack and the substrate. This invention introduces a multi-resolution local pixel clustering framework.

[0073] In the preferred embodiment, the dynamic clustering process in step S5 adopts a statistical discrimination criterion, and iteratively finds the optimal gray-level segmentation threshold so that the ratio of the inter-group variance to the intra-group variance between the segmented defect pixel clusters and the background pixel clusters is maximized.

[0074] With point Centered on a boundary, define a boundary with a side length of... h n Local square neighborhood O ( x , y , h n This neighborhood contains both low-grayscale pixels representing cracks and high-grayscale pixels representing metal. The core idea of ​​the algorithm is to forcibly split this neighborhood into two completely independent clusters of physical components based on grayscale values. The system iterates through and sets a dynamic grayscale threshold s. The grayscale values ​​are then... Pixels ≤ s are assigned to clusters. O 1( x , y , h n , s (Speculated to be a cluster of defect features) Pixels greater than s are assigned to clusters. O 2( x , y , h n , s (Presumably a metal matrix cluster).

[0075] To find an appropriate cutoff point, the system defines a statistical indicator—the ratio of variance between and within groups. :

[0076] Where |O1| and |O2| represent the total number of pixels within the cluster. and This represents the corresponding cluster average intensity. The global average intensity is the intensity of the entire neighborhood.

[0077] The system uses optimization calculations to find the optimal threshold s that maximizes the variance variation ratio T. At this threshold, crack signals and matrix signals are separated most purely.

[0078] After clustering is completed, it is determined which cluster the central pixel P(x,y) to be processed belongs to (assuming it is located within the defect and belongs to O1). Subsequently, the system strictly excludes all pixels from the other cluster (O2) and only uses pixels within the same cluster O1 to perform weighted average repair on P.

[0079] In the preferred embodiment, the weighted average denoising process in step S5 uses a similarity weighting factor. The similarity weighting factor is calculated by exponentially attenuating based on the sum of squared Euclidean distances between the neighborhood of the pixel to be processed and the neighborhood of the surrounding sampling points, so as to achieve edge protection of the defective microstructure.

[0080] To protect the micro-texture inside the crack, robust weights based on high-dimensional spatial feature similarity are calculated. : ; In the formula, This represents the sum of squares of the difference in intensity between two local image patches centered on the target pixel and the sampled pixel, respectively. The noise variance of the global prediction Let Bn be the image patch volume, and Bn be the smoothing tuning parameter that controls the decay rate.

[0081] Finally, the pixels within the cluster are fused and summed based on this exponential similarity weight to generate the optimal denoising intensity value for the pixels in the structural region.

[0082] S503: The output signal is the grayscale value sequence of all pixels in the structure area after high-precision restoration.

[0083] In a preferred embodiment, considering the radial divergence characteristics of ultrasonic imaging, the window size for edge detection and clustering increases linearly with the increase of ultrasonic detection depth to compensate for noise interference caused by the reduction in far-field resolution.

[0084] Through the above steps, this embodiment abandons the traditional isotropic smoothing strategy and instead adopts an adaptive filtering mechanism based on statistical learning. Specifically, it achieves strict structure awareness in the crack edge region through local pixel clustering: neighborhood pixels are intelligently divided into two independent clusters, "defect" and "matrix," based on grayscale features, thus avoiding mutual contamination between the two types of signals during the filtering process. Subsequently, adaptive weights are calculated based on the structural similarity between pixel blocks, and weighted fusion is performed on pixels within each cluster. This process is mathematically equivalent to a local estimator that preserves the edges. It not only effectively suppresses noise but also sharpens and enhances the geometric edges of the crack after denoising by strengthening the contribution of pixels of the same type and eliminating the interference of pixels of different types. This solves the technical problem of denoising becoming blurry in traditional ultrasonic image processing.

[0085] Step 6 (S6): Overall image reconstruction and computational performance evaluation.

[0086] S601: Obtain the denoised pixel sequence output from step 4 (smoothing region) and the denoised pixel sequence output from step 5 (structure region).

[0087] S602: Reconstruction and computational performance evaluation.

[0088] In the preferred scheme, the image reconstruction process adopts a multi-core parallel computing method, and the kernel regression processing in the smooth region and the clustering processing in the structural region are performed independently for each pixel; The noise suppression level is assessed by calculating the signal-to-noise ratio (SNR) and root mean square error (RMSE), and the fidelity of defect edges is measured by the structural similarity index (SSIM).

[0089] In this embodiment, based on the coordinate index retained in step three, the two processed data streams are merged and mapped, filling the original-sized Cartesian coordinate two-dimensional empty matrix, thus completing the seamless stitching and reconstruction of the entire image. Regarding the algorithm execution mechanism, since the processing of each pixel in steps four and five is completely independent and does not interfere with each other, this invention fully utilizes this inherent characteristic in system implementation, allocating the computational tasks to multi-core GPUs for ultra-large-scale parallel computing.

[0090] Assuming the edge detection algorithm takes 1 pixel to complete, Kernel regression takes time to The clustering method takes time of For an ultrasound image with a resolution of n×n, the total time consumed by this invention is... Satisfy the equation: ; Where P(x,y) is the function to determine whether the nearest edge is greater than 0. The probability signature function. Since the smooth, defect-free substrate occupies the vast majority of the area in the lead seal inspection image (i.e., the probability of P(x,y) being 1 is extremely high), the extremely time-consuming clustering algorithm... The call is triggered only at the very small crack edges. Therefore, the overall computation time of this ensemble method is... It is far less efficient than using global clustering methods and can easily meet the real-time mapping requirements of mobile ultrasonic testing equipment for high-voltage cables.

[0091] S603: Outputs a reconstructed ultrasonic 2D sector scan denoised image with an extremely high signal-to-noise ratio and extremely sharp crack edges. The image can be directly imported into the subsequent 3D total focusing (TFM) reconstruction module or AI defect classification and diagnosis network.

[0092] This embodiment constructs a complete processing framework, covering key steps from physical modeling, edge-aware detection, adaptive path planning to dynamic smoothing and classification clustering. This suppresses speckle noise in the original ultrasonic sector scan images, significantly improving the image signal-to-noise ratio. It not only drastically reduces the root mean square error (RMSE) of noise in the background region but also achieves high-fidelity reconstruction of the internal microstructure of cable seals at the sub-pixel scale, including the morphological features of key defects such as micropore edges and fatigue crack tips. This enables inspection personnel and even automated vision systems to clearly and stably identify the geometric parameters and spatial distribution of defects, thereby significantly improving the reliability and repeatability of cable seal quality inspection in terms of quantitative assessment and objective diagnosis.

[0093] Example 2 Further illustrating with reference to Embodiment 1, a cable lead seal ultrasonic sector scan image denoising system, applicable to the method of Embodiment 1, includes: The data acquisition and processing module is used to acquire the original ultrasonic sector scan image of the cable lead seal defect, transform it into a two-dimensional rectangular coordinate pixel matrix through coordinate transformation, and construct a jump regression model based on the superposition of observation intensity and random noise. The edge pixel detection module is used to perform edge pixel detection: estimate the local intensity gradient in the preset neighborhood of each pixel by least squares plane fitting, and identify and extract the set of edge pixels of the lead seal defect based on the significance of the gradient change. The edge pixel calculation module is used to calculate the distance from the pixel to be processed to the nearest edge point in the edge pixel set, and to set the threshold parameter for classification processing; The smoothing module is used to perform adaptive smoothing: if the distance is greater than the threshold parameter, an adaptive elliptical neighborhood that does not cross the edge is constructed based on the reflection information of the nearest edge point on the pixel to be processed, and the pixel intensity after denoising is calculated in the neighborhood using the kernel regression algorithm. The clustering processing module is used to perform multi-resolution local clustering processing: if the distance is less than or equal to the threshold parameter, dynamic clustering based on pixel intensity is implemented in the neighborhood of the pixel to be processed, dividing the neighborhood into different connected regions, and using only the sampling points belonging to the same pixel cluster as the pixel to be processed for weighted average denoising.

[0094] This embodiment provides a method and system for denoising ultrasonic sector scan images of cable lead seals, including its working process, details, and technical effects, which can be found in Embodiment 1 and will not be repeated here.

[0095] The above embodiments are merely preferred technical solutions of the present invention and should not be considered as limitations on the present invention. The scope of protection of the present invention should be limited to the technical solutions described in the claims, including equivalent substitutions of the technical features described in the claims. That is, equivalent substitutions and improvements within this scope are also within the scope of protection of the present invention.

Claims

1. A method for denoising ultrasonic sector scan images of cable lead seals, characterized in that, Includes the following steps: S1: Obtain the original ultrasonic sector scan image of the cable lead seal defect, transform it into a two-dimensional rectangular coordinate pixel matrix through coordinate transformation, and construct a jump regression model based on the superposition of observation intensity and random noise. S2: Perform edge pixel detection: Estimate the local intensity gradient in the preset neighborhood of each pixel by least squares plane fitting, and identify and extract the set of edge pixels of the lead seal defect based on the significance of the gradient change; S3: Calculate the distance from the pixel to be processed to the nearest edge point in the set of edge pixels, and set the threshold parameter for classification processing; S4: Perform adaptive smoothing processing: If the distance is greater than the threshold parameter, construct an adaptive elliptical neighborhood that does not cross the edge based on the reflection information of the nearest edge point on the pixel to be processed, and calculate the denoised pixel intensity within the neighborhood using the kernel regression algorithm. S5: Perform multi-resolution local clustering processing: If the distance is less than or equal to the threshold parameter, then perform dynamic clustering based on pixel intensity in the neighborhood of the pixel to be processed, divide the neighborhood into different connected regions, and only use the sampling points belonging to the same pixel cluster as the pixel to be processed for weighted average denoising.

2. The method for denoising ultrasonic sector scan images of cable lead seals according to claim 1, characterized in that, The process after step S5 also includes: Step S6: Image reconstruction, remapping the processed Cartesian coordinate pixel array back to the fan-shaped scanning space, and performing global grayscale nonlinear stretching to enhance the contrast between the lead seal crack and the metal substrate. The image reconstruction process employs a multi-core parallel computing approach, with kernel regression processing in the smooth region and clustering processing in the structural region executed independently for each pixel. The noise suppression level is assessed by calculating the signal-to-noise ratio (SNR) and root mean square error (RMSE), and the fidelity of defect edges is measured by the structural similarity index (SSIM).

3. The method for denoising ultrasonic sector scan images of cable lead seals according to claim 1, characterized in that, The edge detection process in step S2 includes: Calculate the gradient vector of each pixel in the horizontal and vertical directions, and select reference points in adjacent regions that do not overlap along the gradient direction for difference comparison. When the difference value exceeds the preset significance level, mark the current pixel as a defect edge pixel.

4. The method for denoising ultrasonic sector scan images of cable lead seals according to claim 1, characterized in that, The specific process of constructing the adaptive elliptical neighborhood in step S4 includes: Using the pixel to be processed as a reference, locate its nearest edge point; Calculate the center-symmetric reflection point of the nearest edge point relative to the pixel to be processed; Define a strip-shaped search area in the direction perpendicular to the line connecting the nearest edge point and the reflection point; Within the strip-shaped search area, find the second edge point that is closest to the pixel to be processed; The distance reduction values ​​from the pixel to be processed to the second edge point and the first edge point are used as the major axis radius and minor axis radius of the ellipse, respectively, to generate a dynamically evolving denoised neighborhood.

5. The method for denoising ultrasonic sector scan images of cable lead seals according to claim 4, characterized in that, The elliptical neighborhood axis length adjustment mechanism ensures that there are no intersections between the interior region of the ellipse and the edge pixel set, thereby guaranteeing that the image intensity function within the ellipse coverage area has first-order continuous differentiability.

6. The method for denoising ultrasonic sector scan images of cable lead seals according to claim 1, characterized in that, The kernel regression algorithm in step S4 estimates the optimal predicted value of the pixel to be processed by performing a Taylor series expansion on the local intensity function and combining it with the weighted least squares method with the center of the ellipse as the weight core.

7. The method for denoising ultrasonic sector scan images of cable lead seals according to claim 1, characterized in that, The dynamic clustering process in step S5 adopts a statistical discrimination criterion and iteratively finds the optimal gray-level segmentation threshold so that the ratio of the inter-group variance to the intra-group variance between the defect pixel clusters and the background pixel clusters is maximized.

8. The method for denoising ultrasonic sector scan images of cable lead seals according to claim 1, characterized in that, The weighted average denoising process in step S5 uses a similarity weight factor, which is calculated by exponentially decaying based on the sum of squared Euclidean distances between the neighborhood of the pixel to be processed and the neighborhood of the surrounding sampling points, in order to achieve edge protection of the defective microstructure.

9. The method for denoising ultrasonic sector scan images of cable lead seals according to claim 1, characterized in that, To address the radial divergence characteristics of ultrasonic imaging, the window size for edge detection and clustering increases linearly with the ultrasonic detection depth to compensate for noise interference caused by reduced far-field resolution.

10. A cable lead seal ultrasonic sector scan image denoising system, applicable to the method described in any one of claims 1-9, characterized in that, include: The data acquisition and processing module is used to acquire the original ultrasonic sector scan image of the cable lead seal defect, transform it into a two-dimensional rectangular coordinate pixel matrix through coordinate transformation, and construct a jump regression model based on the superposition of observation intensity and random noise. The edge pixel detection module is used to perform edge pixel detection: estimate the local intensity gradient in the preset neighborhood of each pixel by least squares plane fitting, and identify and extract the set of edge pixels of the lead seal defect based on the significance of the gradient change. The edge pixel calculation module is used to calculate the distance from the pixel to be processed to the nearest edge point in the edge pixel set, and to set the threshold parameter for classification processing; The smoothing module is used to perform adaptive smoothing: if the distance is greater than the threshold parameter, an adaptive elliptical neighborhood that does not cross the edge is constructed based on the reflection information of the nearest edge point on the pixel to be processed, and the pixel intensity after denoising is calculated in the neighborhood using the kernel regression algorithm. The clustering processing module is used to perform multi-resolution local clustering processing: if the distance is less than or equal to the threshold parameter, dynamic clustering based on pixel intensity is implemented in the neighborhood of the pixel to be processed, dividing the neighborhood into different connected regions, and using only the sampling points belonging to the same pixel cluster as the pixel to be processed for weighted average denoising.