CN113822768A - Community network processing method, device, equipment and storage medium - Google Patents

Community network processing method, device, equipment and storage medium Download PDF

Info

Publication number
CN113822768A
CN113822768A CN202011597957.0A CN202011597957A CN113822768A CN 113822768 A CN113822768 A CN 113822768A CN 202011597957 A CN202011597957 A CN 202011597957A CN 113822768 A CN113822768 A CN 113822768A
Authority
CN
China
Prior art keywords
community
service node
node
candidate
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202011597957.0A
Other languages
Chinese (zh)
Other versions
CN113822768B (en
Inventor
郭震
钱智钦
王美青
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Jingdong Technology Holding Co Ltd
Original Assignee
Jingdong Technology Holding Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Jingdong Technology Holding Co Ltd filed Critical Jingdong Technology Holding Co Ltd
Priority to CN202011597957.0A priority Critical patent/CN113822768B/en
Publication of CN113822768A publication Critical patent/CN113822768A/en
Application granted granted Critical
Publication of CN113822768B publication Critical patent/CN113822768B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
    • G06Q50/01Social networking
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Primary Health Care (AREA)
  • Strategic Management (AREA)
  • Economics (AREA)
  • General Health & Medical Sciences (AREA)
  • Human Resources & Organizations (AREA)
  • Marketing (AREA)
  • Computing Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Tourism & Hospitality (AREA)
  • Physics & Mathematics (AREA)
  • General Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The application provides a community network processing method, a community network processing device, community network processing equipment and a community network storage medium, wherein the community network processing method comprises the following steps: acquiring a first service node to be added to a community network; taking communities to which the second service nodes in the community network belong as candidate communities; the second service node is a service node which has an association relation with the first service node in the community network; determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community; the first service node is classified into a first target community of the community network. Therefore, the community division process can be executed only aiming at the newly added service nodes, the calculation workload can be greatly saved, the processing efficiency is improved, the method can be suitable for scenes with high real-time performance, and the applicability of the method is improved.

Description

Community network processing method, device, equipment and storage medium
Technical Field
The present application relates to the field of internet technologies, and in particular, to a method, an apparatus, a device, and a storage medium for processing a community network.
Background
Currently, the following two common community partitioning algorithms can be used: the community network is divided by a Louvain Algorithm and a Label Propagation Algorithm (LPA for short). Compared with the LPA algorithm, the Louvain algorithm has higher execution efficiency, relatively stable calculation result and wide application. The Louvain algorithm is an algorithm for optimizing the Modularity (modulation) based on multiple levels so as to realize community division, and the optimization goal is to maximize the Modularity of the whole community network. The modularity is used for evaluating the rationality of the community network division result, the physical meaning of the modularity is the mean value of the difference between the continuous variable of all the community nodes in the community and the edge number under the random condition in the community network, the value range is (-1,1), and the larger the value is, the more rational the community network is divided according to the current community result is.
In the prior art, each new node needs to adopt the Louvain algorithm to perform the community division process again on all nodes. The division mode consumes a lot of time, and cannot be applied to scenes with strong real-time performance.
Disclosure of Invention
The present application is directed to solving, at least to some extent, one of the technical problems in the related art.
The application provides a processing method, a device, equipment and a storage medium of a community network, which are used for realizing that the community division process is executed only aiming at newly added service nodes, greatly saving the calculation workload, improving the processing efficiency, being applicable to scenes with strong real-time performance, and improving the applicability of the method.
An embodiment of a first aspect of the present application provides a method for processing a community network, including:
acquiring a first service node to be added to a community network;
taking communities to which the second service nodes in the community network belong as candidate communities; the second service node is a service node in the community network, which has an association relation with the first service node;
determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community;
and the first service node is classified into the first target community of the community network.
According to the community network processing method, a first service node to be added to a community network is obtained; taking communities to which the second service nodes in the community network belong as candidate communities; the second service node is a service node which has an association relation with the first service node in the community network; determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community; the first service node is classified into a first target community of the community network. Therefore, the community division process is executed only for the newly added service nodes, the calculation workload can be greatly saved, the processing efficiency is improved, the method can be suitable for scenes with high real-time performance, and the applicability of the method is improved.
An embodiment of a second aspect of the present application provides a processing apparatus for a community network, including:
the system comprises an acquisition module, a service processing module and a service processing module, wherein the acquisition module is used for acquiring a first service node to be added to a community network;
the determining module is used for taking the community to which each second service node belongs in the community network as a candidate community; the second service node is a service node in the community network, which has an association relation with the first service node;
the processing module is used for determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community;
a subsumption module for subsumption of the first service node into the first target community of the community network.
The processing device of the community network in the embodiment of the application acquires a first service node to be added to the community network; taking communities to which the second service nodes in the community network belong as candidate communities; the second service node is a service node which has an association relation with the first service node in the community network; determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community; the first service node is classified into a first target community of the community network. Therefore, the community division process is executed only for the newly added service nodes, the calculation workload can be greatly saved, the processing efficiency is improved, the method can be suitable for scenes with high real-time performance, and the applicability of the method is improved.
An embodiment of the third aspect of the present application provides a computer device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor executes the computer program to implement the processing method of the community network as set forth in the embodiment of the first aspect of the present application.
A fourth aspect of the present application provides a non-transitory computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the processing method of the community network as set forth in the first aspect of the present application.
An embodiment of a fifth aspect of the present application provides a computer program product, where when being executed by an instruction processor, the computer program product performs the processing method of the community network as set forth in the embodiment of the first aspect of the present application.
Additional aspects and advantages of the present application will be set forth in part in the description which follows and, in part, will be obvious from the description, or may be learned by practice of the present application.
Drawings
The foregoing and/or additional aspects and advantages of the present application will become apparent and readily appreciated from the following description of the embodiments, taken in conjunction with the accompanying drawings of which:
fig. 1 is a schematic flowchart illustrating a processing method of a community network according to an embodiment of the present application;
fig. 2 is a schematic flowchart of a processing method of a community network according to a second embodiment of the present application;
fig. 3 is a schematic flowchart of a processing method of a community network according to a third embodiment of the present application;
FIG. 4 is a diagram illustrating a community partitioning process in a community network according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of a processing device of a community network according to a fourth embodiment of the present application;
FIG. 6 illustrates a block diagram of an exemplary computer device suitable for use to implement embodiments of the present application.
Detailed Description
Reference will now be made in detail to embodiments of the present application, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the drawings are exemplary and intended to be used for explaining the present application and should not be construed as limiting the present application.
The Louvain algorithm is an algorithm for optimizing the modularity based on multiple levels so as to realize community division, and the optimization aim is to maximize the modularity of the whole community network.
The modularity is used for evaluating the rationality of the community network division result, and the modularity Q is defined as follows:
Figure BDA0002870420610000031
in the formula (1), CiAnd CjRespectively representing communities to which the node i and the node j belong, and when the node i and the node j belong to the same community, the tail item delta (C)i,Cj) Is 1, and when node i and node j do not belong to the same community, the last item δ (C)i,Cj) Is 0, namely:
Figure BDA0002870420610000032
in the formula (1), AijRepresenting the weight of the edge between the nodes i and j, namely the weight of the connecting edge between the nodes i and j, wherein the weight of all the edges in the graph is 1 for the unweighted graph; k is a radical ofiRepresenting the sum of the weights of all edges connected to node i, i.e. the sum of the weights of all edges pointing to node i, k for a weightless graphiRepresenting the degree of the node i; k is a radical ofjRepresenting the sum of the side-by-side weights of all pointing nodes j, k for a weightless graphjRepresents the degree of node j; m represents the sum of the weights of all edges in the graph.
The calculation process of the Louvain algorithm comprises the following steps:
1. regarding each node in the graph as a single community; at this time, there are several communities as many nodes in the community;
2. for each node i, sequentially trying to distribute the node i to communities where the neighbor nodes are located, calculating the change value delta Q of the modularity before and after distribution, and recording the neighbor nodes with the maximum delta Q. If the maximum value of the delta Q is a positive number, the node i is distributed to a community where a neighbor node corresponding to the maximum delta Q is located;
3. repeating the step 2 until the communities to which the nodes in the graph belong do not change any more and reach a stable state;
4. compressing the graph, compressing the nodes in the same community into a new community node, adding the weights of edges among the nodes in the community node, and compressing into an edge pointing to the community node; adding the weights of the edges between two adjacent communities, and converting the sum into the weight of the edge between the nodes of the adjacent communities;
5. and (4) repeatedly executing the step until the modularity of the whole graph is not changed any more.
Compared with other common community division algorithms, such as the LPA algorithm, the Louvain algorithm has higher execution efficiency and relatively stable calculation results. The operation that the Louvain algorithm consumes the most time is a step of trying to divide each node into communities where adjacent nodes are located and calculating the modularity variation value when the algorithm starts, that is, when step 2 is executed for the first time, the number of nodes needing to calculate the modularity variation value is the largest, so that the calculation amount is the largest. After the nodes are compressed according to the communities, the number of points and edges can be greatly reduced, and the state of the graph can quickly reach a stable state in the subsequent execution process.
The basic idea of the LPA algorithm is as follows: and sending the community of the node i to the neighbor node of the node i, acquiring the community to which the neighbor node belongs, and taking the acquired most communities as the communities to which the node i belongs. And iterating the process until the communities to which all the nodes belong reach stability.
In essence, however, the Louvain algorithm is a process of community division based on an offline manner, and the algorithm can better restore communities to which nodes in a static graph belong at a certain time point. However, for a scene with high real-time performance, when a new node arrives, the information of the community where the new node is located cannot be calculated and acquired in real time. The reason is that when a new node arrives, the Louvain algorithm needs to perform the community division process again on all the nodes, and the time consumption is large.
Therefore, the embodiment of the application provides a processing method for a community network, mainly aiming at the technical problem that in the prior art, the Louvain algorithm cannot be applied to scenes with strong real-time performance.
According to the community network processing method, a first service node to be added to a community network is obtained; taking communities to which the second service nodes in the community network belong as candidate communities; the second service node is a service node which has an association relation with the first service node in the community network; determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community; the first service node is classified into a first target community of the community network. Therefore, the community division process is executed only for the newly added service nodes, the calculation workload can be greatly saved, the processing efficiency is improved, the method can be suitable for scenes with high real-time performance, and the applicability of the method is improved.
A processing method, an apparatus, a device, and a storage medium of a community network according to an embodiment of the present application are described below with reference to the drawings.
Fig. 1 is a flowchart illustrating a processing method of a community network according to an embodiment of the present application.
The embodiment of the present application is exemplified by the processing method of the community network being configured in a processing apparatus of the community network, and the processing apparatus of the community network can be applied to any computer device, so that the computer device can execute the processing function of the community network.
The Computer device may be a Personal Computer (PC), a cloud device, a mobile device, and the like, and the mobile device may be a hardware device having various operating systems, touch screens, and/or display screens, such as a mobile phone, a tablet Computer, a Personal digital assistant, a wearable device, and an in-vehicle device.
As shown in fig. 1, the community network processing method may include the following steps:
step 101, a first service node to be added to a community network is obtained.
In this embodiment of the application, the first service node to be added to the community network may be a newly added service node, where when the service type or the service meaning is different, the service node may be different, for example, the service node may represent a registered user, or represent a transaction request, and the application is not limited to this.
In this embodiment of the present application, when a service node is newly added, a processing device of the community network may obtain the newly added service node, which is denoted as a first service node in the present application.
Step 102, taking communities to which second service nodes in a community network belong as candidate communities; the second service node is a service node in the community network and has an association relation with the first service node.
In the embodiment of the application, the service node in the community network, which has an association relationship with the first service node, may be obtained, which is referred to as a second service node in the application, and the community to which each second service node in the community network belongs is taken as a candidate community.
In a possible implementation manner of the embodiment of the present application, each service node in the community network and an association relationship between each service node in the community network may be stored. Therefore, in the application, the stored data can be directly inquired, and the second service node which has the association relation with the first service node is determined.
As an example, in order to reduce the complexity of the query and the computation time, the community network may be stored in a graph database, and the graph database may store each service node in the community network, a community node corresponding to each community in the community network, an association relationship between each community node and each service node in the corresponding community, and an association relationship between each service node in the community network.
That is, the graph database may be a bipartite graph comprising two types of nodes, one being a service node and the other being a community node, wherein the service node is affiliated with a unique community node, and the community node may comprise a plurality of service nodes.
As another example, in order to improve the applicability of the method, the community network may further be stored in another relational database, a non-relational database (NoSQL), or a search engine, and each service node in the community network, a community node corresponding to each community in the community network, an association relationship between each community node and each service node in the corresponding community, and an association relationship between each service node in the community network may be stored in the relational database, the non-relational database, or the search engine.
Therefore, in the present application, a second service node having an association relationship with the first service node may be directly queried, for example, a query graph database, a relational database, a non-relational database, or a search engine, to determine the second service node having an association relationship with the first service node.
It should be noted that, when a first service node is newly added, there may be no related data of the first service node in a graph database, a relational database, a non-relational database, or a search engine, and therefore, as a possible implementation manner of the embodiment of the present application, when a first service node is newly added, a feature of the first service node in a set dimension may be extracted, and according to a feature of each existing service node in the set dimension and a feature of the first service node in the set dimension, a degree of association between the first service node and each existing service node is determined, where an association relationship between existing service nodes and an association relationship or a membership relationship between each existing service node and a community node are determined and stored.
Therefore, in the application, the second service node having an association relationship with the first service node can be determined according to the association degree, for example, an existing service node having an association degree higher than a preset association degree threshold is selected as the second service node. And the incidence relation between the first service node and the second service node can be used for updating the graph database, the relational database, the non-relational database or the search engine. Therefore, in the application, the query can be directly performed from the graph database, the relational database, the non-relational database or the search engine to obtain the second service node having the association relationship with the first service node.
And 103, determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community.
In the embodiment of the application, the modularity is used for measuring or evaluating the rationality of the community division result in the community network, when the modularity variation value is larger than or equal to the threshold value, the community division result in the community network is reasonable, and when the modularity variation value is smaller than the threshold value, the community division result in the community network is unreasonable.
The threshold is a small value, for example, the threshold may be a small value greater than or equal to 0.
It should be understood that when a first service node has an association relationship with a second service node, the first service node is necessarily more closely associated with a community node corresponding to a candidate community to which the second service node is subordinate. Therefore, in the present application, for each candidate community, the modularity change value Δ Q of the community network before and after the first service node is included in each candidate community may be calculated, and it is determined whether there is a modularity change value greater than or equal to the threshold in the modularity change values Δ Q corresponding to each candidate community, and when there is a modularity change value greater than or equal to the threshold in the modularity change values Δ Q corresponding to each candidate community, the candidate community having the largest modularity change value is determined, and the candidate community having the largest modularity change value is used as the first target community, at this time, the first service node is most closely associated with each service node in the first target community.
When the modularity variation value corresponding to each candidate community does not have the modularity variation value larger than or equal to the threshold, that is, when the modularity variation values corresponding to all the candidate communities are smaller than the threshold, it indicates that the first service node has no association relationship with all the existing service nodes, and therefore, the first target community can be created.
And 104, classifying the first service node into a first target community of the community network.
In the embodiment of the application, after the first target community is determined from the candidate communities or the first target community is created, the first service node may be classified into the first target community of the second community network.
According to the community network processing method, a first service node to be added to a community network is obtained; taking communities to which the second service nodes in the community network belong as candidate communities; the second service node is a service node which has an association relation with the first service node in the community network; determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community; the first service node is classified into a first target community of the community network. Therefore, the community division process is executed only for the newly added service nodes, the calculation workload can be greatly saved, the processing efficiency is improved, the method can be suitable for scenes with high real-time performance, and the applicability of the method is improved.
It should be understood that after the first service node is classified in the first target community, it cannot be determined that the first target community is the community to which the first service node belongs, for example, the first service node may be closely related to a part of the service nodes in the first target community, but sparsely related to the rest of the service nodes in the first target community. Therefore, in a possible implementation manner of the embodiment of the present application, in order to improve the rationality of the community network partitioning result, a second target community may be created, and the home community may be adjusted for at least one or more combinations of the first service node, each third service node, and each associated node according to a modularity variation value of the community network before and after the second target community, where the first service node, each third service node adjacent to the first service node in the first target community, and at least one or more combinations of the associated nodes of each third service node are included in the second target community.
The above process is described in detail with reference to example two.
Fig. 2 is a flowchart illustrating a processing method of a community network according to a second embodiment of the present application.
As shown in fig. 2, the community network processing method may include the following steps:
step 201, a first service node to be added to a community network is obtained.
It should be noted that the execution process of step 201 may refer to the execution process of step 101 in the foregoing embodiment, and details are not described here.
Step 202, determining whether a service node having an association relation with the first service node exists in the community network, if yes, executing step 204, and if not, executing step 203.
In the embodiment of the present application, a query may be performed to determine whether a service node having an association relationship with a first service node exists in the community network, for example, when the community network is stored in a graph database, the graph database may be queried to determine whether a service node having an association relationship with a first service node exists in the community network. If a service node having an association relationship with the first service node exists in the community network, the service node having an association relationship with the first service node is taken as a second service node, and step 204 is executed, if no service node having an association relationship with the first service node exists in the community network, step 203 is executed.
Step 203, creating a first target community to which the first service node belongs in the community network, and adding the first service node to the first target community of the community network.
In the embodiment of the application, when a service node having an association relation with a first service node does not exist in a community network, it may be determined that the service node belongs to a single community, and therefore, a first target community to which the first service node belongs may be created, the first service node is added to the first target community of the community network, and the first service node is pointed to a community node corresponding to the first target community.
And step 204, taking the community to which each second service node belongs in the community network as a candidate community.
The second service node is a service node in the community network and has an association relation with the first service node.
Step 205, determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community.
Step 206, the first service node is classified into a first target community of the community network.
In this embodiment of the present application, steps 204 to 206 may be implemented by any one of the embodiments of the present application, which is not limited in this embodiment and is not described again.
Step 207, create a second target community.
In the embodiment of the application, a new community can be created as the second target community in the community network.
And 208, performing home community adjustment on at least one or more combinations of the first service node, each third service node and each associated node according to the modularity variation value of the community network before and after the first service node, each third service node adjacent to the first service node in the first target community and at least one or more combinations of the associated nodes of each third service node are classified into the second target community.
In this embodiment, the third service node refers to each service node adjacent to the first service node in the first target community.
In a possible implementation of the embodiment of the application, the first service node may be classified into the second target community, each third service node adjacent to the first service node in the first target community is determined to be classified into the modularity variation value of the community network before and after the second target community, and the third service node having the modularity variation value larger than the threshold value after each third service node is classified into the second target community.
That is, a third service node adjacent to the first service node in the first target community and the first service node may be divided into an independent second target community, and it is determined whether a modularity variation value of a community network before and after dividing each third service node into the second target community is greater than a threshold, and the third service node having the modularity variation value greater than or equal to the threshold after dividing the third service node into the second target community is classified into the second target community, and the third service node is directed to a community node corresponding to the second target community. Therefore, the second target community can be obtained by splitting from the first target community, so that each third service node which is closely associated with the first service node is included in the second target community, and the rationality of community division results is improved.
It should be noted that when the modularity variation value is smaller than the threshold value after all the third service nodes are divided into the second target community, it indicates that the division result after community division is unreasonable, and at this time, the first service node may be included in the first target community.
In another possible implementation manner of the embodiment of the application, the first service node may be classified into a second target community, a modularity variation value of a community network around the second target community is determined to classify associated nodes of third service nodes adjacent to the first service node in the first target community, and the service nodes with the modularity variation value larger than a threshold value are classified into the second target community after the associated nodes of the third service nodes are classified into the second target community.
In yet another possible implementation manner of the embodiment of the present application, the first service node may be classified into a second target community, and associated nodes of each third service node and each third service node adjacent to the first service node in the first target community are determined and classified into modularity variation values of the community network before and after the second target community, and a service node whose modularity variation value is greater than a threshold value is classified into the second target community after the associated nodes of each third service node and each third service node are classified into the second target community.
As a possible implementation manner, the first service node may be classified into the second target community, each third service node may be used as a candidate node, a candidate node whose modularity degree variation value is greater than the threshold value after being classified into the second target community in the candidate nodes is used as an expansion node, a relevant node of the expansion node is updated to be a candidate node, and the step of classifying an expansion node whose modularity degree variation value is greater than the threshold value into the second target community after being classified into the second target community in each candidate node is repeatedly performed until the candidate node or the expansion node is empty.
As another possible implementation manner, the first service node may be classified into the second target community, and then, after each third service node is classified into the second target community, the service node whose modularity variation value is greater than the threshold value is classified into the second target community. And then determining the associated nodes of all third service nodes not belonging to the second target community, and after the associated nodes of all third service nodes not belonging to the second target community are included in the second target community, the service nodes with the modularity variation value larger than the threshold value are included in the second target community.
As another possible implementation manner, the first service node may be classified into the second target community, and then the service node whose modularity variation value is greater than the threshold value is classified into the second target community after the first service node is classified into the second target community. And then, determining a fourth service node which is connected with the associated node of the third service node in the second target community but does not belong to the second target community, and after the fourth service node is included in the second target community, the service node with the modularity variation value larger than the threshold value is included in the second target community.
According to the community network processing method, the second target community is created; and performing attribution community adjustment on at least one or more combinations of the first service node, each third service node and each associated node according to the modularity variation value of the community network before and after the first service node and each third service node adjacent to the first service node in the first target community and each associated node of each third service node are classified into the second target community. Therefore, the rationality of community division results can be improved.
In a possible implementation manner of the embodiment of the application, edges are connected between service nodes having an association relationship in a community network, and the weight of the edge is used for indicating the association degree of the association relationship, and a modularity variation value of the community network can be calculated according to the association degree between each service node.
The above process is described in detail with reference to example three.
Fig. 3 is a flowchart illustrating a processing method of a community network according to a third embodiment of the present application.
As shown in fig. 3, the community network processing method may include the following steps:
step 301, a first service node to be added to a community network is obtained.
Step 302, the community to which each second service node belongs in the community network is taken as a candidate community.
The second service node is a service node in the community network and has an association relation with the first service node.
In this embodiment of the present application, steps 301 to 302 may be implemented by any one of the embodiments of the present application, and this is not limited in this embodiment of the present application and is not described again.
Step 303, updating the association degree parameter of the community network according to the association degree between the first service node and the second service node; and the relevancy parameter is obtained by summing the weights of all sides in the community network.
For example, the association degree parameter of the community network may be m in the above formula (1), where m is the sum of the weights of all edges in the community network.
In a possible implementation of the embodiment of the application, in order to avoid a situation that when obtaining the association degree parameter of the community network, all service nodes in the community network are recalculated, so that the calculation amount is large, the association degree between the service nodes may be maintained in the cache, and the association degree parameter is maintained.
It should be noted that, in the present application, the step 303 is only executed after the step 302, and in practical application, the step 303 may be executed when a second service node in the community network, which has an association relationship with the first service node, is determined, that is, the step 303 may also be executed before the step 302, or the step 303 may also be executed in parallel with the step 302, which is not limited to this.
And step 304, determining the modularity variation value of the community network before and after the first service node is classified into each candidate community according to the association degree parameter of the community network.
It should be noted that, in the community division process, the business nodes are classified into the community for many times, which causes the calculation of the modularity variation value, so the calculation efficiency of the modularity variation value directly affects the execution time of the algorithm. In the method and the device, the calculation formula of the module degree change value can be simplified, so that redundant calculation is avoided. Specifically, since only whether the modularity variation value is larger than or equal to the threshold value or smaller than the threshold value is concerned in the calculation, for example, whether the threshold value is equal to 0 or the modularity variation value is a positive number or a negative number, an item having no influence on the positive and negative results in the modularity variation value calculation formula can be removed. Thus, the calculation formula of the modularity variation value Δ Q can be simplified as follows:
Figure BDA0002870420610000111
wherein k isi,inIndicating the weight sum of each adjacent edge connected with the service node i in the community to which the service node i belongs,
Figure BDA0002870420610000112
and the product of the weight of the edge connected with each service node in the community to which the service node i belongs and the weight sum of each adjacent edge connected with the service node i is expressed.
Therefore, in the present application, after the first service node is classified into the candidate community, the sum of the weights of the adjacent edges connected to the first service node in the candidate community may be determined, and after the first service node is classified into the candidate community, the product between the sum of the weights of the edges connected to the service nodes in the candidate community and the sum of the weights of the adjacent edges may be determined, and the association degree parameter, the sum of the weights of the adjacent edges, and the product may be substituted into a calculation formula of the modularity variation value, such as the above formula (3), to obtain the modularity variation value of the community network.
And 305, determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community.
In the embodiment of the application, the modularity change values of the community network before and after the first service node is respectively classified into each candidate community can be obtained, whether the modularity change value larger than or equal to the threshold exists in the modularity change values corresponding to each candidate community or not is judged, if the modularity change value larger than or equal to the threshold exists, the candidate community with the largest modularity change value is used as the first target community, and if the modularity change value larger than or equal to the threshold does not exist, namely, the modularity change values corresponding to each candidate community are smaller than the threshold, the first target community is created.
Step 306, the first service node is classified into a first target community of the community network.
In this embodiment of the present application, step 306 may be implemented by any one of the manners in the embodiments of the present application, which is not limited herein and is not described again.
Similarly, for step 208 in the above embodiment, at least one or more combinations of the first service node, each third service node adjacent to the first service node in the first target community, and the associated node of each third service node may be determined to be included in the modularity variation value of the community network before and after the second target community according to the association degree between the first service node and the second service node, and according to the updated association degree parameter of the community network. Specifically, after the third service node or the associated node is classified into the second target community, the sum of the weights of the adjacent edges connected to the third service node or the associated node in the second target community is determined, and after the third service node or the associated node is classified into the second target community, the product between the sum of the weights of the edges connected to the service nodes in the second target community and the sum of the weights of the adjacent edges is determined, and the association degree parameter of the community network, the sum of the weights of the adjacent edges, and the product are substituted into the calculation formula of the modularity change value, that is, the above formula (3), to obtain the modularity change value of the community network.
As an example, referring to fig. 4, fig. 4 is a schematic diagram of a community division process in a community network according to an embodiment of the present application. A graph database may be used to store a bipartite graph that contains two types of nodes: a service node and a community node. When a new service node i arrives, the service node i and which service nodes in the existing graph have association relations can be obtained based on the graph database. If the service node i does not have an association relationship with any existing service node or existing service node in the graph, it can be determined that the service node i should belong to a single community, a new community node is created, the service node i points to the newly created community node, and the calculation is finished.
When a service node i has an association relationship with a plurality of existing service nodes in the graph, the service node i is necessarily more closely associated with the community nodes to which the association nodes belong, and the modularity variation value Δ Q of the graph caused before and after the service node i is added to each community node can be calculated one by one for the community nodes to which the association nodes belong. If the Δ Q corresponding to all the community nodes is a negative value, it indicates that the modularity of the graph is reduced when the service node i joins the community nodes, and therefore, the service node should join a new individual community, a new community node can be created, the service node i points to the new community node, and the calculation is finished. Otherwise, determining the community node C1 with the maximum delta Q, and determining that the service node i is most closely connected with the service node in the community node C1.
At this time, it is not sufficient to indicate that the service node i can be directly classified into the community node C1, because the service node i may be closely related to some service nodes in the community node C1 and sparsely related to the rest of the service nodes in the community node C1. Therefore, in order to improve the rationality of the community division result, it may be further determined that the service node i in the service node i and the service node C1 adjacent to the service node i individually form a community, and the modularity variation result of the graph indicates that the division result of the graph is more reasonable after the new community is formed by the service node i and the adjacent service node C1 after the modularity variation value Δ Q of the graph is positive after the service node i and the adjacent service node of the service node i in the C1 are individually formed into a community, that is, the division result after the community division is more reasonable, so that the service node and the adjacent service node of the service node i in the C1 may be formed into a new community node C2.
After the community node C2 is established, it may be determined again whether the service node connected to the service node in the community node C2 but not belonging to the community node C2 may be added to the community node C2. Specifically, the modularity change value Δ Q of the graph, which is caused after the service nodes connected to the service node in the community node C2 but not belonging to the community node C2 are separated from the original community node and included in the community node C2, may be calculated one by one. If Δ Q is a positive number, the corresponding service node may be detached from the original community node and transferred to the community node C2. And iterating the process until the modularity of the graph reaches a stable state, and finishing the calculation. Through measurement and calculation, the community expansion process can reach a stable state only by two times of expansion at most, and the calculation efficiency can be greatly improved.
Therefore, based on a Graph Database (Graph Database) mode and assisted by optimization of a modularization degree calculation item, the community to which the newly arrived service node belongs can be calculated in real time, so that real-time calculation is realized, a community division result is obtained, and the applicability of the method is improved.
Before calculation, if a part of historical data exists, an offline luvain algorithm may be run first, and the community partition result is imported into the graph database as start data, which may improve the consistency of the community partition algorithm and the calculation result of the offline luvain algorithm. However, the method can also support the calculation of the community under the condition of no starting data, and the applicability of the method is improved.
Through tests, the processing method of the community network in the embodiment of the application can basically finish the calculation of the community to which a single service node belongs within 500 milliseconds, under the partial extreme condition, the calculation time needs one second, and the calculation result and the community result divided by the offline Louvain algorithm keep consistent similarity. In the method, based on the graph database, an offline Louvain algorithm is simulated by calculating the modularity variation value, and the community to which the newly arrived service node belongs is judged, so that the Louvain algorithm is improved from the offline community division algorithm to the real-time community division algorithm, and the time delay for acquiring the community in which the real-time service node is located and the community statistical information can be greatly reduced.
Corresponding to the processing method of the community network provided in the embodiments of fig. 1 to 3, the present disclosure also provides a processing apparatus of the community network, and since the processing apparatus of the community network provided in the embodiments of the present disclosure corresponds to the processing method of the community network provided in the embodiments of fig. 1 to 3, the implementation of the processing method of the community network is also applicable to the processing apparatus of the community network provided in the embodiments of the present disclosure, and will not be described in detail in the embodiments of the present disclosure.
Fig. 5 is a schematic structural diagram of a processing device of a community network according to a fourth embodiment of the present application.
As shown in fig. 5, the processing device 500 of the community network may include: an acquisition module 510, a determination module 520, a processing module 530, and a subsumption module 540.
The obtaining module 510 is configured to obtain a first service node to be added to a community network.
A determining module 520, configured to use a community to which each second service node belongs in the community network as a candidate community; the second service node is a service node in the community network and has an association relation with the first service node.
The processing module 530 is configured to determine a first target community from the candidate communities or create the first target community according to the modularity variation value of the community network before and after the first service node is included in each candidate community.
An attribution module 540 is configured to attribute the first service node to a first target community of the community network.
Further, in a possible implementation manner of the embodiment of the present application, the processing apparatus 500 of the community network may further include:
and the creating module is used for creating a second target community.
And the adjusting module is used for adjusting the home community of at least one or more combinations of the first service node, each third service node and each associated node according to the modularity variation value of the community network before and after the first service node, each third service node adjacent to the first service node in the first target community and each associated node of each third service node are classified into the second target community.
Further, in a possible implementation manner of the embodiment of the present application, the processing module 530 is specifically configured to: acquiring modularity change values of the community network before and after the first service node is respectively classified into each candidate community; if the modularity variation value which is greater than or equal to the threshold value exists in the modularity variation values corresponding to the candidate communities, taking the candidate community with the maximum modularity variation value as a first target community; and if the modularity variation value corresponding to each candidate community is smaller than the threshold value, creating a first target community.
Further, in a possible implementation manner of the embodiment of the present application, the processing apparatus 500 of the community network may further include:
and the adding module is used for creating a first target community to which the first service node belongs in the community network and adding the first service node to the first target community of the community network if the first service node and each service node in the community network do not have an association relationship.
Further, in a possible implementation manner of the embodiment of the present application, the adjusting module is specifically configured to: the first service node is classified into a second target community; taking each third service node as a candidate node; and after the candidate nodes are classified into the second target community, classifying the expansion nodes with the modularity change value larger than the threshold value into the second target community, updating the associated nodes of the expansion nodes into the candidate nodes, and repeatedly executing the step of classifying the expansion nodes with the modularity change value larger than the threshold value into the second target community after the candidate nodes are classified into the second target community until the candidate nodes or the expansion nodes are empty.
Further, in a possible implementation manner of the embodiment of the present application, edges are connected between service nodes having an association relationship in a community network, and the weights of the edges are used for indicating the association degree of the association relationship; the processing apparatus 500 of the community network may further include:
the updating module is used for updating the association degree parameter of the community network according to the association degree between the first service node and the second service node; and the relevancy parameter is obtained by summing the weights of all sides in the community network.
And the first calculation module is used for determining the modularity variation value of the community network before and after the first service node is classified into each candidate community according to the association degree parameter of the community network.
Further, in a possible implementation manner of the embodiment of the present application, the first calculating module is specifically configured to: determining the weight sum of each adjacent edge connected with the first service node in the candidate community after the first service node is classified into the candidate community; determining the product of the weight sum of the edges connected with each service node in the candidate community and the weight sum of each adjacent edge after the first service node is classified into the candidate community; and substituting the association degree parameter, the weight sum of each adjacent edge and the product into a calculation formula of the modularity degree change value to obtain the modularity degree change value.
Further, in a possible implementation manner of the embodiment of the present application, edges are connected between service nodes having an association relationship in a community network, and the weights of the edges are used for indicating the association degree of the association relationship; the processing apparatus 500 of the community network may further include:
the second calculation module is used for determining the weight sum of each adjacent edge connected with the third service node or the associated node in the second target community after the third service node or the associated node is classified into the second target community, determining the product between the weight sum of each edge connected with each service node in the second target community and the weight sum of each adjacent edge after the third service node or the associated node is classified into the second target community, and substituting the association degree parameter of the community network, the weight sum of each adjacent edge and the product into a calculation formula of the modularity change value to obtain the modularity change value; and the relevancy parameter is obtained by summing the weights of all sides in the community network.
Further, in a possible implementation manner of the embodiment of the present application, the community network is stored in a graph database, and the graph database stores each service node in the community network, a community node corresponding to each community in the community network, an association relationship between each community node and each service node in the corresponding community, and an association relationship between each service node in the community network.
The processing device of the community network in the embodiment of the application acquires a first service node to be added to the community network; taking communities to which the second service nodes in the community network belong as candidate communities; the second service node is a service node which has an association relation with the first service node in the community network; determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community; the first service node is classified into a first target community of the community network. Therefore, the community division process is executed only for the newly added service nodes, the calculation workload can be greatly saved, the processing efficiency is improved, the method can be suitable for scenes with high real-time performance, and the applicability of the method is improved.
In order to implement the foregoing embodiments, the present application also provides a computer device, including: the community network processing method comprises a memory, a processor and a computer program which is stored in the memory and can run on the processor, wherein when the processor executes the program, the community network processing method is realized.
In order to achieve the above embodiments, the present application also proposes a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the processing method of the community network as proposed by the foregoing embodiments of the present application.
In order to implement the foregoing embodiments, the present application further provides a computer program product, which when executed by an instruction processor in the computer program product, performs the processing method of the community network as set forth in the foregoing embodiments of the present application.
FIG. 6 illustrates a block diagram of an exemplary computer device suitable for use to implement embodiments of the present application. The computer device 12 shown in fig. 6 is only an example and should not bring any limitation to the function and scope of use of the embodiments of the present application.
As shown in FIG. 6, computer device 12 is in the form of a general purpose computing device. The components of computer device 12 may include, but are not limited to: one or more processors or processing units 16, a system memory 28, and a bus 18 that couples various system components including the system memory 28 and the processing unit 16.
Bus 18 represents one or more of any of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, and a processor or local bus using any of a variety of bus architectures. These architectures include, but are not limited to, Industry Standard Architecture (ISA) bus, Micro Channel Architecture (MAC) bus, enhanced ISA bus, Video Electronics Standards Association (VESA) local bus, and Peripheral Component Interconnect (PCI) bus, to name a few.
Computer device 12 typically includes a variety of computer system readable media. Such media may be any available media that is accessible by computer device 12 and includes both volatile and nonvolatile media, removable and non-removable media.
Memory 28 may include computer system readable media in the form of volatile Memory, such as Random Access Memory (RAM) 30 and/or cache Memory 32. Computer device 12 may further include other removable/non-removable, volatile/nonvolatile computer system storage media. By way of example only, storage system 34 may be used to read from and write to non-removable, nonvolatile magnetic media (not shown in FIG. 6, and commonly referred to as a "hard drive"). Although not shown in FIG. 6, a disk drive for reading from and writing to a removable, nonvolatile magnetic disk (e.g., a "floppy disk") and an optical disk drive for reading from or writing to a removable, nonvolatile optical disk (e.g., a Compact disk Read Only Memory (CD-ROM), a Digital versatile disk Read Only Memory (DVD-ROM), or other optical media) may be provided. In these cases, each drive may be connected to bus 18 by one or more data media interfaces. Memory 28 may include at least one program product having a set (e.g., at least one) of program modules that are configured to carry out the functions of embodiments of the application.
A program/utility 40 having a set (at least one) of program modules 42 may be stored, for example, in memory 28, such program modules 42 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each of which examples or some combination thereof may comprise an implementation of a network environment. Program modules 42 generally perform the functions and/or methodologies of the embodiments described herein.
Computer device 12 may also communicate with one or more external devices 14 (e.g., keyboard, pointing device, display 24, etc.), with one or more devices that enable a user to interact with computer device 12, and/or with any devices (e.g., network card, modem, etc.) that enable computer device 12 to communicate with one or more other computing devices. Such communication may be through an input/output (I/O) interface 22. Moreover, computer device 12 may also communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public Network such as the Internet) via Network adapter 20. As shown, network adapter 20 communicates with the other modules of computer device 12 via bus 18. It should be understood that although not shown in the figures, other hardware and/or software modules may be used in conjunction with computer device 12, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
The processing unit 16 executes various functional applications and data processing by executing programs stored in the system memory 28, for example, implementing the processing method of the community network mentioned in the foregoing embodiment.
In the description herein, reference to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the application. In this specification, the schematic representations of the terms used above are not necessarily intended to refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. Furthermore, various embodiments or examples and features of different embodiments or examples described in this specification can be combined and combined by one skilled in the art without contradiction.
Furthermore, the terms "first", "second" and "first" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In the description of the present application, "plurality" means at least two, e.g., two, three, etc., unless specifically limited otherwise.
Any process or method descriptions in flow charts or otherwise described herein may be understood as representing modules, segments, or portions of code which include one or more executable instructions for implementing steps of a custom logic function or process, and alternate implementations are included within the scope of the preferred embodiment of the present application in which functions may be executed out of order from that shown or discussed, including substantially concurrently or in reverse order, depending on the functionality involved, as would be understood by those reasonably skilled in the art of the present application.
The logic and/or steps represented in the flowcharts or otherwise described herein, e.g., an ordered listing of executable instructions that can be considered to implement logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (electronic device) having one or more wires, a portable computer diskette (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable medium could even be paper or another suitable medium upon which the program is printed, as the program can be electronically captured, via for instance optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner if necessary, and then stored in a computer memory.
It should be understood that portions of the present application may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. If implemented in hardware, as in another embodiment, any one or combination of the following techniques, which are known in the art, may be used: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application specific integrated circuit having an appropriate combinational logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA), or the like.
It will be understood by those skilled in the art that all or part of the steps carried by the method for implementing the above embodiments may be implemented by hardware related to instructions of a program, which may be stored in a computer readable storage medium, and when the program is executed, the program includes one or a combination of the steps of the method embodiments.
In addition, functional units in the embodiments of the present application may be integrated into one processing module, or each unit may exist alone physically, or two or more units are integrated into one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. The integrated module, if implemented in the form of a software functional module and sold or used as a stand-alone product, may also be stored in a computer readable storage medium.
The storage medium mentioned above may be a read-only memory, a magnetic or optical disk, etc. Although embodiments of the present application have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present application, and that variations, modifications, substitutions and alterations may be made to the above embodiments by those of ordinary skill in the art within the scope of the present application.

Claims (16)

1. A method for processing a community network, the method comprising the steps of:
acquiring a first service node to be added to a community network;
taking communities to which the second service nodes in the community network belong as candidate communities; the second service node is a service node in the community network, which has an association relation with the first service node;
determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community;
and the first service node is classified into the first target community of the community network.
2. The processing method according to claim 1, characterized in that the method further comprises:
creating a second target community;
and performing home community adjustment on the first service node, each third service node and at least one or more combinations of the associated nodes of the first service node, each third service node and each associated node according to the modularity variation value of the community network before and after the first service node, each third service node adjacent to the first service node in the first target community and the associated node of each third service node are classified into the second target community.
3. The processing method according to claim 1, wherein the determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is included in each candidate community comprises:
acquiring the modularity variation value of the community network before and after the first service node is respectively classified into each candidate community;
if the modularity variation value which is greater than or equal to a threshold value exists in the modularity variation values corresponding to the candidate communities, taking the candidate community with the largest modularity variation value as the first target community;
and if the modularity variation value corresponding to each candidate community is smaller than the threshold value, creating the first target community.
4. The processing method according to claim 1, wherein after acquiring the first service node to be added to the community network, further comprising:
if the first service node does not have an association relationship with each service node in the community network, creating a first target community to which the first service node belongs in the community network, and adding the first service node to the first target community of the community network.
5. The processing method according to claim 2, wherein the performing the home community adjustment on at least one or more combinations of the first service node, each third service node, and each associated node according to the modularity variation value of the community network before and after the grouping of at least one or more combinations of the first service node, each third service node adjacent to the first service node in the first target community, and the associated node of each third service node into the second target community comprises:
the first service node is classified into the second target community;
taking each third service node as a candidate node;
and after being classified into the second target community, the expansion nodes with the modularity change value larger than the threshold value in each candidate node are classified into the second target community, the associated nodes of the expansion nodes are updated to be the candidate nodes, and the step of classifying the expansion nodes with the modularity change value larger than the threshold value in each candidate node into the second target community is repeatedly executed until the candidate nodes or the expansion nodes are empty.
6. The processing method according to claim 1, wherein edges are connected between service nodes having an association relationship in the community network, and a weight of the edge is used for indicating an association degree of the association relationship; after the obtaining of the first service node to be added to the community network, the method further includes:
updating the association degree parameter of the community network according to the association degree between the first service node and the second service node; the relevancy parameter is obtained by summing the weight of each side in the community network;
and determining the modularity variation value of the community network before and after the first service node is classified into each candidate community according to the association degree parameter of the community network.
7. The processing method according to claim 6, wherein the determining a modularity variation value of the community network before and after the first service node is included in each candidate community according to the association parameter of the community network comprises:
determining the weight sum of each adjacent edge connected with the first service node in the candidate community after the first service node is classified into the candidate community;
determining the product of the weight sum of the edge connected with each service node in the candidate community and the weight sum of each adjacent edge after the first service node is classified into the candidate community;
and substituting the association degree parameter, the weight sum of each adjacent edge and the product into a calculation formula of the modularity degree change value to obtain the modularity degree change value.
8. The processing method according to claim 2, wherein edges are connected between service nodes having an association relationship in the community network, and the weight of the edges is used for indicating the association degree of the association relationship; the method further comprises the following steps:
determining the weight sum of each adjacent edge connected with the third service node or the associated node in the second target community after the third service node or the associated node is classified into the second target community;
determining the product of the weight sum of the edge connected with each service node in the second target community and the weight sum of each adjacent edge after the third service node or the associated node is classified into the second target community;
substituting the association degree parameter of the community network, the weight sum of each adjacent edge and the product into a calculation formula of a modularity degree change value to obtain the modularity degree change value; and the relevancy parameter is obtained by summing the weights of all sides in the community network.
9. The processing method according to any one of claims 1 to 8, wherein the community network is stored in a graph database, and the graph database stores each service node in the community network, a community node corresponding to each community in the community network, an association relationship between each community node and each service node in the corresponding community, and an association relationship between each service node in the community network.
10. A processing apparatus of a community network, comprising:
the system comprises an acquisition module, a service processing module and a service processing module, wherein the acquisition module is used for acquiring a first service node to be added to a community network;
the determining module is used for taking the community to which each second service node belongs in the community network as a candidate community; the second service node is a service node in the community network, which has an association relation with the first service node;
the processing module is used for determining a first target community from the candidate communities or creating the first target community according to the modularity variation value of the community network before and after the first service node is classified into each candidate community;
a subsumption module for subsumption of the first service node into the first target community of the community network.
11. The processing apparatus as defined in claim 10, the apparatus further comprising:
the creation module is used for creating a second target community;
an adjusting module, configured to perform home community adjustment on at least one or more combinations of the first service node, each third service node, and each associated node according to a modularity variation value of the community network before and after the first service node, each third service node adjacent to the first service node in the first target community, and the associated node of each third service node are included in the second target community.
12. The processing device according to claim 10, wherein the processing module is specifically configured to:
acquiring the modularity variation value of the community network before and after the first service node is respectively classified into each candidate community;
if the modularity variation value which is greater than or equal to a threshold value exists in the modularity variation values corresponding to the candidate communities, taking the candidate community with the largest modularity variation value as the first target community;
and if the modularity variation value corresponding to each candidate community is smaller than the threshold value, creating the first target community.
13. The processing apparatus according to claim 11, wherein the adjusting module is specifically configured to:
the first service node is classified into the second target community;
taking each third service node as a candidate node;
and after being classified into the second target community, the expansion nodes with the modularity change value larger than the threshold value in each candidate node are classified into the second target community, the associated nodes of the expansion nodes are updated to be the candidate nodes, and the step of classifying the expansion nodes with the modularity change value larger than the threshold value in each candidate node into the second target community is repeatedly executed until the candidate nodes or the expansion nodes are empty.
14. The processing apparatus according to any one of claims 10 to 13, wherein the community network is stored in a graph database, and the graph database stores each service node in the community network, a community node corresponding to each community in the community network, an association relationship between each community node and each service node in the corresponding community, and an association relationship between each service node in the community network.
15. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing a method of processing a community network as claimed in any one of claims 1 to 9 when executing the program.
16. A non-transitory computer-readable storage medium having stored thereon a computer program, wherein the program, when executed by a processor, implements the method for processing the community network according to any one of claims 1 to 9.
CN202011597957.0A 2020-12-29 2020-12-29 Method, device, equipment and storage medium for processing community network Active CN113822768B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011597957.0A CN113822768B (en) 2020-12-29 2020-12-29 Method, device, equipment and storage medium for processing community network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011597957.0A CN113822768B (en) 2020-12-29 2020-12-29 Method, device, equipment and storage medium for processing community network

