An automatic water body identification method and device based on multi-scale segmentation

By using NDWI water body index and water body confidence subdivision formula in high-resolution remote sensing images, combined with distributed computing and multi-scale segmentation technology, the problems of inaccurate identification and time-consuming calculation in traditional water body recognition methods are solved, and rapid , accurate water body identification, improve processing speed and resource utilization efficiency.

CN112598685BActive Publication Date: 2024-11-26ZHONGKE XINGTU SPACE TECH CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110049146.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-01-14
Publication Date
2024-11-26
Estimated Expiration
2041-01-14

AI Technical Summary

Technical Problem

The traditional pixel-based water body recognition method has problems with in-class noise and inter-class similarity in high-resolution remote sensing images, resulting in inaccurate identification results. The automatic water body recognition method based on multi-scale segmentation is computationally expensive and time-consuming, so it cannot be used. Quickly process massive data.

Method used

Using NDWI water body index formula and water body confidence subdivision formula: blue + green - near infrared, combined with distributed calculation and multi-scale segmentation technology, suspected water bodies are extracted and Kmean binary classification is performed, and subdivided into high confidence water bodies and lower Confidence water bodies, improve identification accuracy and processing speed.

Benefits of technology

It realizes fast and accurate water body recognition in high-resolution remote sensing images, reduces error and leakage judgment rates, significantly improves processing speed, makes full use of hardware resources, and expands the application range.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112598685B_ABST
    Figure CN112598685B_ABST
Patent Text Reader

Abstract

An automatic water body identification method and device based on multi-scale segmentation, characterized in that the pixel average value of the remote sensing image is brought into the NDWI water body index formula and the empirical threshold to extract the suspected water body; and then the suspected water body is divided into high-confidence water body and low-confidence water body through the water body confidence subdivision formula: blue + green-near infrared. On the basis of the NDWI water body index formula, the water body confidence subdivision formula is introduced: blue + green-near infrared, and the automatic water body identification results are subdivided into non-water body, high-confidence water body and low-confidence water body, which is more in line with the actual application; compared with the traditional single-core serial processing method, the processing speed is greatly improved, the hardware resources on a single machine / cluster can be fully utilized, and the application scope of automatic water body identification based on multi-scale segmentation is greatly expanded: the processing efficiency can be improved by using multiple low-profile machines without updating the hardware, and the application scope is greatly improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of image information processing, and in particular relates to an automatic water body recognition method and device based on multi-scale segmentation. Background Art

[0002] As the spatial resolution of remote sensing sensors continues to improve, water body recognition based on high-resolution images has received widespread attention and application. However, traditional pixel-based water body recognition methods are difficult to adapt to the significantly increased intra-class noise and inter-class similarity brought about by high resolution, and the extraction results often have inaccurate shapes and mixed distribution of pixels of different categories. The existing automatic water body recognition results based on multi-scale segmentation only have two results: water bodies and non-water bodies, which often result in many misjudgments and missed judgments. At the same time, as the spatial resolution of remote sensing images increases to the meter level or even sub-meter level, the amount of data for multispectral images within a province has reached the TB level. When using these huge data to perform water body recognition at the provincial scale, it often takes days or even months to complete using a single machine.

[0003] In order to overcome the above problems, object-oriented ground feature extraction methods were proposed and soon achieved satisfactory results on high-resolution images. However, for massive data, the calculation is large and time-consuming, and it is impossible to achieve fast and automatic processing to meet the requirements of fast and practical use. Summary of the invention

[0004] The present invention aims to solve the above problems and provide an automatic water body recognition method and device based on multi-scale segmentation for rapid automatic water body recognition in massive remote sensing images.

[0005] In the first aspect, the present invention provides an automated water body identification method, which substitutes the pixel average value of the remote sensing image into the NDWI water index formula and the empirical threshold to extract suspected water bodies; and then uses the water body confidence subdivision formula: blue + green - near infrared to distinguish the suspected water bodies into high-confidence water bodies and low-confidence water bodies.

[0006] Furthermore, in the automated water body identification method of the present invention, the pixel average value of the remote sensing image is substituted into the NDWI water body index formula and the empirical threshold to extract suspected water bodies. The specific process is to segment the remote sensing image, determine whether the near-infrared band average value of the segmented object is less than the near-infrared mean, and whether the NDWI is greater than the set water body extraction threshold; if true, extract the suspected water body.

