Patrol and maintenance data anomaly detection method and device, electronic equipment and storage medium

By introducing automated inspection and abnormal detection methods for patrol data in power grid management, the problems of low efficiency and high error rate of manual entry and review are solved, and automated data reading and abnormal detection are realized, which improves the safety and reliability of power grid operation. .

CN119396678APending Publication Date: 2025-02-07BAOSHAN POWER SUPPLY BUREAU OF YUNNAN POWER GRID CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411269739.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-11
Publication Date
2025-02-07

AI Technical Summary

Technical Problem

The prior art relies on manual entry and review in power grid management, resulting in inefficiency, high error rate and long data processing cycles, which may lead to response delays and grid operation risks in emergency situations.

Method used

It provides an abnormal detection method and device for abnormality detection of dimension patrol data, which responds to page browsing operations through automated detection technology, detects page types, analyzes page structure, recognizes visible content elements, and performs abnormal detection according to preset mode patrol detection strategies.

Benefits of technology

It realizes automatic reading of patrol and dimension data, reduces manual input and detection workload, reduces error rate, improves the efficiency and accuracy of data inspection, and ensures the safety and reliability of power grid operation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119396678A_ABST
    Figure CN119396678A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses a patrol and maintenance data anomaly detection method and device, electronic equipment and a storage medium, and the method comprises the steps: responding to a page browsing operation, and detecting whether the page type of a target page corresponding to the page browsing operation is a target type or not; when it is detected that the page type of the target page is the target type, analyzing the page structure of the target page; identifying visible content elements of the target page based on the page structure; and performing anomaly detection on the visible content elements according to a preset patrol and maintenance detection strategy. According to the scheme, the patrol and maintenance data anomaly detection efficiency and accuracy can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a method, device, electronic device and storage medium for detecting anomalies in patrol and maintenance data. Background Art

[0002] With the rapid development of information technology, power grid companies are undergoing an unprecedented digital transformation, which not only involves the collection, storage and processing of data, but also includes the in-depth analysis and application of these data to improve the operating efficiency and reliability of the power grid. The core of digital transformation is to achieve automated data management and intelligent decision support, which is crucial to improving the operation and maintenance management level of the power grid.

[0003] In this context, power grid companies have accumulated a large amount of operating data, including but not limited to equipment status monitoring data, environmental monitoring data, energy consumption data, etc. These data are of great value for the stable operation and preventive maintenance of the power grid. However, with the surge in data volume, the traditional manual data entry and management methods have been unable to meet the needs of modern power grid management. The manual entry method of existing technologies is not only inefficient, but also prone to errors, which directly affects the quality of data and the safety of power grid operation.

[0004] In addition, existing technologies often rely on complex processes and multiple rounds of manual review when processing large-scale data, which not only increases the workload but also prolongs the data processing cycle. In an emergency, this inefficient data management method may lead to delayed response and increase the risk of power grid operation. Summary of the invention

[0005] The embodiments of the present application provide a patrol data anomaly detection system, method, electronic device and storage medium, which can realize automatic reading of patrol data, reduce the workload of manual input and detection, thereby greatly reducing the error rate caused by manual operation, and at the same time, improve the efficiency of patrol data anomaly detection.

[0006] In a first aspect, an embodiment of the present application provides a method for detecting anomalies in patrol and maintenance data, including:

[0007] In response to a page browsing operation, detecting whether a page type of a target page corresponding to the page browsing operation is a target type;

[0008] When it is detected that the page type of the target page is the target type, parsing the page structure of the target page;

[0009] Identifying visible content elements of the target page based on the page structure;

[0010] The visible content elements are detected for abnormalities according to a preset patrol and maintenance detection strategy.

[0011] Optionally, in some embodiments of the present application, the identifying the visible content elements of the target page based on the page structure includes:

[0012] Based on the page structure and the element recognition method of the preset programming language, identifying candidate elements in the target page;

[0013] Detecting whether the candidate element is visible;

[0014] The visible candidate element is determined as a visible content element of the target page.

[0015] Optionally, in some embodiments of the present application, the detecting whether the candidate element is visible includes:

[0016] Detecting whether the element layout information corresponding to the candidate element has a non-zero size;

[0017] When it is detected that the element layout information corresponding to the candidate element has a non-zero size, the candidate element is determined to be a visible candidate element;

[0018] When it is detected that the element layout information corresponding to the candidate element does not have a non-zero size, the candidate element is determined to be an invisible candidate element.

[0019] Optionally, in some embodiments of the present application, the detecting whether the candidate element is visible includes:

[0020] Acquire the position information of the candidate element on the target page in a preset manner;

[0021] Determining whether the candidate element is within the current viewport of the target page according to the position information;

[0022] If the candidate element is within the current viewport of the target page, determining that the candidate element is a visible candidate element;

[0023] If the candidate element is not within the current viewport of the target page, the candidate element is determined to be an invisible candidate element.

[0024] Optionally, in some embodiments of the present application, the performing abnormality detection on the visible content element according to a preset patrol detection strategy includes:

[0025] Obtain the preset patrol and maintenance detection strategy;

[0026] Determining patrol and maintenance attributes detected by the patrol and maintenance detection strategy;

[0027] Anomaly detection is performed on the visible content element according to the patrol attribute.

[0028] Optionally, in some embodiments of the present application, the performing abnormality detection on the visible content element according to the patrol attribute includes:

[0029] Determining element information corresponding to the visible content element;

[0030] Check whether the element information satisfies the patrol condition corresponding to the patrol attribute.

[0031] Optionally, in some embodiments of the present application, the method further includes:

[0032] Create a plugin folder;

[0033] Create a metadata description file and a script file in the plug-in folder;

[0034] The identifying of the visible content elements of the target page based on the page structure includes: identifying the visible content elements of the target page based on the page structure, a metadata description file and a script file. In a second aspect, an embodiment of the present application provides a patrol data anomaly detection device, including:

[0035] A page detection module, used for detecting, in response to a page browsing operation, whether a page type of a target page corresponding to the page browsing operation is a target type;

[0036] A parsing module, configured to parse the page structure of the target page when detecting that the page type of the target page is a target type;

[0037] An identification module, configured to identify visible content elements of the target page based on the page structure;

[0038] The anomaly detection module is used to perform anomaly detection on the visible content elements according to a preset patrol detection strategy.

[0039] Correspondingly, the present application also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the steps of any of the above methods when executing the program.

[0040] The present application also provides a storage medium, wherein the storage medium stores a computer program, and the computer program implements any of the above methods when the computer program is executed by a processor.

[0041] The present application provides a patrol data anomaly detection method, device, electronic device and storage medium. First, in response to a page browsing operation, it is detected whether the page type of the target page corresponding to the page browsing operation is the target type; then, when it is detected that the page type of the target page is the target type, the page structure of the target page is parsed; then, the visible content elements of the target page are identified based on the page structure; finally, the visible content elements are detected for anomalies according to a preset patrol detection strategy. In the patrol data anomaly detection scheme provided in the present application, the automatic reading of patrol data is realized by seamlessly integrating the automated detection technology into the existing power grid management platform, reducing the need for manual input, thereby greatly reducing the error rate caused by manual operation; the read data is analyzed in real time by an intelligent algorithm, and abnormal data points are quickly identified, which not only improves the efficiency of data inspection, but also improves the guarantee of data accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.

[0043] Figure 1 It is a flowchart of a method for detecting anomalies in patrol and maintenance data provided by an embodiment of the present application;

[0044] Figure 2 It is a flowchart of a specific implementation method of the patrol maintenance data anomaly detection method provided in an embodiment of the present application;

[0045] Figure 3 It is a structural schematic diagram of a patrol and maintenance data anomaly detection device provided in an embodiment of the present application;

[0046] Figure 4 It is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0047] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present application. Instead, they are merely examples of systems and methods consistent with the examples detailed in the attached claims, or with some aspects of the present application.

[0048] It should be noted that, in this article, the terms "include", "comprises" or any other variants thereof are intended to cover descriptions such as non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "includes a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element. In addition, components, features, and elements with the same name in different embodiments of the present application may have the same meaning or different meanings, and their specific meanings need to be determined by their explanation in the specific embodiment or further combined with the context of the specific embodiment.

[0049] It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0050] In the subsequent description, the suffixes such as "module", "component" or "unit" used to represent elements are only used to facilitate the description of the present application, and have no specific meanings. Therefore, "module", "component" or "unit" can be used in a mixed manner.

[0051] Embodiments of the present application provide a method, device, electronic device, and storage medium for detecting anomalies in patrol and maintenance data.

[0052] Among them, the patrol and maintenance data anomaly detection device can be deployed in a terminal or a server. The server can include an independently running server or a distributed server, or a server cluster composed of multiple servers. The terminal can include a mobile phone, a tablet computer or a personal computer (PC, Personal Computer).

[0053] It should be noted that the order of description of the following embodiments is not intended to limit the priority order of the embodiments.

[0054] The present application provides a patrol data anomaly detection method, comprising: in response to a page browsing operation, detecting whether the page type of a target page corresponding to the page browsing operation is a target type; when it is detected that the page type of the target page is the target type, parsing the page structure of the target page; identifying visible content elements of the target page based on the page structure; and performing anomaly detection on the visible content elements according to a preset patrol detection strategy.

[0055] See also Figure 1 , Figure 1 : is a flow chart of the patrol data anomaly detection method provided by the present application, and the patrol data anomaly detection method specifically includes the following process:

[0056] S1. In response to a page browsing operation, detecting whether a page type of a target page corresponding to the page browsing operation is a target type;

[0057] Specifically, for step S1, when the user accesses the patrol data page of the power grid management platform through a browser, the plug-in is triggered and starts to respond to the page browsing operation. This step is the starting point of the entire anomaly detection process, ensuring that the plug-in can intervene in the data inspection process at the appropriate time.

[0058] In a specific embodiment, the plug-in first identifies whether the current page is a target page that needs to be inspected for patrol data, for example, by analyzing the URL, title or other features of the page, to ensure that the plug-in only runs in the correct context.

[0059] S2. When it is detected that the page type of the target page is the target type, the page structure of the target page is parsed;

[0060] Specifically, for step S2, when the page type of the target page is detected to be the target type, that is, the page is confirmed to be a patrol data page, the plug-in will parse the HTML structure of the page and identify the data elements contained in the page. This step involves the operation of DOM (Document Object Model), and the plug-in analyzes the DOM tree of the page and locates the HTML element storing the patrol data.

[0061] S3, identifying visible content elements of the target page based on the page structure;

