An unmanned aerial vehicle intelligent inspection path planning method and system for an oil and gas station
By integrating multi-source data to calculate comprehensive risk values and optimizing inspection routes, the problems of overlooking high-risk hazards and insufficient battery life in drone inspections of oil and gas stations have been solved. This has achieved full coverage of high-risk areas and energy consumption balance, improving the safety and efficiency of inspections.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- GUANGDONG INST OF SPECIAL EQUIP INSPECTION
- Filing Date
- 2026-05-15
- Publication Date
- 2026-06-19
AI Technical Summary
Existing drone inspection path planning methods for oil and gas stations cannot adapt to dynamic risk distribution, resulting in the omission of high-risk hazards, insufficient battery life, or incomplete coverage, making it difficult to meet the requirements for inspection safety, efficiency, and comprehensiveness.
By integrating equipment location, historical fault data, and real-time environmental sensor data, a comprehensive risk value is calculated to generate a priority list of high-risk areas. The inspection path is optimized based on the remaining battery life parameters, and the task order is adjusted in real time to ensure full coverage of high-risk areas.
It improved the coverage of high-risk areas, optimized the energy consumption balance of route planning, ensured the safety and efficiency of inspections, and solved the problems of insufficient battery life and incomplete coverage in traditional methods.
Smart Images

Figure CN122239692A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of oil and gas station operation and maintenance technology, and in particular to a method and system for intelligent inspection path planning by unmanned aerial vehicles (UAVs) at oil and gas stations. Background Technology
[0002] Currently, in the field of oil and gas station operation and maintenance technology, with the continuous expansion of station scale and the increasing demand for equipment safety management, drone intelligent inspection, as a core means of efficient operation and maintenance, has its path planning rationality directly related to the inspection coverage and the level of station safety assurance.
[0003] Existing drone inspection path planning methods in the industry mainly rely on fixed route pre-sets or single risk assessments. For example, they may plan paths according to a pre-set coordinate sequence, determine inspection priorities solely based on historical fault data, or ignore real-time environmental and equipment status information obtained through visual inspection. However, this approach is clearly inadequate in complex operating environments. Fixed routes cannot adapt to dynamically changing risk distributions, easily overlooking temporarily emerging high-risk hazards; single risk assessments lack the support of visual inspection data, making it difficult to accurately determine the real-time status of equipment; and they do not adequately consider the balance between energy consumption and coverage, especially in densely populated and complex environments, easily leading to insufficient battery life or incomplete coverage of high-risk areas.
[0004] In summary, existing technologies are insufficient for intelligent optimization of drone inspection routes at oil and gas stations, and cannot meet the multiple requirements of station operation and maintenance for inspection safety, efficiency, and comprehensiveness. Summary of the Invention
[0005] This invention provides a method and system for intelligent inspection path planning by unmanned aerial vehicles (UAVs) at oil and gas stations, so as to realize intelligent optimization of UAV inspection paths at oil and gas stations and meet the multiple requirements of station operation and maintenance for inspection safety, efficiency and comprehensiveness.
[0006] Firstly, to address the aforementioned technical problems, this invention provides a method for intelligent inspection path planning using unmanned aerial vehicles (UAVs) at oil and gas stations, comprising: Acquire the location coordinates, historical fault data, real-time environmental sensor data, and current battery data of each piece of equipment at the oil and gas station; The location coordinates, historical fault data and real-time environmental sensing data are integrated, and the integrated data is input into a preset risk weight model to calculate the comprehensive risk value of each device. The coordinates of devices whose comprehensive risk values exceed a preset risk threshold are clustered to divide high-risk areas, and dynamic risk scores are calculated. The high-risk areas are then sorted in descending order according to the dynamic risk scores to obtain a priority list of high-risk areas. Based on the priority list, an initial inspection path is generated by combining the pre-acquired terrain obstacle distribution data and UAV operating parameters, and the energy consumption estimate of the initial inspection path is calculated. If the energy consumption estimate exceeds the preset endurance threshold, then high-risk tasks that meet the preset ranking conditions are retained, and the remaining tasks are merged and reorganized according to spatial distribution distance to obtain an optimized inspection sequence. Extract the coordinates of the takeoff point and target point from the optimized inspection sequence, and combine them with the current power data to divide the executable path segments; The drone's position and energy consumption are tracked in real time during the execution of the path segment. If the deviation between the energy consumption and the energy consumption estimate exceeds a preset deviation threshold, the remaining tasks are reordered and the inspection order is updated. A control command sequence is generated based on the updated inspection order, sent to the UAV system, and an execution feedback log is obtained. Analyze the device inspection coverage in the execution feedback log, check whether high-risk areas are fully covered, and if not, supplement the appropriate inspection path until the high-risk areas are confirmed to be fully covered, and then generate a complete inspection report.
[0007] Secondly, the present invention provides an intelligent inspection path planning system for oil and gas station unmanned aerial vehicles (UAVs), used to implement the above-mentioned intelligent inspection path planning method for oil and gas station UAVs, including: The data acquisition module is used to acquire the location coordinates of various equipment in the oil and gas station, historical fault data, real-time environmental sensor data, and the current power data of the drone; The risk ranking module is used to integrate the location coordinates, the historical fault data and the real-time environmental sensing data, and input the integrated data into a preset risk weight model to calculate the comprehensive risk value of each device. The coordinates of devices whose comprehensive risk values exceed a preset risk threshold are clustered to divide high-risk areas, and dynamic risk scores are calculated. The high-risk areas are then sorted in descending order according to the dynamic risk scores to obtain a priority list of high-risk areas. The path generation module is used to generate an initial inspection path based on the priority list, combined with pre-acquired terrain obstacle distribution data and UAV operating parameters, and to calculate the energy consumption estimate of the initial inspection path. The sequence optimization module is used to retain high-risk tasks that meet the preset ranking conditions and merge and reorganize the remaining tasks according to the spatial distribution distance if the energy consumption estimate exceeds the preset endurance threshold, so as to obtain an optimized inspection sequence. The segmentation module is used to extract the coordinates of the takeoff point and the target point in the optimized inspection sequence, and combine them with the current power data to divide the path into executable segments. The dynamic adjustment module is used to track the drone's position and energy consumption in real time during the execution of the path segment. If the deviation between the energy consumption and the energy consumption estimate exceeds a preset deviation threshold, the remaining tasks are reordered and the inspection order is updated. The instruction execution module is used to generate a sequence of control instructions according to the updated inspection order, send it to the UAV system, and obtain the execution feedback log. The report generation module is used to analyze the device inspection coverage in the execution feedback log, check whether high-risk areas are fully covered, and if not, supplement the appropriate inspection path until the high-risk areas are confirmed to be fully covered, and then generate a complete inspection report.
[0008] Compared with the prior art, the present invention has the following beneficial effects: (1) This invention obtains the location coordinates of oil and gas station equipment, historical fault data, real-time environmental sensor data and current power data of UAVs, integrates multi-source data to calculate the comprehensive risk value and generate a priority list of high-risk areas. It breaks through the limitation that traditional fixed routes cannot adapt to dynamic risks, explores the correlation characteristics between equipment risks and environmental factors, eliminates high-risk omission interference caused by static planning, provides high-precision risk data support for path planning, effectively improves the priority coverage rate of high-risk areas, and solves the problem of uneven allocation of traditional inspection resources.
[0009] (2) The present invention generates an initial inspection path based on a priority list and endurance parameters. When energy consumption exceeds the threshold, tasks are integrated according to the principle of high risk priority and executable path segments are divided. This invention breaks through the limitation of traditional single path planning ignoring endurance constraints, accurately captures the core characteristics of risk priority and energy consumption balance, provides multi-dimensional basis for path optimization, significantly improves the feasibility of paths in complex station environments, and makes up for the defects of insufficient endurance or incomplete coverage in existing technologies.
[0010] (3) This invention tracks the location and energy consumption of UAVs in real time. When the deviation exceeds the threshold, the remaining tasks are dynamically rearranged. Combined with the execution feedback log, the inspection path of the high-risk area not covered is supplemented. It breaks through the limitations of traditional methods that lack real-time adjustment and closed-loop verification, provides safe and efficient inspection basis for operation and maintenance, solves the problem of inspection interruption or high-risk omission in dynamic environment, takes into account the safety and efficiency of inspection, and meets the dual requirements of comprehensiveness and reliability of oil and gas station operation and maintenance. Attached Figure Description
[0011] Figure 1 This is a flowchart illustrating a method for intelligent inspection path planning of oil and gas station drones according to the first embodiment of the present invention. Figure 2 This is a schematic diagram of the structure of an intelligent inspection path planning system for oil and gas stations provided in the second embodiment of the present invention. Detailed Implementation
[0012] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0013] Reference Figure 1 The first embodiment of the present invention provides a method for intelligent inspection path planning of oil and gas station drones, including the following steps: S101, acquire the location coordinates of each piece of equipment at the oil and gas station, historical fault data, real-time environmental sensor data, and the current battery level of the drone; S102, the location coordinates, the historical fault data and the real-time environmental sensing data are integrated, and the integrated data is input into a preset risk weight model to calculate the comprehensive risk value of each device. The coordinates of devices whose comprehensive risk values exceed the preset risk threshold are clustered to divide high-risk areas, and dynamic risk scores are calculated. The high-risk areas are sorted in descending order according to the dynamic risk scores to obtain a priority list of high-risk areas. S103, Based on the priority list, an initial inspection path is generated by combining the pre-acquired terrain obstacle distribution data and UAV operating parameters, and the energy consumption estimate of the initial inspection path is calculated. S104, if the energy consumption estimate exceeds the preset endurance threshold, then retain the high-risk tasks that meet the preset ranking conditions, and merge and reorganize the remaining tasks according to the spatial distribution distance to obtain an optimized inspection sequence. S105, extract the coordinates of the takeoff point and target point in the optimized inspection sequence, and combine them with the current power data to divide the executable path segments; S106, Real-time tracking of the drone's position and energy consumption during the execution of the path segment; If the deviation between the energy consumption and the energy consumption estimate exceeds a preset deviation threshold, the remaining tasks are reordered and the inspection order is updated. S107, Generate a control command sequence according to the updated inspection order, send it to the UAV system and obtain the execution feedback log; S108, Analyze the device inspection coverage rate in the execution feedback log, check whether the high-risk areas are fully covered, if not covered, supplement the appropriate inspection path, until the high-risk areas are confirmed to be fully covered, and generate a complete inspection report.
[0014] In step S101, the location coordinates, historical fault data, real-time environmental sensor data, and current battery data of each piece of equipment at the oil and gas station are acquired, including: Extract the location coordinates and historical fault data of each device from a pre-established equipment risk database; Real-time data on temperature, humidity, wind speed and gas concentration at oil and gas stations are collected and then denoised to obtain real-time environmental sensing data. Read data from the drone's battery management system and collect current battery level data.
[0015] It should be noted that, firstly, when extracting the location coordinates and historical fault data of each piece of equipment from the pre-established equipment risk database, the equipment risk database adopts a distributed storage architecture, integrating the annual equipment operation and maintenance records, fault repair orders, and equipment installation files of the oil and gas station. The data is stored in a structured manner according to "equipment number - location information - fault record - maintenance log". During extraction, the unique equipment number is used for association query. The location coordinates are based on the unified coordinate system of the station's geographic information system (GIS) and are accurate to the meter level. The historical fault data includes the fault occurrence time, fault type, fault level, and repair plan, and is arranged in reverse chronological order to facilitate the rapid acquisition of key risk information. For example, the location coordinates of the storage tank with equipment number T-003 are extracted as (120.1234°, 30.5678°). Its historical fault data shows that it has experienced two leakage faults in the past 3 years, both of which are of medium risk level.
[0016] Next, real-time data on temperature, humidity, wind speed, and gas concentrations at the oil and gas station are collected. Temperature and humidity data are collected by temperature and humidity sensors deployed throughout the station, wind speed data is obtained from the wind speed sensor at the station's meteorological station, and gas concentration data (such as methane and hydrogen sulfide concentrations) are collected by combustible gas sensors and toxic gas sensors. All sensors are evenly spaced at 50-meter intervals, and the sampling frequency is set to 1Hz. Noise reduction is achieved using a moving average filtering method with a window length of 5 sampling points. The arithmetic mean of continuously collected data is taken to smooth out random noise interference while preserving the true trend of data changes. For example, if a temperature sensor continuously collects data at 32℃, 35℃, 33℃, 34℃, and 33℃, the noise-reduced temperature data after moving average filtering is 33.4℃. Similarly, the methane concentration data collected by the gas concentration sensor, after noise reduction, effectively eliminates instantaneous fluctuations caused by equipment start-up and shutdown.
[0017] Subsequently, when collecting current battery power data from the UAV's battery management system (BMS), the system reads the remaining battery percentage, voltage, current, and temperature data in real time via the wireless communication link between the UAV's BMS and the ground control station. The current battery power data uses the remaining battery percentage as the core indicator, while voltage data is combined to calibrate battery power accuracy. Specifically, the calibration process involves pre-constructing a standard discharge curve mapping table of "voltage-remaining capacity" based on different ambient temperatures and discharge currents within the system. During real-time operation, the system matches the corresponding standard discharge curve in the mapping table based on the currently collected temperature and current status, and calculates the baseline battery power based on the voltage value by looking up the table. Then, this baseline battery power is dynamically weighted and fused with the remaining battery percentage directly output by the BMS, with the fusion weight dynamically adjusted according to the current voltage's position on the discharge curve. Specifically, the system pre-defines the critical voltage value for the end of discharge in the standard discharge curve of "voltage-remaining capacity" (e.g., 3.0V for a single cell, corresponding to a total battery pack voltage of 24V). When the real-time voltage is higher than this critical value, the battery is determined to be in the discharge plateau phase. At this time, the current integration algorithm of the BMS is relatively accurate, with the weight of the baseline charge set at 0.3 and the weight of the remaining charge percentage at 0.7. When the real-time voltage is lower than or equal to this critical value, the battery is determined to have entered the steep slope zone at the end of discharge. At this time, the voltage sensitivity to the remaining capacity increases significantly, with the weight of the baseline charge set at 0.8 and the weight of the remaining charge percentage at 0.2 to correct the falsely high charge display that may occur due to internal resistance fluctuations in the BMS. Through the above segmented weight strategy, the accuracy of charge estimation in low charge states is effectively improved, avoiding misjudgments of battery life caused by relying solely on the percentage. The acquisition frequency is set to 0.5Hz to ensure real-time tracking of battery state changes. The acquired data is mapped to the [0,1] interval after min-max normalization, which facilitates subsequent energy consumption calculation and path planning. For example, if the remaining battery percentage of the drone is read as 75% and the voltage is 25.2V, the baseline battery level calculated from the table is 71.5%. After weighted fusion and calibration, the current effective battery level is determined to be 73%, and the normalized value is 0.73, providing endurance data support for subsequent path segmentation.
[0018] In step S102, the location coordinates, historical fault data, and real-time environmental sensor data are fused, and the fused data is input into a preset risk weight model to calculate the comprehensive risk value of each device. Device coordinates with comprehensive risk values exceeding a preset risk threshold are clustered to identify high-risk areas, and dynamic risk scores are calculated. A priority list of high-risk areas is obtained by sorting the dynamic risk scores in descending order, including: The location coordinates, historical fault data, and real-time environmental sensing data are structurally fused to construct a multi-dimensional feature vector; The feature vector is input into a preset risk weight model, and the comprehensive risk value of each device is calculated according to the preset weight coefficients. The comprehensive risk value is compared with a preset risk assessment threshold. If it exceeds the risk assessment threshold, it is marked as a high-risk device. The location coordinates of the high-risk equipment are clustered to divide them into multiple high-risk areas. The dynamic risk score of each high-risk area is calculated and sorted in descending order according to the dynamic risk score to generate a priority list of high-risk areas.
[0019] It should be noted that, firstly, when constructing a multi-dimensional feature vector by structurally fusing location coordinates, historical fault data, and real-time environmental sensing data, the location coordinates are first converted into relative coordinates (x, y) in the local coordinate system of the station, with the center point of the station as the origin and the unit as meters. The station's length and width extreme values are then used for minimum-maximum normalization and mapping to the [0, 1] interval to ensure the uniformity and dimensionlessness of spatial information. Historical fault data is quantified into two indicators: fault frequency (number of faults in the past 3 years, normalized to the [0, 1] interval based on the preset highest historical frequency) and fault severity (1-5 points, normalized proportionally to the [0.2, 1] interval). Real-time environmental sensing data includes normalized values of temperature, humidity, wind speed, and gas concentration (mapped to the [0, 1] interval through the upper and lower limits of the respective sensor's range). These indicators are concatenated in the order of "relative coordinate x - relative coordinate y - failure frequency - failure severity - temperature - humidity - wind speed - gas concentration" to construct an 8-dimensional feature vector that comprehensively covers spatial, historical risk and real-time environmental factors.
[0020] For example, assume that the station is 100 meters long and wide, and the highest historical failure frequency is 5 times; the relative coordinates of a certain device are (50, 30), which are normalized to 0.5 and 0.3; there have been 2 failures in the past 3 years, which are normalized to 0.4; the severity is 3 points, which are normalized to 0.6; the real-time environmental data are normalized to 0.6, 0.7, 0.3, and 0.4, and the constructed feature vector is [0.5, 0.3, 0.4, 0.6, 0.6, 0.7, 0.3, 0.4].
[0021] Subsequently, the feature vectors are input into a preset risk weighting model. When calculating the comprehensive risk value of each device according to preset weighting coefficients, the risk weighting model adopts a linear weighted model. The highest weight for historical fault severity is set to 0.3, fault frequency to 0.25, gas concentration to 0.2 (directly related to safety risk), temperature to 0.1, humidity to 0.05, wind speed to 0.05, and relative coordinates x and y to 0.025 each (to aid in characterizing regional density). The weighting coefficients are obtained based on regression analysis of historical data. The model training set contains 3 years of equipment operation data from oil and gas stations (10,000+ samples), divided into training and validation sets in a 7:3 ratio. The weighting coefficients are optimized using the least squares method to ensure minimal model prediction error. The comprehensive risk value is the weighted sum of the values of each dimension of the feature vector and their corresponding weighting coefficients. Since all input dimensions have been normalized, the comprehensive risk value strictly falls between 0 and 1; the larger the value, the higher the risk. For example, the comprehensive risk value calculated from the above feature vector is 0.4×0.25+0.6×0.3+0.4×0.2+0.6×0.1+0.7×0.05+0.3×0.05+0.5×0.025+0.3×0.025=0.49, reflecting the comprehensive risk level of the equipment.
[0022] Next, the overall risk value is compared with the preset risk assessment threshold. If it exceeds the threshold, the equipment is marked as high-risk. It should be noted that the risk assessment threshold is set based on historical failure data statistics. Analysis of the overall risk values and actual failure occurrences of all equipment over the past three years revealed that the probability of equipment failure increases significantly when the overall risk value exceeds 0.40; therefore, the base threshold is set at 0.40. Equipment in core areas of the station (such as tank areas and oil pipeline intersections) has higher safety requirements, so the threshold can be lowered to 0.35; equipment in auxiliary areas (such as equipment around office buildings) can be raised to 0.45. Those skilled in the art can adjust the threshold within the range of 0.35-0.45 according to the importance of the area. For example, if a piece of equipment has an overall risk value of 0.49, exceeding the base threshold of 0.40, it is marked as high-risk equipment; similarly, if a piece of equipment in the core area has an overall risk value of 0.38, exceeding the adjusted threshold of 0.35, it is also marked as high-risk equipment.
[0023] Next, the location coordinates of high-risk equipment are clustered to divide the area into multiple high-risk regions. The dynamic risk score for each high-risk region is calculated and sorted in descending order of the dynamic risk score. The K-means clustering algorithm is used for clustering. The training set consists of historical high-risk equipment location coordinate data (5000+ records). The number of clusters, K=5-10 (adjusted according to the site size), is determined using the elbow rule. The number of iterations is set to 100, and the convergence condition is that the sum of squared errors within each cluster changes by less than 0.001. After clustering, each cluster represents a high-risk region. The dynamic risk score for each region is calculated by multiplying the average comprehensive risk value of all high-risk equipment within the region by the square root of the number of equipment in the region (highlighting densely populated risks), and then multiplying by the real-time average environmental risk coefficient. Specifically, the quantification standard for the real-time average environmental risk coefficient is as follows: The normalized mean values of temperature, humidity, wind speed, and gas concentration transmitted from all sensors within the cluster area are extracted and assigned fixed weights of 0.2, 0.1, 0.2, and 0.5 respectively (with gas concentration having the highest weight to highlight the risk of leakage and explosion). These are then weighted and summed to obtain an environmental risk coefficient ranging from 0 to 1. It is worth noting that analysis of historical accident data reveals that regional risk decreases marginally with the increase in the number of devices. The square root function can effectively prevent the risk of large areas from being overstated. Its coefficient is obtained by fitting the risk growth curve of 5000 sets of historical accident samples. For example, a cluster area containing 5 high-risk devices has a real-time average environmental risk coefficient of 0.50 and a dynamic risk score of 0.52 × √5 × 0.50 ≈ 0.58. After sorting by dynamic risk score in descending order, this area ranks second on the priority list.
[0024] In step S103, based on the priority list, an initial inspection path is generated by combining pre-acquired terrain obstacle distribution data and UAV operating parameters, and the energy consumption estimate of the initial inspection path is calculated, including: Extract the center coordinates of each high-risk area in the priority list and generate a sequence of coordinate points in sorted order; Based on the coordinate point sequence, combined with the pre-acquired terrain and obstacle distribution data, an initial inspection path is generated; Based on the pre-acquired flight speed, hovering power, and operating parameters of the UAV, calculate the flight time for each path segment; Based on the flight duration and the preset energy consumption standard per unit time, the energy consumption value of each path segment is calculated, and the summation is used to obtain the energy consumption estimate of the initial inspection path.
[0025] It should be noted that, firstly, when extracting the center coordinates of each high-risk area in the priority list and generating the coordinate point sequence in sorted order, the center coordinates are obtained by calculating the arithmetic mean of the location coordinates of all high-risk equipment within each high-risk area. The horizontal axis is the average of the x-coordinates of all equipment, and the vertical axis is the average of the y-coordinates of all equipment, ensuring that the center coordinates represent the core location of the area. The areas are then sorted in descending order of their dynamic risk scores in the priority list, and the center coordinates of each area are sequentially concatenated to generate the coordinate point sequence. The starting point of the sequence is the coordinates of the drone's takeoff point, and the ending point is the center coordinates of the last high-risk area. The center coordinates of other areas are inserted sequentially in the middle according to the sorted order.
[0026] For example, the dynamic risk scores of the three high-risk areas in the priority list are ranked as Area A > Area B > Area C, with their center coordinates being (100,200), (300,400), and (500,300) respectively, and the takeoff point coordinates being (0,0). The generated coordinate point sequence is (0,0) → (100,200) → (300,400) → (500,300).
[0027] Subsequently, based on the coordinate point sequence and combined with pre-acquired terrain and obstacle distribution data, the A* algorithm is used for path planning when generating the initial inspection path. This algorithm can efficiently find the optimal path and avoid obstacles. The heuristic function of the A* algorithm uses a weighted sum of Manhattan distance and Euclidean distance (each with a weight of 0.5). The training set contains simulated terrain and obstacle data of oil and gas station sites (10,000+ path samples). The maximum search step is set to 1,000 steps, and the obstacle safety distance is 5 meters (to ensure that the UAV maintains a sufficient safety gap with the obstacle). The terrain data includes elevation and slope information, and the obstacle data includes the spatial coordinates and outline dimensions of buildings, oil pipelines, power lines, etc. During path planning, areas with slopes greater than 30° and all obstacle areas are avoided, generating a smooth and continuous polygonal path. For example, if there is a storage tank obstacle on the straight path from (100,200) to (300,400) in the coordinate point sequence, the A* algorithm can plan a path (100,200) → (150,250) → (250,350) → (300,400) to bypass the storage tank, which both guarantees the shortest path trend and avoids the obstacle.
[0028] In this implementation case, based on pre-acquired parameters such as the drone's flight speed, hovering power, and endurance, the flight time for each path segment is calculated. The drone's flight speed is set to 15 m / s (level flight speed, automatically decreasing to 10 m / s in headwinds and increasing to 20 m / s in tailwinds), the hovering power is set to 500 watts, and the endurance parameters include battery capacity (e.g., 1000Wh) and endurance time per unit of battery (e.g., 2 hours). Flight time is divided into flight time and hovering time for each path segment. Flight time is calculated by dividing the path segment length by the flight speed, and hovering time is set at 30 seconds for each high-risk area (for equipment inspection and filming). For example, if a path segment is 2000 meters long, with a level flight speed of 15 m / s, the flight time is 2000 ÷ 15 ≈ 133 seconds. Adding the 30-second hovering time, the total flight time for this path segment is 163 seconds.
[0029] Subsequently, based on the flight duration and the preset energy consumption standard per unit time, the energy consumption value of each path segment was calculated. The energy consumption standard per unit time was set separately for flight and hovering states. The energy consumption standard per unit time for flight state was 200Wh / h (based on the measured power conversion during UAV level flight), and for hovering state it was 500Wh / h (based on hovering power setting). This standard has been calibrated through multiple actual flight tests and can accurately reflect the energy consumption of the UAV. The energy consumption value of each path segment is the sum of flight energy consumption and hovering energy consumption. Flight energy consumption is calculated by multiplying the flight duration (converted to hours) by the flight energy consumption standard per unit time, and hovering energy consumption is calculated by multiplying the hovering duration (converted to hours) by the hovering energy consumption standard per unit time. The sum of the energy consumption values of all path segments is the estimated total energy consumption value. For example, a certain path segment has a flight time of 133 seconds (approximately 0.037 hours), and the flight energy consumption is 0.037 × 200 = 7.4Wh; the hovering time is 30 seconds (approximately 0.008 hours), and the hovering energy consumption is 0.008 × 500 = 4Wh. The total energy consumption of this path segment is 11.4Wh. The energy consumption of the initial inspection path is estimated to be 34.2Wh after adding up the three such path segments.
[0030] In step S104, if the energy consumption estimate exceeds a preset endurance threshold, high-risk tasks that meet the preset ranking conditions are retained, and the remaining tasks are merged and reorganized according to their spatial distribution distance to obtain an optimized inspection sequence, including: If the energy consumption estimate exceeds the preset endurance threshold, then the high-risk area tasks that meet the preset ranking conditions in the priority list are retained, and the remaining area tasks are classified according to spatial distribution. Calculate the spatial distance between tasks in the categorized region. If the spatial distance is lower than a preset integration distance threshold, they are merged into a combined task. The combined task refers to a set of adjacent tasks that are continuously executed while maintaining the cruise attitude. Adjust the task arrangement according to the order of prioritizing high-risk area tasks and postponing combined tasks to generate an optimized inspection sequence; The total estimated energy consumption of the optimized inspection sequence is recalculated. If it still exceeds the endurance threshold, the number of combined tasks is reduced until the total estimated energy consumption is lower than the endurance threshold.
[0031] It should be noted that if the estimated energy consumption exceeds the preset endurance threshold, high-risk area missions at the top of the priority list will be retained. The endurance threshold is based on the drone's battery capacity and safety redundancy settings. 80% of the drone's battery capacity is used as the basic endurance threshold, with 20% reserved for emergency return and sudden adjustments to avoid loss of contact due to depletion of energy. The top 50% of high-risk area tasks are retained in the priority list to ensure priority coverage of core high-risk areas. The remaining area tasks are categorized spatially using the DBSCAN clustering algorithm. This algorithm does not require a pre-set number of clusters, adapts to irregular spatial distributions, and the training set includes simulated data of oil and gas station area distribution (8000+ samples). A neighborhood radius of 50 meters and a minimum sample size of 3 are set. The 50-meter neighborhood radius is based on the effective field of view coverage radius of the UAV's onboard high-definition gimbal camera at normal cruising altitude, ensuring that equipment targets within the same cluster area can be efficiently observed with single hovering or fine-tuning of attitude. The minimum sample size of 3 is based on the lower limit of the number of basic waypoints required to form independent combined inspection routes, preventing excessive fragmentation of low-risk task areas. Tasks in spatially close areas are grouped together. For example, if a UAV has a 1000Wh battery capacity, a range threshold of 800Wh, and an estimated energy consumption of 850Wh exceeding the threshold, the top 3 high-risk tasks from the 6 areas in the priority list are retained, and the remaining 3 areas are grouped into one category using DBSCAN clustering.
[0032] Next, the spatial distance between the categorized regional tasks is calculated. If the spatial distance is lower than the preset integration distance threshold, the tasks are merged into a combined task. The spatial distance is calculated using Euclidean distance, with the center coordinates of each region as the benchmark, to accurately quantify the spatial proximity between tasks. The integration distance threshold is set based on the balance between UAV inspection efficiency and energy consumption. Specifically, by constructing a UAV dynamic energy consumption simulation model, the energy consumption difference curves of two flight modes, namely, phased close-range inspection and continuous inspection while maintaining cruising altitude, are compared and analyzed. Data calculations show that when the distance between the centers of two regions is within 100 meters, the energy consumption of continuous flight while maintaining cruising attitude is significantly lower than the energy consumed by frequent acceleration, deceleration, and altitude climb. At this time, the energy efficiency benefit of merging tasks is the greatest. Therefore, the basic threshold is set at 100 meters. In densely equipped areas of the station (such as tank clusters), it can be lowered to 50 meters, and in open areas (such as along oil pipelines), it can be raised to 150 meters. Those skilled in the art can adjust it within the range of 50-150 meters according to the station layout. Tasks in areas below this threshold are merged into combined tasks. It's important to clarify that "combined tasks" here does not refer to covering multiple target points in a single hover, but rather to linking multiple spatially adjacent independent tasks into a single, continuous flight path. When executing this combined task, the UAV maintains the same cruising altitude and constant speed, dynamically and continuously collecting data on targets along the route. This completely avoids the frequent deceleration, approach, hovering, and acceleration maneuvers between individual task points, reducing round-trip flight energy consumption and improving inspection efficiency. For example, if the center coordinates of two categorized areas are (300, 400) and (350, 430), the calculated spatial distance is approximately 64 meters, which is below the basic threshold of 100 meters, and thus they are merged into a single combined task.
[0033] Subsequently, the task arrangement was adjusted according to the order of prioritizing high-risk area tasks and relegating combined tasks to the back. When generating the optimized inspection sequence, the principle of prioritizing high-risk areas was strictly followed. High-risk area tasks were arranged at the front according to their original priority list, while combined tasks were arranged at the back according to their spatial distribution from near to far. This ensured that the inspection of core risk areas was completed first, followed by the processing of low-priority combined tasks. Each task in the sequence was marked with the coordinates of the area center, the estimated inspection time, and the estimated energy consumption, providing a clear basis for subsequent path division.
[0034] For example, the three high-risk tasks are retained and arranged in order as Task 1, Task 2, and Task 3. The combined task is called Task 4, and the generated optimized inspection sequence is Task 1 → Task 2 → Task 3 → Task 4, which clarifies the execution order and core information of each task.
[0035] Finally, the total estimated energy consumption of the optimized inspection sequence is recalculated. If it still exceeds the endurance threshold, the number of combined tasks is reduced until the total estimated energy consumption is below the endurance threshold. It should be noted that the total estimated energy consumption is recalculated using the method described in step S103 to ensure data accuracy. When reducing combined tasks, they are eliminated sequentially from low to high based on their dynamic risk scores, prioritizing the retention of higher-risk combined tasks to avoid overlooking important areas. Energy consumption is recalculated after each reduction until the total estimated energy consumption is below the endurance threshold, while ensuring full coverage of high-risk areas in the remaining tasks. For example, if the total estimated energy consumption of the optimized inspection sequence is 820Wh, still exceeding the 800Wh endurance threshold, the lowest-risk combined tasks are eliminated based on their dynamic risk scores, and the recalculated energy consumption is 780Wh, below the threshold, thus determining the final optimized inspection sequence.
[0036] In step S105, the coordinates of the takeoff point and target point in the optimized inspection sequence are extracted, and combined with the current power data, executable path segments are divided, including: Extract the takeoff point coordinates and all target point coordinates from the optimized inspection sequence; Based on the preset energy consumption coefficient per unit distance and the current power data, the maximum supported flight distance is calculated. Starting from the coordinates of the takeoff point, the straight-line distance between adjacent target point coordinates is sequentially accumulated. When the accumulated distance reaches the preset safety threshold of the maximum supported flight distance, the previous target point is divided into an executable path segment. Restart accumulating from the end of the current segment, update the current battery level and recalculate the maximum supported distance, and repeat the sequential accumulation of straight-line distance and path segment division until all target points are assigned to their corresponding path segments.
[0037] It should be noted that, firstly, when extracting the takeoff point coordinates and all target point coordinates from the optimized inspection sequence, the takeoff point coordinates are the coordinates of the fixed takeoff and landing field of the UAV preset by the oil and gas station, based on the station's GIS coordinate system, accurate to the meter level, to ensure that the takeoff position is consistent each time; the target point coordinates are the coordinates of the area center corresponding to each task in the optimized sequence, extracted sequentially according to the task execution order, and organized into an ordered coordinate list, with each coordinate bound to the corresponding task identifier, which facilitates subsequent distance calculation and segment division. For example, if the takeoff point coordinates are (0,0), the optimized inspection sequence contains 4 tasks, and the corresponding target point coordinates are (150,200), (300,400), (450,350), (600,500) in sequence, the generated coordinate list is [(0,0), (150,200), (300,400), (450,350), (600,500)].
[0038] Next, based on the preset energy consumption coefficient per unit distance and the current battery level, the maximum supported flight distance is calculated. Starting from the takeoff point, the straight-line distances between adjacent target points are sequentially accumulated. When the accumulated distance reaches the preset safety ratio threshold of the maximum supported flight distance, the previous target points are divided into an executable path segment. It should be noted that the energy consumption coefficient per unit distance is calibrated based on actual UAV test data. The training set contains over 10,000 sets of energy consumption data under different flight conditions (level flight, headwind, tailwind). A base coefficient of 0.1Wh / m (level flight) is obtained through linear regression fitting. The coefficient is increased to 0.15Wh / m in headwind conditions and decreased to 0.08Wh / m in tailwind conditions, and can be dynamically adjusted according to real-time wind speed. The maximum supported flight distance is equal to the current battery level divided by the energy consumption coefficient per unit distance. In practical implementation scenarios, to avoid insufficient absolute reserve margin due to simply calculating as a percentage when the battery is low, a preset fixed safety threshold (e.g., forcibly retaining an absolute reserve flight distance of 50 meters) is usually introduced as a double safety net while implementing the aforementioned preset safety ratio threshold (e.g., 80%). The actual cumulative upper limit executed by the system is the smaller of 80% of the maximum supported flight distance and the maximum supported flight distance minus 50 meters. The straight-line distance between adjacent target points is calculated using Euclidean distance and accumulated in the order of the coordinate list. For example, assuming the drone is fully charged with a current battery level of 100Wh and an initial maximum supported flight distance of 1000 meters; the system calculates the first segment's actual cumulative upper limit to be 800 meters (taking the smaller value between 1000×0.8 and 1000-50); accumulating according to the coordinate list, the distance from (0,0) to (150,200) is 250 meters, then to (300,400) is another 250 meters, and then to (450,350) is approximately 158 meters, totaling about 658 meters; if it were to proceed to (600,500), it would need to add approximately 212 meters, totaling about 870 meters, exceeding the 800-meter limit. Therefore, (0,0)→(150,200)→(300,400)→(450,350) is divided into the first executable path segment.
[0039] Finally, the accumulation restarts from the end of the current segment, updating the current battery level and recalculating the maximum supported distance. This sequential accumulation and path segment division process is repeated until all target points are assigned to their corresponding path segments. Then, the end coordinates of the first segment are used as the new accumulation starting point, and adjacent distances are accumulated sequentially according to the remaining target point coordinates. During actual inspections, the system does not consider mid-flight recharging; instead, it continuously deducts planning based on the state of the same battery during a single takeoff. Before dividing a new segment, the system deducts the planned flight distance from the previous segment, updating the current remaining battery level and remaining maximum supported flight distance accordingly. Simultaneously, the aforementioned proportional limit and fixed safety threshold mechanism continues to be used to calculate the actual accumulation limit for the next segment. Each divided path segment must be labeled with its start coordinates, end coordinates, included task list, and estimated flight distance to ensure clear and traceable execution during segmentation. If the final accumulated distance for the remaining target points does not reach the upper limit, it is still divided into a separate segment. For example, the endpoint of the first segment is (450, 350), and the preceding planned flight distance has consumed 658 meters. The system updates the current maximum remaining supported flight distance to 342 meters (1000 meters - 658 meters). When planning the second segment, the upper limit calculated based on 80% is 273.6 meters, and the upper limit calculated after deducting the 50-meter fixed threshold is 292 meters. The system takes the smaller value to determine the actual cumulative upper limit of the second segment as 273.6 meters. At this time, the remaining target point is (600, 500). The distance from (450, 350) to (600, 500) is approximately 212 meters, which does not reach the 273.6-meter upper limit. Therefore, it is divided into a second executable path segment, ultimately forming two complete path segments that cover all target points.
[0040] In step S106, the drone's position and energy consumption during the execution of the path segment are tracked in real time. If the deviation between the energy consumption and the estimated energy consumption exceeds a preset deviation threshold, the remaining tasks are reordered to determine the updated inspection order, including: Real-time acquisition of the drone's position data and battery power consumption data during the execution of the aforementioned path segments, and calculation of the actual energy consumption per unit distance; The energy consumption deviation value is obtained by calculating the difference between the actual energy consumption and the preset estimated energy consumption per unit distance. If the energy consumption deviation value exceeds the preset deviation threshold, then the remaining unexecuted tasks are intercepted, and the target point coordinates of each remaining task are extracted. Calculate the relative distance between the target point coordinates and the current position of the UAV, assign priority weights to each task based on the remaining battery power data, and reorder the remaining tasks according to the priority weights to determine the update inspection order.
[0041] It should be noted that when collecting real-time position and battery consumption data during the drone's flight path segments to calculate the actual energy consumption per unit distance, the position data is collected via the drone's onboard GPS module at a sampling frequency of 1Hz, with a positioning accuracy of ±1 meter, ensuring real-time tracking of the flight trajectory. Battery consumption data is collected via the Battery Management System (BMS), including parameters such as remaining power, voltage, and current, at a sampling frequency of 0.5Hz, accurately reflecting changes in energy consumption. The actual energy consumption per unit distance is calculated as the ratio of the distance flown to the amount of power consumed. The distance flown is obtained by summing the GPS-collected position data using Euclidean distance, and the power consumed is the difference between the initial power level and the current remaining power level.
[0042] For example, when the drone is executing a certain path segment, it has flown a total distance of 500 meters and consumed 60Wh of electricity. The calculated actual energy consumption per unit distance is 0.12Wh / meter.
[0043] Subsequently, the difference between the actual energy consumption and the preset estimated energy consumption per unit distance is calculated to obtain the energy consumption deviation value. The preset estimated energy consumption per unit distance is the base coefficient calibrated in step S105 (0.1Wh / m for level flight), dynamically adjusted according to the real-time flight environment. The energy consumption deviation value is the actual energy consumption per unit distance minus the estimated energy consumption per unit distance. A positive difference indicates that the actual energy consumption is higher than the estimate, while a negative difference indicates that it is lower than the estimate. The larger the absolute value, the more significant the deviation. For example, if the estimated energy consumption per unit distance is 0.1Wh / m and the actual energy consumption is 0.12Wh / m, the calculated energy consumption deviation value is 0.02Wh / m, indicating that the actual energy consumption is higher than the estimate.
[0044] Next, if the energy consumption deviation exceeds a preset deviation threshold, the remaining unexecuted tasks are extracted. When extracting the target point coordinates of each remaining task, the deviation threshold is set based on historical flight energy consumption deviation data statistics. Extensive field tests show that during normal flight, the energy consumption deviation is mostly below 0.03 Wh / m. Exceeding this value may lead to insufficient power later; therefore, the basic threshold is set at 0.03 Wh / m. In complex environments such as strong winds and high temperatures, the threshold can be increased to 0.04 Wh / m; in stable environments such as calm winds and normal temperatures, it can be decreased to 0.02 Wh / m. Those skilled in the art can adjust it within the range of 0.02-0.04 Wh / m according to the complexity of the environment. Remaining tasks are extracted according to the task execution order of the path segments, retaining tasks that have not yet started, and extracting the center coordinates of the corresponding area for each task to form a list of remaining target point coordinates. For example, if the energy consumption deviation value of 0.025Wh / m does not exceed the basic threshold of 0.03Wh / m, there is no need to truncate the remaining tasks; if the deviation value is 0.035Wh / m, which exceeds the threshold, the two unexecuted tasks are truncated, and the corresponding target point coordinates (450, 350) and (600, 500) are extracted.
[0045] Finally, the relative distance between the target point coordinates and the drone's current position is calculated. Based on the remaining battery power data, each task is assigned a priority weight, and the remaining tasks are reordered according to the priority weight. When determining the updated inspection order, the relative distance is calculated using the Euclidean distance between the drone's current GPS coordinates and the coordinates of the remaining target points, thus quantifying the spatial relationship between the task and the current position. Priority weights are calculated using a weighted summation method. The weight of the remaining power percentage is set to 0.4 (the more remaining power, the higher the priority for handling long-distance tasks), and the weight of the reciprocal of the relative distance is set to 0.6 (the closer the distance, the lower the energy consumption, and the higher the priority for execution). The specific setting of this weight combination is based on importing over 5000 sets of historical interruption inspection data covering different scale stations and wind speed environments into the simulation test platform. A comprehensive evaluation function is constructed with the dual constraints of maximizing the remaining task completion rate and minimizing the low power forced return trigger rate. The weight ratio is traversed in the interval [0,1] with a step size of 0.05 to perform optimization calculations using the control variable method. The results show that when the remaining power weight is 0.4 and the reciprocal of the distance weight is 0.6, the evaluation function obtains the global optimal solution, thus scientifically balancing power utilization and task execution efficiency. The remaining power data is mapped to the [0,1] interval using min-max normalization. The reciprocal of the relative distance is then used for normalization using the maximum and minimum reciprocal values of the current remaining task set. The two are then weighted and summed according to the above weights to obtain the priority weight of each task. Finally, the updated inspection order is obtained by sorting the data in descending order of weights.
[0046] For example, the drone's current position is (300, 400), with a remaining battery power of 40Wh (normalized to 0.5). The relative distance between the remaining target points (450, 350) and (600, 500) is approximately 158 meters (reciprocal normalized to 0.8), and the relative distance between them is approximately 316 meters (reciprocal normalized to 0.4). The priority weight of the former is calculated to be 0.5×0.4+0.8×0.6=0.68, and that of the latter is 0.5×0.4+0.4×0.6=0.44. Therefore, the update inspection order is (450, 350) → (600, 500).
[0047] In step S107, a control command sequence is generated according to the updated inspection order, sent to the UAV system, and an execution feedback log is obtained, including: Extract the three-dimensional coordinates, flight altitude, and preset hovering duration requirements of each task node in the updated inspection sequence to generate an initial control command set; Based on the terrain obstacle distribution data, collision detection and path smoothing are performed on the initial control command set to obtain an optimized control command sequence; The optimized control command sequence is sent to the UAV, and the execution status feedback data of the UAV is received to form an execution feedback log.
[0048] It should be noted that, firstly, when generating the initial control command set, the three-dimensional coordinates, flight altitude, and preset hovering duration requirements of each task node in the inspection sequence are extracted. The three-dimensional coordinates are composed of the target point's planar coordinates and the station's altitude data. The planar coordinates are obtained from the optimized task target point, and the altitude data is acquired through the station's GIS system to accurately reflect the terrain height. The flight altitude is set based on the highest equipment height within the task area plus a 5-meter safety distance. This safety distance is the base value; it can be increased to 8 meters in densely populated areas (such as tank clusters) and decreased to 3 meters in open areas (such as along oil pipelines), balancing inspection visibility and collision risk. The hovering duration is set according to the task risk level: 40 seconds in high-risk areas (to ensure sufficient imaging and detection), and 20 seconds in medium- and low-risk areas. The initial control command set includes waypoint sequences, flight speed (15 m / s), flight altitude, hovering duration, camera shooting trigger commands, etc., arranged in a format that the UAV flight control system can parse.
[0049] For example, the three-dimensional coordinates of a high-risk mission node are (150, 200, 50), the maximum height of equipment in the area is 50 meters, the flight altitude is set to 55 meters, the hovering time is 40 seconds, and the generated initial control command includes the flight parameters and shooting command for this waypoint.
[0050] Next, based on the terrain obstacle distribution data, collision detection and path smoothing were performed on the initial control command set to obtain the optimized control command sequence. For collision detection, the OBB (Oriented Bounding Box) algorithm was used, which can accurately adapt to collision judgments of irregular obstacles. The training set contained 3D model data of oil and gas station obstacles (over 10,000 sets, covering buildings, pipelines, power lines, etc.), with a bounding box expansion factor of 1.2 set to ensure sufficient safety clearance between the UAV and obstacles. Path smoothing employed a B-spline curve algorithm, selecting key waypoints of the initial path as control points, and setting the curve order to 3 to ensure a continuous and smooth optimized path that conforms to UAV flight dynamics constraints.
[0051] It should be noted that the process first uses the OBB algorithm to detect the collision risk between the initial path and obstacles. If a collision is found, the waypoint coordinates are adjusted, and then the path is smoothed using B-spline curves to generate a collision-free, low-energy optimized control command sequence. For example, if a segment of the initial path connecting waypoints poses a collision risk with an oil pipeline, adjusting the waypoint coordinates and smoothing the path using B-spline curves results in a continuous curved path, avoiding collisions and ensuring smooth flight.
[0052] Next, optimized control commands are sent to the UAV, and the execution status feedback data from the UAV is received to form the execution feedback log. A 2.4GHz wireless data link is used for command transmission, with a baud rate of 9600 to ensure low latency and stability. After receiving commands, the UAV executes flight, hovering, and shooting operations sequentially. Onboard GPS, inertial measurement unit, cameras, and other sensors collect execution status data in real time, including current position, flight attitude, remaining battery power, shooting completion status, and whether any anomalies (such as obstacle avoidance triggering) have occurred. The ground control station integrates this feedback data by timestamp (accurate to milliseconds) and stores it in a structured format as an execution feedback log. The log contains key information such as command ID, execution time, status code (normal execution / abnormal interruption), actual energy consumption, and task completion status, providing a basis for subsequent coverage analysis.
[0053] For example, after the optimized control command is sent, the drone feedback data shows that it flies to the position (150,200,55) according to the preset path, hovers for 40 seconds and completes the shooting, the battery has 65% remaining power, and the status code is normal. All of this information is recorded in the execution feedback log.
[0054] In step S108, the device inspection coverage rate in the execution feedback log is analyzed to check whether all high-risk areas are covered. If not, appropriate inspection paths are added until full coverage of high-risk areas is confirmed. A complete inspection report is then generated, including: Extract the coordinates and quantity of inspected equipment from the execution feedback log, and calculate the equipment inspection coverage rate; Compare the coordinates of the inspected equipment with the location range of the high-risk area to determine whether the high-risk area is fully covered. If there are uncovered high-risk areas, a suitable supplementary inspection path will be generated based on the coordinates of the uncovered areas, environmental data, and the remaining status of the drone. Execute the supplementary inspection path and update the execution feedback log. Repeat the coverage check and path supplementation steps until the high-risk area is fully covered, and generate a complete inspection report.
[0055] It should be noted that, firstly, when calculating the equipment inspection coverage rate by extracting the coordinates and quantity of inspected equipment from the execution feedback log, the coordinates of the inspected equipment are the actual location coordinates of the equipment captured by the UAV's onboard camera and confirmed by image recognition. Based on the station's GIS coordinate system, these coordinates are precisely linked to specific equipment numbers. The quantity is the total number of unique equipment corresponding to the extracted coordinates, avoiding duplicate counting. The equipment inspection coverage rate is calculated by dividing the number of inspected equipment by the total number of equipment in the high-risk area of the oil and gas station and then multiplying by 100%, which directly reflects the completion rate of equipment inspections in high-risk areas. For example, if there are 50 critical pieces of equipment in the high-risk area of the oil and gas station, and the valid inspection coordinates of 42 pieces of equipment are extracted from the execution feedback log, the calculated equipment inspection coverage rate is 84%.
[0056] Next, the coordinates of the inspected devices are compared with the location range of the high-risk area to determine whether the high-risk area is fully covered. The location range of the high-risk area is the boundary of the clustered area (such as a rectangular boundary or a polygonal boundary) in step S102. The Point in Polygon (PIP) algorithm is used to determine whether the coordinates of each high-risk device are included in the inspected coordinate set. At the same time, it is verified whether all inspected coordinates fall within the boundary of the high-risk area to avoid deviation of the inspection range. If the coordinates of all high-risk devices can be found to match in the inspected coordinate set (with a positional deviation of no more than 5 meters), it is determined to be full coverage; otherwise, it is determined that there are uncovered areas. For example, if the polygonal boundary of a high-risk area contains 30 devices, and the comparison finds that the coordinates of 8 of these devices do not appear in the inspected coordinate set and there are no other inspected coordinates to match, it is determined that the high-risk area is not fully covered.
[0057] If there are uncovered high-risk areas, a suitable supplementary inspection path is generated based on the coordinates of the uncovered areas, environmental data, and the remaining status of the drone. The coordinates of the uncovered areas are taken as the center coordinates of the uninspected equipment. The environmental data includes the real-time wind speed and gas concentration in the area (obtained from the station's environmental sensors). The remaining status of the drone includes the remaining battery power, current position, and remaining flight time (calculated based on the remaining battery power and energy consumption coefficient per unit distance). The supplementary inspection path is planned using the A* algorithm, and flight parameters are adjusted in conjunction with real-time environmental data (reducing flight speed in headwinds) to avoid obstacles and high-risk environmental areas. The flight altitude is set at the highest altitude of the equipment in the uncovered area plus a safety distance of 5 meters, and the hovering time is maintained at 40 seconds.
[0058] For example, the center coordinates of the uncovered area are (350, 400), the current position of the drone is (450, 350), the remaining power is 30Wh, the energy consumption per unit distance is 0.1Wh / meter, the planned supplementary inspection path is (450, 350) → (380, 380) → (350, 400), avoiding the storage tank obstacle in the middle, the expected flight distance is 180 meters, the energy consumption is 18Wh, and the remaining power can support it.
[0059] Finally, the supplementary inspection path is executed and the execution feedback log is updated. The coverage check and path supplementation steps are repeated until the high-risk area is fully covered. When generating a complete inspection report, the execution process of the supplementary inspection path is the same as step S107. The UAV flies and inspects according to the optimized control commands, and provides real-time feedback on execution status data. The updated execution feedback log adds information such as the coordinates of the supplementary inspected equipment, energy consumption, and completion status. After each supplementary inspection, the equipment inspection coverage is recalculated. If it still does not reach 100%, the above path generation and execution steps are repeated until all high-risk equipment has been inspected. The complete inspection report includes structured content such as basic inspection information (time, UAV number), high-risk area coverage (100% coverage), inspection status of each device (normal / suspected fault), energy consumption statistics, and environmental data records, providing a comprehensive reference for station operation and maintenance.
[0060] For example, after the supplementary inspection is completed, the updated execution feedback log adds the inspection coordinates of 8 devices, recalculates the coverage rate to 100%, and generates a complete inspection report that records that the inspection covered all high-risk areas, found 2 devices with suspected leakage traces, the total energy consumption was 95Wh, and the wind speed and gas concentration were within the safe range.
[0061] In summary, this invention discloses an intelligent inspection path planning method for oil and gas station unmanned aerial vehicles (UAVs). The method includes acquiring equipment location, historical fault data, real-time environmental data, and UAV battery power data; calculating a comprehensive risk value to generate a priority list of high-risk areas; generating an initial inspection path and calculating energy consumption; optimizing the inspection sequence when the endurance threshold is exceeded; dividing the executable path into segments; tracking energy consumption deviations in real time and dynamically adjusting the remaining task order; generating control commands and receiving feedback; supplementing uncovered high-risk areas; and generating a complete inspection report. This achieves intelligent optimization of inspection paths, meeting the safety, efficiency, and comprehensiveness requirements of station operation and maintenance.
[0062] Reference Figure 2 The second embodiment of the present invention provides an intelligent inspection path planning system for oil and gas station drones, comprising: The data acquisition module is used to acquire the location coordinates of various equipment in the oil and gas station, historical fault data, real-time environmental sensor data, and the current power data of the drone; The risk ranking module is used to integrate the location coordinates, the historical fault data and the real-time environmental sensing data, and input the integrated data into a preset risk weight model to calculate the comprehensive risk value of each device. The coordinates of devices whose comprehensive risk values exceed a preset risk threshold are clustered to divide high-risk areas, and dynamic risk scores are calculated. The high-risk areas are then sorted in descending order according to the dynamic risk scores to obtain a priority list of high-risk areas. The path generation module is used to generate an initial inspection path based on the priority list, combined with pre-acquired terrain obstacle distribution data and UAV operating parameters, and to calculate the energy consumption estimate of the initial inspection path. The sequence optimization module is used to retain high-risk tasks that meet the preset ranking conditions and merge and reorganize the remaining tasks according to the spatial distribution distance if the energy consumption estimate exceeds the preset endurance threshold, so as to obtain an optimized inspection sequence. The segmentation module is used to extract the coordinates of the takeoff point and the target point in the optimized inspection sequence, and combine them with the current power data to divide the path into executable segments. The dynamic adjustment module is used to track the drone's position and energy consumption in real time during the execution of the path segment. If the deviation between the energy consumption and the energy consumption estimate exceeds a preset deviation threshold, the remaining tasks are reordered and the inspection order is updated. The instruction execution module is used to generate a sequence of control instructions according to the updated inspection order, send it to the UAV system, and obtain the execution feedback log. The report generation module is used to analyze the device inspection coverage in the execution feedback log, check whether high-risk areas are fully covered, and if not, supplement the appropriate inspection path until the high-risk areas are confirmed to be fully covered, and then generate a complete inspection report.
[0063] It should be noted that the intelligent inspection path planning system for oil and gas stations provided in this embodiment of the invention is used to execute all the process steps of the intelligent inspection path planning method for oil and gas stations provided in the above embodiment. The working principles and beneficial effects of the two are one-to-one, so they will not be described again.
[0064] It should be noted that the system embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Furthermore, in the accompanying drawings of the system embodiments provided by this invention, the connection relationships between modules indicate that they have communication connections, which can be specifically implemented as one or more communication buses or signal lines. Those skilled in the art can understand and implement this without any creative effort.
[0065] The specific embodiments described above further illustrate the purpose, technical solution, and beneficial effects of the present invention. It should be understood that the above descriptions are merely specific embodiments of the present invention and are not intended to limit the scope of protection of the present invention. In particular, it should be noted that any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention for those skilled in the art.
Claims
1. A method for intelligent inspection path planning by unmanned aerial vehicles (UAVs) at oil and gas stations, characterized in that, include: Acquire the location coordinates, historical fault data, real-time environmental sensor data, and current battery data of each piece of equipment at the oil and gas station; The location coordinates, historical fault data and real-time environmental sensing data are integrated, and the integrated data is input into a preset risk weight model to calculate the comprehensive risk value of each device. The coordinates of devices whose comprehensive risk values exceed a preset risk threshold are clustered to divide high-risk areas, and dynamic risk scores are calculated. The high-risk areas are then sorted in descending order according to the dynamic risk scores to obtain a priority list of high-risk areas. Based on the priority list, an initial inspection path is generated by combining the pre-acquired terrain obstacle distribution data and UAV operating parameters, and the energy consumption estimate of the initial inspection path is calculated. If the energy consumption estimate exceeds the preset endurance threshold, then high-risk tasks that meet the preset ranking conditions are retained, and the remaining tasks are merged and reorganized according to spatial distribution distance to obtain an optimized inspection sequence. Extract the coordinates of the takeoff point and target point from the optimized inspection sequence, and combine them with the current power data to divide the executable path segments; The drone's position and energy consumption are tracked in real time during the execution of the path segment. If the deviation between the energy consumption and the energy consumption estimate exceeds a preset deviation threshold, the remaining tasks are reordered and the inspection order is updated. A control command sequence is generated based on the updated inspection order, sent to the UAV system, and an execution feedback log is obtained. Analyze the device inspection coverage in the execution feedback log, check whether high-risk areas are fully covered, and if not, supplement the appropriate inspection path until the high-risk areas are confirmed to be fully covered, and then generate a complete inspection report.
2. The intelligent inspection path planning method for oil and gas station unmanned aerial vehicles according to claim 1, characterized in that, The acquisition of the location coordinates of each piece of equipment at the oil and gas station, historical fault data, real-time environmental sensor data, and the current battery level of the drone includes: Extract the location coordinates and historical fault data of each device from a pre-established equipment risk database; Real-time data on temperature, humidity, wind speed and gas concentration at oil and gas stations are collected and then denoised to obtain real-time environmental sensing data. Read data from the drone's battery management system and collect current battery level data.
3. The intelligent inspection path planning method for oil and gas station unmanned aerial vehicles according to claim 1, characterized in that, The process involves fusing the location coordinates, historical fault data, and real-time environmental sensor data, and inputting the fused data into a preset risk weight model to calculate the comprehensive risk value of each device. Device coordinates with comprehensive risk values exceeding a preset risk threshold are clustered to identify high-risk areas, and dynamic risk scores are calculated. A priority list of high-risk areas is then obtained by sorting the dynamic risk scores in descending order, including: The location coordinates, historical fault data, and real-time environmental sensing data are structurally fused to construct a multi-dimensional feature vector; The feature vector is input into a preset risk weight model, and the comprehensive risk value of each device is calculated according to the preset weight coefficients. The comprehensive risk value is compared with a preset risk assessment threshold. If it exceeds the risk assessment threshold, it is marked as a high-risk device. The location coordinates of the high-risk equipment are clustered to divide them into multiple high-risk areas. The dynamic risk score of each high-risk area is calculated and sorted in descending order according to the dynamic risk score to generate a priority list of high-risk areas.
4. The intelligent inspection path planning method for oil and gas station unmanned aerial vehicles according to claim 1, characterized in that, The step of generating an initial inspection path based on the priority list, combined with pre-acquired terrain obstacle distribution data and UAV operating parameters, and calculating the energy consumption estimate of the initial inspection path includes: Extract the center coordinates of each high-risk area in the priority list and generate a sequence of coordinate points in sorted order; Based on the coordinate point sequence, combined with the pre-acquired terrain and obstacle distribution data, an initial inspection path is generated; Based on the pre-acquired flight speed, hovering power, and operating parameters of the UAV, calculate the flight time for each path segment; Based on the flight duration and the preset energy consumption standard per unit time, the energy consumption value of each path segment is calculated, and the summation is used to obtain the energy consumption estimate of the initial inspection path.
5. The intelligent inspection path planning method for oil and gas station unmanned aerial vehicles according to claim 1, characterized in that, If the estimated energy consumption exceeds a preset endurance threshold, then high-risk tasks that meet the preset ranking conditions are retained, and the remaining tasks are merged and reorganized according to their spatial distribution distance to obtain an optimized inspection sequence, including: If the energy consumption estimate exceeds the preset endurance threshold, then the high-risk area tasks that meet the preset ranking conditions in the priority list are retained, and the remaining area tasks are classified according to spatial distribution. Calculate the spatial distance between tasks in the categorized region. If the spatial distance is lower than a preset integration distance threshold, they are merged into a combined task. The combined task refers to a set of adjacent tasks that are continuously executed while maintaining the cruise attitude. Adjust the task arrangement according to the order of prioritizing high-risk area tasks and postponing combined tasks to generate an optimized inspection sequence; The total estimated energy consumption of the optimized inspection sequence is recalculated. If it still exceeds the endurance threshold, the number of combined tasks is reduced until the total estimated energy consumption is lower than the endurance threshold.
6. The intelligent inspection path planning method for oil and gas station unmanned aerial vehicles according to claim 1, characterized in that, The step involves extracting the coordinates of the takeoff point and target point from the optimized inspection sequence, combining them with the current battery data, and dividing the path into executable segments, including: Extract the takeoff point coordinates and all target point coordinates from the optimized inspection sequence; Based on the preset energy consumption coefficient per unit distance and the current power data, the maximum supported flight distance is calculated. Starting from the coordinates of the takeoff point, the straight-line distance between adjacent target point coordinates is sequentially accumulated. When the accumulated distance reaches the preset safety threshold of the maximum supported flight distance, the previous target point is divided into an executable path segment. Restart accumulating from the end of the current segment, update the current battery level and recalculate the maximum supported distance, and repeat the sequential accumulation of straight-line distance and path segment division until all target points are assigned to their corresponding path segments.
7. The method for intelligent inspection path planning of oil and gas station unmanned aerial vehicles according to claim 1, characterized in that, The real-time tracking of the drone's position and energy consumption during the execution of the path segment, if the deviation between the energy consumption and the estimated energy consumption exceeds a preset deviation threshold, reorders the remaining tasks and determines the updated inspection order, including: Real-time acquisition of the drone's position data and battery power consumption data during the execution of the aforementioned path segments, and calculation of the actual energy consumption per unit distance; The energy consumption deviation value is obtained by calculating the difference between the actual energy consumption and the preset estimated energy consumption per unit distance. If the energy consumption deviation value exceeds the preset deviation threshold, then the remaining unexecuted tasks are intercepted, and the target point coordinates of each remaining task are extracted. Calculate the relative distance between the target point coordinates and the current position of the UAV, assign priority weights to each task based on the remaining battery power data, and reorder the remaining tasks according to the priority weights to determine the update inspection order.
8. The method for intelligent inspection path planning of oil and gas station unmanned aerial vehicles according to claim 1, characterized in that, The step of generating a control command sequence based on the updated inspection order, sending it to the UAV system, and obtaining the execution feedback log includes: Extract the three-dimensional coordinates, flight altitude, and preset hovering duration requirements of each task node in the updated inspection sequence to generate an initial control command set; Based on the terrain obstacle distribution data, collision detection and path smoothing are performed on the initial control command set to obtain an optimized control command sequence; The optimized control command sequence is sent to the UAV, and the execution status feedback data of the UAV is received to form an execution feedback log.
9. The intelligent inspection path planning method for oil and gas station unmanned aerial vehicles according to claim 1, characterized in that, The analysis of the device inspection coverage in the execution feedback log checks whether high-risk areas are fully covered. If not, appropriate inspection paths are added until full coverage of high-risk areas is confirmed, and then a complete inspection report is generated, including: Extract the coordinates and quantity of inspected equipment from the execution feedback log, and calculate the equipment inspection coverage rate; Compare the coordinates of the inspected equipment with the location range of the high-risk area to determine whether the high-risk area is fully covered. If there are uncovered high-risk areas, a suitable supplementary inspection path will be generated based on the coordinates of the uncovered areas, environmental data, and the remaining status of the drone. Execute the supplementary inspection path and update the execution feedback log. Repeat the coverage check and path supplementation steps until the high-risk area is fully covered, and generate a complete inspection report.
10. A path planning system for intelligent inspection of oil and gas stations using unmanned aerial vehicles (UAVs), used to implement the path planning method for intelligent inspection of oil and gas stations using UAVs as described in any one of claims 1 to 9, characterized in that, include: The data acquisition module is used to acquire the location coordinates of various equipment in the oil and gas station, historical fault data, real-time environmental sensor data, and the current power data of the drone; The risk ranking module is used to integrate the location coordinates, the historical fault data and the real-time environmental sensing data, and input the integrated data into a preset risk weight model to calculate the comprehensive risk value of each device. The coordinates of devices whose comprehensive risk values exceed a preset risk threshold are clustered to divide high-risk areas, and dynamic risk scores are calculated. The high-risk areas are then sorted in descending order according to the dynamic risk scores to obtain a priority list of high-risk areas. The path generation module is used to generate an initial inspection path based on the priority list, combined with pre-acquired terrain obstacle distribution data and UAV operating parameters, and to calculate the energy consumption estimate of the initial inspection path. The sequence optimization module is used to retain high-risk tasks that meet the preset ranking conditions and merge and reorganize the remaining tasks according to the spatial distribution distance if the energy consumption estimate exceeds the preset endurance threshold, so as to obtain an optimized inspection sequence. The segmentation module is used to extract the coordinates of the takeoff point and the target point in the optimized inspection sequence, and combine them with the current power data to divide the path into executable segments. The dynamic adjustment module is used to track the drone's position and energy consumption in real time during the execution of the path segment. If the deviation between the energy consumption and the energy consumption estimate exceeds a preset deviation threshold, the remaining tasks are reordered and the inspection order is updated. The instruction execution module is used to generate a sequence of control instructions according to the updated inspection order, send it to the UAV system, and obtain the execution feedback log. The report generation module is used to analyze the device inspection coverage in the execution feedback log, check whether high-risk areas are fully covered, and if not, supplement the appropriate inspection path until the high-risk areas are confirmed to be fully covered, and then generate a complete inspection report.