[0007] In a second aspect, the present invention provides an automatic water body identification device, comprising: an extraction unit, used to substitute the pixel average value of the remote sensing image into the NDWI water body index formula and the empirical threshold to extract suspected water bodies; an identification unit, used to distinguish suspected water bodies into high-confidence water bodies and low-confidence water bodies through the water body confidence subdivision formula: blue + green - near infrared.

[0008] In a third aspect, the present invention provides an automated water body identification method based on multi-scale segmentation, comprising: performing block calculation on a remote sensing image to obtain a near-infrared band threshold;

[0009] Divide the image data into blocks, and enter the distributed calculation after inputting parameters for each block; the parameters include the near infrared band threshold;

[0010] Segment the divided image data block by block;

[0011] Read the average values ​​of green, near infrared and blue bands of the segmented object;

[0012] Determine whether the sum of green and near infrared is 0; if so, mark it as 0; if not, perform NDWI model and near infrared mean calculation;

[0013] Determine whether the average value of the near-infrared band of the segmented object is less than the near-infrared mean, and whether the NDWI is greater than the set water body extraction threshold; if false, mark it as 1; if true, calculate blue + green - near-infrared, and mark its value as the suspected water body index;

[0014] The recorded 1, 0 values ​​and suspected water index are written into the temporary image, and the distributed computing ends;

[0015] Read in the temporary image, perform Kmean binary classification on the suspected water body index, and automatically obtain the binary classification water body threshold;

[0016] The pixel values ​​of the temporary image are marked as 0 or 1, and those greater than the water body threshold are marked as 255, otherwise they are marked as 254. Then the marked value is output to complete the water body identification.

[0017] Furthermore, in the automatic water body identification method based on multi-scale segmentation of the present invention, the output of the tag value is specifically writing the tag value as an output tiff file and a shp file.

[0018] In a fourth aspect, the present invention provides an automatic water body identification device based on multi-scale segmentation, comprising: a remote sensing image segmentation unit, used to divide the remote sensing image into blocks for calculation to obtain a near-infrared band threshold; divide the image data into blocks, input parameters to each block and then enter distributed calculation; the parameters include the near-infrared band threshold; and segment the divided image data block by block;

[0019] The remote sensing image analysis and processing unit is used to read the average values ​​of the green, near-infrared, and blue bands of the segmented object; determine whether the sum of the green and near-infrared is 0; if so, mark it as 0; if not, perform NDWI model and near-infrared mean calculation; determine whether the average value of the near-infrared band of the segmented object is less than the near-infrared mean, and whether the NDWI is greater than the set water body extraction threshold; if false, mark it as 1; if true, calculate blue + green - near-infrared, and mark its value as the suspected water body index; write the recorded 1, 0 values ​​and suspected water body index into the temporary image, and the distributed calculation ends;

[0020] The remote sensing image water body identification unit is used to read temporary images, perform Kmean binary classification on suspected water body indexes, and automatically obtain the binary classification water body threshold; the pixel value of the temporary image is marked as 0 or 1, and the pixel value greater than the water body threshold is marked as 255, otherwise it is marked as 254, and then the marked value is output to complete the water body identification.

[0021] In a fifth aspect, the present invention provides an automatic water body identification electronic device, comprising a memory and a processor; the memory is used to store a computer program; the processor is used to implement the automatic water body identification method as described in any one of claims 1-2 when executing the computer program.

[0022] In a sixth aspect, the present invention provides a computer-readable storage medium, characterized in that a computer program is stored on the storage medium, and when the computer program is executed by a processor, the automatic water body identification method as described in any one of claims 1-2 is implemented.

[0023] In the seventh aspect, the present invention provides an electronic device for automatic water body identification based on multi-scale segmentation, comprising a memory and a processor; characterized in that: the memory is used to store a computer program; the processor is used to implement the automatic water body identification method based on multi-scale segmentation as described in any one of claims 4-5 when executing the computer program.

[0024] In an eighth aspect, the present invention provides a computer-readable storage medium, characterized in that a computer program is stored on the storage medium, and when the computer program is executed by a processor, the automatic water body identification method based on multi-scale segmentation as described in any one of claims 4-5 is implemented.

[0025] The automatic water body identification method and device based on multi-scale segmentation described in the present invention, on the basis of the NDWI water body index formula, introduces a water body confidence subdivision formula: blue + green - near infrared, and subdivides the automatic water body identification results into non-water body, high-confidence water body and low-confidence water body, which is more in line with actual application; at the same time, automatic water body identification based on multi-scale segmentation is performed based on each piece of data, which greatly improves the processing speed compared with the traditional single-core serial processing method, can make full use of the hardware resources on a single machine / cluster, and greatly expands the application scope of automatic water body identification based on multi-scale segmentation: the processing efficiency can be improved by using multiple low-configuration machines without updating the hardware, and the application scope is greatly improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] Figure 1 This is a schematic flow chart of the automatic water body identification method based on multi-scale segmentation according to the present invention;

