CN113822768B - Method, device, equipment and storage medium for processing community network - Google Patents

Method, device, equipment and storage medium for processing community network Download PDF

Info

Publication number
CN113822768B
CN113822768B CN202011597957.0A CN202011597957A CN113822768B CN 113822768 B CN113822768 B CN 113822768B CN 202011597957 A CN202011597957 A CN 202011597957A CN 113822768 B CN113822768 B CN 113822768B
Authority
CN
China
Prior art keywords
community
service node
target
candidate
node
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.)
Active
Application number
CN202011597957.0A
Other languages
Chinese (zh)
Other versions
CN113822768A (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

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 processing method, a device, equipment and a storage medium of a community network, wherein the method comprises the following steps: acquiring a first service node to be added to a community network; the communities affiliated by the second service nodes in the community network are used 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 candidate communities or creating the first target community according to the modularity change value of the community network before and after the first service node is classified into each candidate community; the first service node is included in a first target community of the community network. Therefore, the community division process can be implemented only for the newly added service node, the calculated workload can be greatly saved, the processing efficiency is improved, the method is suitable for scenes with strong instantaneity, and the applicability of the method is improved.

Description

Method, device, equipment and storage medium for processing community network
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, two common community partitioning algorithms can be based on: the Louvain algorithm and the tag propagation algorithm (Label Propagation Algorithm, LPA for short) divide the community network. 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 realizing community division by optimizing module degree (Modularity) based on multiple layers, and the optimization aim is to maximize the module degree 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 average value of the differences between the continuous variable of the nodes in the communities and the edge number under the random condition in all communities in the community network, the value range is (-1, 1), and the larger the value is, the more reasonable the community network is divided according to the current community result.
In the prior art, once a node is newly added, a Louvain algorithm is adopted to re-execute a community division process on all nodes. This division method is time-consuming and cannot be applied to scenes with strong real-time performance.
Disclosure of Invention
The present application aims to solve, at least to some extent, one of the technical problems in the related art.
The method, the device, the equipment and the storage medium for processing the community network are provided to realize that the community division process is only executed for newly added service nodes, so that the workload of calculation can be greatly saved, the processing efficiency is improved, the method can be suitable for scenes with strong instantaneity, and the applicability of the method is improved.
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 affiliated by all second service nodes in the community network 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 candidate communities or creating the first target community according to the modularity change values of the community network before and after the first service node is classified into each candidate community;
And classifying the first service node into the first target community of the community network.
According to the community network processing method, a first service node to be added to the community network is obtained; the communities affiliated by the second service nodes in the community network are used 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 candidate communities or creating the first target community according to the modularity change value of the community network before and after the first service node is classified into each candidate community; the first service node is included in a first target community of the community network. Therefore, the community division process is only executed for the newly added service node, the calculation workload can be greatly saved, the processing efficiency is improved, the method is applicable to scenes with strong instantaneity, 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 acquisition module is used for acquiring a first service node to be added to the community network;
the determining module is used for taking communities affiliated to each second service node in the community network 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;
The processing module is used for determining a first target community from the candidate communities or creating the first target community according to the module degree change values of the community network before and after the first service node is classified into each candidate community;
and the attribution module is used for attributing the first service node to the first target community of the community network.
The processing device of the community network acquires a first service node to be added to the community network; the communities affiliated by the second service nodes in the community network are used 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 candidate communities or creating the first target community according to the modularity change value of the community network before and after the first service node is classified into each candidate community; the first service node is included in a first target community of the community network. Therefore, the community division process is only executed for the newly added service node, the calculation workload can be greatly saved, the processing efficiency is improved, the method is applicable to scenes with strong instantaneity, and the applicability of the method is improved.
An embodiment of a third aspect of the present application proposes a computer device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor implements a method for processing a community network as proposed in the embodiment of the first aspect of the present application when the processor executes the program.
An embodiment of a fourth aspect of the present application proposes a non-transitory computer-readable storage medium, on which a computer program is stored, which when executed by a processor implements a method for processing a community network as proposed by an embodiment of the first aspect of the present application.
An embodiment of a fifth aspect of the present application proposes a computer program product, which when executed by an instruction processor in the computer program product, performs a method for processing a community network as proposed by an embodiment of the first aspect of the present application.
Additional aspects and advantages of the 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 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, in which:
FIG. 1 is a flowchart illustrating a method for processing a community network according to an embodiment of the present disclosure;
fig. 2 is a flow chart of a method for processing a community network according to a second embodiment of the present application;
fig. 3 is a flow chart of a method for processing a community network according to a third embodiment of the present application;
FIG. 4 is a schematic diagram of 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 in implementing embodiments of the present application.
Detailed Description
Embodiments of the present application are described in detail below, examples of which are illustrated in the accompanying drawings, wherein the same or similar reference numerals refer to the same or similar elements or elements having the same or similar functions throughout. The embodiments described below by referring to the drawings are exemplary and intended for the purpose of explaining the present application and are not to be construed as limiting the present application.
The Louvain algorithm is an algorithm for optimizing the modularity based on multiple layers 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 definition of the modularity Q is as follows:
in the formula (1), C i And C j Respectively 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 end term delta (C i ,C j ) 1, and when node i and node j do not belong to the same community, the end term delta (C i ,C j ) 0, i.e.:
in the formula (1), A ij The weight of the edge between the represented nodes i and j, namely the weight of the connecting edge between the nodes i and j, is 1 for the non-weighted graph; k (k) i Representing 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 an unbiased graph i Representing the degree of node i; k (k) j Representing the sum of all edge weights pointing to node j, k for an unbiased graph j The degrees representing node j; m represents the sum of the weights of all the edges in the graph.
The calculation process of the Louvain algorithm comprises the following steps:
1. each node in the graph is considered as a separate community; at this time, there are more nodes in the communities and more communities;
2. and for each node i, sequentially attempting to allocate the node i to the community where the neighbor node is located, calculating the variation value delta Q of the module degree before and after allocation, and recording the neighbor node with the largest 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. Repeatedly executing the step 2 until communities to which the nodes belong in the graph are not changed any more, and achieving a stable state;
4. compressing the graph, compressing nodes in the same community into a new community node, adding the weights of edges among the nodes in the community node, and compressing the weights into an edge pointing to the community node; adding the weights of the edges between two adjacent communities to convert the sum into the weights of the edges between adjacent community nodes;
5. step 4 is repeatedly executed until the modularity of the whole graph is not changed any more.
Compared with other common community division algorithms, such as LPA algorithm, the Louvain algorithm has higher execution efficiency and relatively stable calculation result. The most time-consuming operation of the Louvain algorithm is that when the algorithm is just started, each node is respectively tried to be drawn into the community where the adjacent node is located, and the module degree change value is calculated, namely when the step 2 is executed for the first time, the calculated amount is the largest because the number of the nodes which need to calculate the module degree change value is the largest. After the nodes are compressed according to communities, the number of points and edges can be greatly reduced, and in the subsequent execution process, the state of the graph can be stabilized quickly.
The basic idea of the LPA algorithm is as follows: the community of the node i is sent to the neighbor node of the node i, the community of the neighbor node is obtained, and the obtained maximum community is used as the community of the node i. And iterating the process until communities to which all 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 the community to which the node belongs in a static graph at a certain time point. However, for a scene with strong real-time performance, when a new node arrives, the information of the community where the new node is located cannot be calculated and obtained in real time. The reason is that when a new node arrives, the Louvain algorithm needs to execute the community division process again for all nodes, which is time-consuming.
Therefore, the embodiment of the application mainly aims at the technical problem that the Louvain algorithm cannot be applied to scenes with strong real-time performance in the prior art, and provides a processing method of a community network.
According to the community network processing method, a first service node to be added to the community network is obtained; the communities affiliated by the second service nodes in the community network are used 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 candidate communities or creating the first target community according to the modularity change value of the community network before and after the first service node is classified into each candidate community; the first service node is included in a first target community of the community network. Therefore, the community division process is only executed for the newly added service node, the calculation workload can be greatly saved, the processing efficiency is improved, the method is applicable to scenes with strong instantaneity, and the applicability of the method is improved.
The following describes a processing method, a device, equipment and a storage medium of a community network according to an embodiment of the present application with reference to the accompanying drawings.
Fig. 1 is a flowchart of a method for processing a community network according to an embodiment of the present application.
The embodiment of the application is illustrated by the processing method of the community network being configured in the processing device of the community network, and the processing device 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 (Personal Computer, abbreviated as PC), a cloud device, a mobile device, etc., and the mobile device may be a mobile phone, a tablet computer, a personal digital assistant, a wearable device, a vehicle-mounted device, etc. with various hardware devices including an operating system, a touch screen, and/or a display screen.
As shown in fig. 1, the processing method of the community network 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 present 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, etc., which is not limited in this application.
In this embodiment of the present application, when a service node is newly added, a processing device of the community network may acquire the newly added service node, which is denoted as a first service node in this application.
102, taking communities affiliated by second service nodes in a community network 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.
In the embodiment of the present application, a service node in the community network, which has an association relationship with the first service node, may be obtained, and in the present application, the service node is denoted as a second service node, and communities affiliated by each second service node in the community network are taken as candidate communities.
In one 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 with the association relation with the first service node is determined.
As an example, to reduce complexity of queries, reduce computation time, a community network may be stored in a graph database in which service nodes in the community network, community nodes corresponding to communities in the community network, associations between community nodes and service nodes within corresponding communities, and associations between service nodes in the community network may be stored.
That is, the graph database may be a two-part graph that includes 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 include a plurality of service nodes.
As another example, to promote applicability of the method, the community network may also be stored in another relational database, non-relational database (NoSQL), or search engine, where each service node in the community network, a community node corresponding to each community in the community network, an association between each community node and each service node in the corresponding community, and an association between each service node in the community network may be stored.
Thus, in the present application, a second service node having an association with the first service node may be directly queried to determine a second service node having an association with the first service node, for example, a query graph database, a relational database, a non-relational database, or a search engine.
It should be noted that, when the first service node is newly added, the graph database, the relational database, the non-relational database, or the search engine may not have relevant data of the first service node, so as to be a possible implementation manner of the embodiment of the present application, when the first service node is newly added, the feature of the first service node in the set dimension may be extracted, and according to the feature of each existing service node in the set dimension and the feature of the first service node in the set dimension, the association degree between the first service node and each existing service node is determined and stored, where the association relationship between the existing service nodes and the association relationship or membership relationship between each existing service node and the community node are determined and stored.
Therefore, in the application, the second service node having the association relationship with the first service node can be determined according to the association degree, for example, an existing service node with the association degree higher than a preset association degree threshold is selected as the second service node. And, the association relationship between the first service node and the second service node can be used to update the graph database, the relational database, the non-relational database or the search engine. In this application, the second service node having an association relationship with the first service node may be obtained by directly querying from a graph database, a relational database, a non-relational database, or a search engine.
And step 103, determining a first target community from the candidate communities or creating the first target community according to the modularity change 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 results in the community network, when the modularity change value is greater than or equal to the threshold value, the reasonable community division results in the community network are indicated, and when the modularity change value is smaller than the threshold value, the unreasonable community division results in the community network are indicated.
Wherein the threshold is a smaller value, for example, the threshold may be a smaller value greater than or equal to 0.
It should be appreciated that when a first service node has an association with a second service node, the first service node must be more closely associated with the community node corresponding to the candidate community to which the second service node depends. Therefore, in the application, for each candidate community, the module degree change value Δq of the community network before and after the first service node is included in each candidate community can be calculated, whether the module degree change value greater than or equal to the threshold exists in the module degree change value Δq corresponding to each candidate community is judged, when the module degree change value greater than or equal to the threshold exists in the module degree change value Δq corresponding to each candidate community, the candidate community with the largest module degree change value is determined, and the candidate community with the largest module degree change value is used as the first target community, and at this time, the first service node is most closely related to each service node in the first target community.
And when the module degree variation value corresponding to each candidate community is not greater than or equal to the threshold value, namely, when the module degree variation values corresponding to all candidate communities are smaller than the threshold value, the first service node and all the existing service nodes are not associated, so that 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 determining the first target community from the candidate communities or creating the first target community, 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 the community network is obtained; the communities affiliated by the second service nodes in the community network are used 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 candidate communities or creating the first target community according to the modularity change value of the community network before and after the first service node is classified into each candidate community; the first service node is included in a first target community of the community network. Therefore, the community division process is only executed for the newly added service node, the calculation workload can be greatly saved, the processing efficiency is improved, the method is applicable to scenes with strong instantaneity, and the applicability of the method is improved.
It should be appreciated that, after the first service node is classified into 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 some service nodes in the first target community, but is sparsely related to the rest of service nodes in the first target community. Therefore, in one possible implementation manner of the embodiment of the present application, in order to improve the rationality of the community network division result, a second target community may be created, and according to the module degree variation value of the community network before and after the first service node, each third service node and at least one or more combinations of each third service node, which are adjacent to the first service node in the first target community, and each associated node of each third service node, the home community adjustment is performed on at least one or more combinations of the first service node, each third service node and each associated node.
The above process will be described in detail with reference to the second embodiment.
Fig. 2 is a flow chart of a processing method of a community network according to a second embodiment of the present application.
As shown in fig. 2, the processing method of the community network 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 above embodiment, which is not described herein.
Step 202, judging whether a service node with an association relation with the first service node exists in the community network, if so, executing step 204, and if not, executing step 203.
In the embodiment of the application, the service node having the association relationship with the first service node in the community network can be queried to determine whether the service node having the association relationship with the first service node exists in the community network, for example, when the community network is stored in the graph database, the graph database can be queried to determine whether the service node having the association relationship with the first service node exists in the community network. If there is a service node having an association with the first service node in the community network, the service node having an association with the first service node is used as a second service node, and step 204 is executed, and if there is no service node having an association with the first service node in the community network, step 203 is executed.
Step 203, a first target community to which the first service node belongs is created in the community network, and the first service node is added to the first target community of the community network.
In the embodiment of the present application, when a service node having an association relationship 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, so that 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 204, taking communities affiliated by the second service nodes in the community network 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.
And step 205, determining a first target community from the candidate communities or creating the first target community according to the modularity change value of the community network before and after the first service node is classified into each candidate community.
At step 206, the first service node is included in a first target community of the community network.
In this embodiment, steps 204 to 206 may be implemented in any manner in each embodiment of the present application, which is not limited to this embodiment, and is not described in detail.
Step 207, creating a second target community.
In the embodiment of the application, a new community can be created in the community network as the second target community.
And step 208, 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 change value of 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 in the second target community.
In this embodiment of the present application, the third service node refers to each service node adjacent to the first service node in the first target community.
In one possible implementation of the embodiment of the present application, the first service node may be classified into a second target community, each third service node adjacent to the first service node in the first target community may be determined to be classified into a module degree variation value of the community network before and after the second target community, and each third service node is classified into the second target community, so that the third service node with the module degree variation value greater than the threshold value is classified into the second target community.
That is, a third service node adjacent to the first service node in the first target community may be classified into a second independent target community with the first service node, and it may be determined whether a module degree variation value of the community network before and after the third service node is classified into the second target community is greater than a threshold value, and after the third service node is classified into the second target community, the module degree variation value of the third service node is greater than or equal to the threshold value, 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 all third service nodes which are closely connected with the first service nodes are included in the second target community, and the rationality of community division results is improved.
It should be noted that, when the module degree change value is smaller than the threshold value after all the third service nodes are divided into the second target communities, it is indicated that the division result after the communities are split is unreasonable, and at this time, the first service node may be classified into the first target communities.
In another possible implementation manner of the embodiment of the present application, the first service node may be classified into the second target community, and a module degree change value of the community network before and after classifying the associated node of each third service node adjacent to the first service node in the first target community into the second target community is determined, and the service node with the module degree change value greater than the threshold value is classified into the second target community after classifying the associated node of each third service node into the second target community.
In still another possible implementation manner of the embodiment of the present application, the first service node may be classified into a second target community, and each third service node adjacent to the first service node in the first target community and an associated node of each third service node may be determined to be classified into a module degree change value of a community network before and after the second target community, and the service node whose module degree change value is greater than a threshold value may be classified into the second target community after the third service node and the associated node of 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 is used as a candidate node, a candidate node with a module degree change value greater than a threshold value after the third service node is classified into the second target community is used as an expansion node, an associated node of the expansion node is updated as the candidate node, and the step of classifying the expansion node with a module degree change value greater than the threshold value after the second target community is classified into 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, the service node, of which the modularity change value is greater than the threshold value after being classified into the second target community, is classified into the second target community. And determining the associated nodes of all the third service nodes which do not belong to the second target community, and classifying the service nodes which have the module degree change value larger than the threshold value after classifying the associated nodes of all the third service nodes which do not belong to the second target community into the second target community.
As a further possible implementation manner, the first service node may be classified into the second target community, and then, the service node of each third service node, which is classified into the second target community and then, the modularity change value of which is greater than the threshold value, 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 classifying the service node which has the module degree change value larger than the threshold value after classifying the fourth service node into the second target community.
According to the community network processing method, a 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 change value of the first service node, each third service node adjacent to the first service node in the first target community and the community network before and after the second target community. Therefore, the rationality of community division results can be improved.
In one possible implementation manner of the embodiment of the present application, edges are connected between service nodes having an association relationship in the community network, and weights of the edges are used to indicate association degrees of the association relationship, so that a module degree variation value of the community network can be calculated according to the association degrees between the service nodes.
The above process will be described in detail with reference to the third embodiment.
Fig. 3 is a flow chart of a processing method of a community network according to a third embodiment of the present application.
As shown in fig. 3, the processing method of the community network may include the following steps:
step 301, a first service node to be added to a community network is obtained.
And step 302, taking communities affiliated by the second service nodes in the community network 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.
In this embodiment of the present application, steps 301 to 302 may be implemented in any manner in each embodiment of the present application, which is not limited to this embodiment, and is not described in detail.
Step 303, updating the association parameter of the community network according to the association between the first service node and the second service node; the relevance parameter is obtained by summing the weights of all sides in the community network.
For example, the association parameter of the community network may be m in the above formula (1), where m is the sum of weights of all edges in the community network.
In one possible implementation of the embodiment of the present application, in order to avoid a situation that the calculation amount is large because all service nodes in the community network are recalculated when the association degree parameter of the community network is acquired, the association degree between each service node may be maintained in a cache, and the association degree parameter is maintained, and only when the first service node is newly added, the association degree parameter of the community network is updated by using the association degree between the first service node and the second service node, for example, the previous association degree parameter and the association degree between the first service node and the second service node may be added, so as to obtain the updated association degree parameter.
It should be noted that, in the present application, only the step 303 is executed after the step 302 to illustrate, in practical application, the step 303 may be executed when the second service node having the association relationship with the first service node in the community network 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 module degree change 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, the community dividing process involves classifying the service nodes into communities for several times, which causes calculation of the module degree variation value, so that the calculation efficiency of the module degree variation value directly affects the execution time of the algorithm. In the method, the calculation formula of the module degree change value can be simplified, so that redundant calculation is avoided. Specifically, since only whether the module degree variation value is greater than or equal to the threshold value or less than the threshold value is concerned in the calculation, for example, whether the module degree variation value is positive or negative is concerned when the threshold value is equal to 0, the term that has no influence on the positive and negative results in the module degree variation value calculation formula can be removed. Thus, the calculation formula of the module degree variation value Δq can be simplified as follows:
wherein k is i,in Indicating the weight sum of each adjacent edge connected with the service node i in the community to which the service node i belongs,representing the product between the weight of each service node connected edge and the weight sum of each adjacent edge connected with the service node i in the community to which the service node i belongs.
Therefore, in the application, after the first service node is classified into the candidate community, the weight sum of each adjacent edge connected with the first service node in the candidate community is determined, and after the first service node is classified into the candidate community, the product between the weight sum of each edge connected with each service node in the candidate community and the weight sum of each adjacent edge is determined, and the association parameter, the weight sum of each adjacent edge and the product are substituted into a calculation formula of the module degree change value, such as the formula (3), so as to obtain the module degree change 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 change value of the community network before and after the first service node is classified into each candidate community.
In the embodiment of the present application, the module degree variation values of the community network before and after the first service node is respectively categorized into each candidate community may be obtained, whether the module degree variation value greater than or equal to the threshold exists in the module degree variation values corresponding to each candidate community is determined, if the module degree variation value greater than or equal to the threshold exists, the candidate community with the largest module degree variation value is used as the first target community, and if the module degree variation value greater than or equal to the threshold does not exist, that is, when the module degree variation value corresponding to each candidate community is smaller than the threshold, the first target community is created.
And 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 in any manner in each embodiment of the present application, which is not limited to this embodiment, and is not repeated herein.
Likewise, for step 208 in the foregoing embodiment, the association degree parameter of the community network may be updated according to the association degree between the first service node and the second service node, and the module degree change 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 association nodes of each third service node are classified into the second target community is determined according to the updated association degree parameter of the community network. Specifically, after the third service node or the association node is classified into the second target community, the weight sum of each adjacent edge connected with the third service node or the association node in the second target community is determined, and after the third service node or the association node is classified into the second target community, the product of the weight sum of each edge connected with each service node in the second target community and the weight sum of each adjacent edge is determined, and the association degree parameter of the community network, the weight sum of each adjacent edge and the product are substituted into a calculation formula of a module degree change value, namely the formula (3), so as to obtain the module degree 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 the community network according to an embodiment of the present application. The graph database may be used to store a bipartite graph that contains two types of nodes: service nodes and community nodes. When a new service node i arrives, the association relationship between the service node i and the service nodes in the existing graph can be obtained based on the graph database. If the service node i has no association relation 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 is pointed to the newly created community node, and the calculation is finished.
When the service node i has an association relation with a plurality of existing service nodes in the graph, the service node i is associated with community nodes to which the association nodes belong more tightly, and for the community nodes to which the association nodes belong, a module degree change value delta Q of the graph caused by the fact that the service node i joins each community node can be calculated one by one. If Δq corresponding to all community nodes is negative, it means that the service node i joins these community nodes to reduce the modularity of the graph, so that the service node should join a newly built individual community, a new community node can be created, and the service node i points to the newly built community node, and the calculation is completed. Otherwise, determining the community node C1 with the largest delta Q, and determining that the service node i is in the closest connection with the service nodes in the community node C1.
At this time, it cannot be shown that the service node i may be directly divided into the community node C1, because the service node i may be closely connected to some service nodes in the community node C1 and sparsely connected to the rest of service nodes in the community node C1. Therefore, in order to improve the rationality of the community dividing result, it can be further determined that the service nodes adjacent to the service node i in the service nodes i and C1 are individually formed into a community, and the module degree change result of the graph, if the module degree change value Δq of the graph is a positive number after the service node i and the adjacent service node i in the service node C1 are individually formed into a community, the dividing result of the graph is more reasonable after the service node i and the adjacent service node thereof form a new community, that is, the dividing result after the community is split is more reasonable, so that the service node and the adjacent service node of the service node i in the service node C1 can be formed into a new community node C2.
After the community node C2 is built, whether the service node connected with the service node in the community node C2 but not belonging to the service node in the community node C2 can be added into the community node C2 or not can be judged again. Specifically, the module change value Δq of the graph caused after the service node connected to the service node in the community node C2 but not belonging to the service node in the community node C2 is 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 disconnected from the original community node and transferred to community node C2. And iterating the process until the modularity of the graph reaches a stable state, and ending the calculation. Through measurement and calculation, the community expansion process can reach a stable state only by expanding twice at most, and the calculation efficiency can be greatly improved.
Therefore, based on a Graph Database (Graph Database), the community to which the newly arrived service node belongs can be calculated in real time by optimizing the module degree calculation item, so that the real-time calculation is realized, the community division result is obtained, and the applicability of the method is improved.
Before calculation, if some historical data exists, an offline Louvain algorithm can be operated first, community division results are imported into a graph database, and the starting data can be used as starting data, so that the consistency of the community division algorithm and the offline Louvain algorithm measuring and calculating results can be improved. However, the application can also support the calculation of communities without starting data, so that the applicability of the method is improved.
Through testing, the method for processing the community network can basically finish the computation of the communities to which the single service node belongs within 500 milliseconds, and under the condition of partial extreme, the computation time needs one second, and the computation 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 a module degree change value, and communities to which the newly arrived service nodes belong are judged, so that the Louvain algorithm is improved from the offline community division algorithm to a real-time community division algorithm, and the time delay for acquiring communities to which the real-time service nodes belong and community statistical information can be greatly reduced.
Corresponding to the processing method of the community network provided by the embodiments of fig. 1 to 3, the present disclosure further provides a processing apparatus of a community network, and since the processing apparatus of a community network provided by the embodiments of the present disclosure corresponds to the processing method of a community network provided by the embodiments of fig. 1 to 3, an implementation of the processing method of a community network is also applicable to the processing apparatus of a community network provided by the embodiments of the present disclosure, which is not 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 apparatus 500 of the community network may include: the acquisition module 510, the determination module 520, the processing module 530, and the categorization module 540.
The obtaining module 510 is configured to obtain a first service node to be added to the community network.
The determining module 520 is configured to use communities affiliated by the second service nodes in the community network 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.
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 change value of the community network before and after the first service node falls into each candidate community.
The attribution module 540 is configured to attribute the first service node to a first target community of the community network.
Further, in one possible implementation manner of the embodiment of the present application, the processing apparatus 500 of the community network may further include:
the creation module is used for creating a second target community.
And the adjustment module is used for carrying out 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 change 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.
Further, in one possible implementation manner of the embodiment of the present application, the processing module 530 is specifically configured to: acquiring a modularity change value of a community network before and after classifying a first service node into each candidate community respectively; if the module degree variation value which is larger than or equal to the threshold value exists in the module degree variation values corresponding to the candidate communities, taking the candidate community with the largest module degree variation value as a first target community; and if the module degree change values corresponding to the candidate communities are smaller than the threshold value, creating a first target community.
Further, in one possible implementation manner of the embodiment of the present application, the processing apparatus 500 of the community network may further include:
the adding module is used for creating a first target community to which the first service node belongs in the community network if the first service node does not have an association relationship with each service node in the community network, and adding the first service node to the first target community of the community network.
Further, in one 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 (3) after the expansion nodes with the module degree change value larger than the threshold value are classified into the second target communities, classifying the expansion nodes with the module degree change value larger than the threshold value into the second target communities, updating the associated nodes of the expansion nodes into the candidate nodes, and repeating the step of classifying the expansion nodes with the module degree change value larger than the threshold value into the second target communities after classifying the expansion nodes into the second target communities until the candidate nodes or the expansion nodes are empty.
Further, in a possible implementation manner of the embodiment of the present application, edges and weights of the edges are connected between service nodes having association relationships in the community network, and are used for indicating association degrees of the association relationships; 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; the relevance parameter is obtained by summing the weights of all sides in the community network.
The first calculation module is used for determining the module degree change 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 one possible implementation manner of the embodiment of the present application, the first computing module is specifically configured to: after determining that the first service node belongs to a candidate community, the weight sum of each adjacent edge connected with the first service node in the candidate community; after determining that the first service node belongs to the candidate community, multiplying the weight of the edge connected with each service node in the candidate community by the weight sum of the adjacent edges; substituting the association degree parameter, the weight sum of each adjacent edge and the product into a calculation formula of the module degree change value to obtain the module degree change value.
Further, in a possible implementation manner of the embodiment of the present application, edges and weights of the edges are connected between service nodes having association relationships in the community network, and are used for indicating association degrees of the association relationships; 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 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, 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 a module degree change value to obtain the module degree change value; the relevance parameter is obtained by summing the weights of all sides in the community network.
Further, in one possible implementation manner of the embodiment of the present application, the community network is stored in a graph database, where 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 are stored in the graph database.
The processing device of the community network acquires a first service node to be added to the community network; the communities affiliated by the second service nodes in the community network are used 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 candidate communities or creating the first target community according to the modularity change value of the community network before and after the first service node is classified into each candidate community; the first service node is included in a first target community of the community network. Therefore, the community division process is only executed for the newly added service node, the calculation workload can be greatly saved, the processing efficiency is improved, the method is applicable to scenes with strong instantaneity, and the applicability of the method is improved.
In order to implement the above embodiment, the present application further proposes a computer device, including: the processing method of the community network provided by the previous embodiment of the application is realized when the processor executes the program.
In order to implement the above-mentioned embodiments, the present application also proposes a non-transitory computer-readable storage medium, on which a computer program is stored, which when executed by a processor implements a method for processing a community network as proposed in the previous embodiments of the present application.
In order to implement the above embodiments, the present application further proposes a computer program product, which when executed by an instruction processor in the computer program product, performs a method for processing a community network as proposed in the previous embodiments of the present application.
Fig. 6 illustrates a block diagram of an exemplary computer device suitable for use in implementing embodiments of the present application. The computer device 12 shown in fig. 6 is merely an example and should not be construed as limiting the functionality and scope of use of embodiments of the present application.
As shown in FIG. 6, the computer device 12 is in the form of a general purpose computing device. Components of computer device 12 may include, but are not limited to: one or more processors or processing units 16, a system memory 28, a bus 18 that connects the various system components, including the system memory 28 and the processing units 16.
Bus 18 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processor, and a local bus using any of a variety of bus architectures. By way of example, and not limitation, such architectures include industry Standard architecture (Industry Standard Architecture; hereinafter ISA) bus, micro channel architecture (Micro Channel Architecture; hereinafter MAC) bus, enhanced ISA bus, video electronics standards Association (Video Electronics Standards Association; hereinafter VESA) local bus, and peripheral component interconnect (Peripheral Component Interconnection; hereinafter PCI) bus.
Computer device 12 typically includes a variety of computer system readable media. Such media can 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 (Random Access Memory; hereinafter: RAM) 30 and/or cache memory 32. The 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 or write to non-removable, nonvolatile magnetic media (not shown in FIG. 6, commonly referred to as a "hard disk drive"). Although not shown in fig. 6, a magnetic disk drive for reading from and writing to a removable non-volatile magnetic disk (e.g., a "floppy disk"), and an optical disk drive for reading from or writing to a removable non-volatile optical disk (e.g., a compact disk read only memory (Compact Disc Read Only Memory; hereinafter CD-ROM), digital versatile read only optical disk (Digital Video Disc Read Only Memory; hereinafter DVD-ROM), or other optical media) may be provided. In such cases, each drive may be coupled to bus 18 through one or more data medium interfaces. Memory 28 may include at least one program product having a set (e.g., at least one) of program modules configured to carry out the functions of the embodiments of the present application.
A program/utility 40 having a set (at least one) of program modules 42 may be stored in, for example, 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 or some combination of which may include an implementation of a network environment. Program modules 42 generally perform the functions and/or methods in the embodiments described herein.
The computer device 12 may also communicate with one or more external devices 14 (e.g., keyboard, pointing device, display 24, etc.), one or more devices that enable a user to interact with the computer device 12, and/or any devices (e.g., network card, modem, etc.) that enable the computer device 12 to communicate with one or more other computing devices. Such communication may occur through an input/output (I/O) interface 22. Moreover, the computer device 12 may also communicate with one or more networks such as a local area network (Local Area Network; hereinafter LAN), a wide area network (Wide Area Network; hereinafter WAN) and/or a public network such as the Internet via the network adapter 20. As shown, network adapter 20 communicates with other modules of computer device 12 via bus 18. It should be appreciated that although not shown, other hardware and/or software modules may be used in connection with computer device 12, including, but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, data backup storage systems, and the like.
The processing unit 16 executes various functional applications and data processing by running 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 of the present specification, a description referring to terms "one embodiment," "some embodiments," "examples," "specific examples," 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 present application. In this specification, schematic representations of the above terms are not necessarily directed 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, the different embodiments or examples described in this specification and the features of the different embodiments or examples may be combined and combined by those skilled in the art without contradiction.
Furthermore, the terms "first," "second," and the like, are used for descriptive purposes only and are not to be construed as indicating or implying a relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defining "a first" or "a second" may explicitly or implicitly include at least one such feature. In the description of the present application, the meaning of "plurality" is at least two, such as two, three, etc., unless explicitly defined 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 specific logical functions or steps of the process, and additional 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 embodiments of the present application.
Logic and/or steps represented in the flowcharts or otherwise described herein, e.g., a ordered listing of executable instructions for implementing 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). In addition, the computer readable medium may even be paper or other suitable medium on which the program is printed, as the program may 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 is to be understood that portions of the present application may be implemented in hardware, software, firmware, or a combination thereof. In the above-described embodiments, the various steps or methods may be implemented in software or firmware stored in a memory and executed by a suitable instruction execution system. As with the other embodiments, if implemented in hardware, may be implemented using any one or combination of the following techniques, as is well known in the art: discrete logic circuits having logic gates for implementing logic functions on data signals, application specific integrated circuits having suitable combinational logic gates, programmable Gate Arrays (PGAs), field Programmable Gate Arrays (FPGAs), and the like.
Those of ordinary skill in the art will appreciate that all or a portion of the steps carried out in the method of the above-described embodiments may be implemented by a program to instruct related hardware, where the program may be stored in a computer readable storage medium, and where the program, when executed, includes one or a combination of the steps of the method embodiments.
In addition, each functional unit in each embodiment of the present application may be integrated in one processing module, or each unit may exist alone physically, or two or more units may be integrated in one module. The integrated modules may be implemented in hardware or in software functional modules. The integrated modules may also be stored in a computer readable storage medium if implemented in the form of software functional modules and sold or used as a stand-alone product.
The above-mentioned storage medium may be a read-only memory, a magnetic disk or an optical disk, or the like. Although embodiments of the present application have been shown and described above, it will be understood that the above embodiments are illustrative and not to be construed as limiting the application, and that variations, modifications, alternatives, and variations may be made to the above embodiments by one of ordinary skill in the art within the scope of the application.

Claims (14)

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 affiliated by all second service nodes in the community network 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 candidate communities or creating the first target community according to the modularity change values of the community network before and after the first service node is classified into each candidate community;
grouping the first service node into the first target community of the community network;
creating a second target community;
and 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 first service node, each third service node adjacent to the first service node in the first target community and the module degree change value of the community network before and after the at least one or more combinations of the associated nodes of each third service node are classified into the second target community.
2. The processing method according to claim 1, wherein determining a first target community from among the candidate communities or creating the first target community according to the modularity change value of the community network before and after the first service node belongs to each candidate community comprises:
acquiring a modularity change value of the community network before and after classifying the first service node into each candidate community respectively;
if the module degree variation value which is larger than or equal to the threshold value exists in the module degree variation values which correspond to the candidate communities, the candidate community with the largest module degree variation value is used as the first target community;
and if the module degree change value corresponding to each candidate community is smaller than the threshold value, creating the first target community.
3. The processing method according to claim 1, wherein after the obtaining the first service node to be added to the community network, further comprising:
if the first service node and each service node in the community network have no association relationship, a first target community to which the first service node belongs is created in the community network, and the first service node is added to the first target community of the community network.
4. The processing method according to claim 1, wherein the performing, according to a module degree change 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 at least one or more combinations of associated nodes of each third service node are included in the second target community, home community adjustment on at least one or more combinations of the first service node, each third service node, and each associated node includes:
grouping the first service node into the second target community;
taking each third service node as a candidate node;
the method comprises the steps that after the candidate nodes are classified into a second target community, the expansion nodes with the module degree change values larger than a threshold value are classified into the second target community, the association nodes of the expansion nodes are updated to be the candidate nodes, and the step that after the candidate nodes are classified into the second target community, the expansion nodes with the module degree change values larger than the threshold value are classified into the second target community is repeatedly executed until the candidate nodes or the expansion nodes are empty;
And when all the third service nodes are divided into the second target communities, the modularity change value is smaller than a threshold value, and the first service nodes are classified into the first target communities.
5. The processing method according to claim 1, wherein edges are connected between service nodes having association in the community network, and weights of the edges are used for indicating association degrees of the association; after the obtaining 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 weights of all sides in the community network;
and determining the modularity change 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.
6. The processing method according to claim 5, wherein determining a module degree 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 comprises:
After determining that the first service node belongs to the candidate community, the weight sum of each adjacent edge connected with the first service node in the candidate community;
after determining that the first service node belongs to the candidate community, multiplying the weight of the edge connected with each service node in the candidate community by the weight sum of the adjacent edges;
substituting the association degree parameter, the weight sum of each adjacent edge and the product into a calculation formula of a module degree change value to obtain the module degree change value.
7. The processing method according to claim 1, wherein edges are connected between service nodes having association in the community network, and weights of the edges are used for indicating association degrees of the association; the method further comprises the steps of:
after determining that the third service node or the associated node is classified into the second target community, 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, the product between the weight of the edge connected with each service node in the second target community and the weight sum of each adjacent edge is determined;
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 module degree change value to obtain the module degree change value; the relevancy parameter is obtained by summing the weights of all sides in the community network.
8. The processing method according to any one of claims 1 to 7, wherein the community network is stored in a graph database, and each service node in the community network, a community node corresponding to each community in the community network, an association between each community node and each service node in the corresponding community, and an association between each service node in the community network are stored in the graph database.
9. A processing apparatus for a community network, comprising:
the acquisition module is used for acquiring a first service node to be added to the community network;
the determining module is used for taking communities affiliated to each second service node in the community network 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;
the processing module is used for determining a first target community from the candidate communities or creating the first target community according to the module degree change values of the community network before and after the first service node is classified into each candidate community;
The attribution module is used for attributing the first service node to the first target community of the community network;
the apparatus further comprises:
the creation module is used for creating a second target community;
and the adjustment module is used for carrying out attribution community adjustment on at least one or more combinations among 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 according to the module degree change value of the community network before and after the first service node, each third service node and each associated node are classified into the second target community.
10. The processing device according to claim 9, characterized in that said processing module is in particular configured to:
acquiring a modularity change value of the community network before and after classifying the first service node into each candidate community respectively;
if the module degree variation value which is larger than or equal to the threshold value exists in the module degree variation values which correspond to the candidate communities, the candidate community with the largest module degree variation value is used as the first target community;
And if the module degree change value corresponding to each candidate community is smaller than the threshold value, creating the first target community.
11. The processing device according to claim 9, wherein the adjustment module is specifically configured to:
grouping the first service node into the second target community; taking each third service node as a candidate node;
the method comprises the steps that after the candidate nodes are classified into a second target community, the expansion nodes with the module degree change values larger than a threshold value are classified into the second target community, the association nodes of the expansion nodes are updated to be the candidate nodes, and the step that after the candidate nodes are classified into the second target community, the expansion nodes with the module degree change values larger than the threshold value are classified into the second target community is repeatedly executed until the candidate nodes or the expansion nodes are empty;
and when all the third service nodes are divided into the second target communities, the modularity change value is smaller than a threshold value, and the first service nodes are classified into the first target communities.
12. The processing apparatus according to any one of claims 9 to 11, wherein the community network is stored in a graph database, and each service node in the community network, a community node corresponding to each community in the community network, an association between each community node and each service node in the corresponding community, and an association between each service node in the community network are stored in the graph database.
13. 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 8 when the program is executed.
14. A non-transitory computer-readable storage medium, on which a computer program is stored, characterized in that the program, when executed by a processor, implements a method of processing a community network as claimed in any one of claims 1-8.
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 CN113822768A (en) 2021-12-21
CN113822768B true 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)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114547476A (en) * 2022-01-19 2022-05-27 江汉大学 Community search method, device and processing equipment based on bipartite graph
CN114596040A (en) * 2022-05-09 2022-06-07 浙江口碑网络技术有限公司 Logistics area division method and device, storage medium and electronic equipment

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
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
CN110765320A (en) * 2019-10-23 2020-02-07 腾讯科技(深圳)有限公司 Data processing method, data processing device, storage medium and computer equipment

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8396855B2 (en) * 2010-05-28 2013-03-12 International Business Machines Corporation Identifying communities in an information network
CN107153713B (en) * 2017-05-27 2018-02-23 合肥工业大学 Overlapping community detection method and system based on similitude between node in social networks
US20190147548A1 (en) * 2017-11-14 2019-05-16 International Business Machines Corporation Creation and management of community networks

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
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
CN110765320A (en) * 2019-10-23 2020-02-07 腾讯科技(深圳)有限公司 Data processing method, data processing device, storage medium and computer equipment

