PRPD spectrum processing method and related equipment
Through edge detection, line segment analysis, grayscale transformation and frequency domain filtering technologies, the PRPD atlas is automatically processed, which solves the problem of inconsistent atlas formats generated by equipment from different manufacturers, achieves efficient background elimination and effective content extraction, reduces labor costs and improves analysis efficiency.
Patent Information
- Application Number
- CN202510439793.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-09
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2045-04-09
AI Technical Summary
Existing PRPD spectrum processing methods rely on manually setting color thresholds, resulting in inconsistent spectrum formats generated by equipment from different manufacturers, increasing the complexity and resource consumption of manual preprocessing, and traditional methods may lose discharge characteristics.
Through edge detection, line segment analysis, grayscale transformation, frequency domain filtering and pseudo-color mapping technologies, the PRPD atlas is automatically processed to eliminate background information and extract effective content, thus achieving unified standardization of the atlas.
Efficiently eliminate atlas background, reduce resource consumption, accurately locate effective content, reduce labor costs, improve atlas analysis efficiency, and provide a foundation for the construction of multi-vendor data sets.
Smart Images

Figure CN120318110B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a PRPD spectrum processing method and related equipment. Background Art
[0002] With the annual increase in the number of GIS (gas-insulated switchgear) in operation and the cumulative operating time of these devices, ensuring the safe operation of GIS equipment has become crucial. Partial discharge monitoring and PD type identification, as one of the important means to ensure the safety of GIS equipment, play a key role in this process. Ultra-high frequency signal monitoring, as an effective detection method, can obtain the statistical characteristic spectrum of the phase-discharge amplitude-discharge number of PD signals, namely the PRPD (Phase Resolved Partial Discharge) spectrum, and is widely used in the GIS discharge identification process. However, due to the differences in the technologies and standards used by PD monitoring equipment produced by different manufacturers, the accumulated PD defect PRPD spectrum format is not uniform, which poses a challenge to subsequent spectrum analysis.
[0003] Existing PRPD image processing methods typically rely on manually selecting or setting color thresholds for background and grid lines. This is then used to detect and extract background and gridline pixels from the image. This approach is not only time-consuming and labor-intensive, but also increases the complexity and resource consumption of manual image preprocessing due to differences in rendering colors, background settings, and grid lines between PD monitoring equipment from different manufacturers. Summary of the Invention
[0004] The technical problem to be solved by this application is to provide a PRPD spectrum processing method and related equipment that can effectively eliminate background information in the spectrum. The specific solution is as follows:
[0005] A PRPD spectrum processing method, the method comprising:
[0006] In response to a graph processing instruction, obtaining an original graph corresponding to the graph processing instruction;
[0007] Extracting content from the original graph to obtain graph content in the original graph;
[0008] Adjusting the size of the original atlas to obtain a standard-sized atlas;
[0009] Eliminating background information in the standard size atlas to obtain a target atlas;
[0010] The RGB data of each target pixel in the target atlas is converted into a grayscale value, and a pseudo-color image is generated according to the grayscale value obtained by the conversion using a preset pseudo-color mapping formula, wherein the target pixel is a pixel whose grayscale value is not less than a preset grayscale threshold.
[0011] In the above method, optionally, extracting content from the original graph to obtain the graph content in the original graph includes:
[0012] Performing edge detection on the original atlas to obtain a target area of the original atlas;
[0013] Detecting each line segment within the target area;
[0014] Determining a plurality of target line segments from each of the line segments, and determining a valid content area of the original atlas based on the plurality of target line segments, wherein the target line segments are line segments whose lengths meet a preset length condition and are closest to any boundary of the target area;
[0015] Content extraction is performed on the effective content area to obtain the atlas content of the original atlas.
[0016] Optionally, in the above method, eliminating background information in the standard size atlas to obtain a target atlas includes:
[0017] transforming the standard size spectrum from the two-dimensional spatial domain to the frequency domain;
[0018] The standard size spectrum transformed into the frequency domain is filtered using a preset grid filter, and the filtered standard size spectrum is transformed into a two-dimensional spatial domain to obtain an initial spectrum;
[0019] Eliminate the curves in the initial spectrum to obtain a target spectrum.
[0020] In the above method, optionally, transforming the standard size atlas from the two-dimensional spatial domain to the frequency domain comprises:
[0021] Performing grayscale analysis on the standard size map to obtain a grayscale distribution of the standard size map;
[0022] Determining background pixel positions of the standard size map according to the grayscale distribution of the standard size map;
[0023] Eliminating background pixels of the standard size atlas according to background pixel positions of the standard size atlas;
[0024] The standard size atlas after background pixels are eliminated is transformed from the two-dimensional spatial domain to the frequency domain.
[0025] In the above method, optionally, eliminating the curves in the initial map to obtain the target map includes:
[0026] Determining a curve position in the initial map according to the curve characteristics of the initial map;
[0027] The curves in the initial map are eliminated according to the positions of the curves in the initial map to obtain a target map.
[0028] A PRPD spectrum processing device, comprising:
[0029] an acquiring unit, configured to acquire, in response to a graph processing instruction, an original graph corresponding to the graph processing instruction;
[0030] An extraction unit, configured to extract content from the original graph to obtain graph content in the original graph;
[0031] An adjusting unit, configured to adjust the size of the atlas content of the original atlas to obtain an atlas of standard size;
[0032] A background elimination unit, configured to eliminate background information in the standard size atlas to obtain a target atlas;
[0033] The execution unit is used to convert the RGB data of each target pixel point in the target atlas into a grayscale value, and generate a pseudo-color image according to the grayscale value obtained by the conversion using a preset pseudo-color mapping formula, wherein the target pixel point is a pixel point that is not less than a preset grayscale threshold.
[0034] In the above device, optionally, the extraction unit includes:
[0035] An edge detection subunit, configured to perform edge detection on the original atlas to obtain a target area of the original atlas;
[0036] a line segment detection subunit, configured to detect each line segment within the target area;
[0037] a determination subunit, configured to determine a plurality of target line segments from each of the line segments, and determine a valid content area of the original atlas based on the plurality of target line segments, wherein the target line segments are line segments whose lengths meet a preset length condition and are closest to any boundary of the target area;
[0038] The extraction subunit is used to extract content from the effective content area to obtain the atlas content of the original atlas.
[0039] In the above device, optionally, the background elimination unit includes:
[0040] A transformation subunit, configured to transform the standard size atlas from a two-dimensional spatial domain to a frequency domain;
[0041] A filtering subunit is used to filter the standard size spectrum transformed into the frequency domain using a preset grid filter, and transform the filtered standard size spectrum into a two-dimensional spatial domain to obtain an initial spectrum;
[0042] The execution subunit is used to eliminate the curves in the initial map to obtain the target map.
[0043] A storage medium includes stored instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the PRPD spectrum processing method as described above.
[0044] An electronic device includes a memory and one or more instructions, wherein the one or more instructions are stored in the memory and configured to execute the PRPD pattern processing method described above by one or more processors.
[0045] Based on the above-mentioned implementation of the present application, a PRPD atlas processing method and related equipment are provided, the method comprising: in response to an atlas processing instruction, obtaining the original atlas corresponding to the atlas processing instruction; extracting content from the original atlas to obtain the atlas content in the original atlas; resizing the atlas content of the original atlas to obtain a standard size atlas; eliminating background information in the standard size atlas to obtain a target atlas; converting the RGB data of each target pixel in the target atlas into a grayscale value, and generating a pseudo-color map using a preset pseudo-color mapping formula based on the grayscale value obtained by the conversion, wherein the target pixel is a pixel not less than a preset grayscale threshold. Applying the method provided in the embodiment of the present application, background information in the atlas can be efficiently eliminated, reducing resource consumption. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are merely embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without any creative work.
[0047] Figure 1 A flow chart of a PRPD spectrum processing method provided in this application;
[0048] Figure 2 A flowchart of a process for obtaining the atlas content in the original atlas provided in this application;
[0049] Figure 3 A flowchart of a process for obtaining a target map provided in this application;
[0050] Figure 4 A flowchart of a PRPD two-dimensional atlas preprocessing process provided in this application;
[0051] Figure 5 This is an example of an original map provided in this application;
[0052] Figure 6 This is an example diagram of the graph features after effective content positioning provided by this application;
[0053] Figure 7 This is an example diagram of a spectrum converted to the frequency domain provided by this application;
[0054] Figure 8 This is an example diagram of a frequency domain spectrum after filtering by a grid filter provided in this application;
[0055] Figure 9 This is an example diagram of a target map provided in this application;
[0056] Figure 10 A schematic structural diagram of a PRPD spectrum processing device provided in this application;
[0057] Figure 11 This is a schematic diagram of the structure of an electronic device provided in this application. DETAILED DESCRIPTION
[0058] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0059] In this application, the terms "comprises," "comprising," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, article, or apparatus that includes a list of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not preclude the presence of additional identical elements in the process, method, article, or apparatus that includes the element.
[0060] Existing PRPD image processing methods typically rely on manually selecting or setting color thresholds for background and grid lines. This is then used to detect and extract background and gridline pixels from the image. This approach is not only time-consuming and labor-intensive, but also increases the complexity and resource consumption of manual image preprocessing due to differences in rendering colors, background settings, and grid lines between PD monitoring equipment from different manufacturers.
[0061] Furthermore, conventional universal preprocessing methods use image processing operations such as erosion and dilation to remove grid lines and coordinate ranges from the atlas. While this can, to a certain extent, eliminate background and extract the atlas' discharge features, these operations often lead to degradation of the original discharge features. In particular, features with low discharge frequency and dispersed phase-amplitude distributions may disappear completely. Therefore, existing methods struggle to simultaneously meet the requirements of universality and minimize the loss of discharge features when applied to raw PRPD measurement data from multiple manufacturers.
[0062] Based on this, the embodiment of the present application provides a PRPD spectrum processing method, which can be applied to electronic devices. The method flow chart of the method is as follows: Figure 1 As shown, specifically including:
[0063] S101: In response to a graph processing instruction, obtaining an original graph corresponding to the graph processing instruction.
[0064] In this embodiment, the original spectrum may be a statistical PRPD (Phase Resolved Patterns of Partial Discharge) characteristic spectrum of phase, discharge amplitude, and discharge number of partial discharge signals obtained by original ultra-high frequency signal monitoring.
[0065] Alternatively, the original PRPD two-dimensional map usually contains redundant information such as coordinate information and border information, and the background color and size are not uniform.
[0066] S102: extracting content from the original graph to obtain graph content in the original graph.
[0067] In this embodiment, the atlas content in the original atlas may be the content within the effective content border, and the effective content border is composed of target line segments in multiple directions.
[0068] In an embodiment provided by the present application, based on the above solution, optionally, the original graph is subjected to content extraction to obtain the graph content in the original graph, such as Figure 2 As shown, including:
[0069] S201: Perform edge detection on the original atlas to obtain a target area of the original atlas.
[0070] In this embodiment, the original atlas can be convolved and denoised using a Gaussian filter, and then the gradient value and gradient direction of each pixel in the original atlas after convolution and denoising can be calculated using the Sobel operator; the non-maximum suppression method is used to eliminate false edge information, and specifically, the gradient direction of each pixel can be approximated as up, down, left, right, and 45° directions, which are 0, 45, 90, 135, 180, 225, 270, and 315, respectively. Compare the gradient strength of the pixel point with the surrounding pixels in each gradient direction. If the gradient of the pixel point is the largest, it is retained, otherwise it is suppressed. Finally, the double threshold method is used to determine the potential edge. Specifically, the upper and lower thresholds can be set, and the pixels smaller than the lower threshold are discarded, and the pixels larger than the upper threshold are retained as strong boundaries. If the pixels between the upper and lower thresholds are connected to the strong boundary, they are retained, otherwise they are deleted, and the target area I of the original atlas is obtained. c .
[0071] S202: Detect each line segment within the target area.
[0072] In this embodiment, each line segment in the target area may be detected by a line segment detection method. For example, the line segments in the target area Ic may be detected based on Hough transform.
[0073] S203: Determine a plurality of target line segments from each of the line segments, and determine the effective content area of the original atlas based on the plurality of target line segments, wherein the target line segment is a line segment whose length meets a preset length condition and is closest to any boundary of the target area.
[0074] In this embodiment, the target line segment may be determined based on the coordinate information of the endpoints of each detected line segment.
[0075] Optionally, the length of the detected i-th line segment li and the coordinates of the endpoint of the line segment are defined as {di, (x 1i ,y 1i ), (x 2i ,y 2i )}, determine the type of the line segment, which can be either a horizontal line type or a vertical line type. If the length of the line segment is greater than the length threshold of the corresponding type, the line segment is determined to meet the length condition. The length threshold of the corresponding type of line segment can be set according to actual needs. For example, the length threshold for a horizontal line type can be 2 / 3 of the length of the target area, and the length threshold for a vertical line type can be 2 / 3 of the target length.
[0076] Optionally, the distance between the target line segment and the boundary of the target area may be the distance between the center point of the target line segment and the boundary.
[0077] S204: extracting content from the effective content area to obtain the graph content of the original graph.
[0078] In some embodiments, line segments in the PRPD two-dimensional map can be detected based on Hough transform, all line segments detected in the map are analyzed, and the length li of the i-th line segment detected and the coordinates of the endpoints of the line segment are defined as {di, (x 1i ,y 1i ), (x 2i ,y 2i )}, the horizontal line length is greater than 2 / 3 of the length of the two-dimensional atlas, the vertical line length is greater than 2 / 3 of the width of the two-dimensional atlas, and the four straight lines closest to the atlas boundary are used as target segments. The four target segments form the effective content border of the original atlas. The content within this border is defined as the effective content pixel (that is, the atlas content), that is, the horizontal coordinate of the pixel position coordinate satisfies x∈[x min ,x max ], the vertical coordinate satisfies y∈[y min ,y max ]. The content outside the border is useless redundant information.
[0079] S103: resizing the original atlas content to obtain a standard-sized atlas.
[0080] In this embodiment, the effective pixels of the atlas of indefinite size are standardized to a size of row*col.
[0081] S104: Eliminate background information in the standard size atlas to obtain a target atlas.
[0082] In this embodiment, at least one of the curve and the grayscale background pixels in the standard size map may be eliminated to obtain the target map.
[0083] In one embodiment provided in the present application, based on the above solution, optionally, the process of eliminating the background information in the standard size atlas to obtain the target atlas is as follows: Figure 3 As shown, including:
[0084] S301: transforming the standard size spectrum from the two-dimensional spatial domain to the frequency domain.
[0085] In an embodiment provided in the present application, based on the above solution, optionally, transforming the standard size spectrum from the two-dimensional spatial domain to the frequency domain includes:
[0086] Performing grayscale analysis on the standard size map to obtain a grayscale distribution of the standard size map;
[0087] Determining background pixel positions of the standard size map according to the grayscale distribution of the standard size map;
[0088] Eliminating background pixels of the standard size atlas according to background pixel positions of the standard size atlas;
[0089] The standard size atlas after background pixels are eliminated is transformed from the two-dimensional spatial domain to the frequency domain.
[0090] In this embodiment, the standard size spectrum can be recorded as I, and the grayscale histogram H of the standard size spectrum can be drawn. i , analyze the grayscale histogram H i Grayscale distribution characteristics, define H i The area with a large area and a small grayscale value span is the grayscale range corresponding to the background area of the atlas [G min , G max ], will satisfy the grayscale range [G min , G max ] is determined as the background pixel position, and the background pixels at the background pixel positions in the standard size atlas can be eliminated, and then transformed from the two-dimensional spatial domain to the frequency domain, so as to perform background elimination on the standard size atlas transformed into the frequency domain through a grid elimination filter.
[0091] S302: Filtering the standard size spectrum transformed into the frequency domain using a preset grid filter, and transforming the filtered standard size spectrum into a two-dimensional spatial domain to obtain an initial spectrum.
[0092] In this embodiment, the standard size atlas I can be transformed into the frequency domain feature F(u, v) of the image, and the corresponding components of the evenly distributed grid lines in the background of the atlas I in the frequency domain are analyzed. Based on the analysis results, a grid elimination filter H(u, v) is designed to eliminate the grid components in the frequency domain of the effective content, and then restore it from the frequency domain to the two-dimensional spatial domain. The spatial atlas after spectrum transformation and filtering is recorded as , which is the initial map.
[0093] S303: Eliminate the curves in the initial spectrum to obtain a target spectrum.
[0094] In an embodiment provided in the present application, based on the above solution, optionally, eliminating the curves in the initial map to obtain the target map includes:
[0095] Determining a curve position in the initial map according to the curve characteristics of the initial map;
[0096] The curves in the initial map are eliminated according to the positions of the curves in the initial map to obtain a target map.
[0097] Optionally, the size of the standard size atlas is row*col, the period of the sine curve in the effective content background is T=col, the amplitude is A=row / 2, and the angular velocity of the sine curve is w=2*π / T. Then the expression of the sine curve in the effective content of the standard size atlas is: B=A*sin(w*t), where the value range of t is [1:col]. Use the fitted sine curve to fit the initial atlas. Perform background removal. The spatial map after background removal is recorded as , that is, the target map.
[0098] S105: Convert the RGB data of each target pixel in the target map into a grayscale value, and generate a pseudo-color map using a preset pseudo-color mapping formula according to the converted grayscale value, wherein the target pixel is a pixel whose grayscale value is not less than a preset grayscale threshold.
[0099] In this embodiment, the PRPD map local discharge feature is located and the jet color mapping is realized I_unified: input After the grid elimination filter, the grayscale values corresponding to the grid pixels are greatly reduced. A grayscale threshold σ is defined, and all feature pixels with grayscale values less than the grayscale threshold are defined as background. The set of spatial positions of the remaining pixels is recorded as Index. Based on the coordinates within Index, the RGB three-channel data at the corresponding coordinates are converted to grayscale values, and the jet mapping formula is used to convert the grayscale values into a pseudo-color image.
[0100] See also Figure 4 , which is a PRPD two-dimensional atlas preprocessing process provided in this application, comprising the following steps:
[0101] A1: PRPD two-dimensional map effective content area [x min , x max ,y min ,y max ]position.
[0102] In this embodiment, if Figure 5 As shown in Figure 1, the original PRPD two-dimensional maps collected by four types of partial discharge monitoring equipment. The background color, size, and coordinate axis corresponding position of the four maps are different, and the differences are quite large. First, edge detection can be performed on the original map to generate edge detection map I. c , then use Hough transform to detect I c The line segments in the , and analyze all detected line segments, the length of the i-th line segment l i Its endpoint coordinates are defined as {di, (x 1i ,y1i ), (x 2i ,y 2i )}, through screening, retain the line segments whose horizontal length is greater than 2 / 3 of the length of the two-dimensional map and whose vertical length is greater than 2 / 3 of the width of the two-dimensional map, and define the four straight lines closest to the map boundary as the effective content border of the image. The area within the border is defined as the effective content pixel, whose horizontal and vertical coordinates satisfy x∈[x min ,x max ] and y∈[y min ,y max ], and the content outside the border is regarded as useless redundant information.
[0103] This embodiment uses the Hough transform to detect border information and grid lines in an image to identify the effective content area of the PRPD map. Given that the effective content of a PRPD map feature is typically contained within the coordinate axis border, and the grid lines are also located within this border, this embodiment locates the coordinate axis by determining the four lines closest to the image boundary in the original image. Therefore, the pixel range enclosed by the coordinate axis is considered the effective content area of the valid PRPD map feature.
[0104] like Figure 6 As shown in the figure, after the effective content is located, the atlas features can be used to locate the four different detection devices. From the positioning results, it can be seen that the atlases of the four different detection devices can achieve accurate positioning of the four coordinates through the method provided in the embodiment of the present application, realize the extraction of effective content, and extract the invalid redundant features outside the coordinate axis. The redundant pixels of the atlas features are reduced, and the quality of the dataset is improved for the construction of the dataset. This operation reduces the data dimension of the input recognition network for the target to be identified.
[0105] In this embodiment, the atlas edge detection process in step A1 includes the following steps:
[0106] A11: PRPD spectrum denoising uses Gaussian filter convolution denoising, where the convolution kernel is expressed as follows.
[0107]
[0108] A12: Calculates the gradient value and gradient direction of each pixel based on the Sobel operator.
[0109] The convolution templates in the x and y directions can be expressed as:
[0110] ,
[0111] The convolution results in the x and y directions are represented as cx, cy.
[0112] Finally, the gradient value and direction of each pixel can be expressed as:
[0113] ,
[0114] A13: Use non-maximum suppression to refine edges and eliminate false edge information. In this step, the gradient direction of each pixel is approximately classified into eight standard directions (0°, 45°, 90°, 135°, 180°, 225°, 270°, and 315°). The pixel is then compared with its neighboring pixels along the gradient direction to determine whether to retain the pixel as part of the edge.
[0115] A14: A dual-threshold technique is used to identify potential edges. Two thresholds are set: an upper threshold and a lower threshold. Pixels below the lower threshold are discarded as non-edge points, while pixels above the upper threshold are considered strong edge points and retained. Pixels between the upper and lower thresholds are considered edge points and retained if they are connected to a strong edge point; otherwise, they are discarded. This method effectively identifies true edges in the image while eliminating irrelevant noise and false edges.
[0116] A2: Normalization of PRPD effective content size and estimation of the grayscale interval of the atlas background pixels.
[0117] In this embodiment, in order to standardize the effective pixels of the atlas of different sizes, the atlas can be adjusted to a uniform size of row*col. This standardized two-dimensional image is represented as I. Based on this standardized atlas, its grayscale histogram Hi is drawn to analyze the grayscale distribution characteristics. According to the histogram Hi, the area with a larger area and a smaller grayscale value variation range is defined as the grayscale range corresponding to the background area [G min , G max ]. Pixels that fall within this grayscale range are considered the background of the image.
[0118] Considering that the PRPD spectra obtained from different partial discharge monitoring devices may have different background colors, but the range of variation of these background colors is usually very small, while the range of characteristic colors used to characterize the number of events is wider. Using this prior knowledge, this application adjusts the effective feature intervals of different sizes to a unified specification through scale transformation, and further analyzes the grayscale histogram to identify pixels that meet the color distribution characteristics of the background pixels. Finally, the grayscale value range corresponding to each channel of the spectrum background in the RGB color space is defined. This method can not only effectively remove background noise, but also more accurately extract and analyze key feature information in the PRPD spectrum.
[0119] In this embodiment, the effective content matrix I of the PRPD spectrum is first input, and then the pixel matrices I1, I2, I3, and I4 on the periphery of the spectrum are selected and the grayscale histogram H is drawn; then the grayscale level G with the highest grayscale frequency is recorded, and the frequency attenuation of the grayscale interval [G−σ, G+σ] [G−σ, G+σ] is calculated with G as the center; if the frequency attenuation of this interval reaches half of the maximum frequency, then G is selected as the background grayscale value, otherwise the second highest peak value is reselected as the new G, and the above process is repeated until a background grayscale value that meets the conditions is found (σ=30 in this embodiment); finally, the grayscale interval that meets the conditions is recorded as: [G min , G max ].
[0120] A3: Design of frequency domain filter to remove grid lines in the background of PRPD two-dimensional spectrum.
[0121] In this embodiment, the normalized effective two-dimensional spectrum I is converted to frequency domain features F(u, v) through Fourier transform. The corresponding components of the evenly distributed grid lines in the background in the frequency domain are analyzed and found to appear as horizontal and vertical lines passing through the center point of the frequency domain. Based on this characteristic, a grid elimination filter H(u, v) is designed to accurately remove the frequency components corresponding to the grid lines in the frequency domain. Subsequently, the processed frequency domain features are restored to the spatial domain through inverse Fourier transform, resulting in a spatial spectrum I' after removing the grid lines.
[0122] This application eliminates the background grid in the two-dimensional image of the PRPD spectrum monitored by different devices by setting a grid filter in the frequency domain. Figure 7 As shown in Figure 1, based on space-frequency analysis, it is found that the vertical lines in the spatial domain image appear as horizontal lines in the frequency domain, while the horizontal lines appear as vertical lines. Therefore, the grid lines in the spatial domain appear as two horizontal and vertical lines passing through the center point of the frequency domain in the frequency domain. Based on this characteristic, a special filter is designed to accurately remove the frequency components representing these grid lines in the frequency domain, thereby effectively purifying the PRPD spectrum features and eliminating background grid interference, such as Figure 8 As shown, the result after multiplying the frequency domain image with the grid line removal filter is shown.
[0123] In this embodiment, the process of removing the grid lines of the atlas background in step A3 includes the following steps:
[0124] A31: Convert the input valid content image I(i,j) from the spatial domain to the frequency domain F(u,v), where i and j represent the spatial pixel positions of the valid content of the image, and u and v represent the positions of the valid content of the image in the frequency domain. The space-frequency conversion formula is:
[0125]
[0126] Where M and N represent the length and width of the valid content in pixels, then M=row, N=col;
[0127] A32: Move the zero-frequency point of the space-frequency transform result F(u,v) to the center of the spectrum. Since most of the image information is distributed in the low-frequency part of the spectrum, if the zero-frequency shift is not performed, the energy of the spectrum is mainly concentrated in the four corners, which is not conducive to observation. The centralization transformation formula is:
[0128]
[0129] A33: Calculate the spectrum image amplitude |F'(u,v)|:
[0130]
[0131] Among them, R and Q are the real and imaginary parts of the frequency domain function F'(u,v) after centering.
[0132] A34: Transform the frequency domain image amplitude to the logarithmic interval Fl'(u,v) to make it easier to observe the low-frequency part:
[0133]
[0134] A35: Define the frequency domain grid removal filter D(u,v)=D1(u,v)*D2(u,v)*D3(u,v)*D4(u,v):
[0135]
[0136]
[0137]
[0138]
[0139] A36: Grid filtering is performed in the frequency domain. The filter D(u,v) is multiplied by F'(u,v), and the formula is as follows:
[0140]
[0141] A37: Perform inverse transformation on the filtered spectrum image.
[0142]
[0143] A4: The characteristic sinusoidal curve of PRPD spectrum is eliminated.
[0144] In this embodiment, the input PRPD atlas is a size-normalized image with a size of row*col. In the effective content background, the period T of the sine curve is set to col, the amplitude A is row / 2, and the angular velocity w is calculated as 2π / T. Based on these parameters, the mathematical expression of the sine curve in the effective content of the PRPD atlas can be expressed as: B=A*sin(w*t), where the value range of t is [1,col]. By fitting this sine curve, the periodic interference in the background can be simulated and removed. The spatial atlas obtained after eliminating the background is recorded as I''.
[0145] This application uses a specific curve function expression to precisely locate the sinusoidal line within the payload by fitting sinusoidal curve features in the background. This method identifies pixels that conform to the sinusoidal pattern and defines them as background feature pixels rather than as part of the partial discharge (PD) signature. This method effectively distinguishes background noise from actual PD events, facilitating more accurate analysis and extraction of key feature information from PRPD maps, thereby improving the accuracy of subsequent processing and interpretation. Eliminating these background features allows for a clearer picture of the true nature of PD activity.
[0146] A5: PRPD map partial discharge feature location and jet color mapping I_unified.
[0147] In this embodiment, by setting the grayscale threshold σ, pixels with grayscale values less than σ are defined as background and removed, and the spatial position set of the remaining pixels is recorded as Index. Based on the coordinates in Index, the RGB three-channel data of the corresponding position is extracted and converted into grayscale values, and then the grayscale values are converted into pseudo-color images using the jet mapping formula, as shown in Figure 2. Figure 9 This process effectively removes background interference, highlights the local discharge features, and enhances visual recognition through pseudo-color mapping, facilitating further analysis and interpretation of key information in the PRPD map.
[0148] In short, the universal PRPD two-dimensional spectrum preprocessing method provided in this application can efficiently preprocess PRPD spectra generated by different partial discharge monitoring equipment, replacing traditional manual monitoring methods and significantly reducing labor costs. In addition, this method can accurately locate effective content and remove redundant features in the spectrum, greatly facilitating the construction of diverse and high-quality PRPD datasets and laying the foundation for future PRPD spectrum recognition. This method not only improves work efficiency, but also provides strong support for further research and application.
[0149] This invention discloses a universal two-dimensional PRPD (Pressurized Power Distribution) (PRPD) spectrum preprocessing scheme. This scheme can uniformly normalize raw PRPD spectra acquired from different manufacturers during partial discharge monitoring of GIS (gas-insulated switchgear), laying the foundation for the subsequent construction of diverse PRPD datasets. The scheme implements the following steps: First, Hough transform is used to detect the location of long straight lines in the spectrum to locate valid content, and a method is designed to determine whether redundant information outside the phase-amplitude interval exists. Second, the grayscale threshold of background pixels is estimated based on the grayscale histogram to remove background pixels. Next, a grid-removal filter is designed to remove grid lines from the spectrum through a frequency-domain transformation. Finally, the discharge features after removing the grid lines and background are mapped to the jet color space. This method can batch process PRPD spectra from different sources, overcoming the limitations of traditional methods that require different preprocessing methods due to equipment differences. It uses minimal computing resources to replace the time-consuming and inefficient manual processing. Furthermore, the spectral discharge features are converted to a unified color space, providing a solid foundation for the development of future PRPD spectrum databases.
[0150] and Figure 1 Corresponding to the method described above, the embodiment of the present application further provides a PRPD spectrum processing device, which is applied to electronic equipment for Figure 1 The specific implementation of the method is shown in the structural diagram of the device. Figure 10 As shown, including:
[0151] An acquiring unit 1001 is configured to acquire an original graph corresponding to a graph processing instruction in response to the graph processing instruction;
[0152] The extraction unit 1002 is used to extract content from the original graph to obtain the graph content in the original graph;
[0153] An adjusting unit 1003 is configured to adjust the size of the original atlas to obtain a standard size atlas.
[0154] A background removal unit 1004 is used to remove background information from the standard size atlas to obtain a target atlas;
[0155] The execution unit 1005 is used to convert the RGB data of each target pixel point in the target atlas into a grayscale value, and generate a pseudo-color image based on the grayscale value obtained by the conversion using a preset pseudo-color mapping formula, wherein the target pixel point is a pixel point that is not less than a preset grayscale threshold.
[0156] In an embodiment provided in the present application, based on the above solution, optionally, the extraction unit 1002 includes:
[0157] An edge detection subunit, configured to perform edge detection on the original atlas to obtain a target area of the original atlas;
[0158] a line segment detection subunit, configured to detect each line segment within the target area;
[0159] a determination subunit, configured to determine a plurality of target line segments from each of the line segments, and determine a valid content area of the original atlas based on the plurality of target line segments, wherein the target line segments are line segments whose lengths meet a preset length condition and are closest to any boundary of the target area;
[0160] The extraction subunit is used to extract content from the effective content area to obtain the atlas content of the original atlas.
[0161] In an embodiment provided in the present application, based on the above solution, optionally, the background removal unit 804 includes:
[0162] A transformation subunit, configured to transform the standard size atlas from a two-dimensional spatial domain to a frequency domain;
[0163] A filtering subunit is used to filter the standard size spectrum transformed into the frequency domain using a preset grid filter, and transform the filtered standard size spectrum into a two-dimensional spatial domain to obtain an initial spectrum;
[0164] The execution subunit is used to eliminate the curves in the initial map to obtain the target map.
[0165] In an embodiment provided in the present application, based on the above solution, optionally, the transformation subunit includes:
[0166] A grayscale analysis module, configured to perform grayscale analysis on the standard size map to obtain a grayscale distribution of the standard size map;
[0167] a determination module, configured to determine background pixel positions of the standard size map according to the grayscale distribution of the standard size map;
[0168] A background elimination module, configured to eliminate background pixels of the standard size atlas according to background pixel positions of the standard size atlas;
[0169] The transformation module is used to transform the standard size atlas after background pixels are eliminated from the two-dimensional spatial domain to the frequency domain.
[0170] In an embodiment provided in the present application, based on the above solution, optionally, the background removal unit includes:
[0171] a first processing subunit, configured to determine a curve position in the initial map according to a curve feature of the initial map;
[0172] The second processing subunit is configured to eliminate the curves in the initial map according to the positions of the curves in the initial map to obtain a target map.
[0173] The specific principles and execution processes of each unit and module in the PRPD spectrum processing device disclosed in the above embodiment of the present application are the same as those of the PRPD spectrum processing method disclosed in the above embodiment of the present application. Please refer to the corresponding parts of the PRPD spectrum processing method provided in the above embodiment of the present application, and no further details will be given here.
[0174] An embodiment of the present application further provides a storage medium, which includes stored instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the above-mentioned PRPD spectrum processing method.
[0175] The present application also provides an electronic device, the structure of which is shown in FIG. Figure 11 As shown, it specifically includes a memory 1101 and one or more instructions 1102, wherein the one or more instructions 1102 are stored in the memory 1101 and are configured to be executed by one or more processors 1103 to execute the one or more instructions 1102 to perform the above-mentioned PRPD spectrum processing method.
[0176] It should be noted that the various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. Similarities between the various embodiments can be referred to in conjunction with each other. For device embodiments, since they are generally similar to method embodiments, their description is relatively simple, and for relevant details, reference can be made to the description of the method embodiments.
[0177] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are merely used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations.
[0178] For the convenience of description, the above devices are described as being divided into various units according to their functions. Of course, when implementing this application, the functions of each unit can be implemented in the same or multiple software and / or hardware.
[0179] Through the description of the above embodiments, it can be seen that those skilled in the art can clearly understand that the present application can be implemented by means of software plus the necessary general-purpose hardware platform. Based on this understanding, the technical solution of the present application, or the portion that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a storage medium such as ROM / RAM, a magnetic disk, an optical disk, etc., and includes a number of instructions for enabling a computer device (which can be a personal computer, a server, etc.) to execute the methods described in various embodiments of the present application or certain parts of the embodiments.
[0180] The above is a detailed introduction to a PRPD spectrum processing method provided by the present application. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea. At the same time, for those skilled in the art, according to the ideas of the present application, there may be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.
Claims
1. A PRPD spectrum processing method, characterized in that: include: In response to a graph processing instruction, obtaining an original graph corresponding to the graph processing instruction; Extracting content from the original graph to obtain graph content in the original graph; Adjusting the size of the original atlas to obtain a standard-sized atlas; Eliminating background information in the standard size atlas to obtain a target atlas; Converting the RGB data of each target pixel in the target map into a grayscale value, and generating a pseudo-color map using a preset pseudo-color mapping formula based on the converted grayscale value, wherein the target pixel is a pixel whose grayscale value is not less than a preset grayscale threshold; The extracting content from the original atlas to obtain the atlas content in the original atlas includes: performing edge detection on the original atlas to obtain a target area of the original atlas; detecting each line segment in the target area; determining a plurality of target line segments from each line segment, and determining a valid content area of the original atlas based on the plurality of target line segments, wherein the target line segment is a line segment whose length meets a preset length condition and is closest to any boundary of the target area; extracting content from the valid content area to obtain the atlas content of the original atlas; The process of eliminating background information in the standard size map to obtain a target map includes: transforming the standard size map from a two-dimensional spatial domain to a frequency domain; filtering the standard size map transformed to the frequency domain using a preset grid filter, and transforming the filtered standard size map to a two-dimensional spatial domain to obtain an initial map; and eliminating curves in the initial map to obtain a target map.
2. The method according to claim 1, characterized in that The step of transforming the standard size spectrum from the two-dimensional spatial domain to the frequency domain includes: Performing grayscale analysis on the standard size map to obtain a grayscale distribution of the standard size map; Determining background pixel positions of the standard size map according to the grayscale distribution of the standard size map; Eliminating background pixels of the standard size atlas according to background pixel positions of the standard size atlas; The standard size atlas after background pixels are eliminated is transformed from the two-dimensional spatial domain to the frequency domain.
3. The method according to claim 1, characterized in that Eliminating the curves in the initial map to obtain the target map includes: Determining a curve position in the initial map according to the curve characteristics of the initial map; The curves in the initial map are eliminated according to the positions of the curves in the initial map to obtain a target map.
4. A PRPD spectrum processing device, characterized in that: include: an acquiring unit, configured to acquire, in response to a graph processing instruction, an original graph corresponding to the graph processing instruction; An extraction unit, configured to extract content from the original graph to obtain graph content in the original graph; An adjusting unit, configured to adjust the size of the atlas content of the original atlas to obtain an atlas of standard size; A background elimination unit, configured to eliminate background information in the standard size atlas to obtain a target atlas; an execution unit, configured to convert the RGB data of each target pixel in the target atlas into a grayscale value, and generate a pseudo-color image according to the grayscale value obtained by the conversion using a preset pseudo-color mapping formula, wherein the target pixel is a pixel whose grayscale value is not less than a preset grayscale threshold; The extraction unit comprises: An edge detection subunit, configured to perform edge detection on the original atlas to obtain a target area of the original atlas; a line segment detection subunit, configured to detect each line segment within the target area; a determination subunit, configured to determine a plurality of target line segments from each of the line segments, and determine a valid content area of the original atlas based on the plurality of target line segments, wherein the target line segments are line segments whose lengths meet a preset length condition and are closest to any boundary of the target area; An extraction subunit, configured to extract content from the effective content area to obtain the atlas content of the original atlas; The background removal unit includes: A transformation subunit, configured to transform the standard size atlas from a two-dimensional spatial domain to a frequency domain; A filtering subunit is used to filter the standard size spectrum transformed into the frequency domain using a preset grid filter, and transform the filtered standard size spectrum into a two-dimensional spatial domain to obtain an initial spectrum; The execution subunit is used to eliminate the curves in the initial map to obtain the target map.
5. A storage medium, characterized in that: The storage medium includes stored instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the PRPD spectrum processing method according to any one of claims 1 to 3.
6. An electronic device, characterized in that: The system comprises a memory and one or more instructions, wherein the one or more instructions are stored in the memory and configured to execute the PRPD spectrum processing method according to any one of claims 1 to 3 by one or more processors.