Publications (2)

Publication Number Publication Date
CN113822768A true CN113822768A (en) 2021-12-21
CN113822768B CN113822768B (en) 2024-04-16

Family

ID=78924891

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011597957.0A Active CN113822768B (en) 2020-12-29 2020-12-29 Method, device, equipment and storage medium for processing community network

Country Status (1)

Country Link
CN (1) CN113822768B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114596040A (en) * 2022-05-09 2022-06-07 浙江口碑网络技术有限公司 Logistics area division method and device, storage medium and electronic equipment

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110295832A1 (en) * 2010-05-28 2011-12-01 International Business Machines Corporation Identifying Communities in an Information Network
CN106296420A (en) * 2015-05-25 2017-01-04 中国科学院声学研究所 A kind of community discovery method
CN106327345A (en) * 2016-09-12 2017-01-11 电子科技大学 Social group discovering method based on multi-network modularity
CN106600430A (en) * 2016-11-10 2017-04-26 南京财经大学 Community network detection method and device
CN108038791A (en) * 2017-12-21 2018-05-15 李宝忠 A kind of method and virtual community network for building virtual community network
US20180341696A1 (en) * 2017-05-27 2018-11-29 Hefei University Of Technology Method and system for detecting overlapping communities based on similarity between nodes in social network
US20190147548A1 (en) * 2017-11-14 2019-05-16 International Business Machines Corporation Creation and management of community networks
CN110765320A (en) * 2019-10-23 2020-02-07 腾讯科技(深圳)有限公司 Data processing method, data processing device, storage medium and computer equipment

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110295832A1 (en) * 2010-05-28 2011-12-01 International Business Machines Corporation Identifying Communities in an Information Network
CN106296420A (en) * 2015-05-25 2017-01-04 中国科学院声学研究所 A kind of community discovery method
CN106327345A (en) * 2016-09-12 2017-01-11 电子科技大学 Social group discovering method based on multi-network modularity
CN106600430A (en) * 2016-11-10 2017-04-26 南京财经大学 Community network detection method and device
US20180341696A1 (en) * 2017-05-27 2018-11-29 Hefei University Of Technology Method and system for detecting overlapping communities based on similarity between nodes in social network
US20190147548A1 (en) * 2017-11-14 2019-05-16 International Business Machines Corporation Creation and management of community networks
CN108038791A (en) * 2017-12-21 2018-05-15 李宝忠 A kind of method and virtual community network for building virtual community network
CN110765320A (en) * 2019-10-23 2020-02-07 腾讯科技(深圳)有限公司 Data processing method, data processing device, storage medium and computer equipment

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114596040A (en) * 2022-05-09 2022-06-07 浙江口碑网络技术有限公司 Logistics area division method and device, storage medium and electronic equipment

