A method and system for information analysis of relay protection cabinet pressure plates

CN122574876APending Publication Date: 2026-08-14SHENZHEN POWER SUPPLY BUREAU
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610795967.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-06-04
Publication Date
2026-08-14

AI Technical Summary

Technical Problem

无法还原压板行列结构:压板检测框输出无序,不能自动恢复压板在屏柜中的行列结构;

Benefits of technology

本发明提供一种继电保护屏柜压板的信息解析方法及系统。通过利用垂直重叠判断与邻近搜索的连通分量方法,无需预知屏柜行数或压板数量,即可自动完成分行与列内排序,计算复杂度低,适用于边缘端实时处理。同时,采用中心点横坐标进行方向判定与距离计算,对图像倾斜和检测框边界波动具有天然的鲁棒性。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122574876A_ABST
    Figure CN122574876A_ABST
Patent Text Reader

Abstract

This invention discloses a method and system for information analysis of relay protection cabinet pressure plates. The method includes: acquiring the original image of the pressure plate; performing target detection to obtain the pressure plate detection frame and its engagement / disengagement status; performing optical character recognition to obtain OCR text labels and recognized text; constructing pressure plate rows and restoring the row and column structure based on vertical overlap judgment and proximity search; dynamically defining the text label association region according to the relative position of the pressure plate in the same row and the pressure plate in the next row, and assigning the labels falling into this region to the current pressure plate; for all text labels belonging to the same pressure plate, performing row clustering through adaptive coordinate transformation and normal interval overlap ratio, and distinguishing between numbered rows and name rows according to row order, finally outputting the number string, name string, and engagement / disengagement status of each pressure plate. This invention can automatically restore the pressure plate row and column structure, accurately allocate text labels under dense arrangement, and robustly distinguish between numbered rows and name rows, exhibiting high efficiency, accuracy, and strong robustness.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent operation and maintenance technology for power systems, and in particular to an information analysis method and system for relay protection cabinet pressure plates. Background Technology

[0002] The relay protection panel cabinet contains key components for enabling and disabling protection functions. Maintenance personnel need to create a relay protection panel list when a new station is put into operation and verify the number, name, and enabled / disabled status of each panel during routine inspections. Both of these tasks rely on manual visual inspection, which is inefficient and prone to errors.

[0003] Currently, deep learning object detection (such as YOLO) can accurately locate the position of the pressure plate and identify its deployment and retraction status based on an image, while OCR (such as PaddleOCR) can locate the label position in an image and recognize the text in the label. However, there are still difficulties in the subsequent reconstruction of the row and column structure of the pressure plate and the determination of label attribution: Unable to restore the row and column structure of the pressure plate: The output of the pressure plate detection frame is disordered and cannot automatically restore the row and column structure of the pressure plate in the cabinet; The label assignment is ambiguous under dense arrangement: the spacing between pressure plates is small, and the label is assigned only based on the distance. It is very easy to misassign the text of the current pressure plate to the adjacent pressure plate, causing crosstalk. The pressure plate number and pressure plate name cannot be automatically obtained: the existing method can only read the text content and cannot reliably distinguish between the number line and the name line based on the spatial layout. Especially when the label is tilted or the line spacing changes, simple rules are difficult to accurately group and judge.

[0004] Therefore, there is an urgent need for a method that can restore the row and column structure of the relay protection cabinet pressure plate and resolve the pressure plate number and name. Summary of the Invention

[0005] To overcome the aforementioned deficiencies of the prior art, this invention provides an information analysis method and system for relay protection cabinet pressure plates, which can automatically restore the row and column structure of the pressure plates, accurately allocate text labels under dense arrangement, and robustly distinguish between numbered rows and name rows, and has the characteristics of high efficiency, accuracy and strong robustness.

[0006] This invention provides the following technical solution: a method for analyzing the information of a relay protection cabinet pressure plate, comprising the following steps: Step S10: Obtain the original image of the relay protection panel pressure plate; Step S11: Perform target detection on the original image to obtain multiple pressure plate detection boxes and the deployment / retraction status of each pressure plate; Step S12: Perform optical character recognition on the original image to obtain multiple OCR text labels and the recognized text of each label; Step S13: Based on the vertical overlap judgment and proximity search between the pressure plate detection boxes, construct multiple "pressure plate rows" and sort the pressure plates in each row by column to restore the row and column structure of the pressure plates; Step S14: For each positioned row and column plate, dynamically define the text label association area according to its relative position with the adjacent plate in the same row and the next row plate, and assign the OCR text label that falls into the area to the current plate. Step S15: For all text labels belonging to the same pressure plate, perform row clustering through adaptive coordinate transformation and normal interval overlap ratio, and distinguish between numbered rows and name rows according to row order, and finally output the number string, name string and engagement / disengagement status of each pressure plate.

[0007] In step S11, the target detection adopts a deep learning-based target detection algorithm. The pressure plate detection box contains the position information and status information of the pressure plate. The status information includes the input status or the exit status. The optical character recognition in step S12 uses a deep learning-based OCR algorithm, and the OCR text label contains the label's location information and the recognized text content.

