Image clustering method and device based on granulocyte multi-k-means and electronic equipment

By using a multi-kernel k-means clustering method based on granular spheres and optimizing the kernel matrix through local alignment, the inefficiency problem in existing technologies is solved, and efficient and accurate clustering of large-scale image datasets is achieved.

CN119625360BActive Publication Date: 2025-11-04CHONGQING UNIV OF POSTS & TELECOMM
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411676357.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-22
Publication Date
2025-11-04
Estimated Expiration
2044-11-22

AI Technical Summary

Technical Problem

Existing multi-kernel k-means clustering methods are inefficient on large-scale image datasets, and improper parameter settings may affect clustering performance. It is impossible to find suitable parameters through optimization, resulting in poor clustering results.

Method used

A multi-kernel k-means clustering method based on spheres is adopted. By dividing the image data into spheres, an image sphere kernel matrix is ​​constructed, and the kernel matrix is ​​optimized by local alignment, avoiding neighbor parameter settings and improving clustering efficiency and accuracy.

Benefits of technology

It significantly improves the efficiency of kernel matrix construction, reduces time complexity, is suitable for clustering large-scale image datasets, avoids incorrect clustering label assignment caused by overfitting, and improves the accuracy and efficiency of image clustering.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119625360B_ABST
    Figure CN119625360B_ABST
Patent Text Reader

Abstract

The present application relates to the field of image clustering analysis, in particular to an image clustering method and device based on granular ball multi-kernel k-means and electronic equipment; the method comprises: obtaining a discrete data point set of a plurality of images to be clustered; performing granular ball division on image data to obtain a granular ball set; calculating image granular ball centers, image granular ball distance matrices, and average distances between image granular balls; and calculating an image granular ball kernel matrix; constructing a granular ball-based multi-kernel k-means clustering objective function according to the image granular ball kernel matrix and a preset clustering division matrix; calculating a target clustering division matrix corresponding to the minimum value of the objective function; discretizing the target clustering division matrix according to the multi-kernel k-means algorithm to obtain a clustering result of the image granular balls; and assigning the clustering result of the image granular balls to all discrete data points contained therein to obtain a clustering result of the image data. The present application improves the efficiency and accuracy of image clustering.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of image clustering analysis, in particular to an image clustering method and device based on granular ball multi-kernel k-means and electronic equipment. BACKGROUND

[0002] Image data is growing explosively in various fields of real life, and analyzing and processing these images helps users to understand reality more deeply and optimize the decision-making process. Image clustering technology, as a key part of image processing, has been widely studied in the field of machine learning in recent years, providing strong support for subsequent image segmentation, image recognition, and image retrieval tasks. Traditional clustering methods such as k-means clustering, DBSCAN clustering, and hierarchical clustering are commonly used methods in image clustering. However, due to the complexity of image data, such as image data being often high-dimensional, its features may come from multiple different aspects (brightness, color, orientation, etc.), and being non-linearly separable in the original dimension. This makes it difficult for traditional clustering methods to cope with.

[0003] Multi-kernel k-means clustering, as an extension of k-means clustering method in multi-kernel clustering method, maps data to high-dimensional space by defining multiple kernel matrices, making data that is originally non-linearly separable in low-dimensional space become separable in high-dimensional space, and alleviating the defect that k-means cannot handle complex, non-linearly separable data. At the same time, multiple kernel functions enable the algorithm to more comprehensively capture information in various aspects of the image, achieving more accurate clustering results.

[0004] The recent multi-kernel k-means clustering method SimpleMKKM, in order to avoid the objective function falling into a local optimal solution, first introduced the kernel alignment criterion in supervised learning into unsupervised learning tasks, proposed a new multi-kernel k-means objective function, i.e. minimizing the kernel coefficient and maximizing the clustering partition matrix. And rewrites the objective function, converts the tricky minimization-maximization problem into a minimization problem, and uses a simplified gradient descent algorithm to solve the objective function value. This method has achieved good clustering performance, but the recent LocalizedSimpleMKKM considers that SimpleMKKM forces all sample pairs to align with the ideal similarity matrix in the kernel alignment process, which may lead to incorrect assignment of clustering labels, thereby affecting clustering performance. Therefore, LocalizedSimpleMKKM proposes a local simple multi-kernel k-means clustering method, which sets a neighborhood parameter τ to make the sample only need to align the similarity of τ*n samples adjacent to it on the ideal similarity matrix, where n is the total number of samples. This considers the local structure of the sample and improves the clustering performance.

[0005] Although the LocalizedSimpleMKKM has the above advantages, the method needs to set the neighborhood parameter τ to obtain the neighbor information of each image sample. In actual scenarios, image data is complex, and improper parameter setting can affect the performance of image clustering methods. Moreover, since clustering is unsupervised learning, we cannot estimate the clustering effect of a certain parameter, so we cannot find the appropriate parameter by optimization in practical applications. Therefore, it is a great challenge to set specific parameters for each data set. In addition, we also observe that the existing multi-kernel k-means clustering method is based on a single sample to construct a kernel matrix, i.e. the size of the constructed kernel matrix is n*n. This fine-grained construction makes the whole algorithm inefficient and cannot be applied to large-scale image data sets. SUMMARY

[0006] The purpose of the present application is to solve or alleviate the problems of the prior art, and to provide an image clustering method, device and electronic equipment based on particle ball multi-kernel k-means.

[0007] In order to achieve the above purpose, an image clustering method based on particle ball multi-kernel k-means is proposed, which comprises the following steps:

[0008] Obtain image data; the image data is a set of discrete data points of a plurality of images to be clustered;

[0009] Divide the image data into particle balls to obtain a set of image particle balls;

[0010] According to the image particle ball set, the image particle ball center, the image particle ball distance matrix and the average distance between the image particle balls are calculated;

[0011] According to the image particle ball center, the image particle ball distance matrix, the average distance between the image particle balls and the preset kernel function, the image particle ball kernel matrix is calculated;

[0012] According to the image particle ball kernel matrix and the preset clustering division matrix, a particle ball based multi-kernel k-means clustering objective function is constructed; the objective function is used to indicate the image particle ball kernel matrix alignment difference of the kernel coefficient and the image particle ball kernel matrix alignment difference of the clustering division matrix;

[0013] According to the particle ball based multi-kernel k-means clustering objective function, the target clustering division matrix corresponding to the minimum value of the objective function is calculated;

[0014] Discretize the target clustering division matrix according to the multi-kernel k-means algorithm to obtain the clustering result of the image particle ball;

[0015] Assign the clustering result of the image particle ball to all discrete data points contained in it to obtain the clustering result of the image data.

[0016] In a second aspect, the present application provides an image clustering device based on particle ball multi-kernel k-means, comprising:

[0017] An acquisition module is configured to acquire image data, wherein the image data is a set of discrete data points of a plurality of images to be clustered;

[0018] A division module is configured to divide the image data into particle balls to obtain a set of image particle balls;

[0019] A calculation module is configured to calculate image particle ball centers, an image particle ball distance matrix and an average distance between image particle balls according to the set of image particle balls, and calculate an image particle ball kernel matrix according to the image particle ball centers, the image particle ball distance matrix, the average distance between image particle balls and a preset kernel function;

[0020] A construction module is configured to construct a particle ball-based multi-kernel k-means clustering objective function according to the image particle ball kernel matrix and a preset clustering division matrix, wherein the objective function is used to indicate a difference in alignment of the image particle ball kernel matrix of the kernel coefficient and a difference in alignment of the image particle ball kernel matrix of the clustering division matrix;

[0021] A determination module is configured to calculate a target clustering division matrix corresponding to a minimum value of the particle ball-based multi-kernel k-means clustering objective function;

[0022] A clustering module is configured to discretize the target clustering division matrix according to a multi-kernel k-means algorithm to obtain a clustering result of the image particle balls, and assign the clustering result of the image particle balls to all discrete data points contained therein to obtain a clustering result of the image data.

[0023] In a third aspect, the present application provides an electronic device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the method according to the first aspect of the present application when executing the computer program.

[0024] The present application has the following advantages:

[0025] Compared with the prior art, the present application proposes a new kernel matrix construction method, which uses image granules to perform coarse-grained mapping representation on original image data. Since the number of image granules is much smaller than the amount of original image data, the present application significantly improves the efficiency of constructing the kernel matrix, reduces the time complexity of the present application relative to the prior art, and is suitable for clustering of large-scale image data sets of multi-kernel k-means. In the construction of the image granule kernel matrix, the present application utilizes the local density of the image granule, and gives greater similarity to the image granules with closer distance, so that the kernel matrix more accurately represents the structure of the cluster, and improves the accuracy of image clustering. In solving the objective function, the present application performs similarity alignment based on the coarse-grained granule kernel matrix. Compared with the similarity alignment performed on the kernel matrix constructed on the original image data, this is a local alignment method, which can avoid the allocation of incorrect clustering labels due to overfitting. Moreover, this local alignment method does not need to set a neighbor parameter, and is a self-adaptive local alignment method, which can significantly improve the efficiency of image clustering. BRIEF DESCRIPTION OF DRAWINGS

[0026] Figure 1 A flowchart of the image clustering method based on the granule multi-kernel k-means of the embodiment of the present application;

[0027] Figure 2 A flowchart of the image granule division of the embodiment of the present application;

[0028] Figure 3 A structure diagram of the image granule division of the embodiment of the present application;

[0029] Figure 4 A flowchart of the calculation of the target clustering division matrix of the embodiment of the present application;

[0030] Figure 5 A structure diagram of the image clustering device based on the granule multi-kernel k-means of the embodiment of the present application. DETAILED DESCRIPTION

[0031] The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, but not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor shall fall within the scope of the present application.

[0032] The embodiments of the present application are only used to illustrate the present application but not to limit the present application. Various replacements and modifications can be made according to the ordinary technical knowledge and common practices without departing from the technical idea of the present application, and all the replacements and modifications shall be included in the scope of the present application.

[0033] In the description of the present application, "processor" can include hardware, software or a combination of both. The processor can be a central processor, microprocessor, image processor, digital signal processor or any other suitable processor. The processor has data and / or signal processing functions. The processor can be implemented in software, hardware or a combination of both. The non-transitory computer readable storage medium includes any suitable medium that can store program code, such as a magnetic disk, a hard disk, an optical disk, a flash memory, a read-only memory, a random access memory, etc. The term "A and / or B" means all possible combinations of A and B, such as only A, only B or both A and B.

[0034] In order to solve the problem of low efficiency of traditional MKKM, the present application combines the granule structure and proposes a new coarse-grained kernel matrix construction method, which greatly reduces the size of the kernel matrix and improves the efficiency of the existing MKKM algorithm in constructing the kernel matrix. On the other hand, in order to solve the problem of overfitting of image clustering algorithm caused by global alignment kernel matrix, the present application uses local alignment method and uses image granule instead of surrounding image data samples to participate in the kernel matrix alignment process, and considers the local density of image granule in the kernel matrix construction process, so that the constructed kernel matrix can more accurately represent the structure of the cluster, and can fully mine the features of image data, which is beneficial to improve the efficiency and accuracy of image clustering.

[0035] Figure 1 The flowchart of the image clustering method based on granule multi-kernel k-means of the embodiment of the present application is shown in FIG. 1. Figure 1 As shown in FIG. 1, the method comprises:

[0036] 101, obtaining image data; the image data is a set of discrete data points of a plurality of images to be clustered;

[0037] In some embodiments, the image to be clustered refers to an image that needs to be clustered, such as a face image. The image to be clustered can be acquired by an image acquisition device, such as a camera, etc. It can also be acquired by receiving an image sent by an image acquisition device or other terminal device, etc. The present exemplary embodiment can digitize the image to be clustered based on each image to be clustered by sampling and gray level quantization, and convert the image to be clustered into a set of discrete data D: x1, x2,..., xN by using RGB representation, etc. n i ​D is a d-dimensional vector, representing a d-dimensional data of an image to be clustered; these manners can map the image to be clustered into a feature space, and represent the corresponding image to be clustered in the form of a feature vector. For example, a plurality of face images are acquired, and for each face image, a face feature is extracted therefrom by using the above digitalization manner, and the face feature is converted into a matrix or a feature vector, and is mapped into a feature space, and each feature vector in the feature space represents a face image.

[0038] 102. Dividing the image data into granules to obtain a granule set;

[0039] In the embodiment of the present application, as shown in Figure 2 The step 102 can specifically include:

[0040] 201. Initializing the image data as an image granule, and adding the image granule into a granule set;

[0041] 202. Traversing the granule set, for each image granule, selecting two deterministic centers therefrom, and using a clustering algorithm to divide the image granule into two image sub-granules;

[0042] 203. If the granule quality of the divided image sub-granule is higher than that of the image granule before division, adding the divided image sub-granule into the granule set, and removing the image granule before division from the granule set;

[0043] 204. Repeating the above steps until the number of image granules in the granule set no longer changes, and finally obtaining the granule set.

[0044] The embodiment initializes the image data D as an image granule, and adds the image granule into a granule set; by traversing the granule set, the current image granule is attempted to be divided into two image sub-granules, if the quality of the two granules obtained by division is better than that of the current granule, the two granules are added into the granule set, and the current granule is removed from the set; the above steps are repeated until the number of granules in the set no longer changes, that is, the granule splitting reaches a convergence condition, and finally the granule set GBs={GB1, GB2,..., GB m} is obtained, where m represents the number of image granules.

[0045] The granule quality measures the compactness of the data points in the granule relative to the center of the granule, the more compact the data points in the granule are, the higher the quality of the granule is; on the contrary, the more sparse the data points in the granule are, the lower the quality of the granule is.

[0046] In the embodiment of the present application, the granule quality can be measured by the following formula:

[0047]

[0048] Where DM represents the granule mass, the smaller the DM, the higher the mass; c represents the center of the granule; k represents the number of samples within the granule; and x1, x2, ..., x k This represents the sample within the subsphere. The formula for calculating the weighted quality (DM) value of an image subsphere is: Where k1 and k2 represent the number of samples in the image subsphere, respectively, and DM1 and DM2 represent the DM values ​​of the two image subspheres, respectively.

[0049] For example, in Figure 3 The image shows the process of granulosphere splitting. Initially, as shown... Figure 3 As shown in (a), all image data is mapped to an image grain space, ensuring that all image data resides within the image grain; during splitting, Figure 3 In image (b), the DM value of the granules is 0.532, and the resulting fragments are obtained from the splitting process. Figure 3 (c) After the two image subspheres, the weighted DM value of the image subsphere is 0.486. Clearly, the quality of the split image subsphere is better than that of the parent image sphere. Therefore... Figure 3 The image spheres in (b) need to be split into Figure 3 After the two child balls in (c) have split, Figure 3 (d) represents the final image particles obtained.

[0050] 103. Based on the image particle set, calculate the image particle center, the image particle distance matrix, and the average distance between image particles;

[0051] In this embodiment of the invention, for each image grain sphere in the image grain sphere set, it is assumed that it contains k data points x1, x2, ..., x k The center c of the image spheres is determined by the mean of these k data points; based on the calculated image sphere centers, the sphere distance matrix S is calculated, where S is an m*m matrix, m represents the number of spheres, and S... ij Represents GB i Compared with GB j The distance between them. S ij The calculation formula is: ||c i -c j ||,c i ,,c j Representing image particles GB i With image sphere GB j Based on the calculated particle matrix S at the center, the average distance d between all particles is calculated. avg The formula for calculating the average distance is as follows:

[0052]

[0053] 104. calculating the image granule kernel matrix according to the image granule center, the image granule distance matrix, the average distance between image granules and the preset kernel function;

[0054] In the embodiment of the present application, if the distance between the first image granule and the second image granule in the image granule distance matrix is greater than the average distance between image granules, the value of the image granule kernel matrix is the preset kernel function distance between the first image granule center and the second image granule center; if the distance between the first image granule and the second image granule in the image granule distance matrix is less than or equal to the average distance between image granules, the value of the image granule kernel matrix is the preset kernel function distance between the first image granule center and the discrete data points of the second image granule; the discrete data points of the second image granule are the discrete data points in the second image granule and closest to the first image granule center.

[0055] In the embodiment of the present application, the kernel function κ is selected, and the granule kernel matrix corresponding to κ is constructed according to the following formula:

[0056]

[0057] wherein:

[0058]

[0059] κ(GB j ,GB i )=κ(GB i ,GB j ),1≤i≤j≤m

[0060] wherein, KGB represents the granule kernel matrix, κ(GB i ,GB j ) represents the granule kernel matrix of the image granule GB i and the image granule GB j , κ(GB j ,GB i ) represents the granule kernel matrix of the image granule GB i and the image granule GB j , both of which are reversible, when S ij ≥d avg , then the kernel function κ(c i ,c j ) is selected, when S ij <d avg , then the kernel function κ(c i ,x jThe local density is used, which gives greater similarity to the image granule balls with closer distance, makes the kernel matrix more accurately represent the cluster structure, and improves the accuracy of image clustering.

[0061] The above steps are repeated to finally construct a set of granule ball kernel matrices KGB p , (p = 1, 2,..., v), v represents the number of selected kernel functions.

[0062] It should be noted that the embodiment of the present application uses image granule balls to perform coarse-grained mapping representation on original image data. Since the number of image granule balls is far less than the amount of original image data, the present application significantly improves the efficiency of constructing a kernel matrix, which also makes the present application reduce the time complexity and be suitable for clustering of large-scale image data sets by multi-kernel k-means.

[0063] 105. Construct a multi-kernel k-means clustering objective function based on granule balls according to the image granule ball kernel matrix and the preset clustering division matrix; the objective function is used to indicate the image granule ball kernel matrix alignment difference of the kernel coefficient and the image granule ball kernel matrix alignment difference of the clustering division matrix;

[0064] In the embodiment of the present application, the objective function minimizes the granule ball kernel matrix alignment with respect to the kernel coefficient, so that the method can find a set of more optimal kernel coefficients, reduce the redundancy between kernels, and make the combined granule ball kernel matrix better capture the internal structure of the image data. In addition, the objective function maximizes the granule ball kernel matrix alignment with respect to the clustering division matrix, so that the method learns a clustering division matrix that is more matched with the feature space corresponding to the combined granule ball kernel matrix in the feature space represented by the combined granule ball kernel matrix, thereby obtaining a more accurate image clustering result. Specifically, the multi-kernel k-means clustering objective function based on granule balls can be represented as:

[0065]

[0066] Wherein, w is the weight vector of each image granule ball kernel matrix, Δ is the value range of the weight of the image granule ball kernel matrix, F is the clustering division matrix, F T is the transpose matrix of F; KGB w is the weighted kernel matrix of the v image granule ball kernel matrices, and Γ is the clustering division matrix set. KGB p represents the pth granule ball kernel matrix, F is the clustering division matrix, F T is the transpose matrix of F.

[0067] In the range Δ, the sum of each component in the w vector is 1, and each component is greater than or equal to 0. In the range Γ, Γ limits F must be an m-row y-column matrix, and each element in the matrix is a real number, m represents the number of particles, and y represents the number of clustering clusters.

[0068] 106. According to the particle-based multi-kernel k-means clustering objective function, the target clustering partition matrix corresponding to the minimum objective function value is calculated.

[0069] In the embodiment of the present application, as shown in Figure 4 The calculation method of the target clustering partition matrix comprises:

[0070] 601. The particle-based multi-kernel k-means clustering objective function is minimized using a simplified gradient descent algorithm to obtain the descending gradient of each element; the element is used to indicate the component corresponding to the vector in the objective function;

[0071] The particle-based multi-kernel k-means clustering objective function is represented as:

[0072]

[0073] JGB(w)=max F∈Γ Tr(KGB w FF T ).

[0074] The formula objective function is minimized using a simplified gradient descent algorithm, The descending gradient of the pth element is represented as The calculation method is as follows:

[0075]

[0076] Wherein, u is the index of the maximum component in the vector w.

[0077] 602. If the weight of the pth element is 0 and the descending gradient of the pth element is greater than 0, the descending direction of the pth element is 0;

[0078] 603. If the weight of the pth element is greater than 0 and the pth element is not the element corresponding to the maximum component, the descending direction of the pth element is the opposite number of the descending gradient of the pth element;

[0079] 604. If the pth element is the element corresponding to the maximum component, the descending direction of the pth element is the opposite number of the descending gradient of the element corresponding to the maximum component;

[0080] The calculation formula corresponding to steps 602-604 can be represented as:

[0081]

[0082] Where, d p This indicates the final direction of descent.

[0083] 605. Update the weight of the p-th element based on its weight and the direction of descent.

[0084] In this embodiment of the invention, the formula for updating the weight of the p-th element is expressed as:

[0085] w p '=w p +α*d p

[0086] Among them, w p ' represents the weight of the p-th element after the update, w p Let d represent the weight of the p-th element before the update, α represent the control parameter, and d represent the weight of the p-th element before the update. p This indicates the direction of descent for the p-th element.

[0087] 606. When the objective function of the multi-kernel k-means clustering based on granules converges, the objective clustering partition matrix is ​​obtained.

[0088] Through the above steps, when the multi-kernel k-means clustering objective function based on spheres converges, the final target clustering partitioning clustering matrix F is obtained.

[0089] It is understandable that this invention performs similarity alignment based on a coarse-grained sphere kernel matrix when solving the objective function. Compared to similarity alignment using a kernel matrix constructed on the original image data, this is a local alignment method that avoids incorrect clustering label assignment due to overfitting. Furthermore, this local alignment method does not require setting neighbor parameters, making it an adaptive local alignment method that can significantly improve the efficiency of image clustering.

[0090] 107. Discretize the target clustering partition matrix according to the multi-kernel k-means algorithm to obtain the clustering results of image particles;

[0091] In this embodiment of the invention, a multi-kernel k-means discretization matrix F is used to obtain the clustering results of image particles.

[0092] 108. Assign the clustering results of the image particles to all the discrete data points they contain to obtain the clustering results of the image data.

[0093] Figure 5 This is a structural diagram of an image clustering device based on multi-kernel k-means granulation according to an embodiment of the present invention, as shown below. Figure 5 As shown, the device includes:

[0094] an acquisition module configured to acquire image data, the image data being a set of discrete data points of a plurality of images to be clustered;

[0095] a division module configured to divide the image data into image granules to obtain a set of image granules;

[0096] a calculation module configured to calculate image granule centers, an image granule distance matrix and average distances between image granules according to the set of image granules, and calculate an image granule kernel matrix according to the image granule centers, the image granule distance matrix, the average distances between image granules and a preset kernel function;

[0097] a construction module configured to construct a multi-kernel k-means clustering objective function based on granules according to the image granule kernel matrix and a preset clustering division matrix, the objective function being used to indicate a difference in alignment of the image granule kernel matrix of kernel coefficients and a difference in alignment of the image granule kernel matrix of the clustering division matrix;

[0098] a determination module configured to calculate a target clustering division matrix corresponding to a minimum value of the objective function according to the multi-kernel k-means clustering objective function based on granules;

[0099] a clustering module configured to discretize the target clustering division matrix according to a multi-kernel k-means algorithm to obtain a clustering result of the image granules, and assign the clustering result of the image granules to all discrete data points contained in the image granules to obtain a clustering result of the image data.

[0100] The embodiments of the present application also provide an electronic device capable of implementing the above method. Those skilled in the art can understand that each aspect of the present application can be implemented as a system, a method or a program product. Therefore, each aspect of the present application can be specifically implemented as a complete hardware embodiment, a complete software embodiment (including firmware, microcode, etc.), or an embodiment combining hardware and software, which can be collectively referred to as "circuitry", "module" or "system".

[0101] The embodiments of the present application also provide an electronic device in the form of a general computing device. The components of the electronic device can include but are not limited to the above-mentioned at least one processing unit, the above-mentioned at least one storage unit, a bus connecting different system components (including storage units and processing units), a display unit.

[0102] The storage unit stores program codes, which can be executed by the processing unit, so that the processing unit executes the steps described in the above "Exemplary Method" section according to various exemplary embodiments of the present application. For example, the processing unit can execute the program codes to Figure 1The steps S101-S108 and the like are shown.

[0103] The storage unit can include a readable medium in the form of a volatile storage unit, such as a random access memory (RAM) and / or a cache memory unit, and can further include a read-only memory (ROM).

[0104] The storage unit can also include a program / utility having a set (at least one) of program modules that include, but are not limited to, an operating system, one or more application programs, other program modules, and program data, as each of these examples, or some combination thereof, can include implementation of a network environment.

[0105] The bus can be representative of one or more of several types of bus structures, including a storage unit bus or bus controller, a peripheral bus, a graphics acceleration port, a processing unit bus, or a local bus using any of a variety of bus architectures.

[0106] The electronic device can also communicate with one or more external devices such as a keyboard or a pointing device, through an I / O interface. Furthermore, the electronic device can communicate with one or more devices that enable a user to interact with the electronic device, and / or one or more devices (e.g., a router, a modem, etc.) that enable the electronic device to communicate with one or more other computing devices. Such communication can occur via an I / O interface. Also, the electronic device can communicate with one or more networks (such as a local area network (LAN), a wide area network (WAN), and / or the Internet) through a network adapter. The network adapter communicates with the other components of the electronic device via the bus.

[0107] Those skilled in the art will readily understand that the example embodiments described herein can be implemented by software and / or by software in combination with the necessary hardware. Thus, the technical solutions according to the embodiments of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash disk, a mobile hard disk, or the like) or a network, and includes a number of instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to perform the methods according to the example embodiments of the present disclosure.

[0108] The program product may employ any combination of one or more readable media. A readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples (a non-exhaustive list) of readable storage media include: electrical connections having one or more wires, portable disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.

[0109] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, carrying readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A readable signal medium may also be any readable medium other than a readable storage medium, capable of sending, propagating, or transmitting programs for use by or in conjunction with an instruction execution system, apparatus, or device.

[0110] Program code for performing the operations of this disclosure can be written in any combination of one or more programming languages, including object-oriented programming languages ​​such as Java and C++, and conventional procedural programming languages ​​such as C or similar languages. The program code can execute entirely on the user's computing device, partially on the user's computing device, as a standalone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server. In cases involving remote computing devices, the remote computing devices can be connected to the user's computing device via 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., via the Internet using an Internet service provider).

[0111] Furthermore, the above figures are merely illustrative of the processes included in the method according to exemplary embodiments of this disclosure and are not intended to be limiting. It is readily understood that the processes shown in the above figures do not indicate or limit the temporal order of these processes. Additionally, it is readily understood that these processes may be executed synchronously or asynchronously, for example, in multiple modules.

[0112] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be implemented by a program instructing related hardware. The program can be stored in a computer-readable storage medium, which may include ROM, RAM, disk, or optical disk, etc.

[0113] While embodiments of the application have been shown and described, it is to be understood that the application is not limited to the details of the embodiments described, since numerous changes, modifications, substitutions and variations can be made thereto without departing from the spirit and scope of the application as defined by the appended claims and their equivalents.

Claims

1. An image clustering method based on multi-kernel k-means granular clustering, characterized in that, The method includes: Acquire image data; the image data is a set of discrete data points of multiple images to be clustered; The image data is divided into spheres to obtain an image sphere set; Based on the image particle set, the image particle center, the image particle distance matrix, and the average distance between image particles are calculated; The image particle kernel matrix is ​​calculated based on the image particle center, the image particle distance matrix, the average distance between image particles, and a preset kernel function; the calculation method of the image particle kernel matrix includes: If the distance between the first image particle and the second image particle in the image particle distance matrix is ​​greater than the average distance between image particles, the value of the image particle kernel matrix is ​​the preset kernel function distance between the center of the first image particle and the center of the second image particle; If the distance between the first image particle and the second image particle in the image particle distance matrix is ​​less than or equal to the average distance between image particles, the value of the image particle kernel matrix is ​​the preset kernel function distance between the center of the first image particle and the discrete data points of the second image particle; the discrete data points of the second image particle are the discrete data points in the second image particle that are closest to the center of the first image particle. Based on the image particle kernel matrix and a preset clustering partition matrix, a multi-kernel k-means clustering objective function based on particles is constructed; the objective function is used to indicate the alignment difference of the image particle kernel matrix of the kernel coefficients and the alignment difference of the image particle kernel matrix of the clustering partition matrix. Based on the multi-kernel k-means clustering objective function based on granules, the target clustering partition matrix corresponding to the minimum objective function value is calculated; The target clustering matrix is ​​discretized using the multi-kernel k-means algorithm to obtain the clustering results of image particles; The clustering results of the image particles are assigned to all the discrete data points they contain, thus obtaining the clustering results of the image data.