Also Published As

Publication number Publication date
CN113822768B (en) 2024-04-16

Similar Documents

Publication Publication Date Title
CN107169768B (en) Method and device for acquiring abnormal transaction data
CN112286953A (en) Multidimensional data query method and device and electronic equipment
US10642912B2 (en) Control of document similarity determinations by respective nodes of a plurality of computing devices
CN108804383B (en) Support point parallel enumeration method and device based on measurement space
WO2013155417A2 (en) Data coreset compression
CN103838803A (en) Social network community discovery method based on node Jaccard similarity
CN109978006B (en) Face image clustering method and device
CN111382320A (en) Large-scale data increment processing method for knowledge graph
CN111966495A (en) Data processing method and device
JP2024511018A (en) Methods, devices, computer devices and storage media for determining spatial relationships
CN107426315B (en) Distributed cache system Memcached improvement method based on BP neural network
CN113822768B (en) Method, device, equipment and storage medium for processing community network
CN107257356B (en) Social user data optimal placement method based on hypergraph segmentation
KR102326586B1 (en) Method and apparatus for processing large-scale distributed matrix product
CN106933882B (en) Big data increment calculation method and device
CN116910061A (en) Database splitting and table splitting method, device and equipment and readable storage medium
CN115576502B (en) Data storage method and device, electronic equipment and storage medium
CN116737373A (en) Load balancing method, device, computer equipment and storage medium
CN115934724A (en) Method for constructing database index, retrieval method, device, equipment and medium
CN113568987B (en) Training method and device for knowledge graph embedded model and computer equipment
CN110309367B (en) Information classification method, information processing method and device
US11914603B2 (en) Data layout model generation system
CN113435501B (en) Clustering-based metric space data partitioning and performance measuring method and related components
CN117473331B (en) Stream data processing method, device, equipment and storage medium
CN115730681B (en) Model training method, device, equipment and storage medium

Legal Events

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