[0008] The specific method for constructing the "pressure plate row" in step S13 includes: Set the "Not Added" status attribute for each pressure plate; Create a new "Plate Row" using any "Unadded" plate as the seed; Expand to the right and left respectively, with the following conditions: the pressure plate has not been added; the pressure plate overlaps with the seed pressure plate in the vertical direction, that is, the minimum value of the vertical coordinate of one is less than or equal to the maximum value of the vertical coordinate of the other, and its maximum value of the vertical coordinate is greater than or equal to the minimum value of the vertical coordinate of the other; and the pressure plate is located to the right or left of the current pressure plate, that is, the x-coordinate of its center point is greater than or less than the x-coordinate of the center point of the current pressure plate. Each expansion selects the nearest suitable pressure plate that meets the criteria, until no further expansion is possible; After traversing all the pressure plates, multiple "pressure plate rows" are obtained, and sorted in ascending order according to the y-coordinate of the center point of the first pressure plate in each row.

[0009] The method for dynamically defining the associated region of text labels in step S14 includes: Perform vertical boundary calculations, including: The minimum vertical range is taken at 1 / 5 of the height of the current pressure plate detection frame, offset upwards from the lower boundary of the frame. The maximum vertical range value is initially set at half the height of the current pressure plate detection frame, which is offset downwards from the lower boundary of the current pressure plate detection frame. If there is a next row of pressure plates for the current pressure plate, and the upper boundary of the pressure plates in the same column of the next row is less than the initial value, then the maximum vertical range value is adjusted to the upper boundary value of the next row of pressure plates. Perform horizontal boundary calculations, including: The minimum horizontal range is initially set to the left of the current pressure plate detection frame, which is expanded to the left by 3 times the frame width. If the current pressure plate has an adjacent pressure plate on the left in the same row, it is adjusted to the midpoint between the left boundary of the current pressure plate and the right boundary of the adjacent pressure plate on the left. The maximum value of the horizontal range is initially taken as the right boundary of the current pressure plate detection frame expanded to the right by 3 times the frame width. If there is an adjacent pressure plate on the right in the same row, it is adjusted to the midpoint between the right boundary of the current pressure plate and the left boundary of the adjacent pressure plate on the right. Perform tag filtering, including: determining OCR text tags whose center point coordinates simultaneously meet the above vertical and horizontal ranges as belonging to the current pressure plate.

[0010] Specifically, the adaptive coordinate transformation, row clustering, and methods for distinguishing between numbered rows and name rows in step S15 include: The coordinate transformation includes: among all the text labels belonging to the same pressure plate, select the label with the largest detection box width, take its bottom edge direction as the text line direction, take the lower left corner of the label as the origin, establish an inclined text line coordinate system, and convert the corner coordinates of all labels into normal coordinates and line coordinates, forming a normal interval and a line interval for each label. Perform row clustering, including: calculating the overlap length of the normal intervals of two labels, using the smaller of the heights of the normal intervals of the two labels as the denominator, calculating the overlap ratio, and if the overlap ratio is greater than 0.5, then the two labels are determined to be located on the same text line; Perform inter-row and intra-row sorting, including: grouping all rows, sorting the rows inter-row by using the median value of the normal coordinate of each label in each row to represent the position of the row, and sorting the rows within each row by using the median value of each label along the row direction coordinate. Distinguish between numbered rows and name rows, including: if only one row is formed after clustering, all labels in that row are determined as name labels, and the number string is empty; if two or more rows are formed after clustering, the first row after sorting is determined as the numbered label row, and all other rows are determined as name label rows. Perform string concatenation, including: for the identified number label row and name label row, concatenate the identification text of the labels in each row from left to right according to the row order, and output the number string and name string of the current pressure plate.

[0011] Accordingly, as another aspect of the present invention, an information analysis system for the relay protection cabinet pressure plate is also provided, which includes at least: The image acquisition module is used to acquire the original image of the relay protection cabinet pressure plate; The target detection module is used to perform target detection on the original image and output multiple pressure plate detection boxes and the deployment / retraction status of each pressure plate; An optical character recognition module is used to perform optical character recognition on the original image and output multiple OCR text labels and the recognized text of each label; The row and column structure restoration module is used to construct multiple "pressure plate rows" based on the vertical overlap judgment between pressure plate detection frames and the nearest neighbor search, and to sort the pressure plates in each row by column to output the row and column structure of the pressure plates; The label attribution determination module is used to dynamically define the text label association area for each positioned row and column plate based on its relative position with the adjacent plate in the same row and the next row plate, and assign the OCR text label that falls into the area to the current plate. The number and name parsing module is used to perform row clustering on all text labels belonging to the same pressure plate through adaptive coordinate transformation and normal interval overlap ratio, and to distinguish between numbered rows and name rows according to row order. Finally, it outputs the number string, name string and engagement / disengagement status of each pressure plate.

[0012] The target detection module adopts a deep learning-based target detection algorithm, and the pressure plate detection box contains the position information and status information of the pressure plate, including the input status or the exit status. The optical character recognition module uses a deep learning-based OCR algorithm, and the OCR text label contains the label's location information and the recognized text content.

[0013] The row and column structure restoration module includes: The state initialization unit is used to set the "not added" state for each pressure plate; The row building unit is used to expand to the right and left to build "pressing plate rows" with "unadded" pressing plates as seeds. The expansion conditions include vertical overlap determination, direction determination and nearest neighbor selection. The row sorting unit is used to sort the "pressing plate rows" in ascending order of the ordinate of the center point of the first pressing plate in each row.

