A method for digital storage of relay protection setting sheets

By digitally parsing and structurally storing PDF setting sheets, the problem of inconsistencies in setting sheets in the power grid was solved, thus ensuring the accuracy of relay protection devices and the stability of the power grid.

CN115470213BActive Publication Date: 2026-03-31STATE GRID CHONGQING ELECTRIC POWER COMPANY +1
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-15
Publication Date
2026-03-31

AI Technical Summary

Technical Problem

In the existing technology, the setting sheets of power grid relay protection devices are inconsistent between different systems, which leads to safety hazards and cannot guarantee the stable operation of the power grid.

Method used

By digitally parsing PDF value sheets, designing database table structures, converting table data into JSON arrays, and storing them in a structured manner, consistency of values ​​across systems is ensured.

Benefits of technology

This ensures the accuracy and consistency of relay protection device setting data, avoids errors in setting sheets across different systems, and ensures the safe and stable operation of the power grid.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115470213B_ABST
    Figure CN115470213B_ABST
Patent Text Reader

Abstract

The application discloses a method for digital storage of relay protection setting value single, which comprises the following steps: combing the style of a PDF setting value single, making different analysis templates, converting table data in the PDF into JSON array data, storing the distance of each upper left corner, i.e. latitude and longitude, the width and height of each itself and the grid content in the JSON data, obtaining corresponding data through position characteristics, and performing structured storage. Through the digital storage of the protection setting value single, the application verifies the correctness of the protection setting value of the relay protection setting system and the protection signal system, so as to ensure the consistency and accuracy of the setting value between the systems.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of power grid dispatching and management technology, specifically a method for digital storage of relay protection setting sheets. Background Technology

[0002] When a fault occurs in the power grid or electrical equipment, or when an abnormal situation arises that affects the safe operation of the power grid, the relay protection device will automatically disconnect the faulty equipment and eliminate the abnormal situation. Therefore, the relay protection device plays a crucial role in ensuring the safe and stable operation of the power grid. The collection and setting calculation of relay protection parameters are important conditions for ensuring the safe operation of the power grid. Errors in the settings may lead to malfunctions or failures to operate of the relay protection device, thereby causing the power grid accident to escalate or damaging power equipment, seriously threatening the safe operation of the power grid.

[0003] In recent years, to improve the automation level of relay protection operation and management, the power sector has successively developed related software such as relay protection setting calculation systems, protection information systems, and setting sheet management systems. Power workers perform setting calculations in the production control area, generate setting sheets in PDF format, and publish them to the setting sheet management system in the information management area, initiating the setting sheet review process. However, in actual production, the setting values ​​are sometimes modified offline during the setting sheet review, leading to inconsistencies between setting values ​​in multiple systems and posing certain safety hazards. Summary of the Invention

[0004] To address the shortcomings of existing technologies, this invention proposes a digital storage method for relay protection setting sheets. This method digitizes and stores the final PDF setting sheet uploaded during the setting sheet review process, resolving inconsistencies between online and offline protection setting sheets in relay protection operation and setting sheet management software. Through mutual verification of data from multiple systems, the consistency of relay protection setting data across systems is ensured.

[0005] To achieve the above objectives, the present invention provides the following technical solution: a method for digitally storing relay protection setting sheets, comprising the following steps:

[0006] S1. Analyze the style of PDF value sheets, formulate parsing templates for different styles, and design the database table structure;

[0007] S2. Convert the table data in the PDF into JSON array data. The JSON data stores the distance of each element from the top left corner, i.e., latitude and longitude, as well as its width, height, and cell content.

[0008] S3. Obtain the corresponding data through location features and store it in a structured manner.

[0009] Furthermore, in step S1, the content defined for the fixed value sheet format includes basic information, fixed values, and remarks.

[0010] Furthermore, the basic information and remarks are set as the main table, the fixed value is set as the secondary table, and the remarks are defined as the part of the content whose cell width accounts for more than 90% of the total table width.

[0011] Further, in step S2, converting the table data in the PDF into JSON array data includes the following sub-steps:

[0012] a. Call the method in the CommandLineAPP class in the "tabula-java" jar package to convert the table data in the PDF document into a JSON array;

[0013] b. Perform preliminary filtering on the JSON array data to remove records with empty data during parsing;

[0014] c. Parse the contents of the basic information section. The basic information section in the value sheet includes attribute fields and attribute values.

[0015] d. Parse the contents of the fixed value section. The fixed value section in the fixed value sheet defines the table header and table items. The table header is the attribute field and the table item is the attribute value. The data format of the fixed value item includes the case where there are two sets of fixed values ​​in each row and the case where there is only one set of fixed value parameters in each row.

[0016] e. Parse the notes data. The notes data usually do not have corresponding keywords, but the notes part usually occupies a lot of space. When retrieving values, iterate through the JSON array and record the part that meets the condition that the width / table width is greater than 85% as the notes part.

[0017] Furthermore, when parsing a single set of fixed values, by using the header information data of the fixed value item obtained in step c, it is determined that there is only a single set of "serial number", "fixed item" and "fixed value". According to the starting position of the fixed value, the JSON array data is traversed sequentially, and the data with the same distance from the left side of the header and the same width are recorded to obtain the fixed value details data. If it contains a "unit" field, the data of the two cells of fixed value and unit need to be assembled and concatenated.

[0018] Furthermore, when parsing the two sets of repeated fixed values, the header information data of the fixed value item obtained in step c is used to determine if there are duplicate columns for "serial number", "fixed item" and "fixed value". According to the starting position of the fixed value, the JSON array data is traversed sequentially to obtain the first set of fixed value data. Data with the same distance from the left side of the header and the same width are recorded. After obtaining the first set of fixed value data, the above operation is repeated. Starting from the starting row of the fixed value data, the second set of fixed value data is traversed and recorded. If it contains the "unit" field, the data of the two cells of fixed value and unit need to be assembled and concatenated.

[0019] Compared with the prior art, the beneficial effects of the present invention are: by digitally storing the protection setting sheet, the correctness of the protection setting of the relay protection setting system and the protection information system can be verified in reverse, thereby ensuring the consistency and accuracy of the setting between the systems. Attached Figure Description

[0020] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used together with the embodiments of the invention to explain the invention and do not constitute a limitation thereof.

[0021] In the attached diagram:

[0022] Figure 1 This is the overall flowchart of the present invention;

[0023] Figure 2 This is a flowchart of the sub-items of the present invention;

[0024] Figure 3 This is a diagram of the interface of the fixed value sheet of the present invention;

[0025] Figure 4 This is a JSON array information diagram of the present invention.

[0026] Figure 5 This is a diagram of the empty record interface of the present invention;

[0027] Figure 6 This is a schematic diagram of the basic information parsing part of the present invention;

[0028] Figure 7 This is a schematic diagram of a single set of fixed values ​​in this invention;

[0029] Figure 8 This is a schematic diagram of a single set of fixed values ​​and two sets of fixed values ​​according to the present invention. Detailed Implementation

[0030] The preferred embodiments of the present invention will be described below with reference to the accompanying drawings. It should be understood that the preferred embodiments described herein are for illustration and explanation only and are not intended to limit the present invention.

[0031] Example: Figure 1and Figure 2 As shown, a method for digitally storing relay protection setting sheets includes the following steps:

[0032] Step 1: Organize the format of the PDF value sheet and design the database table structure.

[0033] In step 1.1, the format of the fixed value sheet is defined, consisting of three parts: basic information, fixed value, and remarks. Figure 3 As shown, the basic information is defined as including parts such as "plant name", "protection model", "setting sheet number", "protection equipment", "switch number", "CT ratio", "PT ratio", and "reason for change"; the setting is defined as including parts such as "serial number", "setting item", and "setting value"; and the remarks are defined as the part whose cell width accounts for more than 90% of the total table width.

[0034] In step 1.2, the database table structure is designed. The basic information and remarks are set as the main table, and the attribute fields include: plant name, protection model, setting sheet number, protection equipment, switch number, CT ratio, PT ratio, remarks, setting sheet PDF file name (to facilitate later comparison and verification of the extracted data with the setting sheet); the setting is set as the secondary table, and the attribute fields include: serial number, setting item, setting value, and the ID of the parent table.

[0035] Step 2: Parse the table data in the PDF.

[0036] In step 2.1, the method in the CommandLineAPP class of the "tabula-java" jar package is called to convert the table data in the PDF document into a JSON array. Each JSON array stores the latitude, longitude, width, height, and text information of each cell, such as... Figure 4 As shown.

[0037] In step 2.2, the JSON array data is initially filtered to remove records with empty data during parsing, such as... Figure 5 As shown, for example: {'top':0,'left':0,'width':0,'height':0,'text':0}.

[0038] In step 2.3, the content of the basic information section is parsed. The basic information section of the value sheet includes attribute fields and attribute values. Each JSON array is defined as a group by rows, and each group is represented by []. Each group of JSON arrays is traversed. When the text content of a certain JSON is a basic information field, the text content of the cell immediately following the field is determined to be the attribute value. For example... Figure 6 As shown.

[0039] In step 2.4, the content of the fixed value section is parsed. The fixed value section of the fixed value sheet defines the table header and table items, where the table header is the attribute field and the table item is the attribute value. The position of the table header and the width of its cell are obtained. The JSON array is traversed to obtain and record the latitude and longitude, cell width, and starting line number of the fixed value content for the fixed value header keywords such as "Serial Number," "Fixed Item," and "Fixed Value." The fixed value data exists in two formats: one where there are two sets of fixed values ​​per row, and the other where there is only one set of fixed value parameters per row.