[0062] Specifically, for step S3, the plug-in identifies all visible patrol data elements based on the parsed page structure. The patrol data elements may specifically include tables, text fields, or other data display forms. During the identification process, the plug-in will apply a specific algorithm to determine whether the element is visible, for example, by checking the size, position, or CSS (Cascading Style Sheets) attributes of the element.

[0063] S4. Perform anomaly detection on visible content elements according to a preset patrol and maintenance detection strategy;

[0064] Specifically, for step S4, the visible content elements are detected for anomalies according to the preset patrol detection strategy. For all identified visible content elements, the plug-in will apply the preset patrol detection strategy. The patrol detection strategy can be based on historical data, industry standards or expert experience to define the reasonable range or logical relationship of the data. When it is detected that the value of the element does not meet the preset patrol detection strategy, the plug-in will mark these abnormal data on the page in red or other eye-catching ways, so that the data filler can quickly identify and correct the error.

[0065] It should be noted that the technical implementation of the plug-in in this embodiment includes creating a plug-in directory, writing a manifest.xml configuration file and a JavaScript script. The manifest.xml file defines the basic information and permissions of the plug-in, while the JavaScript script is the core of data reading, analysis and abnormal annotation.

[0066] It can be seen that the patrol and maintenance data anomaly detection method provided in this embodiment can reduce human errors and ensure the accuracy of data through automated detection, thereby improving the safety and reliability of power grid operation; the automated process significantly reduces the time and workload required for manual inspection, making the inspection of patrol and maintenance data faster and more efficient; it reduces dependence on human resources, reduces the additional costs caused by improper manual operation, and achieves cost-effectiveness optimization; the application of the plug-in improves the data management capabilities of power grid companies, making data management more standardized and systematic; by reducing the workload of users in data inspection, the plug-in improves the user experience, allowing users to focus more on data analysis and decision-making.

[0067] Optionally, in some embodiments, step S3 “identifying visible content elements of the target page based on the page structure” may specifically include:

[0068] S31, identifying candidate elements in the target page based on the element identification method of the page structure and the preset programming language;

[0069] S32, detecting whether the candidate element is visible;

[0070] S33: Determine the visible candidate element as a visible content element of the target page.