[0014] The tag attribution determination module includes: The vertical boundary calculation unit is used to dynamically calculate the upper and lower boundaries of the associated area based on the current pressure plate frame height and the position of the next row of pressure plates. The minimum value of the vertical range is taken as 1 / 5 of the frame height offset upward from the current lower boundary of the pressure plate, and the maximum value of the vertical range is dynamically adjusted according to the upper boundary of the next row of pressure plates. The horizontal boundary calculation unit is used to dynamically calculate the left and right boundaries of the associated area based on the position of the current pressure plate and the adjacent pressure plates on the left and right. The horizontal boundary is taken as the midpoint between the current pressure plate boundary and the adjacent pressure plate boundary. The label filtering unit is used to determine whether the center point of the OCR label falls within the dynamically associated area.

[0015] The number name parsing module includes: The coordinate transformation unit is used to transform the coordinates of all label corner points to the slanted text line coordinate system, taking the bottom edge direction of the label with the largest width among all text labels belonging to the same pressure plate as the text line direction. Row clustering units are used to group labels by row based on whether the overlap ratio of normal intervals is greater than 0.5; The row and column sorting unit is used to sort rows and columns within rows. The row role determination unit is used to determine the first row as the number row and the remaining rows as the name row; The string concatenation unit is used to concatenate recognized text from left to right in line order, and output the number string and the name string; The output integration unit is used to integrate the number string, name string, and engagement / disengagement status of each pressure plate into structured data output.

[0016] Implementing this invention has the following beneficial effects: This invention provides a method and system for information analysis of relay protection cabinet pressure plates. By utilizing a connected component method based on vertical overlap judgment and proximity search, it can automatically complete row and column sorting without prior knowledge of the number of cabinet rows or pressure plates, resulting in low computational complexity and suitability for real-time edge processing. Furthermore, by using the x-coordinate of the center point for direction determination and distance calculation, it exhibits inherent robustness to image tilt and detection box boundary fluctuations.

[0017] In this embodiment of the invention, the boundary of the associated region is not a fixed value, but is dynamically calculated based on "dynamic constraints of adjacent pressure plate positions + coordinates of the label center point", which effectively avoids the problem of labels being erroneously captured by adjacent pressure plates under dense arrangement.

[0018] In this embodiment of the invention, the pressure plate number and name are obtained entirely based on spatial location, without relying on any textual semantics: through adaptive coordinate transformation based on the text line direction, and adaptive line clustering based on the normal interval overlap ratio, combined with inter-line sorting and intra-line sorting, the upper number line and the lower name line are accurately identified. Even if the labels are tilted, the line spacing varies, or there are OCR recognition errors, the results can still be accurately output according to the physical layout rule of "number label line on top, name label line below," demonstrating high robustness to differences in naming conventions and abnormal text content.

[0019] In this embodiment of the invention, the decision logic of each step directly corresponds to the physical structural characteristics of the relay protection cabinet. The algorithm behavior is predictable and easy to debug, making it convenient for on-site deployment and maintenance. Attached Figure Description

[0020] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, obtaining other drawings based on these drawings without creative effort still falls within the scope of the present invention. Figure 1 This is a schematic diagram of the main flow of an embodiment of the information parsing method for a relay protection cabinet pressure plate provided by the present invention; Figure 2 A schematic diagram of the original image of the pressure plate of the relay protection cabinet in the method provided by the present invention; Figure 3 This is a schematic diagram showing the result of target detection on the original image in the method provided by the present invention. Figure 4 This is a schematic diagram illustrating the method of obtaining text labels from an original image using OCR recognition. Figure 5 This is a schematic diagram illustrating the method for determining tag attribution provided by the present invention; Figure 6 This is a schematic diagram of a structure of an embodiment of an information analysis system for a relay protection cabinet pressure plate provided by the present invention; Figure 7 for Figure 6 A schematic diagram of the middle row and column structure restoration module; Figure 8 for Figure 6 A schematic diagram of the label determination module; Figure 9 for Figure 6 A schematic diagram of the structure of the Chinese number name parsing module. Detailed Implementation

[0021] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0022] like Figure 1The diagram shown illustrates the main flow of an embodiment of the information parsing method for a relay protection cabinet pressure plate provided by the present invention. (In conjunction with...) Figures 2 to 5 As shown, in this embodiment, the method includes the following steps: Step S10: Obtain the original image of the relay protection panel pressure plate; Step S11: Perform target detection on the original image to obtain multiple pressure plate detection boxes and the deployment / retraction status of each pressure plate; Step S12: Perform optical character recognition on the original image to obtain multiple OCR text labels and the recognized text of each label; Step S13: Based on the vertical overlap judgment and proximity search between the pressure plate detection boxes, construct multiple "pressure plate rows" and sort the pressure plates in each row by column to restore the row and column structure of the pressure plates; Step S14: For each positioned row and column plate, dynamically define the text label association area according to its relative position with the adjacent plate in the same row and the next row plate, and assign the OCR text label that falls into the area to the current plate. Step S15: For all text labels belonging to the same pressure plate, perform row clustering through adaptive coordinate transformation and normal interval overlap ratio, and distinguish between numbered rows and name rows according to row order, and finally output the number string, name string and engagement / disengagement status of each pressure plate.

[0023] The steps of the method provided by the present invention will be described below with reference to specific examples.

[0024] In step S11, the target detection adopts a deep learning-based target detection algorithm. The pressure plate detection box contains the position information and status information of the pressure plate. The status information includes the input status or the exit status. The optical character recognition in step S12 uses a deep learning-based OCR algorithm, and the OCR text label contains the label's location information and the recognized text content.

[0025] In step S13, constructing the "pressure plate rows" aims to divide the disordered pressure plate detection boxes output by the target detection model into rows, restoring their physical row and column matrix within the cabinet. This step employs a connected component method based on nearest neighbor search, which does not rely on prior knowledge of image tilt and exhibits high robustness. Step S13 further includes: Step S130: Set the "Not Added" status attribute for each pressure plate; specifically, add a status attribute for each pressure plate detection object and initialize the attribute of all pressure plates to the "Not Added" status.

[0026] Step S131: Using any "not added" pressure plate as a seed, create a new "pressure plate row"; specifically, iterate through all pressure plate detection boxes, and for each pressure plate with a state of "not added", construct a "pressure plate row" using that pressure plate as the seed, ultimately forming multiple "pressure plate rows". Create the current row: Create a new empty "pressure plate row", add the seed pressure plate to this "pressure plate row", and mark the pressure plate as "added"; Step S132: Expand to the right and left respectively, with the following expansion conditions: The pressure plate was not added; The pressure plate and the seed pressure plate are in the same row, that is, the pressure plate and the seed pressure plate overlap in the vertical direction. Specifically, the minimum value of the vertical coordinate y_min of one side is less than or equal to the maximum value of the vertical coordinate y_max of the other side, and the maximum value of the vertical coordinate y_max is greater than or equal to the minimum value of the vertical coordinate y_min of the other side. And the pressure plate is located to the right or left of the current pressure plate, that is, the x-coordinate of its center point is greater than or less than the x-coordinate of the center point of the current pressure plate; Step S133: Each time the expansion is performed, select the pressure plate that meets the conditions closest to the current pressure plate until no further expansion is possible. If a pressure plate that meets all three conditions is found, set the pressure plate that is closest to the current pressure plate (distance is defined as the x-coordinate of the center point of the current pressure plate minus the x-coordinate of the center point of the current pressure plate) as the current pressure plate and repeat the steps of expanding to the right or left. If no pressure plate that meets all three conditions is found, stop expanding to the right or left.

[0027] Step S134: After traversing all pressure plates, multiple "pressure plate rows" are obtained, and sorted in ascending order according to the y-coordinate of the center point of the first pressure plate in each row.

[0028] In a specific example, step S14 is used to define a unique text label association region for each positioned row and column of pressure plate, and filter out all OCR text labels falling into that region, thus completing the matching of labels with pressure plates. The methods for dynamically defining the text label association region in step S14 include: Step S140, perform vertical boundary calculation, including: It is understandable that, for the current pressure plate, the minimum vertical range of its associated area, y_min, is taken as 1 / 5 of the height of the current pressure plate detection box, which is offset upwards from the lower boundary of the detection box, i.e., y_max - height / 5; The maximum vertical range value y_max is initially set to half the height of the current pressure plate detection box, which is offset downwards from the lower boundary of the current pressure plate detection box. That is, y_max + height / 2. If there is a pressure plate in the next row, and the upper boundary of the pressure plate in the same column of the next row (or the rightmost pressure plate in the row if there is no same column) is less than the lower limit of this initial value, then the maximum vertical range value y_max is adjusted to the upper boundary value of the pressure plate in the next row to prevent the associated area from crossing into the text area of ​​the pressure plate in the next row. Step S141, perform horizontal boundary calculation, including: The minimum horizontal range x_min is initially set to the left of the current pressure plate detection box, which is expanded to the left by 3 times the box width. If the current pressure plate has an adjacent pressure plate on the left in the same row, x_min is adjusted to the midpoint between the left boundary of the current pressure plate and the right boundary of the adjacent pressure plate on the left. This process ensures that the associated region does not intrude into the core text area of ​​the adjacent pressure plate in the horizontal direction.

[0029] The maximum horizontal range x_max is initially set to the right of the current pressure plate detection box, which is expanded by 3 times the box width. If there is an adjacent pressure plate to the right in the same row, x_max is adjusted to the midpoint between the right boundary of the current pressure plate and the left boundary of the adjacent pressure plate to the right. This process ensures that the associated region does not intrude into the core text area of ​​the adjacent pressure plate in the horizontal direction.

[0030] Step S142, perform tag filtering, including: determining OCR text tags whose center point coordinates simultaneously satisfy the above vertical and horizontal ranges as belonging to the current pressure plate; Specifically, iterate through all OCR text tags. If the center point of a tag simultaneously satisfies: (1) The ordinate of the center point > the minimum value of the vertical range y_min (2) The ordinate of the center point < the maximum value of the vertical range y_max (3) The x-coordinate of the center point is greater than the minimum value of the horizontal range, x_min (4) The x-coordinate of the center point is less than the maximum value of the horizontal range, x_max Then the label is determined to belong to the current pressure plate and added to the "all labels" set of the current pressure plate.

[0031] In a specific example, step S15 is used to process all labels belonging to the same pressure plate, obtaining the corresponding number string and name string. This process relies entirely on the relative spatial relationship between the labels, without depending on semantic analysis of the text content. The specific methods for adaptive coordinate transformation, row clustering, and distinguishing between numbered and name rows in this step include: Step S150 involves performing an adaptive coordinate transformation based on the text line direction. To eliminate the impact of tilt on the determination of text label line affiliation and intra-line sorting when the pressure plate is tilted and the text line direction is unknown, this invention performs an adaptive coordinate transformation based on the text line direction for each text label belonging to the same pressure plate. The specific steps are as follows: Among all text labels belonging to the same pressure plate, select the label with the largest detection frame width, and use its bottom edge direction as the text line direction. Record the two endpoints of this bottom edge as the lower left corner point (x, y). 左下 , y 左下 ) and the bottom right corner point (x 右下 ,y 右下 Calculate the text line direction vector (dx, dy) and the base length L, where dx = x 右下 -x 左下 dy = y 右下 - y 左下 L= .

[0032] Using the bottom left corner of the label as the origin, establish an inclined text line coordinate system, convert the corner coordinates of all labels into normal coordinates and line coordinates, and form a normal interval and a line interval for each label; Specifically, for each text label under the current pressure plate, the four corner points (x, y) of its detection frame are taken, and coordinate transformations are performed to obtain the coordinates of each corner point in the new coordinate system: Normal coordinates (perpendicular to the text line direction): v = (dx·(y - y)) 左下 ) - dy·(x - x 左下 )) / L Along the line coordinate (along the text line direction): h = (dx·(x - x) 左下 ) + dy·(y - y 左下 )) / L Obtain the transformed feature interval: For each label, take the minimum and maximum values ​​of the normal coordinates of the four corner points to form the normal interval [v_min, v_max] of the label; take the minimum and maximum values ​​of the coordinates along the row of the four corner points to form the row interval [h_min, h_max].

[0033] After the coordinate transformation described above, the position information of each label is unified into a coordinate system based on the direction of the text line, effectively overcoming the directional deviation caused by the overall tilt of the pressure plate. Specifically, the normal interval is used to determine whether different labels belong to the same text line; the line-direction interval is used to determine the left-right arrangement order of labels within the same line.

[0034] Step S151, perform row clustering, including: calculate the overlap length of the normal intervals of the two labels, use the smaller value of the height of the normal intervals of the two labels as the denominator, calculate the overlap ratio, and if the overlap ratio is greater than 0.5, determine that the two labels are located in the same text line. Specifically, the following rules determine whether two tags belong to the same line: If the normal regions of the two labels overlap, calculate the overlap length overlap = min(v_max1, v_max2) - max(v_min1, v_min2); Take the normal interval heights h1 and h2 of the two labels respectively, where h1 = v_max1 - v_min1 and h2 = v_max2 - v_min2, and set the minimum height min_h = min(h1, h2); Calculate the overlap ratio = overlap length / minimum height min_h; if the overlap ratio is greater than 0.5, the two tags are considered to be on the same line, otherwise they are considered to belong to different lines.

[0035] Step S152: After clustering is completed, perform inter-row sorting and intra-row sorting: Inter-row sorting: Group all rows and sort them in ascending order by the minimum value of (v_min+v_max) / 2 in each label box of each row.

[0036] In-row sorting: Within each row, sort by the value of the label box (h_min + h_max) / 2 in ascending order.

[0037] Step S153: Distinguish between the number row and the name row according to the row order. This is used to set the number label and name label sequentially below the pressure plate according to the secondary equipment identification specifications of the relay protection cabinet (the name label may wrap to a new line if the name is too long). The number and name are determined according to the row order: If clustering results in only one row of groups, all labels in that row are determined as name labels, and the number string is empty; if clustering results in two or more rows of groups, the first row after sorting (i.e., the row with the smallest y-axis) is determined as the number label row, and all other rows are determined as name label rows. Step S154 involves string concatenation, including: concatenating the identification text of the labels in each row from left to right according to the row order for the identified number label row and name label row, and outputting the number string and name string of the current pressure plate.

[0038] In a specific example, such as Figure 2 The image shown is the original image of a relay protection panel pressure plate. The results after target detection are as follows: Figure 3As shown, the target detection results are divided into two categories: In practical applications, the pressure plate in the engaged state can be indicated by features such as a red box. In practical applications, the pressure plate in the exit state can be displayed using methods such as color-coded borders.

[0039] Text tags obtained through OCR recognition, such as Figure 4 As shown, in practical applications, a blue box can be used to display the information.

[0040] After restoring the row and column structure of the pressure plates, a structure with 4 rows of pressure plates and 9 pressure plates in each row can be obtained, as shown in Table 1 below.

[0041] Table 1. Schematic diagram of the restored pressure plate row and column structure.

[0042] After determining the label's ownership, and obtaining the numbered and named labels, specifically... Figure 5 As shown, in practical applications, different colored boxes can be used to distinguish between displaying numbers and names. For example, the number is displayed in the white box, and the name is displayed in the blue box.

[0043] The final number, name, and status of the pressing plates are shown in Table 2 below, which can be used to create a pressing plate ledger or to compare with an existing pressing plate ledger.

[0044] Table 2. Final Analysis of Pressure Plate Information

[0045] It is understood that, in the embodiments of the present invention, the "pressure plate" mentioned in the present invention refers to the connecting piece on the relay protection cabinet used for enabling or disabling protection functions; the "number label" refers to the text label that identifies the pressure plate equipment number (such as "1LP1"), which is usually located in the first row directly below the pressure plate; the "name label" refers to the text label that describes the protection function, which is usually located below the number label.

[0046] The relative proportion parameters in the method (such as vertical offset of 1 / 5 and 1 / 2 of the frame height, horizontal expansion of 3 times the frame width, and overlap ratio of 0.5) can be fine-tuned according to the layout of the pressure plate labels of different screen cabinets.

[0047] This invention can be packaged as an independent module and integrated into intelligent inspection robots, mobile operation terminals or edge computing devices through standard APIs. It receives target detection (such as YOLO) and OCR results, outputs structured pressure plate status data, and seamlessly connects with power grid dispatching, production management and other systems.

[0048] The essential contributions of this invention are: (1) achieving lightweight row and column restoration without pre-sorting using "vertical overlap judgment + connected components of neighbor search", which is naturally robust to image tilt; (2) suppressing label crosstalk in dense scenes using the association region delineation mechanism of "dynamic constraint of adjacent pressure plate positions + coordinates of label center point"; (3) obtaining pressure plate number and name using pure spatial position rules (numbered label is above name label), which does not depend on text content and is highly robust. The three together construct a post-processing framework from discrete recognition results to structured semantic description.

[0049] The application areas of this invention include, but are not limited to, the following aspects: 1. Automated inspection and ledger management of relay protection panel pressure plates The most direct application of this invention lies in improving the digital inspection and record management of relay protection panel pressure plates in substations, power plants, and other substations. It can be integrated into intelligent inspection robot systems, mobile operation terminals, or station-level edge computing devices as a core post-processing module to automatically process the pressure plate positions and text recognition results obtained through target detection and OCR technology. By automatically restoring the row and column matrix structure of the pressure plates in the panel, accurately determining the relationship between each text label and its corresponding pressure plate, and automatically distinguishing between numbered and named text, it can completely replace manual data entry and visual verification, significantly improving the efficiency of pressure plate table creation when new stations are put into operation, and enhancing the efficiency and accuracy of checking pressure plate status during daily inspections. It is a key technology supporting lean management of relay protection operation and maintenance and the digitalization of secondary equipment status.

[0050] 2. Visual inspection of industrial equipment with regular array layout characteristics The technical framework proposed in this invention, which combines "disordered detection boxes, spatial clustering and row division, dynamic boundary partitioning based on adjacency relationships, and relative position rule classification," possesses cross-scenario versatility. It is applicable to visual inspection scenarios such as power, chemical, rail transportation, and electronics manufacturing, where there are also regularly arranged arrays of equipment and a need to establish a correspondence between inspection targets and associated labels. For example, it can be used to automatically parse the terminal block numbers of power distribution cabinets, automatically match instrument panel scale values ​​with range labels, automatically associate production line material trays with electronic tags, and automatically verify the correspondence between the status of indicator lights and circuit breakers in protection device cabinets and their labels. This achieves a leap from "pixel-level discrete recognition" to "structured semantic description" of inspection results, significantly improving the data integrity and practicality of industrial visual inspection systems.

[0051] like Figure 6 The diagram shown illustrates a structural schematic of an embodiment of the information parsing system for a relay protection cabinet pressure plate provided by the present invention. (In conjunction with...) Figures 7 to 9 As shown, in this embodiment, the information parsing system 1 of the relay protection cabinet pressure plate includes at least: Image acquisition module 10 is used to acquire the original image of the relay protection cabinet pressure plate; The target detection module 11 is used to perform target detection on the original image and output multiple pressure plate detection boxes and the deployment / retraction status of each pressure plate; The optical character recognition module 12 is used to perform optical character recognition on the original image and output multiple OCR text labels and the recognized text of each label; The row and column structure restoration module 13 is used to construct multiple "pressure plate rows" based on the vertical overlap judgment and proximity search between pressure plate detection frames, and to sort the pressure plates in each row by column to output the row and column structure of the pressure plates; The label attribution determination module 14 is used to dynamically define the text label association area for each positioned row and column plate according to its relative position with the adjacent plate in the same row and the next row plate, and assign the OCR text label that falls into the area to the current plate. The number and name parsing module 15 is used to perform row clustering on all text labels belonging to the same pressure plate through adaptive coordinate transformation and normal interval overlap ratio, and to distinguish between numbered rows and name rows according to row order, and finally output the number string, name string and engagement / disengagement status of each pressure plate.

[0052] The target detection module 11 adopts a target detection algorithm based on deep learning, and the pressure plate detection frame contains the position information and status information of the pressure plate, including the input status or the exit status. The optical character recognition module 12 adopts a deep learning-based OCR algorithm, and the OCR text label contains the label's position information and the recognized text content.

[0053] like Figure 7 As shown, in a specific example, the row and column structure restoration module 13 includes: The state initialization unit 130 is used to set the "not added" state for each pressure plate; Row construction unit 131 is used to expand to the right and left to construct "pressing plate rows" with "unadded" pressing plates as seeds. The expansion conditions include vertical overlap determination, direction determination and nearest neighbor selection. The row sorting unit 132 is used to sort the "pressing plate rows" in ascending order of the ordinate of the center point of the first pressing plate in each row.

[0054] like Figure 8 As shown, in a specific example, the tag attribution determination module 14 includes: The vertical boundary calculation unit 140 is used to dynamically calculate the upper and lower boundaries of the associated area based on the current pressure plate frame height and the position of the next row of pressure plates. The minimum value of the vertical range is taken as 1 / 5 of the frame height offset upward from the current lower boundary of the pressure plate, and the maximum value of the vertical range is dynamically adjusted according to the upper boundary of the next row of pressure plates. The horizontal boundary calculation unit 141 is used to dynamically calculate the left and right boundaries of the associated area based on the position of the current pressure plate and the adjacent pressure plates on the left and right, wherein the horizontal boundary is taken as the midpoint between the current pressure plate boundary and the adjacent pressure plate boundary; The label filtering unit 142 is used to determine whether the center point of the OCR label falls within the dynamically associated area.

