Remote sensing image clustering method, device, equipment and medium
Through the unsupervised training and contrastive learning algorithm of the remote sensing image clustering model, the clustering of pixel features is optimized, which solves the problem of inaccurate information acquisition in heterogeneous remote sensing image processing and improves the accuracy of image data analysis and feature abstraction capabilities.
Patent Information
- Application Number
- CN202410931761.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-12
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2044-07-12
AI Technical Summary
It is difficult for the existing technology to effectively process heterogeneous remote sensing images and accurately obtain ground object information, and the image data analysis results are not accurate enough.
The remote sensing image clustering model is used to obtain multiple heterogeneous sample remote sensing images, perform initial clustering, construct positive sample pairs and negative sample pairs, construct a loss function, conduct unsupervised training of the model, and combine contrastive learning algorithms to optimize pixel features. The clustering results maximize the intra-class similarity and minimize the inter-class similarity.
It improves the feature abstract representation ability of the remote sensing image clustering model, enhances the feature similarity of pixels of the same category and the similarity of pixel features in different source images, and improves the accuracy of multi-source remote sensing image clustering tasks.
Smart Images

Figure CN118506040B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of remote sensing image processing, and more specifically, to a remote sensing image clustering method, device, equipment and medium. Background Art
[0002] Remote sensing images are the product of information obtained through various sensors and are the information carrier of remote sensing detection targets. Remote sensing images can contain a lot of information about ground objects, such as water bodies, vegetation, land, mountains, etc. Smaller objects can be identified from remote sensing images, such as a tree, a person, a traffic sign, a marking line in a football field, etc.
[0003] With the advancement of science and technology, different types of remote sensing sensors continue to emerge, including optical sensors, radar sensors, infrared sensors, etc. The data obtained by different sensors have different characteristics and information, thus forming heterogeneous remote sensing images. Due to the limitations of a single sensor, comprehensive observation and monitoring of the earth's surface often requires the fusion of data from different sensors. For example, the fusion of optical remote sensing images and SAR remote sensing images can improve the accuracy and robustness of ground object classification. In order to obtain more comprehensive and accurate earth information, it is necessary to use multi-source remote sensing data from different platforms and sensors. For example, combining satellite remote sensing data and drone aerial photography data can achieve more sophisticated ground object identification and monitoring.
[0004] Since remote sensing images have different sources, different acquisition times, large area coverage and cloud cover, how to effectively process remote sensing images and accurately obtain useful information from remote sensing images is an important research direction in various fields. Summary of the invention
[0005] In view of this, the present invention provides a remote sensing image clustering method, device, equipment and medium.
[0006] One aspect of the present invention provides a remote sensing image clustering method, comprising: obtaining at least two heterogeneous target remote sensing images to be processed; inputting at least two heterogeneous target remote sensing images into a remote sensing image clustering model to obtain a first clustering result, the first clustering result characterizing the similarity of pixel features in the same target remote sensing image and the similarity of pixel features between different target remote sensing images; based on the first clustering result, clustering the pixel features in the at least two target remote sensing images to obtain a second clustering result.
[0007] According to an embodiment of the present invention, a training method for a remote sensing image clustering model includes: acquiring multiple heterogeneous sample remote sensing images; performing initial clustering on pixel features in each heterogeneous sample remote sensing image respectively to obtain at least one positive sample pair and at least one negative sample pair, wherein the positive sample pair represents that two pixel features in the same sample remote sensing image belong to the same category, and the negative sample pair represents that two pixel features in the same sample remote sensing image belong to different categories; constructing a loss function based on the at least one positive sample pair and the at least one negative sample pair; and performing unsupervised training on the remote sensing image clustering model to be trained using the loss function to obtain the remote sensing image clustering model.
[0008] According to an embodiment of the present invention, pixel features in each heterogeneous sample remote sensing image are initially clustered to obtain at least one positive sample pair and at least one negative sample pair, including: constructing a graph model for each sample remote sensing image, and extracting node features in the graph model, wherein pixels in the sample remote sensing image represent node features; performing initial clustering on the node features of each sample remote sensing image through a preset clustering algorithm to obtain an initial clustering result, wherein the initial clustering result represents the similarity between two node features; and dividing at least one positive sample pair and at least one negative sample pair of each sample remote sensing image according to the initial clustering result, wherein the positive sample pair represents that the similarity between the two node features is higher than a first threshold, and the negative sample pair represents that the similarity between the two node features is lower than the first threshold.
[0009] According to an embodiment of the present invention, a loss function is constructed based on at least one positive sample pair and at least one negative sample pair, including: constructing a first contrast loss function corresponding to each sample remote sensing image based on at least one positive sample pair and at least one negative sample pair of each sample remote sensing image; constructing a second contrast loss function corresponding to two sample remote sensing images based on at least one positive sample pair and at least one negative sample pair of different sample remote sensing images.
[0010] According to an embodiment of the present invention, the expression of the first contrast loss function is expressed as follows:
[0011]
[0012] in, represents the first contrast loss function corresponding to the Mth sample remote sensing image, Represents the node features of the positive sample pair With node features The similarity between Represents the node features of negative sample pairs With node features The similarity between them is expressed as , and N represents the sum of the number of positive sample pairs and negative sample pairs in the Mth sample remote sensing image.
[0013] According to an embodiment of the present invention, the expression of the second contrast loss function is expressed as follows:
[0014]
[0015] in, represents the second contrast loss function between the mth sample remote sensing image and the nth sample remote sensing image, and m and n are not equal, 1≤m, n≤M, Represents the node features of the positive sample pair With node features The similarity between Represents the node features of negative sample pairs With node features The similarity between them is , and N represents the sum of the number of positive sample pairs and negative sample pairs between the m-th sample remote sensing image and the n-th sample remote sensing image.
[0016] According to an embodiment of the present invention, positive samples of different sample remote sensing images represent node features at the same position in two sample remote sensing images, and negative samples of different sample remote sensing images represent node features at different positions in two sample remote sensing images.
[0017] Another aspect of the present invention provides a remote sensing image clustering device, comprising: an acquisition module, used to acquire at least two heterogeneous target remote sensing images to be processed; a first clustering module, used to input at least two heterogeneous target remote sensing images into a remote sensing image clustering model to obtain a first clustering result, the first clustering result characterizing the similarity of pixel features in the same target remote sensing image and the similarity of pixel features between different target remote sensing images; and a second clustering module, used to cluster the pixel features in the at least two heterogeneous target remote sensing images based on the first clustering result to obtain a second clustering result.
[0018] Another aspect of the present invention provides an electronic device, comprising:
[0019] one or more processors;
[0020] a memory for storing one or more programs,
[0021] When one or more programs are executed by one or more processors, the one or more processors implement the above method.
[0022] Another aspect of the present invention provides a computer-readable storage medium storing computer-executable instructions, which are used to implement the above method when executed.
[0023] At least one of the above technical solutions adopted in the embodiments of the present invention can achieve the following beneficial effects:
[0024] Through the remote sensing image clustering model, we can take into account both the maximization of intra-class similarity and the minimization of inter-class similarity, reduce the distance between pixels with similar features, and ensure that the features finally generated by pixels of the same category have similar representation capabilities. At the same time, we can also maximize the similarity of feature representation of corresponding pixels in different source images at the same position, thereby improving the feature abstraction representation capability of the remote sensing image clustering model and providing support for downstream multi-source remote sensing image clustering tasks. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] The above and other objects, features and advantages of the present invention will become more apparent through the following description of the embodiments of the present invention with reference to the accompanying drawings, in which:
[0026] Figure 1 A sample diagram of a remote sensing image of a heterogeneous target according to an embodiment of the present invention is schematically shown;
[0027] Figure 2 A flowchart of a remote sensing image clustering method according to an embodiment of the present invention is schematically shown;
[0028] Figure 3 A flowchart of a remote sensing image clustering model training method according to an embodiment of the present invention is schematically shown;
[0029] Figure 4 A flowchart of an initial clustering method according to an embodiment of the present invention is schematically shown;
[0030] Figure 5 A schematic diagram of a remote sensing image clustering method according to an embodiment of the present invention is shown;
[0031] Figure 6 A block diagram schematically shows a remote sensing image clustering device according to an embodiment of the present invention; and
[0032] Figure 7 A block diagram of an electronic device suitable for a remote sensing image clustering method according to an embodiment of the present invention is schematically shown. DETAILED DESCRIPTION
[0033] Below, embodiments of the present invention will be described with reference to the accompanying drawings. However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of the present invention. In the following detailed description, for ease of explanation, many specific details are set forth to provide a comprehensive understanding of embodiments of the present invention. However, it is apparent that one or more embodiments may also be implemented without these specific details. In addition, in the following description, descriptions of known structures and technologies are omitted to avoid unnecessary confusion of concepts of the present invention.
[0034] The terms used herein are only for describing specific embodiments and are not intended to limit the present invention. The terms "comprise", "include", etc. used herein indicate the existence of the features, steps, operations and / or components, but do not exclude the existence or addition of one or more other features, steps, operations or components.
[0035] All terms (including technical and scientific terms) used herein have the meanings commonly understood by those skilled in the art unless otherwise defined. It should be noted that the terms used herein should be interpreted as having a meaning consistent with the context of this specification and should not be interpreted in an idealized or overly rigid manner.
[0036] When using expressions such as "at least one of A, B, and C, etc.", they should generally be interpreted according to the meaning of the expression commonly understood by those skilled in the art (for example, "a system having at least one of A, B, and C" should include but is not limited to a system having A alone, B alone, C alone, A and B, A and C, B and C, and / or A, B, C, etc.).
[0037] The embodiments of the present invention provide a remote sensing image clustering method, device, equipment and medium. Before introducing the technical solution provided by the embodiments of the present invention, the related technologies involved in the present invention are first described.
[0038] In related technologies, remote sensing images are the product of obtaining information through various sensors and are the information carriers of remote sensing detection targets. Remote sensing images can contain a lot of information about ground objects, such as water bodies, vegetation, land, mountains, etc. Smaller objects can be identified from remote sensing images, such as a tree, a person, a traffic sign, a marking line in a football field, etc.
[0039] With the advancement of science and technology, different types of remote sensing sensors continue to emerge, including optical sensors, radar sensors, infrared sensors, etc. The data obtained by different sensors have different characteristics and information, thus forming heterogeneous remote sensing images. Due to the limitations of a single sensor, comprehensive observation and monitoring of the earth's surface often requires the fusion of data from different sensors. For example, the fusion of optical remote sensing images and SAR remote sensing images can improve the accuracy and robustness of ground object classification. In order to obtain more comprehensive and accurate earth information, it is necessary to use multi-source remote sensing data from different platforms and sensors. For example, combining satellite remote sensing data and drone aerial photography data can achieve more sophisticated ground object identification and monitoring.
[0040] Since remote sensing images have different sources, different acquisition times, large area coverage and cloud cover, how to effectively process remote sensing images and accurately obtain useful information from remote sensing images is an important research direction in various fields.
[0041] With the rapid development of machine learning, various machine learning algorithms are increasingly being applied to remote sensing image analysis. Image analysis methods based on the combination of bionics and clustering algorithms provide effective and reliable algorithm support for remote sensing image classification. However, existing technologies have the problem that image data analysis results are not accurate enough.
[0042] Before further describing the embodiments of the present invention in detail, the nouns and terms involved in the embodiments of the present invention are described. The nouns and terms involved in the embodiments of the present invention are subject to the following interpretations.
[0043] Contrastive learning is an unsupervised learning method that does not rely on a large number of manually annotated labels for training, so that contrastive learning can use a large amount of unlabeled data to learn feature representation, thereby better mining the potential structure and characteristics of the data.
[0044] The embodiment of the present invention provides a remote sensing image clustering method, including: obtaining at least two heterogeneous target remote sensing images to be processed; inputting at least two heterogeneous target remote sensing images into a remote sensing image clustering model to obtain a first clustering result, the first clustering result characterizing the similarity of pixel features in the same target remote sensing image and the similarity of pixel features between different target remote sensing images; based on the first clustering result, clustering the pixel features in at least two target remote sensing images to obtain a second clustering result. Through the remote sensing image clustering model, it is possible to take into account both the maximization of intra-class similarity and the minimization of inter-class similarity, so that the distance between pixels with similar features is reduced to ensure that the features finally generated by pixels of the same category have similar representation capabilities. At the same time, it is also possible to maximize the feature representation similarity of corresponding pixels in different source images at the same position, thereby improving the feature abstraction representation capability of the remote sensing image clustering model and providing support for downstream multi-source remote sensing image clustering tasks.
[0045] Reference below Figure 1~Figure 5 , the remote sensing image data processing method is further explained in conjunction with a specific embodiment.
[0046] Figure 1 A sample diagram of a remote sensing image of a heterogeneous target according to an embodiment of the present invention is schematically shown; Figure 2 The flowchart of the remote sensing image clustering method according to an embodiment of the present invention is schematically shown.
[0047] like Figure 2 As shown, the remote sensing image clustering method in the embodiment of the present invention includes operations S210 to S230.
[0048] In operation S210, at least two remote sensing images of different sources to be processed are acquired.
[0049] In some embodiments, remote sensing images captured by remote sensing sensors of different types for the same target object belong to heterogeneous target remote sensing images.
[0050] For example, refer to Figure 1 For Chaoyang District in Beijing, optical remote sensing images were obtained by using optical remote sensing sensors, and synthetic aperture radar remote sensing images were obtained by using synthetic aperture radar remote sensing sensors.
[0051] In operation S220, at least two heterogeneous target remote sensing images are input into a remote sensing image clustering model to obtain a first clustering result, which represents the similarity of pixel features in the same target remote sensing image and the similarity of pixel features between different target remote sensing images.
[0052] In some embodiments, the remote sensing image clustering model can perform cluster analysis on a target remote sensing image to obtain the similarity of two pixel features in the target remote sensing image (i.e., the similarity of pixel features in the same target remote sensing image). At the same time, it can also perform cluster analysis on different target remote sensing images (i.e., two remote sensing images taken based on different remote sensing sensors) to obtain the similarity of two pixel features in two target remote sensing images (i.e., the similarity of pixel features in different target remote sensing images).
[0053] In operation S230, pixel features in at least two target remote sensing images are clustered based on the first clustering result to obtain a second clustering result.
[0054] In some embodiments, the similarity results between pixel features in the same target remote sensing image and the similarity results between pixel features in different target remote sensing images obtained after processing the remote sensing image clustering model are clustered again to obtain the final clustering results of pixel features between multiple heterogeneous target remote sensing images (second clustering results).
[0055] It can be understood that through the remote sensing image clustering model, it is possible to take into account both the maximization of intra-class similarity and the minimization of inter-class similarity, so that the distance between pixels with similar features is reduced to ensure that the features finally generated by pixels of the same category have similar representation capabilities. At the same time, it can also maximize the similarity of feature representation of corresponding pixels in different source images at the same position, thereby improving the feature abstraction representation capability of the remote sensing image clustering model and providing support for downstream multi-source remote sensing image clustering tasks.
[0056] Figure 3 The flowchart of the remote sensing image clustering model training method according to an embodiment of the present invention is schematically shown.
[0057] like Figure 3 As shown, in some embodiments, the remote sensing image clustering model training method includes operations S310~S340.
[0058] In operation S310, a plurality of heterogeneous sample remote sensing images are acquired.
[0059] In operation S320, initial clustering is performed on the pixel features in each heterogeneous sample remote sensing image to obtain at least one positive sample pair and at least one negative sample pair, wherein the positive sample pair represents that two pixel features in the same sample remote sensing image belong to the same category, and the negative sample pair represents that two pixel features in the same sample remote sensing image belong to different categories.
[0060] In operation S330 , a loss function is constructed according to at least one positive sample pair and at least one negative sample pair.
[0061] In operation S340, unsupervised training is performed on the remote sensing image clustering model to be trained using a loss function to obtain a remote sensing image clustering model.
[0062] In some embodiments, the remote sensing image clustering model to be trained may be an unsupervised network model.
[0063] Exemplarily, two heterogeneous sample remote sensing images (optical remote sensing image and synthetic aperture radar remote sensing image) are used as examples for explanation. Initial clustering is performed on the pixel features in the optical remote sensing image and the synthetic aperture radar remote sensing image, respectively, to obtain one or more positive sample pairs of the same category and one or more negative sample pairs of different categories. The positive sample pair indicates that the spectral, spatial and texture information between the two pixels is relatively similar. Therefore, the pixels with similar spectral information, spatial information or texture information can be classified into the same category by the clustering algorithm. The negative sample pair indicates that the spectral, spatial and texture information between the two pixels is quite different. Therefore, the pixels with different spectral information, spatial information or texture information can be classified into different categories by the clustering algorithm.
[0064] The loss function is set for optical remote sensing images and synthetic aperture radar remote sensing images to maximize the similarity within a class and minimize the similarity between classes. The goal of the self-supervised training of the remote sensing image clustering model is to continuously reduce the set loss function to improve the similarity between positive sample pairs and minimize the similarity between negative sample pairs.
[0065] Specifically, in an embodiment of the present invention, a stochastic gradient descent algorithm is used when performing model training. In each training iteration, a loss function value is calculated based on the similarity between the current sample pairs, and the network parameters are updated through a back propagation algorithm. The iteration is repeated until the maximum number of rounds is reached or the loss function converges.
[0066] It is understandable that setting a suitable loss function should make the distance between samples (pixels) of the same category as close as possible, and the distance between samples (pixels) of different categories as far as possible, thereby improving the effect of model clustering processing.
[0067] Figure 4 The flowchart of the initial clustering method according to the embodiment of the present invention is schematically shown.
[0068] like Figure 4 As shown, in some embodiments, the remote sensing image clustering model training method includes operations S321~S323.
[0069] In operation S321 , a graph model is constructed for each sample remote sensing image, and node features in the graph model are extracted, wherein pixels in the sample remote sensing image represent node features.
[0070] In operation S322, the node features of each sample remote sensing image are initially clustered by a preset clustering algorithm to obtain an initial clustering result, wherein the initial clustering result represents the similarity between two node features.
[0071] In operation S323, at least one positive sample pair and at least one negative sample pair are obtained for each sample remote sensing image according to the initial clustering result, wherein the positive sample pair represents that the similarity between the two node features is higher than a first threshold, and the negative sample pair represents that the similarity between the two node features is lower than the first threshold.
[0072] Exemplarily, corresponding graph models are constructed on heterogeneous remote sensing images from optical remote sensing and synthetic aperture radar remote sensing, respectively, and the graph model is specifically constructed using a graph neural network GNN. Subsequently, node feature extraction is performed, and node features are extracted from the constructed graph model. The node features are initially clustered using the kmeans algorithm using a similarity metric criterion to obtain an initial clustering result. The node features here refer to pixels or pixel blocks in the image. The similarity between two node features is obtained in the initial clustering result. Positive and negative sample pairs are further divided according to the results of the initial clustering. For example, the similarity is set to 0-100, and a first threshold (70) is set for ease of division. Two pixel features with a similarity higher than 70 can be divided into positive sample pairs, and those with a similarity lower than 70 can be divided into negative sample pairs.
[0073] It can be understood that the automatic clustering method of multi-source remote sensing images based on graph contrast learning can force the distance between pixels with similar characteristics to decrease, so as to ensure that the features finally generated by pixels of the same category with similar spectral, spatial or texture information have similar representation capabilities, and at the same time force the feature representation similarity of corresponding pixels in different source images at the same position to be maximized, thereby improving the feature abstraction representation ability of the network model and providing support for downstream multi-source remote sensing image clustering tasks.
[0074] In some embodiments, in operation S330, a loss function is constructed according to at least one positive sample pair and at least one negative sample pair, including:
[0075] According to at least one positive sample pair and at least one negative sample pair of each sample remote sensing image, a first contrast loss function corresponding to each sample remote sensing image is constructed respectively.
[0076] According to at least one positive sample pair and at least one negative sample pair of different sample remote sensing images, a second contrast loss function corresponding to the two sample remote sensing images is constructed.
[0077] Specifically, a first loss function is constructed for one remote sensing image, and a second loss function is constructed for two (heterogeneous) remote sensing images.
[0078] It can be understood that setting two different types of loss functions can maximize the intra-class similarity and minimize the inter-class similarity.
[0079] In some embodiments, the expression of the first contrast loss function is expressed as follows:
[0080]
[0081] in, represents the first contrast loss function corresponding to the Mth sample remote sensing image, Represents the node features of the positive sample pair With node features The similarity between Represents the node features of negative sample pairs With node features The similarity between them is expressed as , and N represents the sum of the number of positive sample pairs and negative sample pairs in the Mth sample remote sensing image.
[0082] Exemplarily, the first contrast loss function is constructed for the optical remote sensing image (M=1) and the synthetic aperture radar remote sensing image (M=1), respectively, as follows:
[0083]
[0084]
[0085] represents the first contrast loss function constructed for optical remote sensing images; Represents the first contrast loss function constructed for synthetic aperture radar remote sensing images.
[0086] In some embodiments, the expression of the second contrast loss function is expressed as follows:
[0087]
[0088] in, represents the second contrast loss function between the mth sample remote sensing image and the nth sample remote sensing image, and m and n are not equal, 1≤m, n≤M, Represents the node features of the positive sample pair With node features The similarity between Represents the node features of negative sample pairs With node features The similarity between them is , and N represents the sum of the number of positive sample pairs and negative sample pairs between the m-th sample remote sensing image and the n-th sample remote sensing image.
[0089] Exemplarily, the second contrast loss function is constructed for the optical remote sensing image and the synthetic aperture radar remote sensing image, respectively, as follows:
[0090]
[0091] It is understandable that the goal of self-supervised training of remote sensing image clustering model is to continuously reduce the two types of loss function values set respectively, so as to improve the similarity between positive sample pairs and minimize the similarity between negative sample pairs. Using the stochastic gradient descent algorithm, in each training iteration, the loss function value is calculated according to the similarity between the current sample pairs, and the network parameters are updated through the back propagation algorithm. The iteration is repeated until the maximum number of rounds is reached or the loss function converges, and the trained remote sensing image clustering model can be obtained. The trained model can be used to effectively cluster the features in heterogeneous remote sensing images and provide support for other remote sensing downstream tasks.
[0092] In order to facilitate the understanding of the remote sensing image processing method of the embodiment of the present invention, Figure 5 Provide further explanation.
[0093] Figure 5 The schematic diagram shows a principle diagram of a remote sensing image clustering method according to an embodiment of the present invention.
[0094] like Figure 5As shown in the figure, we continue to use the above two heterogeneous sample remote sensing images (optical remote sensing image and synthetic aperture radar remote sensing image) as an example for explanation. Graph models are constructed on optical remote sensing images and synthetic aperture radar remote sensing images respectively, and the node features of each graph model are initially clustered using clustering algorithms such as kmeans. Positive and negative sample pairs are divided according to the results of the initial clustering. Then the positive and negative sample pairs are input into the trained remote sensing image clustering model for comparative learning. Contrastive learning includes two categories. The first type of comparative learning is the result obtained by comparing the positive and negative sample pairs in the optical remote sensing image and the synthetic aperture radar remote sensing image; the second type of comparative learning is the result obtained by comparing the positive and negative sample pairs between the optical remote sensing image and the synthetic aperture radar remote sensing image. The similarity between the positive sample pairs is continuously improved, and the similarity between the negative sample pairs is continuously reduced, so as to maximize the similarity within the class and minimize the similarity between the classes. Subsequently, the optimized node features are clustered again using clustering algorithms such as kmeans. Since the intra-class features (each image) and inter-class features (different images) have been optimized, the second clustering can achieve better results and obtain the final clustering results.
[0095] Based on the above remote sensing image clustering method, the present invention also provides a remote sensing image clustering device. Figure 6 The device is described in detail.
[0096] Figure 6 A block diagram of a remote sensing image clustering device according to an embodiment of the present invention is schematically shown.
[0097] like Figure 6 As shown, the remote sensing image clustering device 600 of this embodiment includes an acquisition module 610 , a first clustering module 620 and a second clustering module 630 .
[0098] The acquisition module 610 is used to acquire at least two heterogeneous target remote sensing images to be processed. In one embodiment, the acquisition module 610 can be used to perform the operation S210 described above, which will not be described in detail here.
[0099] The first clustering module 620 is used to input at least two heterogeneous target remote sensing images into the remote sensing image clustering model to obtain a first clustering result, wherein the first clustering result represents the similarity of pixel features in the same target remote sensing image and the similarity of pixel features between different target remote sensing images. In one embodiment, the first clustering module 620 can be used to perform the operation S220 described above, which will not be repeated here.
[0100] The second clustering module 630 is used to cluster the pixel features in at least two heterogeneous target remote sensing images based on the first clustering result to obtain a second clustering result. In one embodiment, the second clustering module 630 can be used to perform the operation S230 described above, which will not be described in detail here.
[0101] According to an embodiment of the present invention, any multiple modules of the acquisition module 610, the first clustering module 620, and the second clustering module 630 can be combined into one module for implementation, or any one of the modules can be split into multiple modules. Alternatively, at least part of the functions of one or more of these modules can be combined with at least part of the functions of other modules and implemented in one module. According to an embodiment of the present invention, at least one of the acquisition module 610, the first clustering module 620, and the second clustering module 630 can be at least partially implemented as a hardware circuit, such as a field programmable gate array (FPGA), a programmable logic array (PLA), a system on a chip, a system on a substrate, a system on a package, an application-specific integrated circuit (ASIC), or can be implemented by hardware or firmware such as any other reasonable way of integrating or packaging the circuit, or implemented in any one of the three implementation methods of software, hardware, and firmware, or in any appropriate combination of any of them. Alternatively, at least one of the acquisition module 610, the first clustering module 620, and the second clustering module 630 can be at least partially implemented as a computer program module, and when the computer program module is run, the corresponding function can be performed.
[0102] Figure 7 A block diagram of an electronic device suitable for a remote sensing image clustering method according to an embodiment of the present invention is schematically shown. Figure 7 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.
[0103] like Figure 7 As shown, the electronic device 700 according to an embodiment of the present invention includes a processor 701, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 702 or a program loaded from a storage part 708 to a random access memory (RAM) 703. The processor 701 may include, for example, a general-purpose microprocessor (e.g., a CPU), an instruction set processor and / or a related chipset and / or a special-purpose microprocessor (e.g., an application-specific integrated circuit (ASIC)), etc. The processor 701 may also include an onboard memory for caching purposes. The processor 701 may include a single processing unit or multiple processing units for performing different actions of the method flow according to an embodiment of the present invention.
[0104] In RAM 703, various programs and data required for the operation of electronic device 700 are stored. Processor 701, ROM 702 and RAM 703 are connected to each other via bus 704. Processor 701 performs various operations of the method flow according to the embodiment of the present invention by executing the programs in ROM 702 and / or RAM 703. It should be noted that the program can also be stored in one or more memories other than ROM 702 and RAM 703. Processor 701 can also perform various operations of the method flow according to the embodiment of the present invention by executing the programs stored in the one or more memories.
[0105] According to an embodiment of the present invention, the electronic device 700 may further include an input / output (I / O) interface 705, which is also connected to the bus 704. The electronic device 700 may further include one or more of the following components connected to the input / output (I / O) interface 705: an input portion 706 including a keyboard, a mouse, etc.; an output portion 707 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage portion 708 including a hard disk, etc.; and a communication portion 709 including a network interface card such as a LAN card, a modem, etc. The communication portion 709 performs communication processing via a network such as the Internet. A drive 710 is also connected to the input / output (I / O) interface 705 as needed. A removable medium 711, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 710 as needed, so that a computer program read therefrom is installed into the storage portion 708 as needed.
[0106] According to an embodiment of the present invention, the method flow according to an embodiment of the present invention can be implemented as a computer software program. For example, an embodiment of the present invention includes a computer program product, which includes a computer program carried on a computer-readable storage medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 709, and / or installed from the removable medium 711. When the computer program is executed by the processor 701, the above-mentioned functions defined in the system of the embodiment of the present invention are executed. According to an embodiment of the present invention, the system, equipment, device, module, unit, etc. described above can be implemented by a computer program module.
[0107] The present invention also provides a computer-readable storage medium, which may be included in the device / apparatus / system described in the above embodiment; or may exist independently without being assembled into the device / apparatus / system. The above computer-readable storage medium carries one or more programs, and when the above one or more programs are executed, the method according to the embodiment of the present invention is implemented.
[0108] According to an embodiment of the present invention, the computer-readable storage medium may be a non-volatile computer-readable storage medium. For example, it may include but is not limited to: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present invention, the computer-readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system, an apparatus or a device.
[0109] For example, according to an embodiment of the present invention, the computer-readable storage medium may include the ROM 702 and / or the RAM 703 described above and / or one or more memories other than the ROM 702 and the RAM 703 .
[0110] An embodiment of the present invention also includes a computer program product, which includes a computer program, which contains program code for executing the method provided by the embodiment of the present invention. When the computer program product runs on an electronic device, the program code is used to enable the electronic device to implement the remote sensing image clustering method provided by the embodiment of the present invention.
[0111] When the computer program is executed by the processor 701, the above functions defined in the system / device of the embodiment of the present invention are executed. According to the embodiment of the present invention, the system, device, module, unit, etc. described above can be implemented by a computer program module.
[0112] In one embodiment, the computer program may rely on tangible storage media such as optical storage devices, magnetic storage devices, etc. In another embodiment, the computer program may also be transmitted and distributed in the form of signals on a network medium, and downloaded and installed through the communication part 709, and / or installed from the removable medium 711. The program code contained in the computer program may be transmitted using any appropriate network medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.
[0113] According to an embodiment of the present invention, the program code for executing the computer program provided by the embodiment of the present invention can be written in any combination of one or more programming languages. Specifically, these computing programs can be implemented using high-level process and / or object-oriented programming languages, and / or assembly / machine languages. Programming languages include, but are not limited to, Java, C++, python, "C" language or similar programming languages. The program code can be executed entirely on the user computing device, partially on the user device, partially on the remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device can be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computing device (e.g., using an Internet service provider to connect through the Internet).
[0114] The flowcharts and block diagrams in the accompanying drawings illustrate the possible architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present invention. In this regard, each box in the flowchart or block diagram may represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of the code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box may also occur in an order different from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flowchart, and the combination of boxes in the block diagram or flowchart, can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions. It can be understood by those skilled in the art that the features recorded in the various embodiments of the present invention can be combined and / or combined in various ways, even if such a combination or combination is not explicitly recorded in the present invention. In particular, without departing from the spirit and teachings of the present invention, the features recorded in the various embodiments of the present invention can be combined and / or combined in various ways. All such combinations and / or combinations fall within the scope of the present invention.
[0115] The embodiments of the present invention are described above. However, these embodiments are only for the purpose of illustration, and are not intended to limit the scope of the present invention. Although each embodiment is described above, it does not mean that the measures in each embodiment cannot be used in combination advantageously. Without departing from the scope of the present invention, those skilled in the art may make various substitutions and modifications, which should all fall within the scope of the present invention.
Claims
1. A remote sensing image clustering method, characterized in that: include: Acquire at least two remote sensing images of heterogeneous targets to be processed; Inputting the at least two heterogeneous target remote sensing images into a remote sensing image clustering model to obtain a first clustering result, wherein the first clustering result represents the similarity of pixel features in the same target remote sensing image and the similarity of pixel features between different target remote sensing images; Based on the first clustering result, clustering pixel features in the at least two target remote sensing images to obtain a second clustering result; The training method of the remote sensing image clustering model comprises: obtaining a plurality of heterogeneous sample remote sensing images; performing initial clustering on the pixel features in each of the heterogeneous sample remote sensing images respectively, and obtaining at least one positive sample pair and at least one negative sample pair, wherein the positive sample pair represents that two pixel features in the same sample remote sensing image belong to the same category, and the negative sample pair represents that two pixel features in the same sample remote sensing image belong to different categories; constructing a loss function according to the at least one positive sample pair and the at least one negative sample pair; performing unsupervised training on the remote sensing image clustering model to be trained using the loss function, and obtaining the remote sensing image clustering model; The method of respectively performing initial clustering on the pixel features in each of the heterogeneous sample remote sensing images to obtain at least one positive sample pair and at least one negative sample pair includes: constructing a graph model for each of the sample remote sensing images, and extracting node features in the graph model, wherein the pixels in the sample remote sensing image represent the node features; performing initial clustering on the node features of each of the sample remote sensing images by a preset clustering algorithm to obtain an initial clustering result, wherein the initial clustering result represents the similarity between two node features; and dividing at least one positive sample pair and at least one negative sample pair of each of the sample remote sensing images according to the initial clustering result, wherein the positive sample pair represents that the similarity between the two node features is higher than a first threshold, and the negative sample pair represents that the similarity between the two node features is lower than the first threshold.
2. The method according to claim 1, characterized in that in, The step of constructing a loss function according to the at least one positive sample pair and the at least one negative sample pair comprises: According to at least one positive sample pair and at least one negative sample pair of each of the sample remote sensing images, respectively construct a first contrast loss function corresponding to each of the sample remote sensing images; According to at least one positive sample pair and at least one negative sample pair of different sample remote sensing images, a second contrast loss function corresponding to the two sample remote sensing images is constructed.
3. The method according to claim 2, characterized in that in, The expression of the first contrast loss function is as follows: in, represents the first contrast loss function corresponding to the Mth sample remote sensing image, Represents the node features of the positive sample pair With node features The similarity between Represents the node features of negative sample pairs With node features The similarity between them is, N represents the sum of the number of positive sample pairs and negative sample pairs in the Mth sample remote sensing image.
4. The method according to claim 2, characterized in that: in, The expression of the second contrast loss function is as follows: in, represents the second contrast loss function between the mth sample remote sensing image and the nth sample remote sensing image, and m and n are not equal, 1≤m, n≤M, Represents the node features of the positive sample pair With node features The similarity between Represents the node features of negative sample pairs With node features The similarity between them is as follows: N represents the sum of the number of positive sample pairs and negative sample pairs between the mth sample remote sensing image and the nth sample remote sensing image.
5. The method according to claim 2, characterized in that: in, The positive samples of the different sample remote sensing images represent the node features at the same position in the two sample remote sensing images, and the negative samples of the different sample remote sensing images represent the node features at different positions in the two sample remote sensing images.
6. A remote sensing image clustering device, characterized in that: include: An acquisition module, used for acquiring at least two heterogeneous target remote sensing images to be processed; A first clustering module, used for inputting the at least two heterogeneous target remote sensing images into a remote sensing image clustering model to obtain a first clustering result, wherein the first clustering result represents the similarity of pixel features in the same target remote sensing image and the similarity of pixel features between different target remote sensing images; as well as A second clustering module, configured to cluster pixel features in the at least two heterogeneous target remote sensing images based on the first clustering result to obtain a second clustering result; The training method of the remote sensing image clustering model comprises: obtaining a plurality of heterogeneous sample remote sensing images; performing initial clustering on the pixel features in each of the heterogeneous sample remote sensing images respectively, and obtaining at least one positive sample pair and at least one negative sample pair, wherein the positive sample pair represents that two pixel features in the same sample remote sensing image belong to the same category, and the negative sample pair represents that two pixel features in the same sample remote sensing image belong to different categories; constructing a loss function according to the at least one positive sample pair and the at least one negative sample pair; performing unsupervised training on the remote sensing image clustering model to be trained using the loss function, and obtaining the remote sensing image clustering model; The method of respectively performing initial clustering on the pixel features in each of the heterogeneous sample remote sensing images to obtain at least one positive sample pair and at least one negative sample pair includes: constructing a graph model for each of the sample remote sensing images, and extracting node features in the graph model, wherein the pixels in the sample remote sensing image represent the node features; performing initial clustering on the node features of each of the sample remote sensing images by a preset clustering algorithm to obtain an initial clustering result, wherein the initial clustering result represents the similarity between two node features; and dividing at least one positive sample pair and at least one negative sample pair of each of the sample remote sensing images according to the initial clustering result, wherein the positive sample pair represents that the similarity between the two node features is higher than a first threshold, and the negative sample pair represents that the similarity between the two node features is lower than the first threshold.
7. An electronic device, characterized in that: include: one or more processors; a memory for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that: Executable instructions are stored thereon, and when the instructions are executed by a processor, the processor implements the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Satellite remote sensing image target association method and device based on deep metric learning
CN111401307A
Remote sensing image recognition method, device and equipment and computer readable storage medium
CN114581761A
