A method and system for automatically configuring patrol point preset bits
Patent Information
- Application Number
- CN202610799683.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-04
- Publication Date
- 2026-09-22
AI Technical Summary
[0003]针对现有技术中的上述不足,本发明提供的一种巡视点预置位自动配置方法及系统解决了现有技术对预置位配置过程效率低的问题
(1)本发明提供了一种巡视点预置位自动配置方法及系统,根据相对位置映射表、可用摄像头清单和标准巡视点位表,结合光学字符识别、实例分割与深度学习算法,在摄像头全视角画面中识别目标并记录初始PTZ参数;按初始PTZ参数抓拍图像,通过质量评估算法对抓拍图评分,对不合格图像进行多次微调重拍,对仍不达标图像进行偏移诊断修正PTZ参数;将成功配置的资料归档入库,形成可复用的知识库,提高了变电站预置位配置的效率。
Smart Images

Figure CN122802650A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of intelligent substations, specifically relating to an automatic configuration method and system for preset positions of inspection points. Background Technology
[0002] While existing power companies have built high-definition video intelligent inspection systems for remote inspections, the configuration of preset positions still relies on manual operation by maintenance personnel. Maintenance personnel need to adjust the angle and focus of each camera and confirm the image, which, given the large number of substations and equipment, results in repetitive operations, is time-consuming, and inefficient, failing to truly reduce the technical burden. In actual substation environments, factors such as changes in lighting, equipment surface contamination, and electromagnetic interference can cause images captured by cameras to become blurry, out of focus, or misaligned, leading to a decrease in the accuracy of the intelligent analysis system's equipment status recognition and affecting the effectiveness of inspections. Existing systems lack automated support for the preset position configuration process and lack the ability to quickly configure based on standard inspection point tables, making it difficult to ensure consistency and standardization of configurations across different sites and personnel, thus hindering the large-scale application of intelligent inspections. Therefore, this invention proposes an automatic configuration method and system for inspection point preset positions. Summary of the Invention
[0003] In view of the above-mentioned shortcomings in the prior art, the present invention provides an automatic configuration method and system for preset positions of inspection points, which solves the problem of low efficiency in the preset position configuration process of the prior art.
[0004] To achieve the above-mentioned objectives, the technical solution adopted by this invention is: an automatic configuration method for preset positions of inspection points, comprising the following steps: S1. Perform image recognition based on the 2D plan view of the substation, and generate a relative position mapping table between the equipment and the camera based on the image recognition results through geometric modeling and spatial annotation; S2. Call the self-test tool to perform functional tests on all cameras, and use the rule engine to filter out a list of available cameras based on the test results; S3. Generate a standard inspection point table by matching data from the typical inspection point table of substations according to different substation voltage levels and equipment types; S4. Based on the list of available cameras, the relative position mapping table, and the standard inspection point table, combined with optical character recognition, instance segmentation, and deep learning algorithms, the target component is identified in the full-view image of the camera and the PTZ parameters are recorded to generate the initial preset position. S5. Capture an image at the initial preset position, score the captured image using an image quality assessment algorithm, and initiate fine-tuning reshoot and offset diagnosis based on unqualified captured images to optimize the initial preset position. S6. Archive the successfully configured preset PTZ parameters, image quality scores, and self-inspection reports into the database to form a reusable knowledge base to support rapid deployment of subsequent sites.
[0005] Furthermore: S1 includes the following steps: S11. Based on the 2D plan view of the substation, extract the vector information of the equipment and cameras, and generate a vector layer containing outlines, icons and labels; S12. Based on the vectorized layer, generate a preliminary spatial parameter table containing spatial geometric parameters through geometric modeling; S13. Based on the preliminary spatial parameter table and the on-site measured calibration point data, the error is adjusted through the spatial mapping comprehensive accuracy scoring function to obtain the relative position mapping table.
[0006] Furthermore: S2 includes the following steps: S21. Call the automated function test script in the self-test tool to perform camera function tests and record test log information; S22. The rule engine performs anomaly diagnosis based on the test log information and summarizes the status of each camera to generate a camera health status matrix. S23. Based on the camera health status matrix, use a multi-attribute decision analysis method to generate a list of available cameras, which includes the priority ranking of the cameras.
[0007] Furthermore, S3 includes the following sub-steps: S31. Based on the relevant technical documents of the State Grid Corporation of China on intelligent inspection of substations, natural language processing technology is used to extract structured data and construct a knowledge base of standard inspection points. S32. Match the substation voltage level according to the standard inspection point knowledge base and generate a list of equipment to be inspected; S33. Based on the list of equipment to be inspected and the knowledge base of standard inspection points, a standard inspection point table is generated by combining template filling and conditional logical reasoning.
[0008] Furthermore, S4 includes the following sub-steps: S41. Based on the list of available cameras, the relative position mapping table, and the standard patrol point table, the available cameras are controlled by the automatic patrol script to perform full-view scanning and video stream acquisition, and the raw video dataset is output. S42. Based on the original video dataset, use multi-model collaboration to identify equipment components and segment target regions from video frames, read nameplate text, accurately locate the coordinates of inspection points in the image, and output structured detection results. S43. Based on the structured detection results and the camera's PTZ parameters, calculate the overall confidence level using the AI positioning confidence scoring formula. If the overall confidence level exceeds the first preset threshold, record the camera's PTZ parameters and generate the initial preset position.
[0009] Furthermore, S5 includes the following sub-steps: S51. Capture images using the camera at the initial preset position to obtain the captured images; S52. Based on the captured image, image quality is quantified from multiple dimensions using multi-dimensional image quality scoring and color space analysis to obtain a multi-dimensional image quality score. S53. In response to the image quality multi-dimensional score being less than the second preset threshold, multiple rounds of fine-tuning and reshooting and optimal parameter selection are performed to optimize the initial preset position.
[0010] Furthermore, S53 includes the following sub-steps: S531. For captured images with multi-dimensional image quality scores less than the second preset threshold, input them into a pre-trained convolutional neural network classification model and output structured question labels. S532. Taking the captured image and the standard template image as input, the image registration algorithm is used to achieve image registration, and the pixel-level offset of the target in the horizontal and vertical directions is calculated. S533. Based on the pixel-level offset of the target in the horizontal and vertical directions, the PTZ correction formula is used to dynamically solve the gimbal angle that needs to be adjusted for angle compensation. After the correction is performed, the image is re-captured for verification, and the optimized PTZ parameters are output to generate the optimized initial preset position.
[0011] An automatic configuration system for preset patrol points includes: The relative position module uses image recognition algorithms to identify 2D plan views of the substation, and generates a relative position mapping table between equipment and cameras based on the recognition results using geometric modeling and spatial annotation algorithms. The camera testing module calls the self-testing tool to perform functional tests on all cameras, and uses the rule engine to filter out a list of available cameras based on the test results. The standard inspection point module generates a standard inspection point table by matching data from the typical inspection point table of substations based on the voltage level and equipment type of different substations. The preset position initial configuration module, based on the list of available cameras, the relative position mapping table, and the standard inspection point table, combined with optical character recognition, instance segmentation, and deep learning algorithms, identifies target components in the full-view image of the camera and records the initial PTZ parameters to generate the initial preset position; The preset position adjustment module captures images at the initial preset position, scores the captured images using an image quality assessment algorithm, and initiates multiple fine-tuning retakes and offset diagnosis based on unqualified captured images to optimize the initial preset position. The archiving and reuse module archives successfully configured preset PTZ parameters, image quality scores, and self-inspection reports into a database, forming a reusable knowledge base to support rapid deployment of subsequent sites.
[0012] The beneficial effects of this invention are as follows: (1) This invention provides an automatic configuration method and system for preset positions of inspection points. Based on the relative position mapping table, the list of available cameras and the standard inspection point table, combined with optical character recognition, instance segmentation and deep learning algorithms, the target is identified in the full-view image of the camera and the initial PTZ parameters are recorded; the image is captured according to the initial PTZ parameters, the captured image is scored by the quality assessment algorithm, the unqualified image is finely adjusted and retaken multiple times, and the PTZ parameters are corrected by offset diagnosis for the still unqualified image; the successfully configured data is archived into the database to form a reusable knowledge base, which improves the efficiency of preset position configuration in substations.
[0013] (2) Based on distance error and azimuth deviation, this invention evaluates and optimizes the accuracy of spatial mapping between the device and the camera through a spatial mapping comprehensive accuracy scoring function, thereby improving the overall mapping accuracy. Based on the spatial mapping comprehensive accuracy score, the preliminary spatial parameter table is optimized to obtain a relative position mapping table, which provides high-precision spatial prior support for subsequent automatic configuration of preset positions.
[0014] (3) This invention initiates multiple fine-tuning and re-shooting for unqualified images, and uses incremental learning algorithms to iteratively train AI models such as optical character recognition, instance segmentation and PTZ correction, continuously improving the robustness and accuracy of the models in complex scenarios, realizing an intelligent closed loop of learning from experience and continuous optimization, so as to optimize the preset position to obtain the best imaging. Attached Figure Description
[0015] Figure 1 This is a flowchart of an automatic configuration method for preset positions of inspection points according to the present invention.
[0016] Figure 2 This is a schematic diagram of an automatic configuration system for preset inspection points according to the present invention. Detailed Implementation
[0017] The specific embodiments of the present invention are described below to enable those skilled in the art to understand the present invention. However, it should be understood that the present invention is not limited to the scope of the specific embodiments. For those skilled in the art, various changes are obvious as long as they are within the spirit and scope of the present invention as defined and determined by the appended claims. All inventions utilizing the concept of the present invention are protected.
[0018] like Figure 1 As shown, in one embodiment of the present invention, an automatic configuration method for preset patrol points includes the following steps: S1. Perform image recognition based on the 2D plan view of the substation, and generate a relative position mapping table between the equipment and the camera based on the image recognition results through geometric modeling and spatial annotation; S2. Call the self-test tool to perform functional tests on all cameras, and use the rule engine to filter out a list of available cameras based on the test results; S3. Generate a standard inspection point table by matching data from the typical inspection point table of substations according to different substation voltage levels and equipment types; S4. Based on the list of available cameras, the relative position mapping table, and the standard inspection point table, combined with optical character recognition, instance segmentation, and deep learning algorithms, the target component is identified in the full-view image of the camera and the PTZ parameters are recorded to generate the initial preset position. S5. Capture an image at the initial preset position, score the captured image using an image quality assessment algorithm, and initiate fine-tuning reshoot and offset diagnosis based on unqualified captured images to optimize the initial preset position. S6. Archive the successfully configured preset PTZ parameters, image quality scores, and self-inspection reports into the database to form a reusable knowledge base to support rapid deployment of subsequent sites.
[0019] S1 includes the following steps: S11. Based on the 2D plan view of the substation, extract the vector information of the equipment and cameras, and generate a vector layer containing outlines, icons and labels; Based on a 2D plan view of the substation, image quality is improved through grayscale conversion, denoising, and binarization image preprocessing. The Canny edge detection algorithm in OpenCV is used to extract equipment contours to determine their position and shape. Hough line transform is combined to identify camera icons and installation baselines to locate camera positions. Optical character recognition (OCR) technology is used to identify equipment nameplate text and establish equipment ID labels. A vectorized layer containing equipment contours, camera icons, and text labels is generated.
[0020] S12. Based on the vectorized layer, generate a preliminary spatial parameter table containing spatial geometric parameters through geometric modeling; Based on the input vectorized layer, a fixed position in the drawing is set as the origin of the global coordinate system. Affine transformation is used to map the pixel coordinate system of the drawing to the actual physical coordinate system. The coordinates of the center point of each device are calculated using a triangulation algorithm. Coordinates of camera installation point And according to the formula The relative distance between the center point of the computing device and the camera mounting point According to the formula Calculate azimuth To determine the horizontal pointing relationship, and considering the camera's field of view, installation height, and equipment distance, the pitch angle is estimated through field of view modeling and geometric projection principles. This ensures that the camera's observation angle of the target device is accurately reflected. Finally, a preliminary spatial parameter table is generated, containing parameters such as device ID, camera ID, relative distance, azimuth, and elevation angle.
[0021] S13. Based on the preliminary spatial parameter table and the on-site measured calibration point data, the error is adjusted through the spatial mapping comprehensive accuracy scoring function to obtain the relative position mapping table.
[0022] Based on preliminary spatial parameter tables and on-site measured calibration point data, the accuracy of the relative positions of the configured equipment and cameras is verified. For the actual coordinate calibration points of the equipment obtained by the laser rangefinder, the Euclidean distance error between the predicted and measured positions is calculated to quantify the geometric deviation of the spatial mapping. Simultaneously, the predicted azimuth angle is compared with the actual pointing angle to obtain the azimuth angle deviation. Based on the distance error and azimuth angle deviation, the accuracy of the spatial mapping between the equipment and cameras is evaluated and optimized using a comprehensive spatial mapping accuracy scoring function. The comprehensive spatial mapping accuracy score is calculated using this function. The specific expression is: In the formula, The number of devices participating in the evaluation. For distance matching weights, For the first i Distance error of individual devices As an angle consistency weight, This is the azimuth deviation. Weighting the camera's field of view coverage. The standard deviation of camera field-of-view coverage unevenness represents the spatial dispersion of device distribution within the camera's field of view. It is used to penalize unreasonable layouts with excessive overlap or large blind spots. and The attenuation coefficient is determined by making... To maximize and improve overall mapping accuracy, based on The preliminary spatial parameter table is optimized to obtain a relative position mapping table, which provides high-precision spatial prior support for subsequent automatic configuration of preset positions.
[0023] S2 includes the following steps: S21. Call the automated function test script in the self-test tool to perform camera function tests and record test log information; Based on the camera IP address list and parameters of the real-time streaming protocol and the Open Network Video Interface Forum (ONVIF) protocol, network connections were established for each camera in the site using automated functional test scripts in the self-test tool, combined with the OpenCV image processing library and the ONVIF-PTZ control library. The specific process was as follows: The video stream address was obtained using the ONVIF-PTZ protocol's acquisition interface, and the real-time video stream was captured using the OpenCV image processing library to verify normal image output. Subsequently, PTZ control commands were sent to the pan-tilt unit (PTZ), including vertical and horizontal rotation and zoom operations, to check the accuracy of the PTZ response. During zooming, multiple frames were continuously acquired, and the image sharpness variance was calculated using the Laplacian operator to determine if the focusing function was normal. Simultaneously, the average frame rate and resolution of the video stream were statistically analyzed to ensure that minimum imaging requirements were met. The entire test process automatically recorded the response time, image status, and anomaly information for each function, generating structured test log information, including the connection status of each camera, PTZ response status, imaging quality indicators, and function execution timestamps, providing complete data support for subsequent diagnostics.
[0024] S22. The rule engine performs anomaly diagnosis based on the test log information and summarizes the status of each camera to generate a camera health status matrix. The test log information is input into a diagnostic engine based on Drools rules to systematically analyze the functional status and classify faults of each camera. The specific process is as follows: The first step is to analyze the image stream data in the logs. If no valid frames are acquired for three consecutive seconds, or the image is completely black or distorted, it is considered an image anomaly. The second step is to analyze the PTZ command response time. If the time from sending the command to the PTZ starting to move exceeds two seconds, or the PTZ fails to reach the target position, it is marked as a PTZ response delay or PTZ lag. The third step is to check the sharpness change curve during zooming. If the image is blurry after zooming in and cannot be restored to sharpness, combined with the failure of the optical character recognition nameplate, it is judged as lens damage or autofocus failure. The fourth step is to classify any failures as communication interruptions, such as inability to establish an open network video interface forum protocol connection or frequent interruptions in the real-time streaming protocol. All anomalies are mapped to standardized fault types according to preset rules and summarized to generate a camera health status matrix. This matrix uses camera IDs as columns and function items as rows, with levels representing the status of each function, comprehensively reflecting the health status of each camera.
[0025] S23. Based on the camera health status matrix, use a multi-attribute decision analysis method to generate a list of available cameras, which includes the priority ranking of the cameras.
[0026] Based on the camera health status matrix, a multi-attribute decision analysis method is used to filter out functional cameras and generate a priority list of available cameras. The specific process is as follows: First, cameras with malfunctions are filtered out, retaining only those with all functions working properly. Then, these usable cameras are evaluated for performance: response speed is scored based on PTZ response time, image clarity is assessed based on average frame rate and resolution, and stability is measured by the number of video stream interruptions. All metrics are normalized and then weighted and summed to obtain a comprehensive performance score. Finally, a fast sorting algorithm is used to rank the cameras from highest to lowest score, forming a list of usable cameras.
[0027] S3 includes the following steps: S31. Based on the relevant technical documents of the State Grid Corporation of China on intelligent inspection of substations, natural language processing technology is used to extract structured data and construct a knowledge base of standard inspection points. Based on the State Grid Equipment Department's "Notice on Accelerating the Large-Scale Application and Practical Improvement of Intelligent Substation Inspection" (Equipment Monitoring
[2024] No. 49) and the technical specification document "Technical Requirements for Remote Intelligent Substation Inspection Business" (Document No. 57), information extraction algorithms from natural language processing were used to perform structured parsing of the document content. PDF parsing tools were used to extract the text content, and named entity recognition algorithms were applied to identify key fields such as equipment type, inspection point name, and inspection requirements. Through dependency parsing and rule matching, the mapping relationship between equipment type and inspection point was extracted. The extracted structured data was imported into a database to establish a standardized knowledge storage system.
[0028] S32. Match the substation voltage level according to the standard inspection point knowledge base and generate a list of equipment to be inspected; Using the actual voltage level of the substation as input, and combining it with a standard inspection point knowledge base, a rule-matching algorithm is used to determine the types of equipment that should be inspected at that voltage level. The specific process is as follows: A pre-defined voltage level-equipment type configuration rule table is set in the database. Based on the input voltage level, a database query is automatically executed to retrieve the corresponding equipment list. Simultaneously, a weighting mechanism is introduced to exclude outdated or atypical equipment, ensuring the list conforms to current maintenance standards. After deduplication and formatting, the query results generate a structured list of equipment to be inspected.
[0029] S33. Based on the list of equipment to be inspected and the knowledge base of standard inspection points, a standard inspection point table is generated by combining template filling and conditional logical reasoning.
[0030] The system iterates through each type of equipment in the list to be inspected, retrieving all corresponding standard inspection points from the knowledge base for each equipment type. Then, based on a preset shooting strategy template, shooting requirements are added to each point, and priorities are assigned according to the importance of the point. For special environments or equipment states, conditional judgment logic is introduced to dynamically adjust the task order or whether to enable the point. All task items are organized into a unified data structure, outputting a standard inspection point table with fields including: task ID, equipment type, point name, shooting mode, PTZ suggested angle range, priority, execution cycle, etc. This task table serves as the target instruction set for AI-assisted configuration, guiding the camera to automatically locate and configure the corresponding preset positions, achieving a precise mapping from standards to execution.
[0031] S4 includes the following steps: S41. Based on the list of available cameras, the relative position mapping table, and the standard patrol point table, the available cameras are controlled by the automatic patrol script to perform full-view scanning and video stream acquisition, and the raw video dataset is output. Based on the available camera list, a pre-defined PTZ auto-navigation script, using Python technology combined with the ONVIF-PTZ control protocol, controls the camera to perform a systematic spatial scan. Starting from its current position, the camera gradually rotates its pan / tilt head and adjusts its pitch angle along a spiral path, maintaining a standard focal length for continuous shooting to ensure coverage of its entire field of view, achieving 360° horizontal scanning and ±90° vertical scanning. During the scan, a video stream is captured in real-time and recorded as a high-definition video file using OpenCV. The timestamp for each frame and the camera's current PTZ parameters, including azimuth, pitch, and zoom, are also recorded. This process continues until a complete scan cycle is finished, outputting a raw video dataset containing time-series image frames and synchronized PTZ coordinates.
[0032] S42. Based on the original video dataset, use multi-model collaboration to identify equipment components and segment target regions from video frames, read nameplate text, accurately locate the coordinates of inspection points in the image, and output structured detection results. A deep learning algorithm with multi-model fusion is used to perform target recognition and precise localization on the original video dataset. The specific process is as follows: First, the YOLOv8 object detection model is used for fast inference on each frame of the image to initially locate the power equipment and its key components, obtaining bounding box coordinates and category confidence scores. Then, the Mask R-CNN instance segmentation model is called to further extract pixel-level segmentation masks based on the YOLOv8 candidate regions, accurately distinguishing the contour boundaries of different components and improving localization accuracy. Simultaneously, the Tesseract optical character recognition engine is enabled to perform text recognition on the nameplate areas in the images, reading information such as equipment number and name to confirm equipment identity. The three results are then fused: the optical character recognition results are used to verify whether the detected equipment type matches the task requirements, and the instance segmentation results are used to accurately locate the center coordinates of the inspection points in the image. Finally, a structured object detection result set is output, including the target category, segmentation mask, optical character recognition text, confidence score, and image coordinates for each point in each frame of the image.
[0033] S43. Based on the structured detection results and the camera's PTZ parameters, calculate the overall confidence level using the AI positioning confidence scoring formula. If the overall confidence level exceeds the first preset threshold, record the camera's PTZ parameters and generate the initial preset position.
[0034] Based on structured detection results and camera PTZ parameters, an AI positioning reliability scoring formula is constructed to determine whether the current viewpoint meets the preset positioning conditions. The overall confidence level is then calculated using this AI positioning reliability scoring formula. The specific expression is: In the formula, The confidence level for optical character recognition represents the accuracy of nameplate recognition. The intersection-union score (IUCN) for instance segmentation reflects the degree of overlap between the target segmentation region and the standard template. Target centering measures the degree to which the center of the target deviates from the center of the image. Prior scores for spatial mapping are used to enhance geometric plausibility. To determine the standard deviation of illumination non-uniformity, the variance of the image luminance channel is analyzed using the HSV color space to assess the degree of illumination interference. , and The index weights reflect the importance of each indicator. To improve stability, prior knowledge is introduced for the spatial mapping gain coefficients. It is a light penalty factor to suppress misjudgments under strong light or shadow.
[0035] When the calculated overall confidence level is greater than the threshold, it is determined that the current viewpoint meets the requirements of the high-quality preset position. The PTZ parameters at this time are immediately recorded as the initial preset position of the inspection point, and stored in the temporary configuration library along with the point ID, equipment type, image snapshot and other information.
[0036] S5 includes the following steps: S51. Capture images using the camera at the initial preset position to obtain the captured images; Based on the initial preset PTZ parameters, an automated control script sends PTZ commands to the camera, adjusting its pan-tilt-zoom (PTZ) to the target position. Once stable, a single-frame image is captured, ensuring the image is saved in a standard format and uploaded to the central analysis server. A delay mechanism is incorporated into the capture process to prevent image blurring due to PTZ movement. Each image is accompanied by metadata tags, including a timestamp, camera ID, corresponding patrol point name, and current PTZ value. This process is executed once for each patrol point, outputting a high-quality captured image.
[0037] S52. Based on the captured image, image quality is quantified from multiple dimensions using multi-dimensional image quality scoring and color space analysis to obtain a multi-dimensional image quality score. The multi-dimensional image quality score is then calculated. The specific expression is: In the formula, To assess image sharpness, a no-reference image spatial quality assessment algorithm is used to calculate the natural scene statistical features of the image, outputting a sharpness score. A lower score indicates greater sharpness. Indicates the uniformity of illumination. To ensure reasonable brightness, the image needs to be converted to the HSV color space, the luminance channel extracted, and the ratio of average brightness to normal brightness calculated. A combination of control over sharpness, uniformity of illumination, and moderate brightness. The average saturation value. Controlling the impact of noise on image quality scoring. It is the gradient variance, used to measure noise. Used to adjust the penalty for overexposed areas. Impact on total mass fraction.
[0038] S53. In response to the image quality multi-dimensional score being less than the second preset threshold, multiple rounds of fine-tuning and reshooting and optimal parameter selection are performed to optimize the initial preset position.
[0039] In this embodiment, the present invention initiates a multi-round optimization mechanism. A random search and greedy selection strategy is employed: based on the current PTZ parameters, the gimbal angle and zoom magnification are fine-tuned by a preset step size, generating up to three new PTZ combinations; instructions are sequentially sent to the camera to re-capture and evaluate the multi-dimensional image quality scores of the new images. The image quality scores of all attempts, including the original configuration, are recorded, and the PTZ parameter with the highest multi-dimensional image quality score is selected as the optimized PTZ parameter. If the target is still not met within three rounds, the location is marked as having imaging limitations and enters the automatic correction process. This process ensures that a locally optimal configuration is achieved with limited attempts, improving the overall availability of the survey images.
[0040] S53 includes the following steps: S531. For captured images with multi-dimensional image quality scores less than the second preset threshold, input them into a pre-trained convolutional neural network classification model and output structured question labels. Images captured with multi-dimensional quality scores below a threshold are preprocessed (size normalized, noise reduced) and used as input. A pre-trained convolutional neural network classification model automatically identifies and classifies image degradation types. During training, this model learns the visual features of typical defects such as blur, occlusion, overexposure, and offset, outputting probability distributions for each type of problem. A classification threshold is set; if the preset offset category has the highest probability, the main problem is determined to be a misaligned target or deviation from the expected composition, and a structured problem label is output. This diagnostic result serves as the trigger for subsequent image registration and correction processes, ensuring that accurate correction is performed only for quality degradation caused by spatial misalignment.
[0041] S532. Taking the captured image and the standard template image as input, the image registration algorithm is used to achieve image registration, and the pixel-level offset of the target in the horizontal and vertical directions is calculated. Using the low-quality captured image and a pre-constructed standard template image as input, a scale-invariant feature transform algorithm is employed to extract key points and their descriptors from the two images. Nearest neighbor matching is then used to establish the correspondence between feature points. To eliminate mismatch interference, a random sampling consensus algorithm is introduced to robustly estimate the matching point set, fitting the optimal affine transformation matrix to separate rigid transformation components such as translation, rotation, and scaling between the images. Pixel-level translation vectors in the horizontal and vertical directions are then extracted from this data. , This represents the offset of the target along the width of the image. This indicates the offset of the target in the image height direction.
[0042] S533. Based on the pixel-level offset of the target in the horizontal and vertical directions, the PTZ correction formula is used to dynamically solve the gimbal angle that needs to be adjusted for angle compensation. After the correction is performed, the image is re-captured for verification, and the optimized PTZ parameters are output to generate the optimized initial preset position.
[0043] The PTZ correction calculation formula dynamically solves for the incremental horizontal gimbal azimuth angle that needs to be adjusted. The expression is: In the formula, A positive value indicates a right turn. A negative value indicates a left turn. This is the horizontal proportional gain coefficient, used to calibrate the system response sensitivity. The term represents the basic geometric mapping that converts pixel offsets into angular deviations. This is the horizontal pixel offset. Image width, For horizontal field of view, This is the height compensation coefficient, used to compensate for visual distortion caused by height differences. Determine the installation height of the camera. This refers to the distance from the camera to the target device. The term represents the aging degradation factor, and the shift in this factor increases over time. The decay rate constant is The configuration duration for this preset position.
[0044] The PTZ correction calculation formula dynamically solves for the increment of the vertical gimbal azimuth angle that needs to be adjusted. The expression is: In the formula, This is the vertical proportional gain coefficient. Image height, This represents the offset of the target in the image height direction. This is the vertical field of view angle.
[0045] The system automatically updates the current PTZ parameters based on the calculated azimuth angle, sends a new azimuth angle command to the camera, and completes the correction process. It then triggers a re-capture and calls a multi-dimensional image quality scoring formula to verify if the image meets the standards. If it still fails to meet the standards, the process is iterated; if it still fails, it is marked as requiring manual intervention. After manual intervention, the PTZ parameters are recorded.
[0046] S6 specifically refers to: By solidifying configuration results and continuously evolving system capabilities through closed-loop verification and knowledge accumulation, the corrected images undergo a final quality check to confirm that their clarity, target centering, and completeness meet the standards, generating a reliable final preset position configuration set. Subsequently, this configuration set, along with the environmental parameters collected, is stored in a preset position knowledge base, establishing an index structure of substation type-configuration templates to form standardized configuration templates that can be reused at similar sites. Simultaneously, for failure case logs recorded during the configuration process, incremental learning algorithms are used to iteratively train AI models for optical character recognition, instance segmentation, and PTZ correction, continuously improving the robustness and accuracy of the models in complex scenarios, achieving an intelligent closed loop of learning from experience and continuous optimization.
[0047] like Figure 2 As shown, in this embodiment, an automatic configuration system for preset patrol points includes: The relative position module uses image recognition algorithms to identify 2D plan views of the substation, and generates a relative position mapping table between equipment and cameras based on the recognition results using geometric modeling and spatial annotation algorithms. The camera testing module calls the self-testing tool to perform functional tests on all cameras, and uses the rule engine to filter out a list of available cameras based on the test results. The standard inspection point module generates a standard inspection point table by matching data from the typical inspection point table of substations based on the voltage level and equipment type of different substations. The preset position initial configuration module, based on the list of available cameras, the relative position mapping table, and the standard inspection point table, combined with optical character recognition, instance segmentation, and deep learning algorithms, identifies target components in the full-view image of the camera and records the initial PTZ parameters to generate the initial preset position; The preset position adjustment module captures images at the initial preset position, scores the captured images using an image quality assessment algorithm, and initiates multiple fine-tuning retakes and offset diagnosis based on unqualified captured images to optimize the initial preset position. The archiving and reuse module archives successfully configured preset PTZ parameters, image quality scores, and self-inspection reports into a database, forming a reusable knowledge base to support rapid deployment of subsequent sites.
[0048] In the description of this invention, the above are merely preferred embodiments and are not intended to limit the scope of protection of this invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this invention should be included within the scope of protection of this invention.
Claims
1. A method for automatically configuring preset locations of inspection points, characterized in that, Includes the following steps: S1. Perform image recognition based on the 2D plan view of the substation, and generate a relative position mapping table between the equipment and the camera based on the image recognition results through geometric modeling and spatial annotation; S2. Call the self-test tool to perform functional tests on all cameras, and use the rule engine to filter out a list of available cameras based on the test results; S3. Generate a standard inspection point table by matching data from the typical inspection point table of substations according to different substation voltage levels and equipment types; S4. Based on the list of available cameras, the relative position mapping table, and the standard inspection point table, combined with optical character recognition, instance segmentation, and deep learning algorithms, the target component is identified in the full-view image of the camera and the PTZ parameters are recorded to generate the initial preset position. S5. Capture an image at the initial preset position, score the captured image using an image quality assessment algorithm, and initiate fine-tuning reshoot and offset diagnosis based on unqualified captured images to optimize the initial preset position. S6. Archive the successfully configured preset PTZ parameters, image quality scores, and self-inspection reports into the database to form a reusable knowledge base to support rapid deployment of subsequent sites.
2. The automatic configuration method for preset patrol points according to claim 1, characterized in that, S1 includes the following steps: S11. Based on the 2D plan view of the substation, extract the vector information of the equipment and cameras, and generate a vector layer containing outlines, icons and labels; S12. Based on the vectorized layer, generate a preliminary spatial parameter table containing spatial geometric parameters through geometric modeling; S13. Based on the preliminary spatial parameter table and the on-site measured calibration point data, the error is adjusted through the spatial mapping comprehensive accuracy scoring function to obtain the relative position mapping table.
3. The automatic configuration method for preset patrol points according to claim 2, characterized in that, S2 includes the following steps: S21. Call the automated function test script in the self-test tool to perform camera function tests and record test log information; S22. The rule engine performs anomaly diagnosis based on the test log information and summarizes the status of each camera to generate a camera health status matrix. S23. Based on the camera health status matrix, use a multi-attribute decision analysis method to generate a list of available cameras, which includes the priority ranking of the cameras.
4. The automatic configuration method for preset patrol points according to claim 3, characterized in that, S3 includes the following steps: S31. Based on the relevant technical documents of the State Grid Corporation of China on intelligent inspection of substations, natural language processing technology is used to extract structured data and construct a knowledge base of standard inspection points. S32. Match the substation voltage level according to the standard inspection point knowledge base and generate a list of equipment to be inspected; S33. Based on the list of equipment to be inspected and the knowledge base of standard inspection points, a standard inspection point table is generated by combining template filling and conditional logical reasoning.
5. The automatic configuration method for preset patrol points according to claim 1, characterized in that, S4 includes the following steps: S41. Based on the list of available cameras, the relative position mapping table, and the standard patrol point table, the available cameras are controlled by the automatic patrol script to perform full-view scanning and video stream acquisition, and the raw video dataset is output. S42. Based on the original video dataset, use multi-model collaboration to identify equipment components and segment target regions from video frames, read nameplate text, accurately locate the coordinates of inspection points in the image, and output structured detection results. S43. Based on the structured detection results and the camera's PTZ parameters, calculate the overall confidence level using the AI positioning confidence scoring formula. If the overall confidence level exceeds the first preset threshold, record the camera's PTZ parameters and generate the initial preset position.
6. The automatic configuration method for preset patrol points according to claim 1, characterized in that, S5 includes the following steps: S51. Capture images using the camera at the initial preset position to obtain the captured images; S52. Based on the captured image, image quality is quantified from multiple dimensions using multi-dimensional image quality scoring and color space analysis to obtain a multi-dimensional image quality score. S53. In response to the image quality multi-dimensional score being less than the second preset threshold, multiple rounds of fine-tuning and reshooting and optimal parameter selection are performed to optimize the initial preset position.
7. The automatic configuration method for preset patrol points according to claim 6, characterized in that, S53 includes the following steps: S531. For captured images with multi-dimensional image quality scores less than the second preset threshold, input them into a pre-trained convolutional neural network classification model and output structured question labels. S532. Taking the captured image and the standard template image as input, the image registration algorithm is used to achieve image registration, and the pixel-level offset of the target in the horizontal and vertical directions is calculated. S533. Based on the pixel-level offset of the target in the horizontal and vertical directions, the PTZ correction formula is used to dynamically solve the gimbal angle that needs to be adjusted for angle compensation. After the correction is performed, the image is re-captured for verification, and the optimized PTZ parameters are output to generate the optimized initial preset position.
8. An automatic configuration system for preset patrol points, applied to the automatic configuration method for preset patrol points as described in any one of claims 1 to 7, characterized in that the system... include: The relative position module uses image recognition algorithms to identify 2D plan views of the substation, and generates a relative position mapping table between equipment and cameras based on the recognition results using geometric modeling and spatial annotation algorithms. The camera testing module calls the self-testing tool to perform functional tests on all cameras, and uses the rule engine to filter out a list of available cameras based on the test results. The standard inspection point module generates a standard inspection point table by matching data from the typical inspection point table of substations based on the voltage level and equipment type of different substations. The preset position initial configuration module, based on the list of available cameras, the relative position mapping table, and the standard inspection point table, combined with optical character recognition, instance segmentation, and deep learning algorithms, identifies target components in the full-view image of the camera and records the initial PTZ parameters to generate the initial preset position; The preset position adjustment module captures images at the initial preset position, scores the captured images using an image quality assessment algorithm, and initiates multiple fine-tuning retakes and offset diagnosis based on unqualified captured images to optimize the initial preset position. The archiving and reuse module archives successfully configured preset PTZ parameters, image quality scores, and self-inspection reports into a database, forming a reusable knowledge base to support rapid deployment of subsequent sites.