[0040] In step 2.4.1, the single set of constant values ​​is analyzed, such as... Figure 7 As shown, by using the header information data of the fixed value item obtained in step 2.3, it is determined that there is only a single group of "serial number", "fixed item" and "fixed value". According to the starting position of the fixed value, the JSON array data is traversed in sequence, and the data with the same distance from the left side of the header and the same width are recorded to obtain the fixed value details data. If it contains the "unit" field, the data of the two cells of fixed value and unit need to be assembled and concatenated.

[0041] In step 2.4.2, the two sets of constant values ​​are analyzed repeatedly, such as... Figure 8 As shown, by using the header information data of the fixed value items obtained in step 2.3, it is determined that there are duplicate columns in "Serial Number", "Fixed Item", and "Fixed Value". According to the starting position of the fixed value, the JSON array data is traversed sequentially to obtain the first set of fixed value data. The data with the same distance from the left side of the header and the same width are recorded. After obtaining the first set of fixed value data, the above operation is repeated. Starting from the starting row of the fixed value data, the second set of fixed value data is traversed to obtain and record. If it contains the "Unit" field, the data of the two cells of fixed value and unit need to be assembled and concatenated.

[0042] In step 2.5, the notes data is parsed. The notes data usually does not have corresponding keywords, but the notes part usually occupies a lot of space. When retrieving the values, the JSON array is traversed and looped, and the part that meets the condition that the width / table width is greater than 85% is recorded as the notes part.

[0043] Step 3: Based on Step 2, store the parsed PDF value sheet data.

[0044] In step 3.1, the attribute values ​​corresponding to the attribute fields such as plant name, protection model, setting sheet number, protection equipment, switch number, CT ratio, PT ratio, setting sheet file, and remarks are stored in the main table, and empty values ​​are stored for those fields that do not have corresponding fields.

[0045] In step 3.2, the serial number, the set item, and the attribute value of the set value are stored in the slave table, and the master table ID is automatically generated to establish the master-slave table relationship.

[0046] Finally, it should be noted that the above descriptions are merely preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A method for digitizing storage of relay protection setting values, characterized by, The method comprises the following steps: S1, carding PDF fixed value single style, making different style analysis template, designing database table structure; S2, converting table data in PDF into JSON array data, storing the distance from each respective upper left corner in JSON data, i.e. latitude and longitude, respective width, height and grid content; S3, obtaining corresponding data through position characteristics and performing structured storage; In step S2, converting table data in PDF into JSON array data comprises the following sub-steps: a, calling the method in the CommandLineAPP class in the tabula-javajar package to convert table data in the PDF document into a JSON array; b, performing preliminary filtering on the JSON array data to remove records with empty data in the parsing; c, parsing the content of the basic information part, the basic information part of the fixed value single includes attribute fields and attribute values; d, parsing the content of the fixed value part, the fixed value part of the fixed value single defines table headers and table items, wherein the table header is an attribute field, and the table item is an attribute value, wherein the fixed value item data format includes the case of two groups of fixed values in each row and the case of only one group of fixed value parameters in each row; e, parsing the remark data, traversing the JSON array when taking values, and recording the part with a width / table width greater than 85% as a remark part; When parsing a single group of fixed values, the fixed value item header information data obtained in step c is used to determine that there is only a single group, the JSON array data is traversed according to the fixed value starting position, the data corresponding to the same distance from the left side and the same width of the table header is recorded, the fixed value detail data is obtained, and if the unit field is included, the data of the two cells of the fixed value and the unit are assembled and spliced; When parsing two groups of repeated fixed values, the fixed value item header information data obtained in step c is used to determine that there are repeated columns, the JSON array data is traversed according to the fixed value starting position, the first group of fixed value data is obtained by recording the data corresponding to the same distance from the left side and the same width of the table header, and after the first group of fixed value data is obtained, the same operation process as the first group of fixed value data is repeated to traverse and obtain the second group of fixed value data from the fixed value data starting row, and if the unit field is included, the data of the two cells of the fixed value and the unit are assembled and spliced.

2. The method for digital storage of relay protection setting value single according to claim 1, characterized in that: In step S1, the content of defining the fixed value single format includes basic information, fixed value and remark.

3. The method of claim 2, wherein: the digital storage of the relay protection setting values is performed by a microprocessor. The basic information and the remark are set as the main table, the fixed value is set as the slave table, and the remark is defined as the part with a grid width ratio greater than 90% of the entire table width.

Citation Information

Patent Citations

  • Method and system for processing relay protection constant value list in PDF format

    CN112528832A