Also Published As

Publication number Publication date
CN113822768A (en) 2021-12-21

Similar Documents

Publication Publication Date Title
CN110019568B (en) Spatial clustering-based addressing method and device, computer equipment and storage medium
CN111709533A (en) Distributed training method and device of machine learning model and computer equipment
CN113822768B (en) Method, device, equipment and storage medium for processing community network
WO2013155417A2 (en) Data coreset compression
CN109978006B (en) Face image clustering method and device
CN111159184A (en) Metadata tracing method and device and server
JP2024511018A (en) Methods, devices, computer devices and storage media for determining spatial relationships
US20110179013A1 (en) Search Log Online Analytic Processing
CN113467851A (en) Dynamic vehicle calculation task unloading method and device based on vehicle clustering
CN114565807A (en) Method and device for training target image retrieval model
KR20210061119A (en) Method and apparatus for processing large-scale distributed matrix product
CN112699134A (en) Distributed graph database storage and query method based on graph subdivision
CN106933882B (en) Big data increment calculation method and device
CN114897666B (en) Graph data storage, access, processing method, training method, device and medium
CN115934724A (en) Method for constructing database index, retrieval method, device, equipment and medium
CN115409070A (en) Method, device and equipment for determining critical point of discrete data sequence
CN117610541B (en) Author disambiguation method and device for large-scale data and readable storage medium
US11914603B2 (en) Data layout model generation system
CN112183567A (en) Optimization method, device, equipment and storage medium of BIRCH algorithm
CN117473331B (en) Stream data processing method, device, equipment and storage medium
CN113435501B (en) Clustering-based metric space data partitioning and performance measuring method and related components
CN113641870B (en) Vector index construction method, vector retrieval method and system corresponding to vector index construction method and vector retrieval method
CN112579841B (en) Multi-mode database establishment method, retrieval method and system
WO2024139461A1 (en) Machine learning model training method and apparatus, device, and storage medium
CN117156200A (en) Method, system, electronic equipment and medium for removing duplication of massive videos

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