Disclosure of Invention
The invention mainly aims to provide a satellite image coverage rate detection method, device, equipment and storage medium, and aims to solve the technical problems of low detection efficiency, high data quality requirement and high failure rate of the satellite image coverage rate in the prior art.
In order to achieve the above purpose, the present invention provides a satellite image coverage rate detection method, which includes the following steps:
acquiring initial satellite image data;
Performing view processing on the initial satellite image data according to the space data of the initial satellite image data to obtain a target fast view;
determining the corresponding grid number of the target view through a preset grid division model based on the target fast view;
And detecting the coverage rate of the initial satellite image data based on the target view grid number and the reference grid number.
Optionally, the performing view processing on the initial satellite image data according to the spatial data of the initial satellite image data to obtain a target fast view includes:
Collecting the space coordinates of the initial satellite image data;
thinning the initial satellite image data to obtain an initial quick view;
And positioning and deflecting the initial fast view based on the space coordinates to obtain a target fast view.
Optionally, the acquiring the spatial coordinates of the initial satellite image data includes:
traversing the image boundary of the initial satellite image data;
and acquiring coordinate information corresponding to the image boundary to obtain the space coordinates of the initial satellite image data.
Optionally, the determining, based on the target fast view, the corresponding target view grid number through a preset grid division model includes:
Dividing the target fast view according to a preset dividing area to obtain an initial view grid number;
image division is carried out on the target quick view according to the initial grid number, so that all initial grid views are obtained;
Performing view traversal on each initial grid view to obtain a target grid view;
And determining the grid number of the target view according to the target grid view.
Optionally, performing view traversal on each initial grid view to obtain a target grid view, including:
acquiring a central area of each initial grid view;
acquiring an average pixel value of the central area;
and if the average pixel value is not the preset pixel value, determining the initial grid view as a target grid view.
Optionally, before the coverage rate detection of the initial satellite image data is completed based on the target view grid number and the reference grid number, the method further includes:
acquiring preset reference data;
Performing regular outward expansion on the preset reference image in the preset reference data to obtain an outward expansion image;
and dividing the outward-expansion image according to a preset dividing area to obtain a reference grid number.
Optionally, after the coverage rate detection of the initial satellite image data is completed based on the target view grid number and the reference grid number, the method further includes:
acquiring a search instruction and attribute data of initial satellite image data;
determining retrieval attribute data according to the retrieval instruction;
And determining corresponding search image data based on the search attribute data and the attribute data of the initial satellite image data.
In addition, in order to achieve the above objective, the present invention further provides a satellite-image-oriented coverage rate detection device, which includes:
The acquisition module is used for acquiring initial satellite image data;
The processing module is used for performing view processing on the initial satellite image data according to the space data of the initial satellite image data to obtain a target fast view;
the determining module is used for determining the corresponding grid number of the target view through a preset grid division model based on the target fast view;
And the detection module is used for completing coverage rate detection of the initial satellite image data based on the target view grid number and the reference grid number.
In addition, in order to achieve the above purpose, the invention also provides a satellite-image-oriented coverage rate detection device, which comprises a memory, a processor and a satellite-image-oriented coverage rate detection program stored on the memory and capable of running on the processor, wherein the satellite-image-oriented coverage rate detection program is configured to implement the satellite-image-oriented coverage rate detection method.
In addition, in order to achieve the above object, the present invention further provides a storage medium, on which a satellite-image-oriented coverage rate detection program is stored, which when executed by a processor, implements the satellite-image-oriented coverage rate detection method as described above.
The method comprises the steps of obtaining initial satellite image data, performing view processing on the initial satellite image data according to space data of the initial satellite image data to obtain a target fast view, determining the corresponding target view grid number through a preset grid division model based on the target fast view, and completing coverage rate detection of the initial satellite image data based on the target view grid number and the reference grid number. According to the method, the initial satellite image data is processed through the space data of the initial satellite image data to obtain the target fast view, so that coverage rate detection of the initial satellite image data is completed by utilizing the fast view and the reference grid number, limitation of a processed object space data model is broken through, a coverage map generation method is optimized, and processing efficiency is improved.
Detailed Description
It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the scope of the invention.
Referring to fig. 1, fig. 1 is a schematic structural diagram of a satellite image coverage rate detection device facing to a hardware operation environment according to an embodiment of the present invention.
As shown in fig. 1, the satellite-image-oriented coverage detection device may include a processor 1001, such as a central processing unit (Central Processing Unit, CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Wherein the communication bus 1002 is used to enable connected communication between these components. The user interface 1003 may include a Display, an input unit such as a Keyboard (Keyboard), and the optional user interface 1003 may further include a standard wired interface, a wireless interface. The network interface 1004 may optionally include a standard wired interface, a Wireless interface (e.g., a Wireless-Fidelity (Wi-Fi) interface). The Memory 1005 may be a high-speed random access Memory (Random Access Memory, RAM) Memory or a stable Non-Volatile Memory (NVM), such as a disk Memory. The memory 1005 may also optionally be a storage device separate from the processor 1001 described above.
It will be appreciated by those skilled in the art that the structure shown in fig. 1 is not limiting of the satellite-facing image coverage detection apparatus and may include more or fewer components than shown, or may combine certain components, or a different arrangement of components.
As shown in fig. 1, the memory 1005, which is a storage medium, may include an operating system, a network communication module, a user interface module, and a satellite-image-oriented coverage detection program.
In the satellite image coverage rate detection device shown in fig. 1, the network interface 1004 is mainly used for data communication with a network server, the user interface 1003 is mainly used for data interaction with a user, and the processor 1001 and the memory 1005 in the satellite image coverage rate detection device can be arranged in the satellite image coverage rate detection device, and the satellite image coverage rate detection device invokes a satellite image coverage rate detection program stored in the memory 1005 through the processor 1001 and executes the satellite image coverage rate detection method provided by the embodiment of the invention.
The embodiment of the invention provides a satellite-image-oriented coverage rate detection method, and referring to fig. 2, fig. 2 is a flow chart of a first embodiment of the satellite-image-oriented coverage rate detection method.
In this embodiment, the satellite-image-oriented coverage rate detection method includes the following steps:
step S10, initial satellite image data are acquired.
It should be noted that, the execution body of the embodiment is a terminal device, on which satellite image coverage rate detection software is installed, and after initial satellite image data acquired by a satellite is acquired by the satellite image coverage rate detection software of the terminal device, view processing is performed on the initial satellite image according to space data of the initial satellite image data to obtain a corresponding target fast view, grid division is performed on the target fast view to obtain a corresponding target view grid number, and image coverage rate detection of the initial satellite image data acquired by the satellite is completed according to the obtained target view grid number and the reference grid number.
It will be appreciated that the original image data acquired by the satellite is the original satellite image data.
And step S20, performing view processing on the initial satellite image data according to the space data of the initial satellite image data to obtain a target quick view.
After the initial satellite image data collected by the satellite is obtained, the initial satellite image data is preprocessed and put into storage, and the spatial range (spatial data) of the satellite image data is collected by using an image metadata processing tool, wherein the spatial data refers to the image boundaries of each image in the initial satellite image data and the spatial coordinates corresponding to the image boundaries.
It can be understood that, in order to avoid the calculation of coverage rate by vector fusion, each initial satellite image in the initial satellite image data is extracted and positioned to obtain a target fast view in PNG format, and the obtained target fast view is written into the mongo db set, and the separate thematic image layers are respectively stored in the corresponding space tables.
In a specific implementation, in order to obtain a target fast view meeting a detection coverage rate standard, further, view processing is performed on the initial satellite image data according to the spatial data of the initial satellite image data to obtain the target fast view, wherein the view processing comprises the steps of collecting the spatial coordinates of the initial satellite image data, thinning the initial satellite image data to obtain the initial fast view, and positioning and deflecting the initial fast view based on the spatial coordinates to obtain the target fast view.
The spatial coordinates of the initial satellite image data refer to image boundary coordinates of each initial satellite image in the acquired initial satellite image data.
It can be understood that, in order to reduce the data amount of data processing and improve the data processing efficiency, each initial satellite image of the initial satellite image data is extracted and thinned through a preset resolution, so as to obtain a coverage fast view (initial fast view) corresponding to each initial satellite image.
In a specific implementation, because the image boundary of the extracted and thinned initial fast view deflects from the image boundary of the initial satellite image, and the initial fast view deviates from the actual ground area by a certain degree, the initial fast view needs to be positioned and deflected according to the image boundary coordinates (space coordinates) of each initial satellite image, so that a target fast view which can be matched with the actual ground area is obtained.
It should be noted that, in order to make the subsequent positioning of the initial fast view more accurate, the acquiring the spatial coordinates of the initial satellite image data includes traversing the image boundary of the initial satellite image data, and acquiring the coordinate information corresponding to the image boundary to obtain the spatial coordinates of the initial satellite image data.
It can be understood that, the outline traversal is performed on each initial satellite image in the initial satellite image data to obtain the image boundary of each initial satellite image, the space coordinates (coordinate information) corresponding to the image boundary are collected in the data in advance of initial warehouse entry, and the coordinate information of the image boundary of each initial satellite image is used as the space coordinates of the initial satellite image data.
And step S30, determining the corresponding grid number of the target view through a preset grid division model based on the target fast view.
After the target fast view is obtained, performing equal area division on the target fast view through a preset grid division model, so as to obtain a target fast view grid number corresponding to the target fast view, for example, 25 target fast views currently exist, the length and the width of each target fast view are 1.6 km by 1.6 km, each fast view is divided through the preset grid division model, and 100 target view grid numbers are obtained, wherein the preset grid division model is a model which is obtained through sample fast view division training and can perform equal area division on the fast view.
And S40, detecting the coverage rate of the initial satellite image data based on the target view grid number and the reference grid number.
It should be noted that, the reference grid number is the grid number corresponding to the reference area, the reference area is a reference object of statistical coverage, the reference area may obtain other self-defined space ranges for each level of administrative area range, key river basin boundary and natural protection area boundary, which is not limited in this embodiment, for example, the current image coverage of the satellite above beijing needs to be counted, and the reference area is beijing.
It can be understood that after the number of the target view grids corresponding to the initial satellite image data acquired by the satellite above the reference area is obtained, the coverage rate of the satellite above the reference area can be obtained according to the number of the target view grids and the number of the reference grids. For example, if the number of target view grids S Covering of corresponding to the initial satellite image data acquired by the satellite is 10000 and the number of reference grids S Datum is 10800, the coverage ratio C Coverage rate =(S Covering of /S Datum ) is 100% =92.59%.
In a specific implementation, before calculating the coverage rate, an accurate reference grid number is required to be obtained, and further, before completing the coverage rate detection of the initial satellite image data based on the target view grid number and the reference grid number, the method further comprises the steps of obtaining preset reference data, performing regular outward expansion on preset reference images in the preset reference data to obtain outward expansion images, and dividing the outward expansion images according to a preset dividing area to obtain the reference grid number.
Before the coverage rate calculation, preset reference data of a reference area stored in a database in advance is acquired, wherein the preset reference data comprises a reference image corresponding to the reference area and boundary coordinates of the reference image.
It can be understood that, the preset reference image refers to a range image of the reference area, and since the preset reference image may be an irregular image, the preset reference image needs to be regularly expanded by an outsourcing rectangle to obtain an expanded image, for example, as shown in fig. 3, the current preset reference image is an irregular image a, and after the preset reference image is regularly expanded, the obtained expanded image is an image B.
In a specific implementation, after the outer expansion image is obtained, the outer expansion image is divided according to a preset dividing area for grid division, so as to obtain a reference grid number, for example, the length and width of the current outer expansion image are 16 km by 16 km, the preset dividing area is 0.8 km by 0.8 km, and the reference grid number is 400.
The method comprises the steps of acquiring an initial satellite image acquired by a satellite, searching the required initial satellite image in real time, acquiring a search instruction and attribute data of the initial satellite image data after coverage rate detection of the initial satellite image data is completed based on the target view grid number and the reference grid number, determining the search attribute data according to the search instruction, and determining corresponding search image data based on the search attribute data and the attribute data of the initial satellite image data.
It can be understood that after the initial satellite image data is obtained, the initial satellite image data is preprocessed and put in storage, the image metadata processing tool is utilized to obtain basic metadata information in the initial satellite image data, the basic metadata information is written into the space table, the basic metadata information is the attribute data of the initial satellite image data, and the attribute data comprises satellite types, sensors, scene numbers, resolution, acquisition time and the like used for acquiring each initial satellite image in the initial satellite image data.
In a specific implementation, the search instruction refers to an image search instruction sent by a user, search attribute data of an image to be searched can be obtained according to the search instruction sent by the user, and after the search attribute data is determined, attribute data identical to the search attribute data is searched in the attribute data of the initial satellite image data, so that the search image data is obtained.
The method comprises the steps of obtaining initial satellite image data, carrying out view processing on the initial satellite image data according to space data of the initial satellite image data to obtain a target fast view, determining the corresponding target view grid number through a preset grid division model based on the target fast view, and completing coverage rate detection of the initial satellite image data based on the target view grid number and the reference grid number. According to the method, the initial satellite image data is processed through the space data of the initial satellite image data to obtain the target fast view, so that coverage rate detection of the initial satellite image data is completed by utilizing the fast view and the reference grid number, limitation of a processed object space data model is broken through, a coverage map generation method is optimized, and processing efficiency is improved.
Referring to fig. 4, fig. 4 is a flowchart illustrating a second embodiment of a satellite image coverage rate detection method according to the present invention.
Based on the first embodiment, the step S30 in the satellite image coverage rate detection method according to the present embodiment includes:
and S31, dividing the target fast view according to a preset dividing area to obtain an initial view grid number.
It should be noted that, the target fast view is divided according to a preset dividing area for grid division, so as to obtain an initial grid number.
And S32, carrying out image division on the target quick view according to the initial grid number to obtain each initial grid view.
After the initial grid number is obtained, the target fast view needs to be uniformly divided, so that each divided initial grid view is obtained.
And step S33, performing view traversal on each initial grid view to obtain a target grid view.
It should be noted that, because there is a situation that the target view is not fully covered by the image, there may be a certain corner or azimuth on the target view, and the image is not acquired, so that each initial grid view corresponding to the target view needs to be traversed, and a target grid view meeting the condition is obtained according to a preset screening condition.
It can be appreciated that, in order to reduce the error in coverage rate detection, an initial grid view needs to be screened, and further, view traversal is performed on each initial grid view to obtain a target grid view, where the method includes obtaining a central area of each initial grid view, obtaining an average pixel value of the central area, and determining that the initial grid view is the target grid view if the average pixel value is not a preset pixel value.
It should be noted that, because the area where the image is not collected on the target fast view is identified by the preset first color, the preset first color corresponds to the first pixel value, other areas where the image is collected correspond to other pixel values except the first pixel value, a central area of each initial grid view is obtained, a plurality of pixel points exist in the central area, each pixel point corresponds to a pixel value of itself, an average pixel value of the pixel points in the central area is calculated, when the average pixel value is not the preset pixel value which is preset and is used for screening the grid view, the preset pixel value is the first pixel value, the initial grid view central area is indicated to collect the image, the initial grid view can be determined to be the target grid view, when the average pixel value is the preset pixel value, the initial grid view central area is indicated to not collect the image, and the initial grid view is deleted and is not taken as the target grid view.
And step S34, determining the grid number of the target view according to the target grid view.
After the target grid view is obtained, the number of target view grids corresponding to the target grid view may be determined.
According to the embodiment, the target quick view is divided according to a preset dividing area to obtain initial view grid numbers, image division is conducted on the target quick view according to the initial grid numbers to obtain initial grid views, view traversal is conducted on the initial grid views to obtain target grid views, and the target view grid numbers are determined according to the target grid views. And performing raster division on the target fast view, performing traversal screening on the obtained initial raster views, so as to obtain the target raster view with large image coverage area, and finally determining the raster number of the target view, thereby improving the precision and reducing the error rate when the coverage rate is detected subsequently.
In addition, referring to fig. 5, the embodiment further provides a satellite-image-oriented coverage rate detection device, where the satellite-image-oriented coverage rate detection device includes:
The acquisition module 10 is configured to acquire initial satellite image data.
And the processing module 20 is configured to perform view processing on the initial satellite image data according to the spatial data of the initial satellite image data, so as to obtain a target fast view.
The determining module 30 is configured to determine, based on the target fast view, a corresponding target view grid number through a preset grid division model.
And the detection module 40 is used for completing coverage rate detection of the initial satellite image data based on the target view grid number and the reference grid number.
The method comprises the steps of obtaining initial satellite image data, carrying out view processing on the initial satellite image data according to space data of the initial satellite image data to obtain a target fast view, determining the corresponding target view grid number through a preset grid division model based on the target fast view, and completing coverage rate detection of the initial satellite image data based on the target view grid number and the reference grid number. According to the method, the initial satellite image data is processed through the space data of the initial satellite image data to obtain the target fast view, so that coverage rate detection of the initial satellite image data is completed by utilizing the fast view and the reference grid number, limitation of a processed object space data model is broken through, a coverage map generation method is optimized, and processing efficiency is improved.
In one embodiment, the processing module 20 is further configured to acquire spatial coordinates of the initial satellite image data;
thinning the initial satellite image data to obtain an initial quick view;
And positioning and deflecting the initial fast view based on the space coordinates to obtain a target fast view.
In one embodiment, the processing module 20 is further configured to traverse the image boundary of the initial satellite image data;
and acquiring coordinate information corresponding to the image boundary to obtain the space coordinates of the initial satellite image data.
In an embodiment, the determining module 30 is further configured to divide the target fast view according to a preset dividing area to obtain an initial view grid number;
image division is carried out on the target quick view according to the initial grid number, so that all initial grid views are obtained;
Performing view traversal on each initial grid view to obtain a target grid view;
And determining the grid number of the target view according to the target grid view.
In an embodiment, the determining module 30 is further configured to obtain a central area of each initial grid view;
acquiring an average pixel value of the central area;
and if the average pixel value is not the preset pixel value, determining the initial grid view as a target grid view.
In an embodiment, the detection module 40 is further configured to obtain preset reference data;
Performing regular outward expansion on the preset reference image in the preset reference data to obtain an outward expansion image;
and dividing the outward-expansion image according to a preset dividing area to obtain a reference grid number.
In one embodiment, the detection module 40 is further configured to obtain the search instruction and attribute data of the initial satellite image data;
determining retrieval attribute data according to the retrieval instruction;
And determining corresponding search image data based on the search attribute data and the attribute data of the initial satellite image data.
Because the device adopts all the technical schemes of all the embodiments, the device at least has all the beneficial effects brought by the technical schemes of the embodiments, and the description is omitted here.
In addition, the embodiment of the invention also provides a storage medium, on which a satellite-image-oriented coverage rate detection program is stored, wherein the satellite-image-oriented coverage rate detection program, when executed by a processor, realizes the steps of the satellite-image-oriented coverage rate detection method described above.
Because the storage medium adopts all the technical schemes of all the embodiments, the storage medium has at least all the beneficial effects brought by the technical schemes of the embodiments, and the description is omitted here.
It should be noted that the above-described working procedure is merely illustrative, and does not limit the scope of the present invention, and in practical application, a person skilled in the art may select part or all of them according to actual needs to achieve the purpose of the embodiment, which is not limited herein.
In addition, technical details not described in detail in the present embodiment may refer to the satellite-image-oriented coverage detection method provided in any embodiment of the present invention, which is not described herein.
Furthermore, it should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or system. Without further limitation, an element defined by the phrase "comprising one does not exclude the presence of other like elements in a process, method, article, or system that comprises the element.
The foregoing embodiment numbers of the present invention are merely for the purpose of description, and do not represent the advantages or disadvantages of the embodiments.
From the above description of the embodiments, it will be clear to those skilled in the art that the above-described embodiment method may be implemented by means of software plus a necessary general hardware platform, but of course may also be implemented by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (e.g. Read Only Memory)/RAM, magnetic disk, optical disk) and including several instructions for causing a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to perform the method according to the embodiments of the present invention.
The foregoing description is only of the preferred embodiments of the present invention, and is not intended to limit the scope of the invention, but rather is intended to cover any equivalents of the structures or equivalent processes disclosed herein or in the alternative, which may be employed directly or indirectly in other related arts.