[0027] Figure 2 This is a schematic diagram of decomposing tasks according to the input image range according to an embodiment of the present invention;

[0028] Figure 3 This is a schematic diagram of the parallel multi-scale segmentation automatic water body recognition task distribution according to an embodiment of the present invention;

[0029] Figure 4 This is a schematic diagram of the water body recognition result according to an embodiment of the present invention;

[0030] Figure 5 It is a schematic diagram of the structure of the automatic water body identification device based on multi-scale segmentation of the present invention. DETAILED DESCRIPTION

[0031] The following is a detailed description of the automatic water body identification method and device based on multi-scale segmentation of the present invention through the accompanying drawings and embodiments.

[0032] Embodiment 1

[0033] In the automated water body identification method of the disclosed embodiment, the pixel average value of the remote sensing image is substituted into the NDWI water body index formula and the empirical threshold to extract suspected water bodies; and then the suspected water bodies are divided into high-confidence water bodies and low-confidence water bodies through the water body confidence subdivision formula: blue + green - near infrared.

[0034] The NDWI water index formula is: ; Among them, green is the pixel value of the green band, nir is the pixel value of the near-infrared band, and NDWI is the calculated water index.

[0035] It should be noted that the pixel average value of the remote sensing image is substituted into the NDWI water index formula and the empirical threshold to extract the suspected water body. The specific process is to segment the remote sensing image, determine whether the average value of the near-infrared band of the segmented object is less than the near-infrared mean, and whether the NDWI is greater than the set water body extraction threshold; if true, extract the suspected water body. In the specific implementation, the empirical threshold can be adjusted each time it is calculated according to the actual situation.

[0036] The existing automatic water body recognition results based on multi-scale segmentation only have two results: water body and non-water body, which often leads to many misjudgments and missed judgments. Based on the results of the "NDWI" water body index formula, this paper introduces the water body confidence subdivision formula "blue + green - near infrared", and subdivides the automatic water body recognition results into non-water body, high-confidence water body and low-confidence water body, which is more in line with actual applications.

[0037] In order to quickly perform automatic water body identification calculations on massive remote sensing images, multi-scale segmentation is an iterative merging process. During the calculation process, it is necessary to preserve the correspondence between superpixels and pixels, and the adjacent relationship between superpixels. When the amount of data is large, the algorithm memory overhead and iterative calculation time cannot be ignored. The data block method can be used to perform segmentation iterations in parallel in multiple data blocks to speed up the algorithm operation.

[0038] like Figure 1 The steps shown include:

[0039] Step 1: Input remote sensing images;

[0040] Step 2: Perform block calculation on the master node to obtain the required global near-infrared band threshold that meets the conditions;

[0041] Step 3: Divide the input image data into blocks, input the required parameters for each block, including the near-infrared band threshold calculated previously, and enter the distributed calculation;

[0042] Step 4: Split block by block;

[0043] Step 5: Read the average values ​​of the green, near-infrared, and blue light bands of the segmented object;

[0044] Step 6: Determine whether the denominator of the model is 0, that is, whether the sum of green and near-red is 0; if not, perform NDWI model and near-infrared mean calculation; if yes, mark it as 0;

[0045] Step 7: Check whether the average value of the near-infrared band of the segmented object is less than the near-infrared mean, and whether the NDWI is greater than the water extraction threshold set by the user; if false, mark it as 1; if true, calculate blue + green - near-infrared, and its value is marked as the suspected water body index;

[0046] Step 8: Write the recorded 1, 0 values ​​and suspected water body index into the temporary image, and the distributed computing ends;

[0047] Step 9: read the temporary image generated by the distributed method, perform Kmean binary classification on the suspected water body index, and automatically obtain the binary classification water body threshold;

[0048] Step 10. The pixel value of the distributed generated temporary image is 0 or 1, and the corresponding mark is 0 or 1. If it is greater than the water body threshold, it is marked as 255, otherwise it is 254. The mark value is written out as the output tiff file and shp file, and the recognition process ends.

[0049] Embodiment 2

[0050] The present invention discloses another embodiment of an automatic water body identification method based on multi-scale segmentation, which first performs block calculation on a master node to obtain a required global near-infrared band threshold that meets the conditions.