[0055] like Figure 9 As shown, in a specific example, the number name parsing module 15 includes: The coordinate transformation unit 150 is used to transform the coordinates of all label corner points to the slanted text line coordinate system, taking the bottom edge direction of the label with the largest width among all text labels belonging to the same pressure plate as the text line direction. Row clustering unit 151 is used to group labels by row based on whether the overlap ratio of normal intervals is greater than 0.5; The row and column sorting unit 152 is used to sort rows and rows within rows; The row role determination unit 153 is used to determine the first row as the number row and the remaining rows as the name row; String concatenation unit 154 is used to concatenate recognized text from left to right in line order and output a number string and a name string; The output integration unit 155 is used to integrate the number string, name string and engagement / disengagement status of each pressure plate into structured data output.

[0056] For more details, please refer to and combine with the above. Figures 1 to 5 The description of that will not be repeated here.

[0057] Implementing this invention has the following beneficial effects: This invention provides a method and system for information analysis of relay protection cabinet pressure plates. By utilizing a connected component method based on vertical overlap judgment and proximity search, it can automatically complete row and column sorting without prior knowledge of the number of cabinet rows or pressure plates, resulting in low computational complexity and suitability for real-time edge processing. Furthermore, by using the x-coordinate of the center point for direction determination and distance calculation, it exhibits inherent robustness to image tilt and detection box boundary fluctuations.

[0058] In this embodiment of the invention, the boundary of the associated region is not a fixed value, but is dynamically calculated based on "dynamic constraints of adjacent pressure plate positions + coordinates of the label center point", which effectively avoids the problem of labels being erroneously captured by adjacent pressure plates under dense arrangement.

[0059] In this embodiment of the invention, the pressure plate number and name are obtained entirely based on spatial location, without relying on any textual semantics: through adaptive coordinate transformation based on the text line direction, and adaptive line clustering based on the normal interval overlap ratio, combined with inter-line sorting and intra-line sorting, the upper number line and the lower name line are accurately identified. Even if the labels are tilted, the line spacing varies, or there are OCR recognition errors, the results can still be accurately output according to the physical layout rule of "number label line on top, name label line below," demonstrating high robustness to differences in naming conventions and abnormal text content.

[0060] In this embodiment of the invention, the decision logic of each step directly corresponds to the physical structural characteristics of the relay protection cabinet. The algorithm behavior is predictable and easy to debug, making it convenient for on-site deployment and maintenance.

[0061] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 Units that specify functions within one or more boxes.

[0062] The above description is merely a preferred embodiment of the present invention and should not be construed as limiting the scope of the invention. Therefore, any equivalent variations made in accordance with the claims of the present invention are still within the scope of the present invention.

Claims

1. A method for analyzing information from the pressure plate of a relay protection cabinet, characterized in that, Includes the following steps: Step S10: Obtain the original image of the relay protection panel pressure plate; Step S11: Perform target detection on the original image to obtain multiple pressure plate detection boxes and the deployment / retraction status of each pressure plate; Step S12: Perform optical character recognition on the original image to obtain multiple OCR text labels and the recognized text of each label; Step S13: Based on the vertical overlap judgment and proximity search between the pressure plate detection boxes, construct multiple "pressure plate rows" and sort the pressure plates in each row by column to restore the row and column structure of the pressure plates; Step S14: For each positioned row and column plate, dynamically define the text label association area according to its relative position with the adjacent plate in the same row and the next row plate, and assign the OCR text label that falls into the area to the current plate. Step S15: For all text labels belonging to the same pressure plate, perform row clustering through adaptive coordinate transformation and normal interval overlap ratio, and distinguish between numbered rows and name rows according to row order, and finally output the number string, name string and engagement / disengagement status of each pressure plate.

2. The method according to claim 1, characterized in that, in: The target detection in step S11 adopts a deep learning-based target detection algorithm. The pressure plate detection box contains the position information and status information of the pressure plate. The status information includes the input status or the exit status. The optical character recognition in step S12 uses a deep learning-based OCR algorithm, and the OCR text label contains the label's location information and the recognized text content.

3. The method according to claim 2, characterized in that, The specific methods for constructing the "pressure plate row" in step S13 include: Set the "Not Added" status attribute for each pressure plate; Create a new "Plate Row" using any "Unadded" plate as the seed; Expand to the right and left respectively, with the following conditions: the pressure plate has not been added; the pressure plate overlaps with the seed pressure plate in the vertical direction, that is, the minimum value of the vertical coordinate of one is less than or equal to the maximum value of the vertical coordinate of the other, and its maximum value of the vertical coordinate is greater than or equal to the minimum value of the vertical coordinate of the other; and the pressure plate is located to the right or left of the current pressure plate, that is, the x-coordinate of its center point is greater than or less than the x-coordinate of the center point of the current pressure plate. Each expansion selects the nearest suitable pressure plate that meets the criteria, until no further expansion is possible; After traversing all the pressure plates, multiple "pressure plate rows" are obtained, and sorted in ascending order according to the y-coordinate of the center point of the first pressure plate in each row.

4. The method according to claim 3, characterized in that, The methods for dynamically defining the associated text label region in step S14 include: Perform vertical boundary calculations, including: The minimum vertical range is taken at 1 / 5 of the height of the current pressure plate detection frame, offset upwards from the lower boundary of the frame. The maximum vertical range value is initially set at half the height of the current pressure plate detection frame, which is offset downwards from the lower boundary of the current pressure plate detection frame. If there is a next row of pressure plates for the current pressure plate, and the upper boundary of the pressure plates in the same column of the next row is less than the initial value, then the maximum vertical range value is adjusted to the upper boundary value of the next row of pressure plates. Perform horizontal boundary calculations, including: The minimum horizontal range is initially set to the left of the current pressure plate detection frame, which is expanded to the left by 3 times the frame width. If the current pressure plate has an adjacent pressure plate on the left in the same row, it is adjusted to the midpoint between the left boundary of the current pressure plate and the right boundary of the adjacent pressure plate on the left. The maximum value of the horizontal range is initially taken as the right boundary of the current pressure plate detection frame expanded to the right by 3 times the frame width. If there is an adjacent pressure plate on the right in the same row, it is adjusted to the midpoint between the right boundary of the current pressure plate and the left boundary of the adjacent pressure plate on the right. Perform tag filtering, including: determining OCR text tags whose center point coordinates simultaneously meet the above vertical and horizontal ranges as belonging to the current pressure plate.