[0071] Specifically, for step S3, the process of identifying visible content elements of the target page is as follows: First, the plug-in needs to identify all candidate elements that may contain patrol data in the target page. For example, the tags in the HTML document are scanned, and possible data carriers are screened out according to the preset programming language element recognition method, such as <input> , 、 Etc. Then, after identifying the candidate elements, the plug-in will perform visibility detection. This step is crucial because only visible elements are meaningful to users and may be patrol data that need to be detected. Visibility detection can be performed in two ways: layout information detection and viewport position detection. The layout information detection method checks the layout information of the element, such as width and height, to determine whether the element has a non-zero size, thereby determining whether the element is visible. The viewport position detection method obtains the position information of the element in the page and determines whether the element is located in the current viewport (that is, the visible area of ​​the user's screen) to determine its visibility.

[0072] Finally, based on the above detection results, the plug-in will determine which candidate elements are visible and use them as targets for patrol data anomaly detection, ensuring that the plug-in only detects data that is actually displayed to the user, thereby improving the pertinence and accuracy of the detection.

[0073] It should be noted that to implement the above process, you need to write corresponding JavaScript code and use the DOM API to access and operate page elements. For example, use the getBoundingClientRect() method to obtain the position and size information of the element, and use the clientWidth and clientHeight properties to determine whether the element has a non-zero size.

[0074] By accurately identifying visible elements, this embodiment can prevent the plug-in from erroneously detecting hidden or invisible elements, thereby improving the accuracy of anomaly detection; only detecting visible elements reduces unnecessary calculations and resource consumption, and improves the plug-in's operating efficiency. By quickly and accurately identifying and detecting visible data, the plug-in reduces the user's workload on data checking and improves the user experience; the plug-in can also promptly identify and detect dynamically loaded or changed content, ensuring real-time monitoring of the latest data; by focusing only on visible elements, the plug-in can complete data detection tasks more quickly, improving the overall efficiency of data processing; accurately identifying visible elements helps reduce false positives caused by detecting irrelevant or hidden elements, ensuring the reliability of detection results.

[0075] Optionally, in some embodiments, step S32 “detecting whether the candidate element is visible” may specifically include:

[0076] S321, detecting whether the element layout information corresponding to the candidate element has a non-zero size;

[0077] S322: When it is detected that the element layout information corresponding to the candidate element has a non-zero size, the candidate element is determined to be a visible candidate element;

[0078] S323: When it is detected that the element layout information corresponding to the candidate element does not have a non-zero size, the candidate element is determined to be an invisible candidate element.

[0079] Specifically, the specific process of detecting whether a candidate element is visible in this embodiment is as follows: after identifying the candidate elements in the page, the plug-in will first detect the layout information of each candidate element, and determine whether the element is visible by obtaining the layout attributes of the element, such as width (width), height (height), and whether CSS styles such as display:none or visibility:hidden are applied; then, the plug-in checks the layout information of each candidate element to determine whether its size is non-zero. If the element has a non-zero width and height, this usually means that the element is visible on the page. This judgment process can be implemented by element.offsetWidth>0&&element.offsetHeight>0 in JavaScript. Then, when the layout information of the element shows that it has a non-zero size, the plug-in marks the candidate element as visible. This means that the element can be seen by the user in the current page view and may contain patrol data that needs to be detected. Finally, for elements whose layout information shows zero size, the plug-in will consider them invisible and exclude them from the list of candidate elements for abnormal detection, thereby ensuring that the plug-in does not waste time and resources to detect data that is not displayed to the user.

[0080] It should be noted that the above process requires writing JavaScript code to access the style and size attributes of page elements using DOM API technology. In a specific embodiment, for example, window.getComputedStyle(element) can be used to obtain the actual style of an element, including its width and height.

[0081] By excluding invisible elements, the plug-in in this embodiment ensures that anomaly detection is performed only on data actually displayed to the user, thereby improving the accuracy of detection; avoiding invalid detection of invisible elements, reducing the amount of calculation, and improving the operating efficiency and response speed of the plug-in; focusing on the detection of visible elements, reducing the impact on browser performance, especially when processing large amounts of data or complex page layouts; completing detection tasks quickly and accurately, reducing user waiting time, and improving users' overall satisfaction with the power grid management platform; accurately identifying visible elements helps reduce false alarms, while ensuring that all visible patrol and maintenance data are detected, reducing the possibility of missed alarms; for content dynamically added to the page through JavaScript, the plug-in can also accurately identify its visibility and perform corresponding anomaly detection.

[0082] Optionally, in some embodiments, step S32 of “detecting whether the candidate element is visible” may further include:

[0083] S324, obtaining the position information of the candidate element on the target page in a preset manner;

[0084] S325, determining whether the candidate element is within the current viewport of the target page according to the position information;

[0085] S326: If the candidate element is within the current viewport of the target page, determine that the candidate element is a visible candidate element;

[0086] S327: If the candidate element is not within the current viewport of the target page, determine that the candidate element is an invisible candidate element.

[0087] Specifically, this embodiment also provides another method for detecting whether a candidate element is visible. The specific process is as follows: First, the position information of each candidate element on the target page is obtained through the plug-in. The position information can specifically include the coordinate position of the element, such as the distance between the element and the top and left of the page. The acquisition method can be implemented by the element.getBoundingClientRect() method. Then, the obtained position information is used by the plug-in to determine whether the candidate element is located in the current viewport. Among them, the viewport in this embodiment refers to the page area that the user can currently see, excluding the part hidden by the scroll bar. If the position information of the candidate element indicates that it is in the viewport, the plug-in will determine that the element is visible, which means that the user can see this element without scrolling the page. If the candidate element is not in the viewport, the plug-in will consider it invisible and will not use it as an object of abnormal detection. This can avoid invalid detection of data that the current user cannot see.

[0088] It should be noted that the implementation of the above process requires JavaScript code, which can process the position information of the DOM element and compare it with the size and position of the viewport. For example, visibility can be determined by comparing the coordinates of the element with its position in the viewport.

[0089] This embodiment improves the accuracy of detection and avoids invalid detection of invisible elements by ensuring that only elements within the current viewport are detected; reduces the comprehensive scan of all elements on the page and only focuses on the parts that the current user can see, thereby optimizing performance and response speed; focuses on elements within the current viewport, reduces unnecessary calculations and memory usage, and improves the operating efficiency of the plug-in; quickly responds to user operations and performs instant detection of visible data, thereby enhancing the user's interactive experience; the plug-in can adapt to page scrolling and other dynamic changes, and always only detects elements within the current viewport to ensure the timeliness and relevance of detection; accurately identifying elements within the current viewport helps reduce false alarms caused by detecting invisible or hidden elements; for content that appears after dynamic loading or user scrolling, the plug-in can update the detection range in a timely manner to ensure that all elements entering the viewport can be detected.

[0090] Optionally, in some embodiments, step S4 "performing abnormality detection on visible content elements according to a preset patrol detection strategy" may specifically include:

[0091] S41, obtaining a preset patrol and maintenance detection strategy;

[0092] S42, determining the patrol and maintenance attributes detected by the patrol and maintenance detection strategy;

[0093] S43: Perform anomaly detection on visible content elements according to patrol attributes.

[0094] Specifically, the specific process of abnormality detection for visible content elements in this embodiment is as follows: First, the preset patrol detection strategy is obtained through the plug-in. The patrol detection strategy can be formulated according to the professional standards and experience of power grid operation, and is used to guide the specific rules and thresholds for abnormality detection; then, according to the obtained patrol detection strategy, the plug-in will determine the patrol attributes that need to be detected, and the patrol attributes can specifically include key parameters such as voltage, current, temperature, and pressure of the equipment; then, the plug-in will analyze the page content elements that have been determined to be visible to determine the specific data and attributes corresponding to these elements; then, for each visible content element, the plug-in will perform abnormality detection according to the preset patrol attributes and detection strategy. This may include data range checking, trend analysis, threshold comparison, etc.; finally, the plug-in detects the information of each element, such as the value size, change rate, etc., and matches this information with the patrol conditions to determine whether there is an abnormality.

[0095] It should be noted that the above process requires writing JavaScript code, which can read the value of the page element, perform logical judgment, and compare it with the preset inspection conditions. For example, you can use element.innerText to obtain the text content of the element, and then use the written function to analyze whether the text content meets the expected numerical range or logical condition.

[0096] In this embodiment, by performing anomaly detection according to professional standards, the plug-in can ensure the accuracy of data and promptly discover and correct data entry errors; automated anomaly detection provides real-time data monitoring capabilities, allowing power grid operation and maintenance personnel to quickly respond to potential data problems; automated detection reduces the need for manual inspection and greatly improves detection efficiency, especially when processing large amounts of data; reduces the cost and time of manual inspection, while reducing potential risks and costs caused by data errors; quickly feeds back abnormal information, allowing users to correct data in a timely manner, optimizing the user experience when using the power grid management platform; accurate data detection supports data-based decision-making and provides reliable data support for power grid operation and maintenance; the implemented patrol and maintenance detection strategy helps to promote technical standardization of data detection within the industry and improve the data processing level of the entire industry; by promptly discovering data anomalies, the risk of power grid operation caused by data errors is reduced, and the reliability and security of the system are improved.

[0097] Optionally, in some embodiments, step S43 "performing abnormality detection on visible content elements according to patrol attributes" may specifically include:

[0098] S431, determining element information corresponding to the visible content element;

[0099] S432: Check whether the element information satisfies the patrol and maintenance conditions corresponding to the patrol and maintenance attributes.

[0100] Specifically, for step S43, first, the element information corresponding to each visible content element is determined by the plug-in. The element information may specifically include obtaining the text value, numerical value, or other data form of the element; then, for each element, the plug-in will establish its corresponding relationship with a specific patrol attribute. For example, if the element displays a voltage reading, it will be associated with a patrol attribute related to voltage. In addition, the patrol condition can also be set by the plug-in according to the preset patrol detection strategy. The patrol condition is used to define whether the element information is within the normal range, for example, the voltage value should be within a specific threshold; then, the abnormality detection logic is implemented by the plug-in, which compares the element information with the patrol condition. If the element information does not meet the preset conditions, the plug-in will judge it as abnormal; finally, once an abnormality is detected, the abnormal data is marked by the plug-in, such as by changing the text color, adding a special icon, or popping up a warning box, so that the user can immediately notice it.

[0101] It should be noted that the above process requires JavaScript code, which can access the value of the page element, perform conditional judgment, and perform DOM operations based on the results to mark the exception. For example, element.style.color = 'red' can be used to change the text color.

[0102] In this embodiment, through automated anomaly detection, the plug-in can quickly identify and prompt data entry errors or abnormal fluctuations to ensure data accuracy; the plug-in provides the ability to monitor data changes in real time, so that operation and maintenance personnel can promptly understand the operating status of the power grid and respond quickly to possible problems; the automated detection process significantly improves the detection speed and reduces the need for manual inspection, especially when processing large-scale data; reduces the time and cost incurred by manual inspection, while reducing the potential risks and costs caused by data errors; quickly feedbacks abnormal information, so that users can correct data in a timely manner, improving the experience of using the power grid management platform; accurate data detection provides reliable data support for decision-making, helping power grid companies make more scientific operation and maintenance decisions; timely detection and correction of data anomalies reduces the risk of power grid operation caused by data errors and improves the reliability and security of the system; the implemented patrol and maintenance detection strategy helps to promote the technical standardization of data detection within the industry and improve the data processing level of the entire industry.

[0103] Optionally, in some embodiments, the patrol and maintenance data anomaly detection method further includes:

[0104] Create a plugin folder;

[0105] Create metadata description files and script files in the plugin folder;

[0106] Identifying the visible content elements of the target page based on the page structure includes: identifying the visible content elements of the target page based on the page structure, the metadata description file, and the script file.

[0107] Specifically, the patrol data anomaly detection method in this embodiment can also include a method for creating a plug-in folder and its related files. First, a plug-in folder is created. The plug-in folder is used to store all files related to the plug-in, which can specifically include metadata description files, script files, style sheets, icons, etc.; then, a manifest.json (or manifest.xml, depending on the requirements of the browser) file is created in the plug-in folder. This metadata description file contains the metadata of the plug-in, such as the name, version, and permissions of the plug-in, and instructions on how the browser loads and runs the plug-in; then, a JavaScript script file is written. The script file is the core of the plug-in and is responsible for realizing functions such as reading, analyzing, and detecting anomalies of patrol data. The script file specifically includes the aforementioned codes such as page type detection, page structure parsing, content element identification, and anomaly detection logic. In addition, if the plug-in needs to interact with the user, such as displaying a list of abnormal data or providing configuration options, HTML and CSS files will be created to build a user interface, and JavaScript will be used to interact with the user. Icons and other visual resources can also be added to the plug-in, which enhances the identifiability of the plug-in in the browser and provides a better user experience.

[0108] During the development process, the plug-in is tested and debugged to ensure that it can work properly in different web pages and browser environments and can accurately detect anomalies in patrol and maintenance data. After development is completed, the developed plug-in is deployed to the user's browser and continuously maintained and updated based on user feedback and updates to the power grid management platform.

[0109] The plug-in of this embodiment improves the management efficiency of power grid patrol and maintenance data in an automated manner and reduces the need for manual inspection; the automated anomaly detection mechanism helps to detect data errors in a timely manner, thereby improving the accuracy and reliability of data; the reliance on professional technicians for data inspection is reduced, thereby reducing related labor costs; users can quickly identify and correct data problems through the plug-in, thereby improving the interactive experience with the power grid management platform; accurate and timely data anomaly detection helps prevent power grid operation risks caused by data errors and enhances data security; the maintainability and updatability of the plug-in support the continuous iteration of technology and ensure that the plug-in can be upgraded accordingly as the power grid management needs change; the development and application of the plug-in promotes the standardization of the power grid data detection process and provides a reference for similar applications in the industry; the fast anomaly detection and feedback mechanism enables the power grid management system to respond to potential problems in a timely manner, thereby improving the response speed and stability of the system.

[0110] In order to make it easier to understand the patrol data anomaly detection method provided in this embodiment, this embodiment also provides a specific implementation method of the patrol data anomaly detection method, such as Figure 2 As shown, this embodiment mainly develops a browser plug-in for reading and judging whether the patrol data is correct from a web page carrying patrol data. When the browser is opened, the plug-in will automatically run. After the plug-in determines that the opened web page is the target web page, the plug-in will read the patrol data in the web page and judge it according to the data judgment rules built into the plug-in to filter out abnormal data and mark the abnormal data in red on the web page, so that the filling personnel can judge and change the abnormal data in time.

[0111] Specifically, the specific process of implementing the patrol data anomaly detection method through the plug-in is as follows:

[0112] The first step is the browser plug-in development process. Create a plug-in directory: create a new folder to store all plug-in files, including configuration files, HTML files, JavaScript files, icons, etc.; write manifest.xml: create a manifest.xml file in the plug-in directory and write necessary configuration information, such as plug-in ID, name, version number, API version requirements, permission declaration, etc. This file is the metadata description file of the plug-in, and the browser identifies and manages the plug-in by reading this file.

[0113] Then, write the JavaScript code:

[0114] Create a JavaScript file (such as background.js or content_script.js) in the plugin directory to write the logic for reading and manipulating the content of DOM elements. These codes will be executed when the plugin is loaded, and can operate on the DOM elements on the page. For the URL page containing the patrol data, read the page structure and use JavaScript's DOMAPI to read and modify the DOM elements on the page (thereby completing the patrol data reading on the web page and marking abnormal data in red). For example, use methods such as document.getElementById() and document.getElementsByClassName() to obtain DOM elements, use methods such as innerText to obtain the content of DOM elements, and write judgment logic (see 1.6 for details of data judgment logic) to judge the patrol data. If the data is abnormal, modify the DOM element style through methods such as style (that is, mark the abnormal data in red on the web page).

[0115] Next, create the HTML file:

[0116] If the plug-in needs to display a user interface (such as a pop-up window), you can create an HTML file (such as popup.html) to define the layout and content of the interface. Then, in the JavaScript file, you can modify the DOM to update the content of this interface.

[0117] Next, add the icon:

[0118] Add an icon file (such as icon.png) for the plug-in so that the plug-in icon can be displayed in the browser's toolbar or extension management interface.

[0119] Finally, abnormal data judgment:

[0120] The data is judged based on the experience and regulations of daily inspections and maintenance, and the judgment rules are written into the program. For example, for temperature measurement data, the temperature of the equipment is normally not lower than 10 degrees and not higher than 60 degrees, and the temperature difference between the three phases of the equipment does not exceed 15 degrees. If the above conditions are not met, it is judged as abnormal; for pressure data, it can be judged according to its rated value (if it is lower than the rated value, it is judged as abnormal); for battery voltage data, when the voltage of a single battery exceeds the normal value range (1.8V-2.2V), it is judged as data abnormal.

[0121] In summary, the embodiment of the present application provides a method for detecting anomalies in patrol and maintenance data. First, in response to a page browsing operation, it is detected whether the page type of the target page corresponding to the page browsing operation is the target type; then, when it is detected that the page type of the target page is the target type, the page structure of the target page is parsed; then, the visible content elements of the target page are identified based on the page structure; finally, the visible content elements are detected for anomalies according to a preset patrol and maintenance detection strategy. In the patrol and maintenance data anomaly detection scheme provided in the embodiment of the present application, the automatic reading of patrol and maintenance data is realized by seamlessly integrating the automated detection technology into the existing power grid management platform, thereby reducing the need for manual input and greatly reducing the error rate caused by manual operation; the read data is analyzed in real time through an intelligent algorithm to quickly identify abnormal data points, which not only improves the efficiency of data inspection, but also improves the guarantee of data accuracy.

[0122] In order to better implement the patrol data anomaly detection method of the present application embodiment, the present application embodiment also provides a patrol data anomaly detection device. The meanings of the terms are the same as those in the above patrol data anomaly detection method, and the specific implementation details can refer to the description in the method embodiment.

[0123] See also Figure 3 , Figure 3 A schematic diagram of the structure of a patrol data anomaly detection device provided in an embodiment of the present application, wherein the patrol data anomaly detection device may specifically include a page detection module 201, a parsing module 202, an identification module 203 and an anomaly detection module 204, which may be specifically as follows:

[0124] The page detection module 201 is used to detect whether the page type of the target page corresponding to the page browsing operation is the target type in response to the page browsing operation;

[0125] The parsing module 202 is used to parse the page structure of the target page when it is detected that the page type of the target page is the target type;

[0126] An identification module 203, used to identify visible content elements of a target page based on the page structure;

[0127] The anomaly detection module 204 is used to perform anomaly detection on visible content elements according to a preset patrol detection strategy.

[0128] Optionally, in some embodiments, the identification module 203 may specifically include:

[0129] A recognition unit, used for recognizing candidate elements in a target page based on a page structure and an element recognition method of a preset programming language;

[0130] A first detection unit, used to detect whether the candidate element is visible;

[0131] The first determining unit is configured to determine the visible candidate element as a visible content element of the target page.

[0132] Optionally, in some embodiments, the identification module 203 may further include:

[0133] A second detection unit is used to detect whether the element layout information corresponding to the candidate element has a non-zero size;

[0134] A second determining unit, configured to determine that the candidate element is a visible candidate element when it is detected that the element layout information corresponding to the candidate element has a non-zero size;

[0135] The third determining unit is configured to determine that the candidate element is an invisible candidate element when it is detected that the element layout information corresponding to the candidate element does not have a non-zero size.

[0136] Optionally, in some embodiments, the first detection unit may be specifically used for:

[0137] Obtaining the location information of the candidate element on the target page in a preset manner;

[0138] Determine whether the candidate element is within the current viewport of the target page based on the position information;

[0139] If the candidate element is within the current viewport of the target page, the candidate element is determined to be a visible candidate element;

[0140] If the candidate element is not within the current viewport of the target page, the candidate element is determined to be an invisible candidate element.

[0141] Optionally, in some embodiments, the anomaly detection module 204 may specifically include:

[0142] A strategy acquisition unit, used to acquire a preset patrol and maintenance detection strategy;

[0143] An attribute determination unit, used to determine the patrol and maintenance attributes detected by the patrol and maintenance detection strategy;

[0144] The anomaly detection unit is used to perform anomaly detection on visible content elements according to patrol attributes.

[0145] Optionally, in some embodiments, the anomaly detection unit is specifically used to:

[0146] Determine element information corresponding to the visible content element;

[0147] Check whether the element information meets the patrol conditions corresponding to the patrol attributes.

[0148] Optionally, in some embodiments, the patrol and maintenance data anomaly detection device also includes a creation module, which is specifically used to: create a plug-in folder; create a metadata description file and a script file in the plug-in folder; and identify the visible content elements of the target page based on the page structure, including: identifying the visible content elements of the target page based on the page structure, the metadata description file and the script file.

[0149] The embodiment of the present application provides a patrol data anomaly detection device, which first responds to the page browsing operation through the page detection module 201 to detect whether the page type of the target page corresponding to the page browsing operation is the target type; then the parsing module 202 parses the page structure of the target page when it detects that the page type of the target page is the target type; then the identification module 203 identifies the visible content elements of the target page based on the page structure; finally, the anomaly detection module 204 performs anomaly detection on the visible content elements according to the preset patrol detection strategy. In the patrol data anomaly detection scheme provided in the present application, the automatic reading of patrol data is realized by seamlessly integrating the automated detection technology into the existing power grid management platform, reducing the need for manual input, thereby greatly reducing the error rate caused by manual operation; the read data is analyzed in real time through the intelligent algorithm to quickly identify abnormal data points, which not only improves the efficiency of data inspection, but also improves the guarantee of data accuracy.

[0150] In addition, the present application also provides an electronic device, such as Figure 4 As shown, it shows a schematic diagram of the structure of the electronic device involved in the embodiment of the present application, specifically:

[0151] The electronic device may include components such as a processor 301 with one or more processing cores, a memory 302 with one or more computer-readable storage media, a power supply 303, and an input unit 304. Those skilled in the art will appreciate that Figure 4 The electronic device structure shown in the figure does not constitute a limitation on the electronic device, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.

[0152] The processor 301 is the control center of the electronic device. It uses various interfaces and lines to connect various parts of the entire electronic device. By running or executing software programs and / or modules stored in the memory 302, and calling data stored in the memory 302, it executes various functions of the electronic device and processes data, thereby monitoring the electronic device as a whole. Optionally, the processor 301 may include one or more processing cores; preferably, the processor 301 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 301.

[0153] The memory 302 can be used to store software programs and modules. The processor 301 executes various functional applications and patrol data anomaly detection methods by running the software programs and modules stored in the memory 302. The memory 302 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the electronic device, etc. In addition, the memory 302 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices. Accordingly, the memory 302 may also include a memory controller to provide the processor 301 with access to the memory 302.

[0154] The electronic device also includes a power supply 303 for supplying power to various components. Preferably, the power supply 303 can be logically connected to the processor 301 through a power management system, so as to manage charging, discharging, power consumption and other functions through the power management system. The power supply 303 can also include one or more DC or AC power supplies, recharging systems, power failure detection circuits, power converters or inverters, power status indicators and other arbitrary components.

[0155] The electronic device may further include an input unit 304, which may be used to receive input digital or character information and generate keyboard, mouse, joystick, optical or trackball signal input related to user settings and function control.

[0156] Although not shown, the electronic device may further include a display unit, etc., which will not be described in detail herein. Specifically in this embodiment, the processor 301 in the electronic device will load the executable files corresponding to the processes of one or more application programs into the memory 302 according to the following instructions, and the processor 301 will run the application programs stored in the memory 302, thereby realizing various functions, as follows:

[0157] In response to a page browsing operation, detect whether the page type of a target page corresponding to the page browsing operation is a target type; when it is detected that the page type of the target page is a target type, parse the page structure of the target page; identify visible content elements of the target page based on the page structure; and perform anomaly detection on the visible content elements according to a preset patrol detection strategy.

[0158] The specific implementation of the above operations can be found in the previous embodiments, which will not be described in detail here.

[0159] The embodiment of the present application first responds to a page browsing operation and detects whether the page type of the target page corresponding to the page browsing operation is the target type; then, when it is detected that the page type of the target page is the target type, the page structure of the target page is parsed; then, the visible content elements of the target page are identified based on the page structure; finally, the visible content elements are detected for abnormalities according to a preset patrol and maintenance detection strategy. In the patrol and maintenance data anomaly detection scheme provided in the embodiment of the present application, the patrol and maintenance data is automatically read by seamlessly integrating the automated detection technology into the existing power grid management platform, thereby reducing the need for manual input and greatly reducing the error rate caused by manual operation; the read data is analyzed in real time by an intelligent algorithm to quickly identify abnormal data points, which not only improves the efficiency of data inspection, but also improves the guarantee of data accuracy.

[0160] A person of ordinary skill in the art will appreciate that all or part of the steps in the various methods of the above embodiments may be completed by instructions, or by controlling related hardware through instructions. The instructions may be stored in a computer-readable storage medium and loaded and executed by a processor.

[0161] To this end, an embodiment of the present application provides a storage medium in which a plurality of instructions are stored, and the instructions can be loaded by a processor to execute the steps in any one of the patrol data anomaly detection methods provided in the embodiment of the present application. For example, the instructions can execute the following steps:

[0162] In response to a page browsing operation, detect whether the page type of a target page corresponding to the page browsing operation is a target type; when it is detected that the page type of the target page is a target type, parse the page structure of the target page; identify visible content elements of the target page based on the page structure; and perform anomaly detection on the visible content elements according to a preset patrol detection strategy.

[0163] The specific implementation of the above operations can be found in the previous embodiments, which will not be described in detail here.

[0164] The storage medium may include: a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.

[0165] Since the instructions stored in the storage medium can execute the steps in any patrol data anomaly detection method provided in the embodiments of the present application, the beneficial effects that can be achieved by any patrol data anomaly detection method provided in the embodiments of the present application can be achieved. Please refer to the previous embodiments for details and will not be repeated here.

[0166] The above is a detailed introduction to a patrol and maintenance data anomaly detection method, device, electronic device and storage medium provided in an embodiment of the present application. Specific examples are used in this article 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 technical personnel in this field, according to the idea of ​​the present application, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.

Claims

1. A method for detecting anomaly in patrol and maintenance data, characterized in that: include: In response to a page browsing operation, detecting whether a page type of a target page corresponding to the page browsing operation is a target type; When it is detected that the page type of the target page is the target type, parsing the page structure of the target page; Identifying visible content elements of the target page based on the page structure; The visible content elements are detected for abnormalities according to a preset patrol and maintenance detection strategy.

2. The method for detecting anomalies in patrol and maintenance data according to claim 1, characterized in that: The identifying the visible content elements of the target page based on the page structure includes: Based on the page structure and the element recognition method of the preset programming language, identifying candidate elements in the target page; Detecting whether the candidate element is visible; The visible candidate element is determined as a visible content element of the target page.

3. The method for detecting anomalies in patrol and maintenance data according to claim 2, characterized in that: The detecting whether the candidate element is visible includes: Detecting whether the element layout information corresponding to the candidate element has a non-zero size; When it is detected that the element layout information corresponding to the candidate element has a non-zero size, the candidate element is determined to be a visible candidate element; When it is detected that the element layout information corresponding to the candidate element does not have a non-zero size, the candidate element is determined to be an invisible candidate element.

4. The method for detecting anomalies in patrol and maintenance data according to claim 2, characterized in that: The detecting whether the candidate element is visible includes: Acquire the position information of the candidate element on the target page in a preset manner; Determining whether the candidate element is within the current viewport of the target page according to the position information; If the candidate element is within the current viewport of the target page, determining that the candidate element is a visible candidate element; If the candidate element is not within the current viewport of the target page, the candidate element is determined to be an invisible candidate element.

5. The method for detecting anomalies in patrol and maintenance data according to claim 1, characterized in that: The performing abnormality detection on the visible content element according to the preset patrol detection strategy includes: Obtain the preset patrol and maintenance detection strategy; Determining patrol and maintenance attributes detected by the patrol and maintenance detection strategy; Anomaly detection is performed on the visible content element according to the patrol attribute.

6. The method for detecting anomalies in patrol and maintenance data according to claim 5, characterized in that: The performing abnormality detection on the visible content element according to the patrol attribute includes: Determining element information corresponding to the visible content element; Check whether the element information satisfies the patrol condition corresponding to the patrol attribute.

7. The method for detecting anomaly in patrol and maintenance data according to any one of claims 1 to 6, characterized in that: Also includes: Create a plugin folder; Create a metadata description file and a script file in the plug-in folder; The identifying the visible content elements of the target page based on the page structure includes: identifying the visible content elements of the target page based on the page structure, a metadata description file, and a script file.

8. A patrol and maintenance data anomaly detection device, characterized in that: include: A page detection module, used for detecting, in response to a page browsing operation, whether a page type of a target page corresponding to the page browsing operation is a target type; A parsing module, configured to parse the page structure of the target page when detecting that the page type of the target page is a target type; An identification module, configured to identify visible content elements of the target page based on the page structure; The anomaly detection module is used to perform anomaly detection on the visible content elements according to a preset patrol detection strategy.

9. An electronic device, characterized in that: include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program according to the steps of the patrol data anomaly detection method as described in any one of claims 1 to 7.

10. A storage medium, characterized in that: A computer program is stored which can be loaded by a processor and execute the patrol and maintenance data anomaly detection method as described in any one of claims 1 to 7.