[0051] Then divide the input image into task blocks according to the given block size, such as Figure 2 As shown, the task is divided into 25 blocks according to the number of rows and columns of the input image, and each rectangular grid of the yellow grid is used as an image block to be processed for each task;

[0052] Automatic water body identification task distribution mechanism based on OpenMPI parallel multi-scale segmentation Figure 3 As shown in Figure 1, the OpenMPI framework consists of two roles: Controller and Agent. The Controller is responsible for receiving requests from external programs, and the Agent is responsible for starting and monitoring specific computing tasks. Agents are all homogeneous computing units, and each Agent can only accommodate one computing task at a time.

[0053] According to the idea of ​​the OpenMPI framework, the image is divided into blocks according to the given block size in the main process and the block parameters are calculated. Then the block parameters and the previously calculated near-infrared band threshold parameters are sent to each computing node.

[0054] The computation and analysis process of each computing node subprocess includes:

[0055] 1) Read the average values ​​of the green, near-infrared and blue light bands of the segmented object;

[0056] 2) Determine whether the denominator of the model (whether the sum of green and near-red is 0) is 0. If not, perform NDWI model and near-infrared mean calculation; if yes, mark it as 0;

[0057] 3) Whether the average value of the near-infrared band of the segmented object is less than the near-infrared mean, and whether the NDWI is greater than the water body extraction threshold set by the user; if false, it is marked as 1; if true, blue + green - near-infrared is calculated, and its value is marked as the suspected water body index;

[0058] 4) Write the recorded 1, 0 values ​​and suspected water body index into the temporary image, and the distributed computing ends.

[0059] Then the temporary image generated by the distributed system is read in, and the suspected water body index is subjected to Kmean binary classification to automatically obtain the binary classification water body threshold;

[0060] Finally, the pixel value of the temporary image generated by the distributed system is 0 or 1, and the corresponding mark is 0 or 1. If it is greater than the water body threshold, it is marked as 255, otherwise it is 254. The mark value is written as the output tiff file and shp file. The recognition results are as follows Figure 4 shown.

[0061] After the above process 3), usually, the suspected water body index amplifies the characteristics of high-confidence water bodies and suppresses the characteristics of low-confidence water bodies. The pixel value set of high-confidence water bodies and the pixel value set of low-confidence water bodies are sets represented by different peaks. With such a bimodal feature, Kmean can be used to automatically obtain the binary classification water body threshold, and then automatically perform binary classification.

[0062] The disclosed embodiment is based on the multi-process block of OpenMPI, and performs automatic identification of water bodies based on multi-scale segmentation based on each piece of data, which greatly improves the processing speed compared with the traditional single-core serial processing method. Supporting multi-core processing in a single machine / cluster can make full use of the hardware resources on the single machine / cluster, greatly expanding the application scope of automatic identification of water bodies based on multi-scale segmentation; in terms of single-machine hardware resources, it can make full use of CPU cores, which is more than most traditional multi-scale segmentation automatic identification of water bodies that can only use one CPU core, and has a larger application scope improvement; at the same time, it can adapt to multi-machine parallel processing, reduce algorithm running time, and several low-profile machines have higher computing efficiency than a single high-profile machine. It can improve processing efficiency by using multiple low-profile machines without updating hardware, and has a larger application scope improvement.

[0063] Embodiment 3

[0064] Another specific embodiment of the present disclosure is an automatic water body recognition device based on multi-scale segmentation, such as Figure 5 The system includes: a remote sensing image segmentation unit, which is used to divide the remote sensing image into blocks and calculate the near-infrared band threshold; divide the image data into blocks, input parameters to each block and then enter the distributed calculation; the parameters include the near-infrared band threshold; and segment the divided image data block by block.

[0065] The remote sensing image analysis and processing unit is used to read the average values ​​of the green, near-infrared, and blue bands of the segmented object; determine whether the sum of the green and near-infrared is 0; if so, mark it as 0; if not, perform NDWI model and near-infrared mean calculation; determine whether the average value of the near-infrared band of the segmented object is less than the near-infrared mean, and whether the NDWI is greater than the set water body extraction threshold; if false, mark it as 1; if true, calculate blue + green - near-infrared, and mark its value as the suspected water body index; write the recorded 1, 0 values ​​and suspected water body index into the temporary image, and the distributed calculation ends;

[0066] The remote sensing image water body identification unit is used to read temporary images, perform Kmean binary classification on suspected water body indexes, and automatically obtain the binary classification water body threshold; the pixel value of the temporary image is marked as 0 or 1, and the pixel value greater than the water body threshold is marked as 255, otherwise it is marked as 254, and then the marked value is output to complete the water body identification.

