CN116486077A - Remote sensing image semantic segmentation model sample set generation method and device - Google Patents

Remote sensing image semantic segmentation model sample set generation method and device Download PDF

Info

Publication number
CN116486077A
CN116486077A CN202310355592.8A CN202310355592A CN116486077A CN 116486077 A CN116486077 A CN 116486077A CN 202310355592 A CN202310355592 A CN 202310355592A CN 116486077 A CN116486077 A CN 116486077A
Authority
CN
China
Prior art keywords
vector element
window
current
size
cutting
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202310355592.8A
Other languages
Chinese (zh)
Other versions
CN116486077B (en
Inventor
宋佳
夏罗生
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Institute of Geographic Sciences and Natural Resources of CAS
Original Assignee
Institute of Geographic Sciences and Natural Resources of CAS
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Institute of Geographic Sciences and Natural Resources of CAS filed Critical Institute of Geographic Sciences and Natural Resources of CAS
Priority to CN202310355592.8A priority Critical patent/CN116486077B/en
Priority claimed from CN202310355592.8A external-priority patent/CN116486077B/en
Publication of CN116486077A publication Critical patent/CN116486077A/en
Application granted granted Critical
Publication of CN116486077B publication Critical patent/CN116486077B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/26Segmentation of patterns in the image field; Cutting or merging of image elements to establish the pattern region, e.g. clustering-based techniques; Detection of occlusion
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/11Region-based segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/10Terrestrial scenes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10032Satellite or aerial image; Remote sensing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20112Image segmentation details
    • G06T2207/20132Image cropping
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The application provides a remote sensing image semantic segmentation model sample set generation method and device, wherein the method comprises the following steps: vector labeling data of the remote sensing image to be processed are obtained and rasterized to obtain a grid labeling image; sequencing the areas of the vector element objects in the vector annotation data from large to small to obtain a vector element object list; traversing the vector element object, if the current vector element object is not covered by the cutting window of the vector element object sequenced in front, or the size proportion covered by the cutting window of the vector element object sequenced in front is smaller than a preset proportion threshold value, acquiring the cutting window of the current vector element object, otherwise, skipping the current vector element object; obtaining object clipping windows of all vector element objects; and cutting and sampling the remote sensing image and the grid marked image according to the object cutting window to obtain a remote sensing image semantic segmentation model sample set. The method and the device can avoid repeated sampling, and improve sampling efficiency and the relative information content of each sample.

Description

Remote sensing image semantic segmentation model sample set generation method and device
Technical Field
The application relates to the technical field of obtaining a remote sensing image semantic segmentation model sample set, in particular to a remote sensing image semantic segmentation model sample set generation method and device.
Background
The remote sensing image semantic segmentation is used for classifying each pixel in the remote sensing image according to the ground object category or the ground object element. Moreover, semantic segmentation of the remote sensing image generally requires the generation of a semantic segmentation sample set based on the vector annotation data and the remote sensing image. However, in the prior related art, in the process of sampling, when one object is sampled, the semantic segmentation of the remote sensing image may cover the other object, so that repeated sampling is caused, the sampling efficiency is reduced, and the disadvantage of low relative information content of each sample in the sampled sample set is caused.
Disclosure of Invention
The utility model aims to overcome the defects and shortcomings in the prior art, and provides a remote sensing image semantic segmentation model sample set generation method and device, which can avoid repeated sampling, improve the sampling efficiency and improve the relative information content of each sample in the sampled sample set.
A first aspect of an embodiment of the present application provides a method for generating a sample set of a semantic segmentation model of a remote sensing image, including:
acquiring vector labeling data of a remote sensing image to be processed;
carrying out grid combination processing on the vector labeling data to obtain a grid labeling image;
globally sorting the areas of the vector element objects in the vector labeling data from large to small to obtain a sorted vector element object list;
traversing the vector element objects of the vector element object list, if the current vector element object is not covered by the cutting windows of the vector element objects sequenced in front, or the size proportion covered by the cutting windows of the vector element objects sequenced in front is smaller than a preset proportion threshold value, acquiring the cutting windows of the current vector element object, otherwise, skipping the current vector element object; obtaining object clipping windows of all vector element objects;
and cutting and sampling the remote sensing image and the grid labeling image according to object cutting windows of all the vector element objects to obtain a remote sensing image semantic segmentation model sample set comprising a plurality of sample pairs.
A second aspect of the embodiments of the present application provides a remote sensing image semantic segmentation model sample set generating device, including:
the vector annotation data acquisition module is used for acquiring vector annotation data of the remote sensing image to be processed;
the grid labeling image acquisition module is used for carrying out grid combination processing on the vector labeling data to obtain a grid labeling image;
the vector element object ordering module is used for globally ordering the areas of the vector element objects in the vector annotation data from large to small to obtain an ordered vector element object list;
the object clipping window acquisition module is used for traversing the vector element objects of the vector element object list, if the current vector element object is not covered by the clipping window of the vector element object which is sequenced in front, or the size proportion covered by the clipping window of the vector element object which is sequenced in front is smaller than a preset proportion threshold value, acquiring the clipping window of the current vector element object, otherwise, skipping the current vector element object; obtaining object clipping windows of all vector element objects;
a sample set acquisition module: and cutting and sampling the remote sensing image and the grid labeling image according to object cutting windows of all the vector element objects to obtain a remote sensing image semantic segmentation model sample set comprising a plurality of sample pairs.
Compared with the related art, the method and the device for acquiring the vector element object have the advantages that a plurality of vector element objects are traversed from large to small according to the size of the vector element object so as to acquire object cutting windows of the vector element object which is not sampled one by one, and the vector element object which is not sampled is not covered by the acquired object cutting windows or is covered by the acquired object cutting windows, so that the vector element object with small size can be prevented from being subjected to the operation of acquiring the object cutting windows again under the condition that the vector element object with small size is covered by the acquired object cutting windows in the process of acquiring the object cutting windows, the repeated sampling condition caused by sampling of one vector element object by the plurality of object cutting windows is avoided, the step of acquiring redundant object cutting windows is also saved, and the technical effects of improving the sampling efficiency and improving the relative information content of each sample in the sampled sample set are achieved.
In order that the present application may be more clearly understood, specific embodiments thereof will be described below with reference to the accompanying drawings.
Drawings
Fig. 1 is a flowchart of a method for generating a remote sensing image semantic segmentation model sample set according to an embodiment of the present application.
Fig. 2 is a schematic diagram of an object clipping window of a large-size object according to a remote sensing image semantic segmentation model sample set generating method according to an embodiment of the present application.
Fig. 3 is a schematic diagram of five candidate clipping windows of a small-sized object according to a remote sensing image semantic segmentation model sample set generating method according to an embodiment of the present application.
Fig. 4 is a schematic diagram of a candidate clipping window of a small-sized object according to a method for generating a sample set of semantic segmentation models of remote sensing images according to an embodiment of the present application.
Fig. 5 is a schematic diagram of an object clipping window of a remote sensing image semantic segmentation model sample set generating method according to an embodiment of the present application.
Fig. 6 is a schematic diagram of module connection of a remote sensing image semantic segmentation model sample set generating device according to an embodiment of the present application.
100. The remote sensing image semantic segmentation model sample set generating device; 101. the vector annotation data acquisition module; 102. a grid labeling image acquisition module; 103. a vector element object ordering module; 104. an object clipping window acquisition module; 105. and a sample set acquisition module.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present application more apparent, the following detailed description of the embodiments of the present application will be given with reference to the accompanying drawings.
It should be understood that the described embodiments are merely some, but not all, of the embodiments of the present application. All other embodiments, which can be made by one of ordinary skill in the art without undue burden from the embodiments of the present application, are within the scope of the embodiments of the present application.
When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. In the description of this application, it should be understood that the terms "first," "second," "third," and the like are used merely to distinguish between similar objects and are not necessarily used to describe a particular order or sequence, nor should they be construed to indicate or imply relative importance. The specific meaning of the terms in this application will be understood by those of ordinary skill in the art as the case may be. As used in this application and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. The word "if"/"if" as used herein may be interpreted as "at … …" or "at … …" or "in response to a determination".
Furthermore, in the description of the present application, unless otherwise indicated, "a plurality" means two or more. "and/or", describes an association relationship of an association object, and indicates that there may be three relationships, for example, a and/or B, and may indicate: a exists alone, A and B exist together, and B exists alone. The character "/" generally indicates that the context-dependent object is an "or" relationship.
Referring to fig. 1, a flowchart of a method for generating a sample set of a semantic segmentation model of a remote sensing image according to a first embodiment of the present application includes:
s1: and obtaining vector labeling data of the remote sensing image to be processed.
The vector annotation data of the remote sensing image comprises a plurality of vector annotation files which can be classified into positive sample vector annotation files and negative sample vector annotation files, wherein the number of the positive sample vector annotation files and the negative sample vector annotation files is not limited.
The positive sample vector annotation file is a vector annotation file of a semantic segmentation target class. When a plurality of different segmentation target categories exist, a plurality of positive sample vector annotation files aiming at the different categories are corresponding; the negative sample vector markup file refers to a vector markup file which is not a semantic division target class but is easily divided into semantic division target classes by mistake.
S2: and carrying out grid combination processing on the vector labeling data to obtain a grid labeling image.
The rasterizing and synthesizing process includes a rasterizing process and a synthesizing process.
When rasterizing, the projection coordinate system of the vector labeling data needs to be converted into the same projection coordinate system as the remote sensing image. The rasterization processing is to rasterize all vector annotation files in the vector annotation data one by taking the boundary of the remote sensing image as a rasterization range and the spatial resolution of the remote sensing image as the spatial resolution of the rasterization, so as to obtain a plurality of raster annotation files. A grid mark file represents a single category of layers, and the background grid value is 0; the positive sample grid value, the negative sample grid value and the uncertain region grid value are all different in value, for example, the positive sample grid value is a corresponding value of the category, and the value range is 0-99; the negative sample grid value is unified to be 100; if the vector annotation data further comprises an uncertainty region annotation file, the uncertainty region grid value of the uncertainty region annotation file may be set to 255.
The synthesizing process is to synthesize all positive sample grid labeling files into one grid labeling image by using a maximum synthesizing method, wherein the maximum value of a pixel in all image layers is the synthesized value of the pixel in the grid labeling image.
S3: and carrying out global sorting on the areas of the vector element objects in the vector labeling data from large to small to obtain a sorted vector element object list.
The global sorting refers to sorting vector element objects of all positive sample labeling files and vector element objects of negative sample labeling files in vector labeling data together, for example, the positive sample labeling files of the vector labeling data comprise lake positive sample labeling files, forest positive sample labeling files and grassland positive sample labeling files, the negative sample labeling files of the vector labeling data comprise cloud shadow negative sample labeling files, and when executing step S3, the vector element objects of the lake positive sample labeling files representing the lake, the vector element objects of the forest positive sample labeling files representing the forest, the vector element objects of the grassland positive sample labeling files representing the grassland and the vector element objects of the cloud shadow negative sample labeling files together are sorted according to the area from large to small.
S4: traversing the vector element objects of the vector element object list, if the current vector element object is not covered by the cutting windows of the vector element objects sequenced in front, or the size proportion covered by the cutting windows of the vector element objects sequenced in front is smaller than a preset proportion threshold value, acquiring the cutting windows of the current vector element object, otherwise, skipping the current vector element object; and obtaining object clipping windows of all the vector element objects.
The preset ratio threshold is at least 60%, and may be 65%, 68%, 70%, 71%, etc.
S5: and cutting and sampling the remote sensing image and the grid labeling image according to object cutting windows of all the vector element objects to obtain a remote sensing image semantic segmentation model sample set comprising a plurality of sample pairs.
Compared with the related art, the method and the device for acquiring the vector element object have the advantages that a plurality of vector element objects are traversed from large to small according to the size of the vector element object so as to acquire object cutting windows of the vector element object which is not sampled one by one, and the vector element object which is not sampled is not covered by the acquired object cutting windows or is covered by the acquired object cutting windows, so that the vector element object with small size can be prevented from being subjected to the operation of acquiring the object cutting windows again under the condition that the vector element object with small size is covered by the acquired object cutting windows in the process of acquiring the object cutting windows, the repeated sampling condition caused by sampling of one vector element object by the plurality of object cutting windows is avoided, the step of acquiring redundant object cutting windows is also saved, and the technical effects of improving the sampling efficiency and improving the relative information content of each sample in the sampled sample set are achieved.
In one possible embodiment, the step S4: traversing the vector element objects of the vector element object list, if the current vector element object is not covered by the cutting windows of the vector element objects sequenced in front, or the size proportion covered by the cutting windows of the vector element objects sequenced in front is smaller than a preset proportion threshold value, acquiring the cutting windows of the current vector element object, otherwise, skipping the current vector element object; the step of obtaining object clipping windows of all vector element objects comprises the following steps:
s41: and acquiring the rectangular length and rectangular width of the outsourcing rectangle of the current vector element object.
Wherein, the outsourcing rectangle refers to the minimum circumscribed rectangle surrounding the vector element object and parallel to the x, y axes.
S42: if the current rectangular length is smaller than the preset cutting window length and the rectangular width is smaller than the preset cutting window width, determining the current vector element object as a small-size object; if the current rectangular length is greater than or equal to a preset cutting window or the rectangular width is greater than or equal to the preset cutting window width, the current vector element object is determined to be a large-size object.
For example, the rectangle length of the outsourcing rectangle of the current vector element object is o_l, the rectangle width is o_w, the preset clipping window length is w_l, the preset clipping window width is w_w, when o_l < w_l and o_w < w_w, the corresponding vector element object is a small-size object, otherwise, the corresponding vector element object is a large-size object.
S43: and acquiring the object cutting window of the large-size object according to a preset large-size object cutting window acquisition mode.
The object clipping window of the large-size object may be composed of one or more default clipping windows, where the window length of each default clipping window is a preset clipping window length, and the window width of each default clipping window is a preset clipping window width.
S44: and acquiring the object cutting window of the small-size object according to a preset small-size object cutting window acquisition mode.
The window length of the object cutting window of the small-size object is a preset cutting window length, and the window width of the object cutting window of the small-size object is a preset cutting window width.
In this embodiment, considering that the coverage area of the object clipping window of the large-size object is larger, there is a larger probability of covering other vector element objects with smaller sizes, so by traversing the large-size object from large to small and then traversing the small-size object, the object clipping window of the non-sampled large-size object and the object clipping window of the non-sampled small-size object are obtained, and the situation of repeated sampling caused by sampling one vector element object by a plurality of object clipping windows can be more reasonably prevented.
In one possible embodiment, the step S43: according to a preset large-size object cutting window acquisition mode, the step of acquiring the object cutting window of the large-size object comprises the following steps:
s431: the outsourcing rectangle of the current large-sized object is expanded by the random buffer.
The random buffer is a buffer of random size, for example, the buffer distance corresponding to the long (i.e. long side) of the outsourcing rectangle is random (0, w_l// 8), the buffer distance corresponding to the wide (i.e. short side) of the outsourcing rectangle is random (0, w_w// 8), and if the buffer exceeds the boundary of the remote sensing image, the buffer of random size is expanded to the boundary, and the buffer of random size is used for solving the problem of fixed spacing of the samples.
S432: and generating one or more windows which completely cover the current large-size object according to the preset cutting window length and the preset cutting window width by taking the outsourcing rectangle of the expanded current large-size object as a cutting range and taking the upper left corner of the cutting range as a starting point, so as to obtain the object cutting window of the current large-size object.
For example, one or more windows which completely cover the current large-size object are sequentially produced from left to right and from top to bottom according to the window size of the default cutting window by taking the left upper corner of the cutting range as a starting point, and then the object cutting window of the current large-size object can be obtained.
In this embodiment, the outsourcing rectangle of the current large-size object is expanded according to the buffer area with random size, and then a plurality of windows of the current large-size object are obtained according to the expanded outsourcing rectangle to serve as corresponding object cutting windows, so that the object cutting windows of the current large-size object can completely cover the current large-size object, and the problem of fixed spacing of samples can be solved.
In one possible embodiment, the grid-labeled image is labeled with an uncertainty region and an invalid value region.
The vector annotation data comprises an uncertain region annotation file, the uncertain region can be obtained through the uncertain region vector annotation file, and the invalid value region can be obtained through an invalid value mask of the remote sensing image; the uncertain region vector annotation file refers to a vector annotation file with unclear segmentation category in a region, and the uncertain region vector annotation file is used for excluding an uncertain region from a generated sample set. Preferably, a screening algorithm in the GDAL (Geospatial Data Abstraction Library) library may be used to remove the region in the invalid value mask where the pel value that may be present is exactly equal to the invalid value, to prevent the region from being misclassified as an invalid value region. The GDAL (Geospatial Data Abstraction Library) library is an open source raster space data conversion library under the X/MIT permission protocol.
The S432: taking the expanded outsourcing rectangle of the current large-size object as a cutting range, taking the upper left corner of the cutting range as a starting point, and generating one or more windows which completely cover the current large-size object according to the preset cutting window length and the preset cutting window width to obtain an object cutting window of the current large-size object, wherein the step of obtaining the object cutting window of the current large-size object comprises the following steps:
when one or more windows which completely cover the current large-size object are generated according to the preset cutting window length and the preset cutting window width, if the current range of the window comprises an uncertain region or an invalid value region, skipping the current range; and if the current range of the window does not comprise the pixels of the current large-size object, skipping the current range.
Referring to fig. 2, in this embodiment, by skipping the current range of window sizes including the uncertain region or the invalid value region and skipping the current range of window sizes of pixels not including the current large-size object, the obtained multiple object clipping windows of the current large-size object are as shown in fig. 2, which is beneficial to improving the sampling efficiency and the sample effectiveness during sampling.
In one possible embodiment, the step S44: according to a preset small-size object cutting window acquisition mode, the step of acquiring the object cutting window of the small-size object comprises the following steps:
s441: and acquiring the rectangular midpoint of the outsourcing rectangle of the current small-size object.
S442: and generating a plurality of candidate windows which are at different positions and respectively comprise the rectangular midpoints according to the preset clipping window length and the preset clipping window width.
The number of the candidate windows is at least 5, and the rectangular midpoints are respectively positioned at the left upper part, the left lower part, the central part, the right upper part and the right lower part of the 5 candidate windows. For example, the number of the candidate windows is 5, as shown in fig. 3, and a schematic view of the candidate window when the midpoint of the rectangle is located at the lower right of the candidate window is shown in fig. 4.
S443: and selecting an object clipping window of the current small-size object from the plurality of candidate windows according to a preset selection rule.
Specifically, the step S443 includes:
s4431: and checking whether each candidate window comprises an uncertain region and an invalid value region, and if only one candidate window does not comprise the uncertain region and the invalid value region, determining the corresponding candidate window as an object clipping window of the current small-size object.
S4432: and deleting the candidate window comprising the uncertain region and the invalid value region if two or more candidate windows do not comprise the uncertain region and the invalid value region.
S4433: and acquiring the number of the non-sampled pixels of the vector element objects which are not sampled in the rest candidate windows, and determining the candidate window with the largest number of the non-sampled pixels as an object clipping window of the current small-size object.
Among the remaining candidate windows described in step S4433, the candidate window remaining after the execution of step S4432 is the candidate window.
S4434: and if the number of the non-sampled pixels is two or more than two, deleting the candidate window with the non-sampled pixels not being the maximum number.
S4435: and acquiring the number of sampled pixels of the sampled vector element object in each remaining candidate window, and determining the candidate window with the minimum number of sampled pixels as an object clipping window of the current small-size object.
Among the remaining candidate windows described in step S4435, the candidate window remaining after the execution of step S4434 is the candidate window.
In the present embodiment, through steps S441 to S443, and steps S4431 to S4435, an object clipping window of the current small-sized object as shown in fig. 5 can be selected, which helps to improve the sampling efficiency and the validity of the sample at the time of sampling.
Referring to fig. 6, a second embodiment of the present application provides a device for generating a sample set of a semantic segmentation model of a remote sensing image, including:
the vector annotation data acquisition module is used for acquiring vector annotation data of the remote sensing image to be processed;
the grid labeling image acquisition module is used for carrying out grid combination processing on the vector labeling data to obtain a grid labeling image;
the vector element object ordering module is used for globally ordering the areas of the vector element objects in the vector annotation data from large to small to obtain an ordered vector element object list;
the object clipping window acquisition module is used for traversing the vector element objects of the vector element object list, if the current vector element object is not covered by the clipping window of the vector element object which is sequenced in front, or the size proportion covered by the clipping window of the vector element object which is sequenced in front is smaller than a preset proportion threshold value, acquiring the clipping window of the current vector element object, otherwise, skipping the current vector element object; obtaining object clipping windows of all vector element objects;
a sample set acquisition module: and cutting and sampling the remote sensing image and the grid labeling image according to object cutting windows of all the vector element objects to obtain a remote sensing image semantic segmentation model sample set comprising a plurality of sample pairs.
It should be noted that, when the remote sensing image semantic segmentation model sample set generating device provided in the second embodiment of the present application executes the remote sensing image semantic segmentation model sample set generating method, only the division of the above functional modules is used for illustrating, in practical application, the above functional allocation may be completed by different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules, so as to complete all or part of the functions described above. In addition, the remote sensing image semantic segmentation model sample set generating device provided in the second embodiment of the present application and the remote sensing image semantic segmentation model sample set generating method in the first embodiment of the present application belong to the same concept, which embody detailed implementation procedures in method embodiments, and are not described herein again.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks. These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart block or blocks and/or block diagram block or blocks.
In one typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include volatile memory in a computer-readable medium, random Access Memory (RAM) and/or nonvolatile memory, etc., such as Read Only Memory (ROM) or flash RAM. Memory is an example of a computer-readable medium.
Computer readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of storage media for a computer include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium, which can be used to store information that can be accessed by a computing device. Computer-readable media, as defined herein, does not include transitory computer-readable media (transmission media), such as modulated data signals and carrier waves.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus 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 apparatus. 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 apparatus that comprises an element.
The foregoing is merely exemplary of the present application and is not intended to limit the present application. Various modifications and changes may be made to the present application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc. which are within the spirit and principles of the present application are intended to be included within the scope of the claims of the present application.

Claims (10)

1. The method for generating the remote sensing image semantic segmentation model sample set is characterized by comprising the following steps of:
acquiring vector labeling data of a remote sensing image to be processed;
carrying out grid combination processing on the vector labeling data to obtain a grid labeling image;
globally sorting the areas of the vector element objects in the vector labeling data from large to small to obtain a sorted vector element object list;
traversing the vector element objects of the vector element object list, if the current vector element object is not covered by the cutting windows of the vector element objects sequenced in front, or the size proportion covered by the cutting windows of the vector element objects sequenced in front is smaller than a preset proportion threshold value, acquiring the cutting windows of the current vector element object, otherwise, skipping the current vector element object; obtaining object clipping windows of all vector element objects;
and cutting and sampling the remote sensing image and the grid labeling image according to object cutting windows of all the vector element objects to obtain a remote sensing image semantic segmentation model sample set comprising a plurality of sample pairs.
2. The method for generating the remote sensing image semantic segmentation model sample set according to claim 1, wherein the traversing the vector element object of the vector element object list obtains a current clipping window of the vector element object if the current vector element object is not covered by a clipping window of a vector element object ranked ahead or a size ratio covered by a clipping window of a vector element object ranked ahead is smaller than a preset ratio threshold, otherwise skips the current vector element object; the step of obtaining object clipping windows of all vector element objects comprises the following steps:
acquiring the rectangular length and rectangular width of an outsourcing rectangle of a current vector element object;
if the current rectangular length is smaller than the preset cutting window length and the rectangular width is smaller than the preset cutting window width, determining the current vector element object as a small-size object; if the current rectangular length is greater than or equal to the preset cutting window length or the rectangular width is greater than or equal to the preset cutting window width, determining the current vector element object as a large-size object;
acquiring an object cutting window of the large-size object according to a preset large-size object cutting window acquisition mode;
and acquiring the object cutting window of the small-size object according to a preset small-size object cutting window acquisition mode.
3. The method for generating a sample set of semantic segmentation models for remote sensing images according to claim 2, wherein the step of obtaining the object clipping window of the large-size object according to a preset large-size object clipping window obtaining manner comprises the following steps:
expanding an outsourcing rectangle of the current large-size object through the random buffer area;
and generating one or more windows which completely cover the current large-size object according to the preset cutting window length and the preset cutting window width by taking the outsourcing rectangle of the expanded current large-size object as a cutting range and taking the upper left corner of the cutting range as a starting point, so as to obtain the object cutting window of the current large-size object.
4. The method for generating a sample set of semantic segmentation models for remote sensing images according to claim 3, wherein the grid-labeled image is labeled with an uncertain region and an invalid value region;
the step of generating one or more windows completely covering the current large-size object by taking the outsourcing rectangle of the expanded current large-size object as a cutting range and taking the upper left corner of the cutting range as a starting point according to the preset cutting window length and the preset cutting window width to obtain an object cutting window of the current large-size object comprises the following steps:
when traversing the outsourcing rectangle of the current large-size object according to the window size of the default clipping window, if the current range of the window size comprises an uncertain region or an invalid value region, skipping the current range; and if the current range of the window size does not comprise the pixels of the current large-size object, skipping the current range.
5. The method for generating a sample set of semantic segmentation models for remote sensing images according to claim 2, wherein the step of obtaining the object clipping window of the small-sized object according to a preset small-sized object clipping window obtaining manner comprises the following steps:
acquiring a rectangular midpoint of an outsourcing rectangle of a current small-size object;
generating a plurality of candidate windows which are at different positions and respectively comprise the rectangular midpoints according to the preset cutting window length and the preset cutting window width;
and selecting an object clipping window of the current small-size object from the plurality of candidate windows according to a preset selection rule.
6. The method for generating the semantic segmentation model sample set of the remote sensing image according to claim 5, wherein the method comprises the following steps of: the number of the candidate windows is at least 5, and the rectangular midpoints are respectively positioned at the left upper part, the left lower part, the central part, the right upper part and the right lower part of the 5 candidate windows.
7. The method for generating the remote sensing image semantic segmentation model sample set according to claim 5, wherein the grid labeling image is labeled with an uncertain region and an invalid value region; the step of selecting the object clipping window of the current small-size object from the plurality of candidate windows according to a preset selection rule includes:
and checking whether each candidate window comprises an uncertain region and an invalid value region, and if only one candidate window does not comprise the uncertain region and the invalid value region, determining the corresponding candidate window as an object clipping window of the current small-size object.
8. The method for generating the remote sensing image semantic segmentation model sample set according to claim 7, wherein the grid labeling image is labeled with an uncertain region and an invalid value region; the step of selecting the object clipping window of the current small-size object from the plurality of candidate windows according to a preset selection rule further comprises:
if two or more candidate windows exist, the candidate windows which do not comprise the uncertain region and the invalid value region are deleted;
and acquiring the number of the non-sampled pixels of the vector element objects which are not sampled in the rest candidate windows, and determining the candidate window with the largest number of the non-sampled pixels as an object clipping window of the current small-size object.
9. The method for generating the remote sensing image semantic segmentation model sample set according to claim 8, wherein the grid labeling image is labeled with an uncertain region and an invalid value region; the step of selecting the object clipping window of the current small-size object from the plurality of candidate windows according to a preset selection rule further comprises:
if the number of the non-sampled pixels is two or more than two, deleting the candidate window with the non-sampled pixels not being the maximum;
and acquiring the number of sampled pixels of the sampled vector element object in each remaining candidate window, and determining the candidate window with the minimum number of sampled pixels as an object clipping window of the current small-size object.
10. The utility model provides a remote sensing image semantic segmentation model sample set generation device which characterized in that includes:
the vector annotation data acquisition module is used for acquiring vector annotation data of the remote sensing image to be processed;
the grid labeling image acquisition module is used for carrying out grid combination processing on the vector labeling data to obtain a grid labeling image;
the vector element object ordering module is used for globally ordering the areas of the vector element objects in the vector annotation data from large to small to obtain an ordered vector element object list;
the object clipping window acquisition module is used for traversing the vector element objects of the vector element object list, if the current vector element object is not covered by the clipping window of the vector element object which is sequenced in front, or the size proportion covered by the clipping window of the vector element object which is sequenced in front is smaller than a preset proportion threshold value, acquiring the clipping window of the current vector element object, otherwise, skipping the current vector element object; obtaining object clipping windows of all vector element objects;
a sample set acquisition module: and cutting and sampling the remote sensing image and the grid labeling image according to object cutting windows of all the vector element objects to obtain a remote sensing image semantic segmentation model sample set comprising a plurality of sample pairs.
CN202310355592.8A 2023-04-04 Remote sensing image semantic segmentation model sample set generation method and device Active CN116486077B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310355592.8A CN116486077B (en) 2023-04-04 Remote sensing image semantic segmentation model sample set generation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310355592.8A CN116486077B (en) 2023-04-04 Remote sensing image semantic segmentation model sample set generation method and device

Publications (2)

Publication Number Publication Date
CN116486077A true CN116486077A (en) 2023-07-25
CN116486077B CN116486077B (en) 2024-04-30

Family

ID=

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117349462A (en) * 2023-12-06 2024-01-05 自然资源陕西省卫星应用技术中心 Remote sensing intelligent interpretation sample data set generation method

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110765951A (en) * 2019-10-24 2020-02-07 西安电子科技大学 Remote sensing image airplane target detection method based on bounding box correction algorithm
US20200342655A1 (en) * 2019-04-29 2020-10-29 Wuhan University Method and system for vector-raster overlay analysis of ground surface image area based on edge clipping
CN111914102A (en) * 2020-08-27 2020-11-10 上海掌门科技有限公司 Method for editing multimedia data, electronic device and computer storage medium
CN112884791A (en) * 2021-02-02 2021-06-01 重庆市地理信息和遥感应用中心 Method for constructing large-scale remote sensing image semantic segmentation model training sample set
CN114463623A (en) * 2021-12-17 2022-05-10 浙江万维空间信息技术有限公司 Method and device for detecting farmland change based on multi-scale remote sensing image
CN114519819A (en) * 2022-02-10 2022-05-20 西北工业大学 Remote sensing image target detection method based on global context awareness
US20220245715A1 (en) * 2019-06-24 2022-08-04 Terry's Textiles Ltd Image cropping method and system
CN115311555A (en) * 2022-07-15 2022-11-08 武汉大学 Remote sensing image building extraction model generalization method based on batch style mixing
CN115841552A (en) * 2022-11-30 2023-03-24 北京百度网讯科技有限公司 High-precision map generation method and device, electronic equipment and medium
CN115861609A (en) * 2022-11-15 2023-03-28 浙江大华技术股份有限公司 Segmentation labeling method of remote sensing image, electronic device and storage medium
CN116860906A (en) * 2023-09-05 2023-10-10 高德软件有限公司 Track generation method, track generation device, track generation equipment and storage medium

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20200342655A1 (en) * 2019-04-29 2020-10-29 Wuhan University Method and system for vector-raster overlay analysis of ground surface image area based on edge clipping
US20220245715A1 (en) * 2019-06-24 2022-08-04 Terry's Textiles Ltd Image cropping method and system
CN110765951A (en) * 2019-10-24 2020-02-07 西安电子科技大学 Remote sensing image airplane target detection method based on bounding box correction algorithm
CN111914102A (en) * 2020-08-27 2020-11-10 上海掌门科技有限公司 Method for editing multimedia data, electronic device and computer storage medium
CN112884791A (en) * 2021-02-02 2021-06-01 重庆市地理信息和遥感应用中心 Method for constructing large-scale remote sensing image semantic segmentation model training sample set
CN114463623A (en) * 2021-12-17 2022-05-10 浙江万维空间信息技术有限公司 Method and device for detecting farmland change based on multi-scale remote sensing image
CN114519819A (en) * 2022-02-10 2022-05-20 西北工业大学 Remote sensing image target detection method based on global context awareness
CN115311555A (en) * 2022-07-15 2022-11-08 武汉大学 Remote sensing image building extraction model generalization method based on batch style mixing
CN115861609A (en) * 2022-11-15 2023-03-28 浙江大华技术股份有限公司 Segmentation labeling method of remote sensing image, electronic device and storage medium
CN115841552A (en) * 2022-11-30 2023-03-24 北京百度网讯科技有限公司 High-precision map generation method and device, electronic equipment and medium
CN116860906A (en) * 2023-09-05 2023-10-10 高德软件有限公司 Track generation method, track generation device, track generation equipment and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
陈苏晋,孟令奎,张 文: "面向河长制的河湖"乱占"现象遥感监测技术研究", 水 利 信 息 化 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117349462A (en) * 2023-12-06 2024-01-05 自然资源陕西省卫星应用技术中心 Remote sensing intelligent interpretation sample data set generation method
CN117349462B (en) * 2023-12-06 2024-03-12 自然资源陕西省卫星应用技术中心 Remote sensing intelligent interpretation sample data set generation method

Similar Documents

Publication Publication Date Title
US8917935B2 (en) Detecting text using stroke width based text detection
CN110990516B (en) Map data processing method, device and server
CN112734641A (en) Training method and device of target detection model, computer equipment and medium
CN110517334B (en) Vector map data acquisition method and device
CN111310759B (en) Target detection inhibition optimization method and device for dual-mode cooperation
CN113761999A (en) Target detection method and device, electronic equipment and storage medium
CN114998595B (en) Weak supervision semantic segmentation method, semantic segmentation method and readable storage medium
CN114677596A (en) Remote sensing image ship detection method and device based on attention model
CN110879972A (en) Face detection method and device
CN108573510B (en) Grid map vectorization method and device
CN116486077B (en) Remote sensing image semantic segmentation model sample set generation method and device
CN111967449B (en) Text detection method, electronic device and computer readable medium
CN116486312B (en) Video image processing method and device, electronic equipment and storage medium
CN114638996A (en) Model training method, device, equipment and storage medium based on counterstudy
CN116486077A (en) Remote sensing image semantic segmentation model sample set generation method and device
CN109855634B (en) Image processing method and device for grid map
CN111881996A (en) Object detection method, computer device and storage medium
CN111870953A (en) Height map generation method, device, equipment and storage medium
CN115861609A (en) Segmentation labeling method of remote sensing image, electronic device and storage medium
CN115424142A (en) Coastline type discrimination method, coastline type discrimination device, coastline type discrimination medium and coastline type discrimination equipment based on remote sensing images
CN115035404A (en) Method and system for constructing semantic map based on three-dimensional laser radar
CN114332112A (en) Cell image segmentation method and device, electronic equipment and storage medium
CN116737852A (en) Vector tile data-based vector drawing method and device and electronic equipment
CN112634286A (en) Image cropping method and device
CN112102338A (en) Method and device for acquiring image sample data based on deep learning

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant