Overlapping community detection method, device, electronic device and storage medium

The PageRank-based method for overlapping community detection stabilizes and enhances the accuracy of community identification by determining label update order and incorporating similarity measures, addressing the instability of existing SLPA-based approaches.

CN115484198BActive Publication Date: 2024-12-13CHINA MOBILE QUANTONG SYST INTEGRATION CO LTD +3
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110660201.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-06-15
Publication Date
2024-12-13
Estimated Expiration
2041-06-15

AI Technical Summary

Technical Problem

Existing overlapping community detection methods, such as those based on the SLPA algorithm, produce unstable detection results due to random determination of label update order, leading to inconsistent outcomes.

Method used

An overlapping community detection method utilizing the PageRank algorithm to determine the update order of node labels, followed by iterative label propagation and post-processing to stabilize the detection results, incorporating similarity measures when multiple labels have the highest frequency.

Benefits of technology

The method reduces interference during label propagation, stabilizes community detection, and improves efficiency by ensuring accurate and consistent overlapping community identification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115484198B_ABST
    Figure CN115484198B_ABST
Patent Text Reader

Abstract

The present invention provides an overlapping community detection method, device, electronic device and storage medium. The overlapping community detection method includes: determining the update order of the labels of each node in the target network based on the PageRank algorithm; updating the labels of each node in the target network a target number of times based on the update order to obtain the label list of each node; and obtaining the overlapping community detection result of the target network based on the label list of each node. The overlapping community detection method, device, electronic device and storage medium provided by the present invention can reduce the interference force formed between nodes during the label propagation process by determining the update order of the labels of each node in the target network and performing label propagation based on the update order, eliminate the instability caused by the random determination of the update order of the conventional label propagation algorithm, and obtain a more stable and accurate overlapping community detection result.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to an overlapping community detection method, device, electronic device and storage medium. Background Art

[0002] Community identification of complex networks has become one of the hot issues in the field of big data research. It has important theoretical and behavioral significance for the topological structure analysis, functional analysis and behavior prediction of complex networks. A community is composed of a series of specific node organizations, which is academically called "communalization."

[0003] Communities within a network share key nodes. Communities with this feature are called overlapping communities, and these shared key nodes are called overlapping nodes. Existing overlapping community detection methods are usually implemented based on SLPA (Speaker-listener Label Propagation Algorithm), but the detection results of overlapping community detection based on SLPA are unstable, that is, the detection results obtained from multiple detections of the same network may differ greatly. Summary of the invention

[0004] The present invention provides an overlapping community detection method, device, electronic device and storage medium, which are used to solve the defect of unstable detection results in the prior art and achieve overlapping community detection results with better stability.

[0005] In a first aspect, the present invention provides an overlapping community detection method, comprising:

[0006] Based on the PageRank algorithm, determine the update order of the labels of each node in the target network;

[0007] Based on the update sequence, update the label of each node in the target network a target number of times to obtain a label list of each node;

[0008] Based on the label lists of the nodes, an overlapping community detection result of the target network is obtained.

[0009] In one embodiment, updating the label of the node specifically includes:

[0010] When there are at least two labels with the highest frequency among the labels propagated to the node in this update, respectively obtain the similarity between the node and each neighbor node corresponding to the label with the highest frequency;

[0011] Based on the similarity, a result of updating the label of the node is determined.

[0012] In one embodiment, determining the update order of the labels of each node in the target network based on the PageRank algorithm specifically includes:

[0013] The PageRank algorithm is based on the above method, and the PR value of each node is obtained through iteration.

[0014] The update order is determined based on the PR value of each of the nodes.

[0015] In one embodiment, the formula for obtaining the PR value of node i in each iteration is:

[0016]

[0017] Among them, PR(i) represents the PR value of node i; n represents the number of nodes in the target network; α is a preset constant, 0<α<1; M(i) represents the set of neighbor nodes of node i; node j is the neighbor node of node i; PR(j) represents the PR value of node j; d(j) represents the degree of node j.

[0018] In one embodiment, the formula for obtaining the similarity between the node and the neighboring node corresponding to the label with the highest frequency of occurrence is:

[0019]

[0020] Among them, node j is the neighbor node of node i; sim(i,j) represents the similarity between node i and node j; Γ(i) represents the set of neighbor nodes of node i; Γ(j) represents the set of neighbor nodes of node j.

[0021] In one embodiment, determining the result of updating the label of the node based on the similarity specifically includes:

[0022] When the occurrence frequency of the maximum value of the similarity is 1, the label corresponding to the maximum value is determined as the result of updating the label of the node this time.

[0023] In one embodiment, determining the result of updating the label of the node based on the similarity further includes:

[0024] When the occurrence frequency of the maximum value of the similarity is greater than 1, any label corresponding to the maximum value is determined as the result of updating the label of the node this time.

[0025] In a second aspect, the present invention provides an overlapping community detection device, comprising:

[0026] The order determination module is used to determine the update order of the labels of each node in the target network based on the PageRank algorithm;

[0027] A label propagation module, used to update the label of each node in the target network a target number of times based on the update sequence, and obtain a label list of each node;

[0028] The community detection module is used to obtain overlapping community detection results of the target network based on the label list of each node.

[0029] In a third aspect, the present invention provides an electronic device, comprising a processor and a memory storing a computer program, wherein the processor implements the steps of any one of the above-mentioned overlapping community detection methods when executing the computer program.

[0030] In a fourth aspect, the present invention provides a processor-readable storage medium, wherein the processor-readable storage medium stores a computer program, and the computer program is used to enable the processor to execute the steps of any one of the above-mentioned overlapping community detection methods.

[0031] The overlapping community detection method, device, electronic device and storage medium provided by the present invention can reduce the interference between nodes during the label propagation process by determining the update order of the labels of each node in the target network and performing label propagation based on the update order, eliminate the instability caused by the random determination of the update order of the conventional label propagation algorithm, and obtain more stable and accurate overlapping community detection results. In addition, the efficiency of overlapping community detection can be improved to a certain extent. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0033] Figure 1 It is a flow chart of the overlapping community detection method provided by the present invention;

[0034] Figure 2 It is a flow chart of the overlapping community detection method provided by the present invention;

[0035] Figure 3 is a schematic diagram of the structure of the target network provided by the present invention;

[0036] Figure 4 It is a structural schematic diagram of the overlapping community detection device provided by the present invention;

[0037] Figure 5 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION

[0038] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0039] Combine the following Figure 1-Figure 5 The overlapping community detection method, device, electronic device and storage medium of the present invention are described.

[0040] Figure 1 Schematic diagram of the overlapping community detection method provided by the present invention. Figure 1 The overlapping community detection method provided in the embodiment of the present application is described. Figure 1 As shown, the method includes: Step 101, determining the update order of the labels of each node in the target network based on the PageRank algorithm.

[0041] Specifically, the target network is an undirected network, which includes multiple nodes and at least one edge. For any node, there is at least one neighbor node, and the node is connected to each neighbor node of the node through an edge.

[0042] The usual PageRank algorithm is used to assign weight to each web page.

[0043] The core ideas of the PageRank algorithm include:

[0044] (1) If a web page is linked to by many other web pages, it means that this web page is relatively important, that is, the PageRank value (i.e. PR value or weight) will be relatively high;

[0045] (2) If a web page with a high PageRank value links to another web page, the PageRank value of the linked web page will be increased accordingly.

[0046] In the embodiment of the present invention, based on the PageRank algorithm, the PR value of each node can be obtained and the PR value of each node can be sorted to obtain the update order of the label of each node in the target network.

[0047] Step 102: Based on the update sequence, update the label of each node in the target network a target number of times to obtain a label list of each node.

[0048] Specifically, the label of each node is updated in an iterative manner, and the total number of iterations is a preset target number.

[0049] The target number of times T can be set according to actual conditions. For example, the target number of times is 10 times. The embodiment of the present invention does not specifically limit the specific value of the target number of times. T is independent of the scale and structure of the target network.

[0050] Preferably, T>20. When T>20, a more stable overlapping community detection result can be obtained.

[0051] It should be noted that, before the first iteration, the initial label of each node may be a unique identifier of the node (eg, ID or number, etc.). The nodes correspond to the unique identifiers one by one.

[0052] Optionally, the unique identifier of the node may be encoded in a 1 to n manner, where n represents the number of nodes in the target network.

[0053] For each node, a label list of the node can be obtained based on the initial label of the node and the label of the node determined in each iteration. The label list of the node stores the initial label of the node and the label of the node determined in each iteration.

[0054] In each iteration, based on the update order determined in step 101, the label of each node is updated in turn. The label of each node can be updated based on the label propagation mechanism in the SLPA algorithm. Based on the probability of each label appearing in the label list of each neighbor node of the node, a label is randomly selected as a label propagated to the node (that is, the higher the proportion of a certain label in its label list, the greater the probability of being selected). For the node, the label of the node is updated according to the label with the highest frequency in the labels propagated to the node by each neighbor node of the node. If there are multiple labels with the highest frequency, one of them can be randomly selected as the update result of the label of the node.

[0055] The node label update rules include the following two methods: the update rules of the synchronous update method are shown in formula (1), and the update rules of the asynchronous update method are shown in formula (2). k Represents the neighbor nodes of node i. Function f returns the node with the highest frequency of appearance among the neighbor nodes of node i.

[0056]

[0057]

[0058] The synchronous update method is more stable, while the asynchronous update method makes the label propagation process faster.

[0059] Preferably, the embodiment of the present invention adopts a synchronous update method to update the node label.

[0060] Each time a node's label is updated, the node's label list is also updated.

[0061] Step 103: Based on the label list of each node, the overlapping community detection result of the target network is obtained.

[0062] Specifically, after T iterations, the length of the label list of each node is T+1.

[0063] The label list of each node is processed using the post-processing threshold r. For each different label in the label list, the labels with a probability greater than or equal to the post-processing threshold r are retained, and the remaining labels (i.e., labels with a probability less than the post-processing threshold r) are deleted.

[0064] Each label in the processed label list of each node represents a community to which the node belongs. Nodes with two or more labels in the processed label list are overlapping nodes in the target network.

[0065] If there are no overlapping nodes in the target network, the overlapping community detection results of the target network are each community, and there is no overlapping community in the above communities; if there is no at least one overlapping node in the target network, the overlapping community detection results of the target network are each community, and the above communities include at least two overlapping communities, and each community including overlapping nodes is an overlapping community in the target network.

[0066] It should be noted that, in the embodiment of the present invention, for the post-processing threshold r, r□[0,0.5], when r>0.5, a non-overlapping community is obtained after processing, that is, the number of labels in the processed label list is 1.

[0067] The embodiment of the present invention determines the update order of the labels of each node in the target network and performs label propagation based on the update order, thereby reducing the interference between nodes during the label propagation process, eliminating the instability caused by the random determination of the update order in the conventional label propagation algorithm, and obtaining a more stable and accurate overlapping community detection result. In addition, the efficiency of overlapping community detection can be improved to a certain extent.

[0068] Based on the content of any of the above embodiments, updating the label of the node specifically includes: when there are no less than 2 labels with the highest frequency in the labels propagated to the node in this update, respectively obtaining the similarity between the node and each neighbor node corresponding to the label with the highest frequency.

[0069] Specifically, in the process of updating the node label each time, for any node, if there are no less than two labels with the highest frequency among the labels propagated to the node, the similarity between the node and each neighbor node corresponding to the label with the highest frequency can be obtained respectively.

[0070] The neighbor node corresponding to the label with the highest frequency of occurrence refers to the neighbor node whose label propagated to the node is the label with the highest frequency of occurrence.

[0071] Optionally, the similarity between the node and the neighboring nodes may be measured based on the Jaccard similarity coefficient. For example, the Jaccard similarity coefficient between the node and the neighboring nodes may be obtained as the similarity between the node and the neighboring nodes.

[0072] Based on the similarity, the result of updating the node label is determined.

[0073] Specifically, the maximum similarity between the node and each neighbor node corresponding to the label with the highest frequency can be determined, and the neighbor node corresponding to the maximum similarity value is propagated to the label of the node, which is determined as the update result of the node's label in this update.

[0074] The neighbor node corresponding to the maximum similarity refers to the neighbor node whose similarity between the node and the neighbor node is the maximum similarity between the node and each neighbor node corresponding to the label with the highest occurrence frequency.

[0075] The embodiment of the present invention can eliminate the instability caused by the random selection of the most frequently appearing label as the result of updating the node label in the conventional label propagation algorithm by determining the result of updating the node label based on the similarity between the node and the neighboring nodes corresponding to the most frequently appearing label when there are at least two labels with the highest frequency among the labels propagated to the node, and can obtain a more stable and accurate overlapping community detection result. In addition, the efficiency of overlapping community detection can be improved to a certain extent.

[0076] Based on the content of any of the above embodiments, based on the PageRank algorithm, determining the update order of the labels of each node in the target network specifically includes: based on the PageRank algorithm, through iteration, respectively obtaining the PR value of each node.

[0077] Specifically, in the embodiment of the present invention, the PR value of each node is determined based on the PageRank algorithm. The PR value of a node can be determined based on the number of neighbor nodes of the node and the PR value of the neighbor nodes. Under the same other factors, the more neighbor nodes a node has, the higher the PR value of the node is; the higher the PR value of the neighbor nodes of a node is, the higher the PR value of the node is.

[0078] The PR value of each node is calculated in an iterative manner.

[0079] It should be noted that the PR value of each node can be initialized to 1 / n, where n represents the number of nodes in the target network.

[0080] Through iteration, the PR value of each node can be updated until the PR value of each node no longer changes. The iteration ends and the PR value of each node at this time is determined as the final PR value of each node.

[0081] Based on the PR value of each node, the update order is determined.

[0082] Specifically, by sorting the PR value of each node, the update order of the label of each node can be determined.

[0083] Optionally, the PR values ​​of the nodes are arranged in ascending order to obtain the order of the nodes, which is used as the update order of the labels of the nodes. That is, the nodes with smaller PR values ​​have their labels updated earlier; the nodes with larger PR values ​​have their labels updated earlier.

[0084] If multiple nodes have the same PR value, the multiple nodes with the same PR value may be sorted based on the unique identifier of the node, thereby determining the update order of the label.

[0085] The embodiment of the present invention obtains the PR value of each node in an iterative manner, and determines the update order of the label of each node based on the PR value of each node. The determined update order has better performance, so that label propagation can be performed based on the update order to reduce the interference force formed between nodes during the label propagation process, eliminate the instability caused by the random determination of the update order of the conventional label propagation algorithm, and obtain more stable and accurate overlapping community detection results.

[0086] Based on the content of any of the above embodiments, in each iteration, the formula for obtaining the PR value of node i is:

[0087]

[0088] Among them, PR(i) represents the PR value of node i; n represents the number of nodes in the target network; α is a preset constant, 0<α<1; M(i) represents the set of neighbor nodes of node i; node j is the neighbor node of node i; PR(j) represents the PR value of node j; d(j) represents the degree of node j.

[0089] Specifically, during each iteration, for each node, the PR value of the node can be updated according to the scale of the target network (i.e., the number of nodes in the target network), the PR value and degree of each neighboring node of the node. The PR value of each neighboring node is obtained after the update in the previous iteration; the degree of a node refers to the number of edges connecting the node.

[0090] During this iteration, for node i, its PR value PR(i) can be updated by the following formula:

[0091]

[0092] Among them, PR(j) is the PR value of node j determined in the last iteration.

[0093] The embodiment of the present invention updates the PR value of the node according to the scale of the target network, the PR values ​​and degrees of each of the node's neighboring nodes, and the obtained PR value is more accurate, so that the update order of the labels of each node with better performance can be determined based on the PR value of each node, and then label propagation can be performed based on the update order to reduce the interference force formed between nodes during the label propagation process, eliminate the instability caused by the random determination of the update order of the conventional label propagation algorithm, and obtain a more stable and accurate overlapping community detection result.

[0094] Based on the content of any of the above embodiments, the formula for obtaining the similarity between a node and its neighboring nodes is:

[0095]

[0096] Among them, node j is the neighbor node of node i; sim(i,j) represents the similarity between node i and node j; Г(i) represents the set of neighbor nodes of node i; Г(j) represents the set of neighbor nodes of node j.

[0097] Specifically, for the node (node ​​i) and any neighbor node (node ​​j) corresponding to the label with the highest frequency, the similarity sim(i, j) between the two values ​​can be calculated by the following formula:

[0098]

[0099] Among them, || represents the number of nodes included in the set. |Γ(i)∩Γ(j)| represents the number of nodes included in the intersection of Γ(i) and Γ(j); |Γ(i)∪Γ(j)| represents the number of nodes included in the union of Γ(i) and Γ(j).

[0100] Different from the usual Jaccard similarity coefficient calculation formula, the numerator on the right side of formula (4) includes the constant 2, which represents node i and node j, so that the value range of sim(i,j) is in the range of (0,1], which is convenient for comparing the similarity between the node and each neighbor node corresponding to the label with the highest frequency, thereby determining the result of updating the node label this time.

[0101] The embodiment of the present invention obtains the similarity between the node and the neighbor nodes corresponding to the label with the highest frequency based on the number of neighbor nodes of the node and the number of neighbor nodes of the neighbor nodes corresponding to the label with the highest frequency. The obtained similarity is more accurate, so that when there are no less than two labels with the highest frequency in the labels propagated to the node, the result of updating the label of the node can be determined based on the similarity between the node and the neighbor nodes corresponding to the label with the highest frequency. This can eliminate the instability caused by the random selection of the label with the highest frequency as the result of updating the node's label in the conventional label propagation algorithm, and can obtain a more stable and accurate overlapping community detection result.

[0102] Based on the content of any of the above embodiments, based on similarity, the result of updating the label of the node is determined, specifically including: when the occurrence frequency of the maximum value of the similarity is 1, determining the label corresponding to the maximum value as the result of updating the label of the node.

[0103] Specifically, in the similarity between the node and each neighbor node corresponding to the label with the highest frequency of occurrence, if the frequency of occurrence of the maximum value of the similarity is 1, it means that among the neighbor nodes corresponding to the label with the highest frequency of occurrence, there is only one neighbor node that is most similar to the node, and the label corresponding to the maximum value of the similarity is unique. The label corresponding to the maximum value of the similarity (that is, the label propagated from the most similar neighbor node to the node) can be determined as the result of updating the label of the node this time.

[0104] The embodiment of the present invention can eliminate the instability caused by randomly selecting the most frequently occurring label as the result of updating the node in the conventional label propagation algorithm by determining the label corresponding to the maximum similarity value as the result of updating the node label when the frequency of occurrence of the maximum similarity value between the node and each neighbor node corresponding to the label with the highest frequency is 1, and can obtain a more stable and accurate overlapping community detection result.

[0105] Based on the content of any of the above embodiments, based on similarity, determining the result of updating the label of the node this time also includes: when the frequency of occurrence of the maximum value of the similarity is greater than 1, determining any label corresponding to the maximum value as the result of updating the label of the node this time.

[0106] Specifically, among the similarities between the node and each neighbor node corresponding to the label with the highest frequency of occurrence, if the frequency of occurrence of the maximum value of the similarity is greater than 1, it means that among the neighbor nodes corresponding to the label with the highest frequency of occurrence, there are at least two neighbor nodes that are most similar to the node, and the label corresponding to the maximum value of the similarity is not unique. Any label corresponding to the maximum value of the similarity (that is, the label of any most similar neighbor node propagated to the node) can be determined as the result of updating the label of the node this time.

[0107] The embodiment of the present invention can eliminate the instability caused by randomly selecting the most frequently occurring label as the result of updating the node in the conventional label propagation algorithm by determining any label corresponding to the maximum value of the similarity as the result of updating the node label when the frequency of occurrence of the maximum value of the similarity between the node and each neighbor node corresponding to the label with the highest frequency of occurrence is greater than 1, and can obtain a more stable and accurate overlapping community detection result.

[0108] To facilitate understanding of the above embodiments of the present invention, the overlapping community detection method provided by the embodiments of the present invention is described below by using an example.

[0109] Figure 2 FIG. 1 is a flow chart of the overlapping community detection method provided by the present invention. Figure 2 As shown, the method comprises the following steps:

[0110] Step 201: Initialize algorithm parameters.

[0111] The algorithm parameters mainly include the adjacency matrix net, the maximum number of iterations T (i.e. the target number T) and the post-processing threshold r.

[0112] The adjacency matrix net is used to describe the connection relationship between nodes and reflect the internal structure of the target network. The adjacency matrix net can be an n-order matrix, where n represents the number of nodes in the target network.

[0113]

[0114] Take any A kl , k∈[1,n], l∈[1,n], we have:

[0115]

[0116] Where E represents the set of edges in the target network; (k, l) represents the connection between node k and node l.

[0117] Step 202: Initialize the node label list.

[0118] For any node, the initialization result of the label list of the node is to store the initial label of the node (ie, the displacement identifier).

[0119] Step 203: Calculate the PR value.

[0120] Based on the PageRank algorithm, the PR value of each node is calculated and sorted to obtain the update order of the labels of each node in the target network.

[0121] Step 204: Label propagation.

[0122] Label propagation is performed in an iterative manner. The label of each node is updated in the update order, and the total number of iterations is the target number T.

[0123] Step 205: Determine whether the tag with the most occurrences is unique.

[0124] In the process of updating the node labels in each iteration, for any node, it is determined whether there are at least two labels with the highest frequency among the labels propagated to the node.

[0125] If yes, execute step 206 ; if no, execute step 207 .

[0126] Step 206: Add the label to the label list of the node.

[0127] Add the label with the highest number of occurrences to the label list of the node, and update the label list of the node.

[0128] Step 207: Calculate sim(i,j) and select an update label.

[0129] Calculate the similarity sim(i,j) between the node (node ​​i) and each neighbor node (node ​​j) corresponding to the label with the highest frequency.

[0130] When the frequency of occurrence of the maximum value of the similarity is 1, the label corresponding to the maximum value is determined as the result of the label of the node updated this time; when the frequency of occurrence of the maximum value of the similarity is greater than 1, any label corresponding to the maximum value is determined as the result of the label of the node updated this time.

[0131] Step 208: Determine whether the iteration reaches the maximum number T.

[0132] If yes, execute step 209; if no, return to execute step 204.

[0133] Step 209: Calculate the probability p of occurrence of mutually different labels.

[0134] After the iteration, for each node's label list, the probability p of each different label in the list appearing is calculated.

[0135] Step 210: Determine whether p is less than r.

[0136] If yes, execute Step 211; if no, execute Step 212.

[0137] Step 211: Delete the label.

[0138] Delete the label with the occurrence probability p < r from the label list of the node.

[0139] Step 212: Retain the label.

[0140] Retain the label with the occurrence probability p ≥ r in the label list of the node.

[0141] Step 213: Output the label list of the node.

[0142] Output the label lists of the processed nodes.

[0143] Figure 3 It is a schematic structural diagram of the target network provided by the present invention. As Figure 3 shown, the node includes 10 nodes: Node 1 - Node 10.

[0144] In the initialization stage, use the adjacency matrix to represent the network structure, and initialize the parameters T = 10 and r = 0.3 simultaneously.

[0145] The adjacency matrix net is

[0146]

[0147] Initialize the matrix table to represent the label lists of the nodes. Initialize the label lists of the nodes with the node numbers, and the initialization result of the matrix table is

[0148]

[0149] Calculate the PR values of each node to obtain the vector PR and the vector UpdateOrder representing the update order.

[0150]

[0151]

[0152] In the label propagation phase, the node labels are updated in the order of the label sequence obtained in the initialization phase. In the synchronous update method, for the nodes whose labels need to be updated currently, corresponding update operations are performed according to the labels propagated by their neighbor nodes. Each neighbor node randomly selects a label to be propagated according to the probability of occurrence in its current label list. When there is exactly one label with the highest occurrence frequency among the received labels, the label of this node is updated; when there are multiple labels with the highest occurrence frequency, the similarity between this node and the nodes to which the labels with the highest propagation frequency belong is calculated according to formula (4), and the label of the node corresponding to the highest similarity value is selected and added to the label list of this node.

[0153] For example, in the first label update process of node 4, its neighbor node list is [1, 2, 3, 5, 6, 7, 8], and the label memory propagated to node 4 is [1, 2, 3, 5, 6, 7, 8]. At this time, the 7 distinct labels are all labels with the highest occurrence frequency. Calculate the similarity between node 4 and the 7 neighbor nodes, which are [0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.2000] respectively. It can be observed that the nodes with the highest similarity to the node are [1, 2, 3, 5, 6, 7]. Therefore, node 4 randomly selects a label from the labels [1, 2, 3, 5, 6, 7] for update. It can be observed from the table matrix after label propagation that label 5 is selected.

[0154] After 10 iterations, the label propagation phase stops, and a 10×11 matrix table is obtained, that is, each of the 10 nodes in the target network has 11 label values, including 1 label in the initialization phase and 10 labels after 10 iterations. The label propagation phase ends.

[0155] The matrix table after the label propagation phase stops is as follows

[0156]

[0157] In the post - processing phase, calculate the probability of occurrence of distinct labels in the label list of each node, and perform post - processing with the post - processing threshold r. For example, after the label propagation phase of node 1, the label list is [1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1]. The probability of the 1st label occurrence is p1 = 10 / 11 = 0.909, and the probability of the 2nd label occurrence is p2 = 1 / 11 = 0.091. The threshold r = 0.3, p1 > r, so the 1st label is retained, p2 < r, so the 2nd label is deleted. Therefore, the final label value of node 1 is 1. Perform the same processing on the label memory of the remaining nodes in the target network, and the obtained matrix resulttable is the division of the final network nodes.

[0158]

[0159] The 1st to 10th rows of the matrix resulttable correspond to nodes 1 to 10 respectively. From the matrix resulttable, we can see that there are three communities in the target network: D1, D5 and D9; community D1 includes nodes 1 to 4; community D5 includes nodes 4 to 7; community D9 includes nodes 8 to 10. Node 4 is an overlapping node, and there is overlap between community D1 and community D5.

[0160] The overlapping community detection device provided by the present invention is described below. The overlapping community detection device described below and the overlapping community detection method described above can be referred to each other.

[0161] Figure 4 is a schematic diagram of the structure of the overlapping community detection device provided by the present invention. Based on the content of any of the above embodiments, Figure 4 As shown, the overlapping community detection device includes an order determination module 401, a label propagation module 402 and a community detection module 403, wherein:

[0162] The order determination module 401 is used to determine the update order of the labels of each node in the target network based on the PageRank algorithm;

[0163] The label propagation module 402 is used to update the label of each node in the target network a target number of times based on the update order, and obtain a label list of each node;

[0164] The community detection module 403 is used to obtain overlapping community detection results of the target network based on the label list of each node.

[0165] Specifically, the order determination module 401, the label propagation module 402 and the community detection module 403 are electrically connected in sequence.

[0166] The order determination module 401 may obtain the PR value of each node and sort the PR value of each node based on the PageRank algorithm to obtain the update order of the label of each node in the target network.

[0167] The label propagation module 402 updates the label of each node in an iterative manner, and the total number of iterations is a preset target number of times; after each update of the node label, the node label list is also updated to obtain the label list of each node.

[0168] The community detection module 403 processes the label list of each node using the post-processing threshold r. For each different label in the label list, the labels with a probability greater than or equal to the post-processing threshold r are retained, and the remaining labels (i.e., labels with a probability less than the post-processing threshold r) are deleted.

[0169] Each label in the processed label list of each node represents a community to which the node belongs. Nodes with two or more labels in the processed label list are overlapping nodes in the target network.

[0170] If there are no overlapping nodes in the target network, the overlapping community detection result of the target network is that there are no overlapping communities; if there is no at least one overlapping node in the target network, each community including the overlapping nodes is determined as an overlapping community in the target network, thereby detecting overlapping communities in the target network.

[0171] Optionally, the label propagation module 402 includes:

[0172] A similarity calculation unit, used for obtaining the similarity between the node and each neighbor node corresponding to the label with the highest frequency in the labels propagated to the node in this update when there are at least two labels with the highest frequency;

[0173] The label updating unit is used to determine the result of updating the label of the node based on the similarity.

[0174] Optionally, the sequence determination module 401 includes:

[0175] The weight acquisition unit is used to obtain the PR value of each node through iteration based on the PageRank algorithm;

[0176] The order determination unit is used to determine the update order based on the PR value of each node.

[0177] Optionally, the label updating unit is used to determine the label corresponding to the maximum value as the result of updating the label of the node this time when the occurrence frequency of the maximum value of the similarity is 1.

[0178] Optionally, the label updating unit is further configured to, when the occurrence frequency of the maximum value of the similarity is greater than 1, determine any label corresponding to the maximum value as the result of updating the label of the node this time.

[0179] The overlapping community detection device provided in an embodiment of the present invention is used to execute the above-mentioned overlapping community detection method of the present invention. Its implementation method is consistent with the implementation method of the overlapping community detection method provided by the present invention and can achieve the same beneficial effects, which will not be repeated here.

[0180] The overlapping community detection device is used in the overlapping community detection method in the aforementioned embodiments. Therefore, the description and definition in the overlapping community detection method in the aforementioned embodiments can be used for understanding each execution module in the embodiments of the present invention.

[0181] The embodiment of the present invention determines the update order of the labels of each node in the target network and performs label propagation based on the update order, thereby reducing the interference between nodes during the label propagation process, eliminating the instability caused by the random determination of the update order in the conventional label propagation algorithm, and obtaining a more stable and accurate overlapping community detection result. In addition, the efficiency of overlapping community detection can be improved to a certain extent.

[0182] The electronic device and storage medium provided by the present invention are described below. The electronic device and storage medium described below and the overlapping community detection method described above can be referenced to each other.

[0183] Figure 5 An example of a physical structure diagram of an electronic device is shown in FIG. Figure 5 As shown, the electronic device may include: a processor 510, a communication interface 520, a memory 530 and a communication bus 540, wherein the processor 510, the communication interface 520 and the memory 530 communicate with each other through the communication bus 540. The processor 510 may call a computer program in the memory 530 to execute the steps of the overlapping community detection method, for example, including: determining the update order of the labels of each node in the target network based on the PageRank algorithm; based on the update order, updating the labels of each node in the target network a target number of times to obtain the label list of each node; based on the label list of each node, obtaining the overlapping community detection result of the target network.

[0184] In addition, the logic instructions in the above-mentioned memory 530 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.

[0185] On the other hand, the present invention also provides a computer program product, which includes a computer program stored on a non-transitory computer-readable storage medium, and the computer program includes program instructions. When the program instructions are executed by a computer, the computer can execute the steps of the overlapping community detection method provided by the above methods, for example, including: based on the PageRank algorithm, determining the update order of the labels of each node in the target network; based on the update order, updating the labels of each node in the target network a target number of times to obtain a label list of each node; based on the label list of each node, obtaining the overlapping community detection result of the target network.

[0186] On the other hand, an embodiment of the present application also provides a processor-readable storage medium, which stores a computer program, and the computer program is used to enable the processor to execute the steps of the methods provided in the above embodiments, for example, including: based on the PageRank algorithm, determining the update order of the labels of each node in the target network; based on the update order, updating the labels of each node in the target network a target number of times to obtain a label list of each node; based on the label list of each node, obtaining the overlapping community detection results of the target network.

[0187] The processor-readable storage medium can be any available medium or data storage device that can be accessed by the processor, including but not limited to magnetic storage (such as floppy disks, hard disks, magnetic tapes, magneto-optical disks (MO), etc.), optical storage (such as CD, DVD, BD, HVD, etc.), and semiconductor storage (such as ROM, EPROM, EEPROM, non-volatile memory (NANDFLASH), solid-state drive (SSD)), etc.

[0188] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.

[0189] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0190] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. An overlapping community detection method, characterized in that: include: Based on the PageRank algorithm, determine the update order of the labels of each node in the target network; Based on the update sequence, update the label of each node in the target network a target number of times to obtain a label list of each node; Based on the label list of each node, obtaining the overlapping community detection result of the target network; Update the label of the node, specifically including: When there are at least two labels with the highest frequency among the labels propagated to the node in this update, respectively obtain the similarity between the node and each neighbor node corresponding to the label with the highest frequency; Based on the similarity, determining the result of updating the label of the node this time; The formula for obtaining the similarity between the node and the neighboring node corresponding to the label with the highest frequency of occurrence is: Among them, node j is the neighbor node of node i; sim(i,j) represents the similarity between node i and node j; Γ(i) represents the set of neighbor nodes of node i; Γ(j) represents the set of neighbor nodes of node j; The determining, based on the similarity, a result of updating the label of the node this time specifically includes: When the occurrence frequency of the maximum value of the similarity is 1, the label corresponding to the maximum value is determined as the result of updating the label of the node this time; The determining, based on the similarity, a result of updating the label of the node, further includes: When the occurrence frequency of the maximum value of the similarity is greater than 1, any label corresponding to the maximum value is determined as the result of updating the label of the node this time.

2. The overlapping community detection method according to claim 1, characterized in that: The step of determining the update order of the labels of each node in the target network based on the PageRank algorithm specifically includes: The PageRank algorithm is based on the above method, and the PR value of each node is obtained through iteration. The update order is determined based on the PR value of each of the nodes.

3. The overlapping community detection method according to claim 2, characterized in that: In each iteration, the formula for obtaining the PR value of node i is: Among them, PR(i) represents the PR value of node i; n represents the number of nodes in the target network; α is a preset constant, 0<α<1; M(i) represents the set of neighbor nodes of node i; node j is the neighbor node of node i; PR(j) represents the PR value of node j; d(j) represents the degree of node j.

4. An overlapping community detection device, characterized in that: include: The order determination module is used to determine the update order of the labels of each node in the target network based on the PageRank algorithm; A label propagation module, used to update the label of each node in the target network a target number of times based on the update sequence, and obtain a label list of each node; A community detection module, used to obtain overlapping community detection results of the target network based on the label list of each node; The label propagation module includes: a similarity calculation unit, which is used to obtain the similarity between the node and each neighbor node corresponding to the label with the highest frequency in the labels propagated to the node in this update, when there are at least two labels with the highest frequency in the labels propagated to the node in this update; a label update unit, which is used to determine the result of updating the label of the node in this update based on the similarity; The formula for obtaining the similarity between the node and the neighboring node corresponding to the label with the highest frequency of occurrence is: Among them, node j is the neighbor node of node i; sim(i,j) represents the similarity between node i and node j; Γ(i) represents the set of neighbor nodes of node i; Γ(j) represents the set of neighbor nodes of node j; The label updating unit is used to determine the label corresponding to the maximum value as the result of updating the label of the node this time when the occurrence frequency of the maximum value of the similarity is 1; and to determine any label corresponding to the maximum value as the result of updating the label of the node this time when the occurrence frequency of the maximum value of the similarity is greater than 1.

5. An electronic device comprising a processor and a memory storing a computer program, characterized in that: When the processor executes the computer program, the steps of the overlapping community detection method according to any one of claims 1 to 3 are implemented.

6. A processor-readable storage medium, characterized in that: The processor-readable storage medium stores a computer program, and the computer program is used to enable the processor to execute the steps of the overlapping community detection method according to any one of claims 1 to 3.