2. The image clustering method based on multi-kernel k-means granular clustering according to claim 1, characterized in that, The step of dividing the image data into spheres to obtain an image sphere set includes: The image data is initialized as an image sphere, and the image sphere is added to the image sphere set; The image particle set is traversed. For each image particle, two deterministic centers are selected and a clustering algorithm is used to divide the image particle into two image subspheres. If the mass of the image sub-sphere after division is higher than the mass of the image sub-sphere before division, then the image sub-sphere after division is added to the image sub-sphere set, and the image sub-sphere before division is removed from the image sub-sphere set. Repeat the above steps until the number of image particles in the image particle set no longer changes, and finally obtain the image particle set.

3. The image clustering method based on multi-kernel k-means granular clustering according to claim 1, characterized in that, The objective function for the granular multi-kernel k-means clustering based on granules is expressed as follows: Where w is the weight vector of each image particle kernel matrix, Δ is the range of values ​​for the weights of the image particle kernel matrix, and F is the clustering matrix. T It is the transpose of F; KGB w It is the weighted kernel matrix of v image particle kernel matrices, and Γ is the constraint range of the clustering partitioning matrix.

4. The image clustering method based on multi-kernel k-means granular clustering according to claim 1, characterized in that, The calculation method for the target clustering partition matrix includes: The simplified gradient descent algorithm is used to minimize the particle-sphere-based multi-kernel k-means clustering objective function to obtain the descent gradient of each element; the element is used to indicate the component corresponding to the vector in the objective function; If the weight of the p-th element is 0 and the descent gradient of the p-th element is greater than 0, then the descent direction of the p-th element is 0. If the weight of the p-th element is greater than 0 and the p-th element is not the element corresponding to the maximum component, then the descent direction of the p-th element is the negative of the descent gradient of the p-th element. If the p-th element is the element corresponding to the maximum component, then the descent direction of the p-th element is the negative of the descent gradient of the element corresponding to the maximum component. Update the weight of the p-th element based on its weight and the direction of descent. When the objective function of the multi-kernel k-means clustering based on spheres converges, the target clustering partition matrix is ​​obtained.

5. The image clustering method based on multi-kernel k-means granular clustering according to claim 4, characterized in that, The formula for updating the weight of the p-th element is expressed as: w p ′=w p +α*d p Among them, w p ' represents the weight of the p-th element after the update, w p Let d represent the weight of the p-th element before the update, α represent the control parameter, and d represent the weight of the p-th element before the update. p This indicates the direction of descent for the p-th element.

6. An image clustering device based on granular multi-kernel k-means, the device being used to perform the method according to any one of claims 1 to 5, characterized in that, include: The acquisition module is used to acquire image data; The image data is a set of discrete data points of multiple images to be clustered; The partitioning module is used to divide the image data into particle spheres to obtain an image particle sphere set; The calculation module is used to calculate the image particle center, the image particle distance matrix, and the average distance between image particles based on the image particle set; and to calculate the image particle kernel matrix based on the image particle center, the image particle distance matrix, the average distance between image particles, and a preset kernel function. The construction module is used to construct a multi-kernel k-means clustering objective function based on the image particle kernel matrix and a preset clustering partitioning matrix; the objective function is used to indicate the alignment difference of the image particle kernel matrix of the kernel coefficients and the alignment difference of the image particle kernel matrix of the clustering partitioning matrix. The determination module is used to calculate the target clustering partition matrix corresponding to the minimum value of the objective function based on the multi-kernel k-means clustering objective function of the particle-sphere-based clustering. The clustering module is used to discretize the target clustering partition matrix according to the multi-kernel k-means algorithm to obtain the clustering result of the image particles; and to assign the clustering result of the image particles to all the discrete data points contained therein to obtain the clustering result of the image data.

7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Face image clustering method and system based on localized simple multi-kernel k-mean value

    CN113762354A

  • Image content noise processing method based on granular ball calculation

    CN116071253A