5. The method according to any one of claims 1 to 4, characterized in that, The specific methods for adaptive coordinate transformation, row clustering, and distinguishing between numbered rows and name rows in step S15 include: The coordinate transformation includes: among all the text labels belonging to the same pressure plate, select the label with the largest detection box width, take its bottom edge direction as the text line direction, take the lower left corner of the label as the origin, establish an inclined text line coordinate system, and convert the corner coordinates of all labels into normal coordinates and line coordinates, forming a normal interval and a line interval for each label. Perform row clustering, including: calculating the overlap length of the normal intervals of two labels, using the smaller of the heights of the normal intervals of the two labels as the denominator, calculating the overlap ratio, and if the overlap ratio is greater than 0.5, then the two labels are determined to be located on the same text line; Perform inter-row and intra-row sorting, including: grouping all rows, sorting the rows inter-row by using the median value of the normal coordinate of each label in each row to represent the position of the row, and sorting the rows within each row by using the median value of each label along the row direction coordinate. Distinguish between numbered rows and name rows, including: if only one row is formed after clustering, all labels in that row are determined as name labels, and the number string is empty; if two or more rows are formed after clustering, the first row after sorting is determined as the numbered label row, and all other rows are determined as name label rows. Perform string concatenation, including: for the identified number label row and name label row, concatenate the identification text of the labels in each row from left to right according to the row order, and output the number string and name string of the current pressure plate.

6. An information analysis system for a relay protection cabinet pressure plate, characterized in that, At least including: The image acquisition module is used to acquire the original image of the relay protection cabinet pressure plate; The target detection module is used to perform target detection on the original image and output multiple pressure plate detection boxes and the deployment / retraction status of each pressure plate; An optical character recognition module is used to perform optical character recognition on the original image and output multiple OCR text labels and the recognized text of each label; The row and column structure restoration module is used to construct multiple "pressure plate rows" based on the vertical overlap judgment between pressure plate detection frames and the nearest neighbor search, and to sort the pressure plates in each row by column to output the row and column structure of the pressure plates; The label attribution determination module is used to dynamically define the text label association area for each positioned row and column plate based on its relative position with the adjacent plate in the same row and the next row plate, and assign the OCR text label that falls into the area to the current plate. The number and name parsing module is used to perform row clustering on all text labels belonging to the same pressure plate through adaptive coordinate transformation and normal interval overlap ratio, and to distinguish between numbered rows and name rows according to row order. Finally, it outputs the number string, name string and engagement / disengagement status of each pressure plate.

7. The system according to claim 6, characterized in that, in: The target detection module adopts a deep learning-based target detection algorithm. The pressure plate detection box contains the position information and status information of the pressure plate. The status information includes the input status or the exit status. The optical character recognition module uses a deep learning-based OCR algorithm, and the OCR text label contains the label's location information and the recognized text content.

8. The system according to claim 7, characterized in that, The row and column structure restoration module includes: The state initialization unit is used to set the "not added" state for each pressure plate; The row building unit is used to expand to the right and left to build "pressing plate rows" with "unadded" pressing plates as seeds. The expansion conditions include vertical overlap determination, direction determination and nearest neighbor selection. The row sorting unit is used to sort the "pressing plate rows" in ascending order of the ordinate of the center point of the first pressing plate in each row.

9. The system according to claim 8, characterized in that, The tag attribution determination module includes: The vertical boundary calculation unit is used to dynamically calculate the upper and lower boundaries of the associated area based on the current pressure plate frame height and the position of the next row of pressure plates. The minimum value of the vertical range is taken as 1 / 5 of the frame height offset upward from the current lower boundary of the pressure plate, and the maximum value of the vertical range is dynamically adjusted according to the upper boundary of the next row of pressure plates. The horizontal boundary calculation unit is used to dynamically calculate the left and right boundaries of the associated area based on the position of the current pressure plate and the adjacent pressure plates on the left and right. The horizontal boundary is taken as the midpoint between the current pressure plate boundary and the adjacent pressure plate boundary. The label filtering unit is used to determine whether the center point of the OCR label falls within the dynamically associated area.

10. The system according to any one of claims 6 to 9, characterized in that, The number and name parsing module includes: The coordinate transformation unit is used to transform the coordinates of all label corner points to the slanted text line coordinate system, taking the bottom edge direction of the label with the largest width among all text labels belonging to the same pressure plate as the text line direction. Row clustering units are used to group labels by row based on whether the overlap ratio of normal intervals is greater than 0.5; The row and column sorting unit is used to sort rows and columns within rows. The row role determination unit is used to determine the first row as the number row and the remaining rows as the name row; The string concatenation unit is used to concatenate recognized text from left to right in line order, and output the number string and the name string; The output integration unit is used to integrate the number string, name string, and engagement / disengagement status of each pressure plate into structured data output.