Disclosure of Invention
One or more embodiments of the present disclosure provide a method, an apparatus, and a device for oil well inspection based on multiple unmanned aerial vehicles, which are used for solving the following technical problems: how to provide an unmanned aerial vehicle inspection method capable of improving the inspection efficiency and inspection accuracy of an oil well.
One or more embodiments of the present disclosure adopt the following technical solutions:
one or more embodiments of the present specification provide a multi-unmanned aerial vehicle-based oil well inspection method, including:
acquiring an oil well inspection task; the oil well inspection task comprises geographic coordinate positions of all oil wells in an area to be inspected;
dividing an area to be inspected of the oil well inspection task into a plurality of inspection subareas, and distributing a plurality of unmanned aerial vehicles with corresponding functions for each inspection subarea;
determining the optimal flight path of each unmanned aerial vehicle in the plurality of patrol sub-areas;
controlling the unmanned aerial vehicle to acquire images in a patrol sub-area according to the optimal flight path, and acquiring an initial shooting image of the oil well;
determining overlapping areas of a plurality of unmanned aerial vehicle initial shooting images in each inspection subarea according to the position coordinates of the initial shooting images;
Filtering the overlapped area of each inspection subarea to obtain a clear image of each inspection subarea as an image to be analyzed;
inputting the image to be analyzed meeting the requirements of each inspection subarea into a preset oil well hidden danger identification network model, and outputting the type and position coordinates of the potential safety hazards of the oil well.
Optionally, in one or more embodiments of the present disclosure, the dividing the area to be inspected of the oil well inspection task into a plurality of inspection sub-areas specifically includes:
acquiring historical inspection actions of all oil well equipment in the area to be inspected;
performing cluster analysis on the historical inspection actions based on a cluster algorithm to obtain a cluster center of the historical inspection actions within a preset distance threshold; wherein, the history inspection action includes: inspection of suspicious personnel, oil leakage inspection of oil well equipment, inspection of dangerous objects and inspection of combustible objects;
and dividing the region to be inspected according to the clustering range of the clustering center to obtain a plurality of inspection sub-regions.
Optionally, in one or more embodiments of the present disclosure, the determining, according to the determining, a preset optimal flight path in the multiple sub-areas specifically includes:
Determining initial oil well coordinates and target oil well coordinates of the unmanned aerial vehicle according to the coordinates of the oil wells in the inspection area and the importance level of the oil wells;
determining the flying height of the unmanned aerial vehicle based on the inspection task of the unmanned aerial vehicle;
intercepting a two-dimensional plan of the patrol sub-area according to the flying height;
determining a flight area of the unmanned aerial vehicle based on the two-dimensional plan;
determining an unmanned aerial vehicle passing path in the patrol sub-area according to the flight area of the unmanned aerial vehicle, the starting point oil well coordinates and the target oil well coordinates of the unmanned aerial vehicle;
and analyzing the unmanned aerial vehicle passing path based on a variable neighborhood search algorithm to obtain the optimal flight path of the patrol sub-area.
Optionally, in one or more embodiments of the present disclosure, after the determining the preset optimal flight path in the plurality of sub-areas, the method further includes:
selecting a plurality of shooting positions in the optimal flight path of each patrol sub-area;
and setting shooting angles and shooting parameters at each shooting position of the unmanned aerial vehicle according to the shooting positions and the range of the patrol sub-area, so that the shooting images cover preset fault patrol points of the oil well in the patrol sub-area.
Optionally, in one or more embodiments of the present disclosure, before the inputting the image to be analyzed meeting the requirements of each inspection subarea into a preset oil well hidden danger identification network model, the method further includes:
performing gray level correction and self-adaptive histogram equalization processing on the images to be analyzed of each inspection subarea to obtain corrected images of the images to be analyzed;
processing the corrected image based on a preset filtering mode, removing noise data of the corrected image, and obtaining a denoising image;
and taking the denoising image as an image to be analyzed meeting the requirements of each inspection subarea.
Optionally, in one or more embodiments of the present disclosure, the processing the corrected image based on a preset filtering manner, removing noise data of the corrected image, and obtaining a denoised image specifically includes:
determining parameters of wavelet transformation according to the estimated noise intensity of the corrected image; wherein the parameters include: wavelet basis function, decomposition layer number and threshold function;
decomposing the correction image according to the parameters of the wavelet transformation to obtain a high-frequency component and a low-frequency component of the correction image;
Projecting the high-frequency component into a low-frequency space by using a Gaussian random matrix to obtain a measured value after filtering a noise vector;
and carrying out wavelet inverse transformation on the low-frequency component and the measured value so as to reconstruct the denoising image.
Optionally, in one or more embodiments of the present disclosure, after the acquiring the clear image of each inspection sub-area as the image to be analyzed, the method further includes:
determining an optimal splicing mode among images in the patrol sub-areas based on a minimum-cut maximum flow principle and an overlapping area backed up by each patrol sub-area;
splicing the images to be analyzed of the patrol sub-area according to the optimal splicing mode to obtain an initial spliced image of the patrol sub-area;
and fusing the spliced images through a multi-resolution technology to obtain a panoramic image of the area to be inspected so as to realize task statistics of unmanned aerial vehicle inspection.
Optionally, in one or more embodiments of the present disclosure, before the inputting the image to be analyzed meeting the requirements of each inspection subarea into a preset oil well hidden danger identification network model, the method further includes:
acquiring a historical inspection image of an area to be inspected, and generating a sample library of the area to be inspected; wherein, the history inspection image includes: coordinates of the inspection oil well, fault points of the inspection oil well, potential safety hazard position labels and non-staff areas;
Dividing the historical inspection image according to the range of the inspection subarea to be used as an image sample;
extracting and decomposing a feature vector of the image sample, and performing dimension reduction decomposition on the feature vector to serve as a training sample;
training the training sample as input, and the potential safety hazard and position coordinates of the oil well as output pairs to obtain a recognition result;
and selecting the model with small recognition result error as the potential oil well hazard recognition network model.
One or more embodiments of the present specification provide an oil well inspection apparatus based on a multi-unmanned aerial vehicle, the apparatus comprising:
at least one processor; the method comprises the steps of,
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to:
acquiring an oil well inspection task; the oil well inspection task comprises geographic coordinate positions of all oil wells in an area to be inspected;
dividing an area to be inspected of the oil well inspection task into a plurality of inspection subareas, and distributing a plurality of unmanned aerial vehicles with corresponding functions for each inspection subarea;
Determining the optimal flight path of each unmanned aerial vehicle in the plurality of patrol sub-areas;
controlling the unmanned aerial vehicle to acquire images in a patrol sub-area according to the optimal flight path, and acquiring an initial shooting image of the oil well;
determining overlapping areas of a plurality of unmanned aerial vehicle initial shooting images in each inspection subarea according to the position coordinates of the initial shooting images;
filtering the overlapped area of each inspection subarea to obtain a clear image of each inspection subarea as an image to be analyzed;
inputting the image to be analyzed meeting the requirements of each inspection subarea into a preset oil well hidden danger identification network model, and outputting the type and position coordinates of the potential safety hazards of the oil well.
One or more embodiments of the present specification provide a non-volatile computer storage medium storing computer-executable instructions configured to:
acquiring an oil well inspection task; the oil well inspection task comprises geographic coordinate positions of all oil wells in an area to be inspected;
dividing an area to be inspected of the oil well inspection task into a plurality of inspection subareas, and distributing a plurality of unmanned aerial vehicles with corresponding functions for each inspection subarea;
Determining the optimal flight path of each unmanned aerial vehicle in the plurality of patrol sub-areas;
controlling the unmanned aerial vehicle to acquire images in a patrol sub-area according to the optimal flight path, and acquiring an initial shooting image of the oil well;
determining overlapping areas of a plurality of unmanned aerial vehicle initial shooting images in each inspection subarea according to the position coordinates of the initial shooting images;
filtering the overlapped area of each inspection subarea to obtain a clear image of each inspection subarea as an image to be analyzed;
inputting the image to be analyzed meeting the requirements of each inspection subarea into a preset oil well hidden danger identification network model, and outputting the type and position coordinates of the potential safety hazards of the oil well.
The above-mentioned at least one technical scheme that this description embodiment adopted can reach following beneficial effect:
based on many unmanned aerial vehicles patrol and examine in each subregion to patrol and examine the region, solve single unmanned aerial vehicle and patrol and examine the region and carry out the problem of time spent in the working at the oil well in a large scale. Through selecting the analysis path of a plurality of unmanned aerial vehicles, the unmanned aerial vehicles can cover the to-be-inspected area of the oil well in the shortest time, and the problem of the oil well inspection efficiency is solved. Meanwhile, through a preset oil well hidden danger identification network model, the image acquired by the multiple unmanned aerial vehicles is processed and analyzed, so that the identification of the oil well hidden danger can be realized, and the safety and reliability of an oil well inspection area are ensured.
Detailed Description
The embodiment of the specification provides an oil well inspection method, equipment and medium based on multiple unmanned aerial vehicles.
In order to make the technical solutions in the present specification better understood by those skilled in the art, the technical solutions in the embodiments of the present specification will be clearly and completely described below with reference to the drawings in the embodiments of the present specification, and it is obvious that the described embodiments are only some embodiments of the present specification, not all embodiments. All other embodiments, which can be made by one of ordinary skill in the art based on the embodiments herein without making any inventive effort, shall fall within the scope of the present disclosure.
Petroleum is an energy artery, and ensuring safe operation of oil well equipment is an important responsibility of enterprises. The oil well equipment operates throughout the year on the petroleum exploitation site, and is easy to damage and corrode due to the loss of the mechanical equipment and the influence of natural environment factors such as wind, rain, lightning and the like, if the equipment is not found and eliminated in time, various faults can be developed, and the safety of the oil field is greatly threatened. Meanwhile, due to the precious and high economic value of petroleum resources, illegal molecules occur during the phenomenon of petroleum resource theft, and great economic loss is brought to an oil field, so that the inspection of the area of oil well equipment is very important.
In the traditional inspection mode, important operators for inspection are people whether the inspection is performed manually or semi-automatically. At present, part of oil fields are also distributed in areas such as gobi, salt marsh, high mountains, ravines, low-lying areas and the like, the geographic environment is complex, and the production and maintenance management of ground equipment after casting completely depend on manual inspection, so that the workload and difficulty of personnel are increased, the input cost is greatly increased, the normal production of the oil fields is influenced, and the requirements of digital oil field construction cannot be met. Therefore, unmanned aerial vehicle aerial photography inspection becomes a new oil well inspection mode in the prior art with characteristics such as low cost, high accuracy. However, as the complexity of tasks and the diversity of environments are continuously increased, the requirements on the performance of the unmanned aerial vehicle are also increasing, and the single unmanned aerial vehicle cannot feed back real-time information of a large-scale inspection task, so that the accuracy of inspection information acquired by the single unmanned aerial vehicle cannot meet the requirements. In addition, single unmanned aerial vehicle still has the shortcoming that the execution task is single, inefficiency, risk are big, consequently can't ensure the security of oil well equipment and oil well property.
In order to solve the technical problems, the specification provides an oil well inspection method based on multiple unmanned aerial vehicles. By dividing the oil well inspection tasks, different inspection tasks can cooperate through different multiple unmanned aerial vehicles, so that the accurate matching of the inspection tasks is realized, and the problem that the single unmanned aerial vehicle can not meet the multi-target inspection tasks due to single execution task is solved. Meanwhile, the problem of low efficiency of a single unmanned aerial vehicle in inspection is solved by adopting cooperative work of multiple unmanned aerial vehicles, and accuracy of data acquisition is improved. By planning the inspection path of multiple unmanned aerial vehicles, an optimal path of the inspection process of the unmanned aerial vehicles is obtained, the inspection time of the unmanned aerial vehicles is shortened, and the energy consumption in the inspection process is reduced, so that the inspection cost is reduced. By processing and analyzing the unmanned aerial vehicle inspection image, the real-time monitoring of potential safety hazards of the oil well is realized, and the safety of oil well equipment and property is ensured.
The embodiment of the present specification is executed by the internal unit of the server controlling the unmanned aerial vehicle inspection or the server controlling the unmanned aerial vehicle inspection.
The technical scheme provided in the specification is described in detail below with reference to the accompanying drawings.
As shown in fig. 1, in one or more embodiments of the present disclosure, a flow diagram of a multi-unmanned-plane-based oil well inspection method is provided.
As shown in fig. 1, the method comprises the steps of:
step 101: acquiring an oil well inspection task; the oil well inspection task comprises geographic coordinate positions of all oil wells in an area to be inspected.
For oil and gas engineering, the production coordination in the initial oil exploration, design and subsequent large-drill platform site selection, oil and gas pipeline laying and installation processes all need high-precision and time-efficient images to support analysis planning. In the production process of petroleum, because oil well equipment operates throughout the year in petroleum exploitation sites, the damage and corrosion of the oil well equipment are easily caused by the loss of the mechanical equipment and the influence of natural factors such as weather, if the damage and corrosion are not found and eliminated in time, the safety and stability of the oil field can be threatened, in addition, because the economic value of petroleum is higher, the phenomenon of petroleum stealing frequently occurs, and great loss is caused to the economy of the oil field.
Therefore, in the inspection process of an oil well, various inspection works with different targets are required for the oil field based on various common potential safety hazards in the oil field and the oil field data which need to be collected and analyzed. And acquiring position coordinates of different inspection areas contained in the oil well inspection task, so that the targets of the inspection task are clearer.
Step 102: dividing the region to be inspected of the oil well inspection task into a plurality of inspection sub-regions, and distributing a plurality of unmanned aerial vehicles with corresponding functions for each inspection sub-region.
In one or more embodiments of the present disclosure, the dividing the area to be inspected of the oil well inspection task into a plurality of inspection sub-areas specifically includes:
acquiring historical inspection actions of all oil well equipment in the area to be inspected;
performing cluster analysis on the historical inspection actions based on a cluster algorithm to obtain a cluster center of the historical inspection actions within a preset distance threshold; wherein, the history inspection action includes: inspection of suspicious personnel, oil leakage inspection of oil well equipment, inspection of dangerous objects and inspection of combustible objects;
and dividing the region to be inspected according to the clustering range of the clustering center to obtain a plurality of inspection sub-regions.
Based on the oil well inspection tasks obtained in the step 101, the areas to be inspected of each oil well inspection task and the corresponding coordinate positions of the oil wells are obtained. Based on the to-be-inspected area contained in the inspection task, the historical inspection data of each oil well device in the to-be-inspected area can be searched and called through the database. After the historical inspection data is subjected to cluster analysis through a clustering algorithm, the clusters of various inspection tasks performed in the past time in the area to be inspected can be obtained, namely, the range in which each inspection task or each potential safety hazard occurs in the area to be inspected is obtained. For example: the inspection tasks of suspicious personnel are concentrated in the range near the oil tank of the oil well equipment, the oil leakage inspection of the oil well occurs near the turning node of each oil pipe line, and the inspection tasks of dangerous objects and combustible objects are in the threshold range of each oil well equipment. Based on the determination of the cluster center and the cluster range of each inspection task by cluster analysis, the division of inspection scenes of the area to be inspected is realized, and a plurality of inspection subareas with targeted inspection tasks in the area to be inspected are obtained.
The following description is needed: in one or more embodiments of the present disclosure, the performing cluster analysis on the obtained historical inspection actions based on the clustering algorithm specifically includes:
taking each inspection task as a sample of cluster analysis, and determining an inspection range threshold value of each inspection task;
selecting any one of the inspection tasks as a cluster center of the area to be inspected;
calculating the distance between each inspection task in the area to be inspected and the center of the cluster, and selecting the minimum distance as a marking value of the inspection task;
selecting the inspection task with the largest value from the marking values of the inspection tasks, and taking the inspection task as a newly-added cluster center if the inspection task exceeds the inspection range threshold;
iteratively obtaining all cluster centers of the area to be inspected;
dividing according to the preset range of each cluster center to obtain a plurality of inspection subareas of the area to be inspected.
Through the cluster analysis of the area to be inspected, each inspection task can be divided, so that the range of the cluster does not exceed the threshold range of the inspection task, the targeted inspection of multiple unmanned aerial vehicles on each task is ensured, the problem of confusion of the inspection task caused by large-scale inspection is avoided, meanwhile, all the inspection tasks are effectively divided, and the problems of omission of the inspection task and single execution task are avoided.
Step 103: and determining the optimal flight path of each unmanned aerial vehicle in the plurality of patrol sub-areas.
In one or more embodiments of the present disclosure, the determining an optimal flight path of each of the plurality of inspection areas specifically includes:
determining initial oil well coordinates and target oil well coordinates of the unmanned aerial vehicle according to the coordinates of the oil wells in the inspection area and the importance level of the oil wells;
determining the flying height of the unmanned aerial vehicle based on the inspection task of the unmanned aerial vehicle;
intercepting a two-dimensional plan of the patrol sub-area according to the flying height;
determining a flight area of the unmanned aerial vehicle based on the two-dimensional plan;
determining an unmanned aerial vehicle passing path in the patrol sub-area according to the flight area of the unmanned aerial vehicle, the starting point oil well coordinates and the target oil well coordinates of the unmanned aerial vehicle;
and analyzing the unmanned aerial vehicle passing path based on a variable neighborhood search algorithm to obtain the optimal flight path of the patrol sub-area.
In one or more embodiments of the present disclosure, after the determining the optimal flight path of each drone in the plurality of inspection sub-areas, the method further includes:
selecting a plurality of shooting positions in the optimal flight path of each patrol sub-area;
And setting shooting angles and shooting parameters at each shooting position of the unmanned aerial vehicle according to the shooting positions and the range of the patrol sub-area, so that the shooting images cover preset fault patrol points of the oil well in the patrol sub-area.
After the unmanned aerial vehicle takes off for a period of time, the unmanned aerial vehicle enters a stage of stable flight. Based on the precision required by the inspection task, the flight speed and the flight height of the unmanned aerial vehicle are basically kept constant when the unmanned aerial vehicle stably flies. Therefore, based on the flying height of the unmanned aerial vehicle, the two-dimensional plan view of the patrol sub-area under the flying height is intercepted, and the two-dimensional plan view of the unmanned aerial vehicle at the flying height can be obtained. At the moment, the flight obstacle of the unmanned aerial vehicle can be identified by using geometric figures, so that a complex analysis process during path planning in a three-dimensional space is avoided. Through the analysis of the flight height two-dimensional plan, the unmanned aerial vehicle barrier-free flight area can be determined, and a plurality of passing paths of the unmanned aerial vehicle under the flight height can be obtained based on the starting point oil well coordinates and the target oil well coordinates of the unmanned aerial vehicle in the unmanned aerial vehicle flight area. And analyzing a plurality of communication paths through a variable neighborhood search algorithm to obtain the optimal flight path of the unmanned aerial vehicle in the inspection subarea, so that the unmanned aerial vehicle can realize the oil well inspection task in the shortest path, and the oil well inspection cost is saved.
After the flight path of the unmanned aerial vehicle is obtained, the plane position of the unmanned aerial vehicle flight is required to be determined according to the clustering center dividing the subareas and the flight height of the unmanned aerial vehicle. And taking the arithmetic average value of the positions of all the oil wells, which are required to be inspected, of the unmanned aerial vehicle in each inspection subarea as the center position, which is required to be photographed, of the unmanned aerial vehicle inspection. And selecting a plurality of shooting positions, setting shooting angles and shooting parameters of the shooting positions according to the range of the inspection subarea, and aligning from the boundary of the inspection subarea to the shot central position, so as to ensure that the shot image can cover all preset fault inspection points. Through the setting of unmanned aerial vehicle shooting position and shooting parameter, can cover whole scene when having guaranteed to shoot the attention object, avoided because treat the scene segmentation that the scope of patrolling and examining caused based on cluster analysis to lead to the incomplete problem of patrolling and examining.
The following description is needed: the nature of the varying neighborhood search algorithm is an improved local search algorithm. The neighborhood in the variable neighborhood search algorithm refers to the set of all solutions obtained for one operation on the current solution, so different neighborhood actions result in different neighbors. The variable neighborhood search algorithm generates corresponding neighborhoods by using different actions and searches in the neighborhoods alternately, so that the algorithm is balanced in evacuability and concentration.
Step 104: and controlling the unmanned aerial vehicle to acquire images in the inspection subarea according to the optimal flight path, and acquiring an initial shooting image of the oil well.
And (3) acquiring the optimal flight path of the unmanned aerial vehicle in each inspection subarea according to step 103, and shooting based on the optimal flight path and the set shooting points to obtain an initial shooting image capable of covering the inspection subarea.
Step 105: and determining the overlapping area of the initial shooting images of the unmanned aerial vehicle in each inspection area according to the position coordinates of the initial shooting images.
When unmanned aerial vehicle shoots according to the shooting position that sets up, because shooting angle needs to ensure that inspection fault point is shot, therefore the unavoidable problem that there is the initial shooting image that unmanned aerial vehicle was shot in a plurality of shooting positions that the shooting content part overlaps exists, or there is overlap region in the initial shooting image of a plurality of unmanned aerial vehicle exists. The image shot by the unmanned aerial vehicle contains the position information of each point in the image, and the overlapping area shot by the unmanned aerial vehicle in each inspection area can be determined through the position coordinates contained in the initial shot image.
Step 106: and filtering the overlapped area of each inspection subarea, and obtaining the clear image of each inspection subarea as an image to be analyzed.
In one or more embodiments of the present disclosure, after the acquiring the clear image of each inspection sub-area as the image to be analyzed, the method further includes:
determining an optimal splicing mode among images in the patrol sub-areas based on a minimum-cut maximum flow principle and an overlapping area backed up by each patrol sub-area;
splicing the images to be analyzed of the patrol sub-area according to the optimal splicing mode to obtain an initial spliced image of the patrol sub-area;
and fusing the spliced images through a multi-resolution technology to obtain a panoramic image of the area to be inspected so as to realize task statistics of unmanned aerial vehicle inspection.
By effectively filtering the overlapping area acquired based on the step 105, after the overlapping area is backed up, one clear image is reserved as a subsequent image to be analyzed, and the redundant information contained in the overlapping area is avoided through filtering the overlapping area, so that the problem of high calculation complexity is solved.
In addition, by analyzing the backup of the overlapping area based on the principle of minimum cut maximum flow, the optimal splicing mode of the image pieces in each inspection area, namely the optimal splicing seam in each inspection area, can be determined. And splicing the images to be analyzed through the acquired optimal splicing seam, so that an initial spliced image of the inspection subarea can be obtained. And the spliced images can be fused based on a multi-resolution technology, so that the resolutions of the spliced images are consistent, a panoramic image of unmanned aerial vehicle inspection in an inspection area is obtained, and overall task statistics of the unmanned aerial vehicle in the inspection area can be realized based on the panoramic image. The problem of unavoidable registration errors caused by internal or external reasons such as illumination in actual conditions is solved, and meanwhile, the accuracy of the inspection task is improved by reducing the registration errors.
In one embodiment of the present disclosure, if two photos with overlapping areas are respectively an image a and an image B, based on the principle of minimum cut maximum flow and the overlapping area backed up by each patrol sub-area, the optimal stitching manner between the images in the patrol sub-area is determined as follows: pixels from image a are denoted as connection source points and pixels from image B are denoted as connection sink points. The image is divided into two sub-images respectively containing a source point and a sink point by adopting a network maximum flow method, and the weighted sum of the braiding of the two sub-images is minimum, so that the maximum flow at the moment corresponds to the minimum cut, and the minimum cut is the optimal splicing line of the image A and the image B. The method of the network maximum flow is a prior art means, and will not be described herein.
Step 107: inputting the image to be analyzed meeting the requirements of each inspection subarea into a preset oil well hidden danger identification network model, and outputting the type and position coordinates of the potential safety hazards of the oil well.
In one or more embodiments of the present disclosure, before the inputting the image to be analyzed meeting the requirements of each inspection subarea into the preset oil well hidden danger identification network model, the method further includes:
Performing gray level correction and self-adaptive histogram equalization processing on the images to be analyzed of each inspection subarea to obtain corrected images of the images to be analyzed;
processing the corrected image based on a preset filtering mode, removing noise data of the corrected image, and obtaining a denoising image;
and taking the denoising image as an image to be analyzed meeting the requirements of each inspection subarea.
In one or more embodiments of the present disclosure, the processing the corrected image based on a preset filtering manner, removing noise data of the corrected image, and obtaining a denoised image specifically includes:
determining parameters of wavelet transformation according to the estimated noise intensity of the corrected image; wherein the parameters include: wavelet basis function, decomposition layer number and threshold function;
decomposing the correction image according to the parameters of the wavelet transformation to obtain a high-frequency component and a low-frequency component of the correction image;
projecting the high-frequency component into a low-frequency space by using a Gaussian random matrix to obtain a measured value after filtering a noise vector;
and carrying out wavelet inverse transformation on the low-frequency component and the measured value so as to reconstruct the denoising image.
In one or more embodiments of the present disclosure, before the image to be analyzed that meets the requirements of each inspection subarea is input into the preset oil well hidden danger identification network, the method further includes:
acquiring a historical inspection image of an area to be inspected, and generating a sample library of the area to be inspected; wherein, the history inspection image includes: coordinates of the inspection oil well, fault points of the inspection oil well, potential safety hazard position labels and non-staff areas;
dividing the historical inspection image according to the range of the inspection subarea to be used as an image sample;
extracting and decomposing a feature vector of the image sample, and performing dimension reduction decomposition on the feature vector to serve as a training sample;
training the training sample as input, and the potential safety hazard and position coordinates of the oil well as output pairs to obtain a recognition result;
and selecting the model with small recognition result error as the potential oil well hazard recognition network model.
After the images to be analyzed of each inspection subarea are obtained, the images of the images to be analyzed are corrected by carrying out gray level correction and self-adaptive histogram equalization on the images to be analyzed of each inspection subarea. Based on the estimated noise intensity of the corrected image, parameters of the wavelet transform may be determined to noise filter the corrected image.
The parameters of the wavelet transformation include: wavelet basis, number of decomposition layers, and threshold function. Typically, the images acquired by the unmanned aerial vehicle are corrected to include smooth regions and also abrupt regions, and different regions should be selected from different wavelet bases. In the smoothing region, a wavelet function having a higher order vanishing matrix is generally selected because it can detect finer singularities contained in the image signal, thereby recovering image detail problems as much as possible. While a tightly supported wavelet basis is typically selected in the abrupt region to make the wavelet transform process of the image simple and efficient. And the number of decomposition layers is three to five based on actual conditions, so that the error of the reconstructed image is minimum, and the accuracy of the image is ensured.
And decomposing the corrected image based on the determined wavelet transformation parameters to obtain a high-frequency component and a low-frequency component of the corrected image. And projecting the transformed high frequency component into a low frequency space through a Gaussian observation matrix to obtain a measured value only containing an N-dimensional noise vector, wherein the smaller the value of N is, the more noise is removed. And reconstructing the low-frequency component after wavelet transformation decomposition and the measured value after Gaussian observation matrix processing based on wavelet inverse transformation to obtain a denoising image after noise filtering. Through the filtration of curved noise image, the problem that image analysis reliability is low that noise interference in unmanned aerial vehicle collection image leads to has been solved.
And taking the filtered denoising image as an image to be analyzed, wherein the image to be analyzed meets the requirements of the region to be inspected, and inputting a preset potential safety hazard model of the oil well for analysis, so that the potential safety hazard type and the position coordinates of the oil well in the region to be inspected are obtained.
The following description is needed: before the images to be analyzed meeting the requirements of all inspection subareas are input into a preset oil well hidden danger identification model, building and training are needed to be carried out on the oil well hidden danger identification model, and the training model meeting the requirements is used as the oil well hidden danger identification model. Specifically, in one or more embodiments of the present disclosure, a historical inspection image of an area to be inspected is obtained based on internet-based crawler technology or based on data stored in a database, where information included in the historical inspection image includes: coordinates of the oil well in the history inspection, fault points of the oil well in the history inspection, positions of potential safety hazards detected in the history inspection, related potential hazard data, the activity range of non-staff obtained in the history inspection, and the like. The obtained historical inspection image of the area to be inspected is used as a sample library of the area to be inspected, and the historical image in the sample library is segmented according to the range of the inspection subarea to be used as an image sample to be trained, so that the training model can ensure the targeted training analysis of the image in the area to be inspected. And performing dimension reduction processing on the feature vector by extracting the feature vector of the decomposed image sample, inputting the feature vector subjected to dimension reduction decomposition as training data into a training model, and outputting the type of potential safety hazards and the positions of the potential safety hazards of the oil well to train the neural network model. And evaluating the training result, and taking the model as an oil well hidden danger identification network model when the identified error is smaller than a set threshold value.
As shown in fig. 2, one or more embodiments of the present disclosure provide a multi-unmanned aerial vehicle-based oil well inspection apparatus, the apparatus comprising:
at least one processor 201; the method comprises the steps of,
a memory 202 communicatively coupled to the at least one processor 201; wherein,
the memory 202 stores instructions executable by the at least one processor 201 to enable the at least one processor 201 to:
acquiring an oil well inspection task; the oil well inspection task comprises geographic coordinate positions of all oil wells in an area to be inspected;
dividing an area to be inspected of the oil well inspection task into a plurality of inspection subareas, and distributing a plurality of unmanned aerial vehicles with corresponding functions for each inspection subarea;
determining the optimal flight path of each unmanned aerial vehicle in the plurality of patrol sub-areas;
controlling the unmanned aerial vehicle to acquire images in a patrol sub-area according to the optimal flight path, and acquiring an initial shooting image of the oil well;
determining overlapping areas of a plurality of unmanned aerial vehicle initial shooting images in each inspection subarea according to the position coordinates of the initial shooting images;
Filtering the overlapped area of each inspection subarea to obtain a clear image of each inspection subarea as an image to be analyzed;
inputting the image to be analyzed meeting the requirements of each inspection subarea into a preset oil well hidden danger identification network model, and outputting the type and position coordinates of the potential safety hazards of the oil well.
As shown in fig. 3, in one or more embodiments of the present specification, there is provided a nonvolatile storage medium storing executable instructions 301 of a computer, the executable instructions 301 including:
acquiring an oil well inspection task; the oil well inspection task comprises geographic coordinate positions of all oil wells in an area to be inspected;
dividing an area to be inspected of the oil well inspection task into a plurality of inspection subareas, and distributing a plurality of unmanned aerial vehicles with corresponding functions for each inspection subarea;
determining the optimal flight path of each unmanned aerial vehicle in the plurality of patrol sub-areas;
controlling the unmanned aerial vehicle to acquire images in a patrol sub-area according to the optimal flight path, and acquiring an initial shooting image of the oil well;
determining overlapping areas of a plurality of unmanned aerial vehicle initial shooting images in each inspection subarea according to the position coordinates of the initial shooting images;
Filtering the overlapped area of each inspection subarea to obtain a clear image of each inspection subarea as an image to be analyzed;
inputting the image to be analyzed meeting the requirements of each inspection subarea into a preset oil well hidden danger identification network model, and outputting the type and position coordinates of the potential safety hazards of the oil well.
The foregoing describes specific embodiments of the present disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims can be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
The foregoing is merely one or more embodiments of the present description and is not intended to limit the present description. Various modifications and alterations to one or more embodiments of this description will be apparent to those skilled in the art. Any modification, equivalent replacement, improvement, or the like, which is within the spirit and principles of one or more embodiments of the present description, is intended to be included within the scope of the claims of the present description.