[0067] Embodiment 4

[0068] Another specific embodiment of the present disclosure describes an electronic device for automatic water body identification based on multi-scale segmentation, comprising a memory and a processor; the memory is used to store a computer program; the processor is used to enable the computer to execute the automatic water body identification method based on multi-scale segmentation in the above-mentioned embodiments 1 and 2 when executing the computer program. The specific storage steps are the same as those in the above-mentioned embodiments and will not be repeated here.

[0069] Embodiment 5

[0070] The present invention discloses another specific embodiment of a computer-readable medium, wherein the computer-readable medium stores program code. When the computer program code runs on a computer, the computer executes the automatic water body identification method based on multi-scale segmentation in the above-mentioned embodiment 1 and embodiment 2. The specific storage steps are the same as those in the above-mentioned embodiment and will not be repeated here.

[0071] The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or may be transmitted from one computer-readable storage medium to another computer-readable storage medium. The computer-readable storage medium may be any available medium that can be read by a computer or a data storage device such as a server or a data center that includes one or more available media integrated therein. The available medium may be a magnetic medium (e.g., a floppy disk, a hard disk, a magnetic tape), an optical medium (e.g., a digital versatile disk (DVD)), or a semiconductor medium (e.g., a solid-state drive (SSD)), etc. The software formed by the computer storage code may be located in a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, or other mature storage media in the art.

[0072] Each functional unit in each embodiment of the present application may be integrated into a processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part.

[0073] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. An automated water body recognition method based on multi-scale segmentation, characterized in that include: The remote sensing image is divided into blocks for calculation to obtain the near-infrared band threshold; Divide the image data into blocks, and enter the distributed calculation after inputting parameters for each block; the parameters include the near infrared band threshold; Segment the divided image data block by block; Read the average values ​​of green, near infrared and blue bands of the segmented object; Determine whether the sum of green and near infrared is 0; if so, mark it as 0; if not, perform NDWI model and near infrared mean calculation; Determine whether the average value of the near-infrared band of the segmented object is less than the near-infrared mean, and whether the NDWI is greater than the set water extraction threshold; if false, mark it as 1; If true, calculate blue + green - near infrared and mark its value as the suspected water index; The recorded 1, 0 values ​​and suspected water index are written into the temporary image, and the distributed computing ends; Read in the temporary image, perform Kmean binary classification on the suspected water body index, and automatically obtain the binary classification water body threshold; The pixel values ​​of the temporary image are marked as 0 or 1, and those greater than the water body threshold are marked as 255, otherwise they are marked as 254. Then the marked value is output to complete the water body identification.

2. The automatic water body identification method based on multi-scale segmentation according to claim 1 is characterized in that: The outputting of the mark value specifically includes writing the mark value as an output tiff file and a shp file.

3. An automatic water body identification device based on multi-scale segmentation, characterized in that include: A remote sensing image segmentation unit is used to divide the remote sensing image into blocks and calculate the near-infrared band threshold; Divide the image data into blocks, input parameters to each block and then enter the distributed calculation; the parameters include the near infrared band threshold; segment the divided image data block by block; The remote sensing image analysis and processing unit is used to read the average values ​​of the green, near-infrared, and blue bands of the segmented object; determine whether the sum of the green and near-infrared is 0; if so, mark it as 0; if not, perform NDWI model and near-infrared mean calculation; determine whether the average value of the near-infrared band of the segmented object is less than the near-infrared mean, and whether the NDWI is greater than the set water extraction threshold; if false, mark it as 1; If true, calculate blue + green - near infrared and mark its value as suspected water index; write the recorded 1, 0 values ​​and suspected water index into the temporary image, and the distributed calculation ends; The remote sensing image water body identification unit is used to read temporary images, perform Kmean binary classification on suspected water body indexes, and automatically obtain the binary classification water body threshold; the pixel value of the temporary image is marked as 0 or 1, and the pixel value greater than the water body threshold is marked as 255, otherwise it is marked as 254, and then the marked value is output to complete the water body identification.

4. An electronic device for automatic water body identification based on multi-scale segmentation, comprising a memory and a processor; characterized in that: The memory is used to store a computer program; the processor is used to implement the automatic water body identification method based on multi-scale segmentation as described in any one of claims 1-2 when executing the computer program.

5. A computer-readable storage medium, characterized in that: The storage medium stores a computer program, and when the computer program is executed by the processor, the automatic water body identification method based on multi-scale segmentation as described in any one of claims 1-2 is implemented.