Node classification method, device, equipment, medium and computer program product
By updating the feature differences and similarities between nodes in the network graph, and iterative feature transfer and fusion, accurate classification of nodes is achieved, the classification accuracy is improved, and it is suitable for different types of network graphs.
Patent Information
- Application Number
- CN202210106326.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-01-28
- Publication Date
- 2024-09-10
- Estimated Expiration
- 2042-01-28
AI Technical Summary
Traditional node classification methods cannot achieve accurate classification, resulting in low classification accuracy.
By determining the feature difference between each target node in the network graph, and updating the feature transfer coefficient based on the feature difference and initial feature similarity, iteratively performs feature transfer and fusion, and finally performs classification based on the target features.
It improves the accuracy of node classification, is suitable for homo-affiliated and hetero-affiliated network graphs, and reduces the feature gap of similar nodes while increasing the feature gap of dissimilar nodes.
Smart Images

Figure CN114511024B
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence technology, and in particular to a node classification method, device, equipment, medium and computer program product. Background Art
[0002] With the development of computer technology, artificial intelligence technology has emerged. Artificial Intelligence (AI) is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology in computer science. It attempts to understand the essence of intelligence and produce a new intelligent machine that can respond in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines so that machines have the functions of perception, reasoning and decision-making. When faced with large-scale node data, we can realize automatic classification of nodes based on artificial intelligence technology.
[0003] In traditional technology, nodes are mainly classified based on the similarity between the inherent features of the objects represented by the nodes. However, the traditional node classification method cannot achieve accurate classification of nodes, resulting in low node classification accuracy. Summary of the invention
[0004] Based on this, it is necessary to provide a node classification method, device, equipment, medium and computer program product that can improve the accuracy of node classification in response to the above technical problems.
[0005] In a first aspect, the present application provides a node classification method, the method comprising:
[0006] During this round of feature transfer, for each target node in the network graph, the feature difference between the target node and the adjacent node is determined; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer;
[0007] Determine a feature transfer coefficient of the target node in this round based on the feature difference and the initial feature similarity between the target node and the adjacent nodes;
[0008] Based on the feature transfer coefficient of this round, determine the transfer feature transferred from the first feature to this round, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the feature transfer of this round;
[0009] Taking the next round as the current round, returning to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph to iterate until the iteration stop condition is reached, and obtaining the target feature of each node in the network graph after the last round of feature transfer;
[0010] Based on the target features of each node in the network graph, each node is classified to obtain a node classification result.
[0011] In a second aspect, the present application provides a node classification device, the device comprising:
[0012] A determination module is used to determine, for each target node in the network graph, a feature difference between the target node and an adjacent node during this round of feature transfer; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer; based on the feature difference and the initial feature similarity between the target node and the adjacent node, determine the feature transfer coefficient of the target node in this round;
[0013] A fusion module, used to determine the transfer feature transferred from the first feature to the current round based on the current round feature transfer coefficient, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the current round feature transfer;
[0014] The determination module is further configured to use the next round as the current round, return to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph to iterate until the iteration stop condition is reached, and obtain the target feature of each node in the network graph after the last round of feature transfer;
[0015] The classification module is used to classify each node in the network diagram based on the target features of each node to obtain a node classification result.
[0016] In one embodiment, the target initial feature of the object represented by the target node is a first initial feature; and the device further includes:
[0017] A calculation module is used to obtain a second initial feature of the object represented by the adjacent node; perform similarity calculation on the first initial feature and the second initial feature to obtain the initial feature similarity between the target node and the adjacent node.
[0018] In one embodiment, the determination module is also used to obtain the first feature of the target node after the last round of feature transfer, and to obtain the second feature of the adjacent node after the last round of feature transfer; the adjacent node is a node in the network graph connected to the target node by an edge; the adjacent node is at least one; for each adjacent node, a first adjustment coefficient for the target node and a second adjustment coefficient for the adjacent node are determined; the first adjustment coefficient is determined based on the correlation between the adjacent node and the target node compared with a first reference node; the first reference node is a node adjacent to the target node and other than the adjacent node; the second adjustment coefficient is determined based on the correlation between the target node and the adjacent node compared with a second reference node; the second reference node is a node adjacent to the adjacent node and other than the target node; according to the first adjustment coefficient, the first feature is adjusted to obtain the first adjusted feature of the target node; according to the second adjustment coefficient, the second feature is adjusted to obtain the second adjusted feature of the adjacent node; according to the first adjustment feature and the second adjustment feature, the feature difference between the target node and the adjacent node is determined.
[0019] In one embodiment, the initial feature similarity between the target node and the adjacent nodes is a first initial feature similarity; the determination module is further used to obtain a first similarity comprehensive value of the target node; the first similarity comprehensive value is determined based on the first initial feature similarity between the target node and each of the adjacent nodes; for each adjacent node, a second similarity comprehensive value of the adjacent node is obtained; the second similarity comprehensive value is determined based on the second initial feature similarity between the adjacent node and each target adjacent node; the target adjacent node is a node in the network graph that is connected to the adjacent node through an edge; according to the ratio of the first initial feature similarity to the first similarity comprehensive value, a first adjustment coefficient for the target node is determined; according to the ratio of the first initial feature similarity to the second similarity comprehensive value, a second adjustment coefficient for the adjacent node is determined.
[0020] In one embodiment, the determination module is also used to determine the current round initial feature transfer coefficient of the target node based on the feature difference and the initial feature similarity between the target node and the adjacent nodes; adjust the current round initial feature transfer coefficient according to a first similarity comprehensive value to obtain the current round feature transfer coefficient of the target node; the first similarity comprehensive value is determined based on the initial feature similarity between the target node and each of the adjacent nodes.
[0021] In one embodiment, the fusion module is also used to determine a first weighting coefficient for the first feature; adjust the first weighting coefficient based on the feature transfer coefficient of this round to obtain a second weighting coefficient; adjust the first feature according to the second weighting coefficient, and use the adjusted feature as the transfer feature transferred from the first feature to this round.
[0022] In one embodiment, the fusion module is also used to determine the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value; the first similarity comprehensive value is determined based on the initial feature similarity between the target node and each of the adjacent nodes; based on the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value, and the preset feature transfer hyperparameters, determine the first weighting coefficient for the first feature.
[0023] In one embodiment, the fusion module is also used to determine a third weighting coefficient of the target initial feature of the object represented by the target node; adjust the target initial feature according to the third weighting coefficient to obtain the retained feature transferred from the target initial feature to this round; fuse the transferred feature with the retained feature to obtain the feature of the target node after the feature transfer in this round.
[0024] In one embodiment, the fusion module is further used to adjust the first weighting coefficient according to a preset feature transfer hyperparameter to obtain a third weighting coefficient for the target initial feature of the object represented by the target node.
[0025] In one embodiment, the node classification result is predicted by a trained node classification model; the node classification model includes a feature extraction network and a classification prediction network with first network parameters; the determination module is also used to use the feature extraction network to return to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network diagram through the next round as the current round to iterate until the iteration stop condition is reached, and output the target features of each node in the network diagram after the last round of feature transfer; the classification module is also used to input the target features of each node in the network diagram into the classification prediction network to adjust the target features based on the first network parameters, and classify each node based on the adjusted features to obtain a node classification result.
[0026] In one embodiment, the network parameters of the feature extraction network include a second network parameter; the second network parameter is a network parameter used to initialize the feature; the device further includes:
[0027] An acquisition module is used to acquire the initial features of the object represented by the target node; the initial features are input into the feature extraction network to adjust the initial features based on the second network parameters to obtain the target initial features of the object represented by the target node.
[0028] In a third aspect, the present application provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:
[0029] During this round of feature transfer, for each target node in the network graph, the feature difference between the target node and the adjacent node is determined; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer;
[0030] Determine a feature transfer coefficient of the target node in this round based on the feature difference and the initial feature similarity between the target node and the adjacent nodes;
[0031] Based on the feature transfer coefficient of this round, determine the transfer feature transferred from the first feature to this round, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the feature transfer of this round;
[0032] Taking the next round as the current round, returning to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph to iterate until the iteration stop condition is reached, and obtaining the target feature of each node in the network graph after the last round of feature transfer;
[0033] Based on the target features of each node in the network graph, each node is classified to obtain a node classification result.
[0034] In a fourth aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the following steps are implemented:
[0035] During this round of feature transfer, for each target node in the network graph, the feature difference between the target node and the adjacent node is determined; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer;
[0036] Determine a feature transfer coefficient of the target node in this round based on the feature difference and the initial feature similarity between the target node and the adjacent nodes;
[0037] Based on the feature transfer coefficient of this round, determine the transfer feature transferred from the first feature to this round, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the feature transfer of this round;
[0038] Taking the next round as the current round, returning to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph to iterate until the iteration stop condition is reached, and obtaining the target feature of each node in the network graph after the last round of feature transfer;
[0039] Based on the target features of each node in the network graph, each node is classified to obtain a node classification result.
[0040] In a fifth aspect, the present application provides a computer program product, including a computer program, which implements the following steps when executed by a processor:
[0041] During this round of feature transfer, for each target node in the network graph, the feature difference between the target node and the adjacent node is determined; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer;
[0042] Determine a feature transfer coefficient of the target node in this round based on the feature difference and the initial feature similarity between the target node and the adjacent nodes;
[0043] Based on the feature transfer coefficient of this round, determine the transfer feature transferred from the first feature to this round, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the feature transfer of this round;
[0044] Taking the next round as the current round, returning to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph to iterate until the iteration stop condition is reached, and obtaining the target feature of each node in the network graph after the last round of feature transfer;
[0045] Based on the target features of each node in the network graph, each node is classified to obtain a node classification result.
[0046] The node classification method, device, equipment, medium and computer program product, in the process of this round of feature transfer, for each target node in the network diagram, determine the feature difference between the target node and the adjacent node; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer. Based on the feature difference and the initial feature similarity between the target node and the adjacent node, the feature transfer coefficient of the target node in this round can be determined. Based on the feature transfer coefficient of this round, the transfer feature transferred from the first feature to this round can be determined, and the transfer feature is fused with the target initial feature of the object represented by the target node, so as to obtain the feature of the target node after this round of feature transfer. The next round is taken as the current round, and the step of determining the feature difference between the target node and the adjacent node for each target node in the network diagram is returned to iterate until the iteration stop condition is reached, and the target feature of each node in the network diagram after the last round of feature transfer can be obtained. Based on the target feature of each node in the network diagram, each node is classified to obtain the node classification result. Compared with the traditional method of directly classifying nodes based on the similarity between the inherent features of the objects represented by the nodes, the present application can continuously update the initial feature similarity between the target node and the adjacent nodes based on the feature difference between the target node and the adjacent nodes, so as to obtain the feature transfer coefficient of each round of the target node, and then determine the transfer feature of each round based on the feature transfer coefficient of each round, so as to continuously update the features of each node in the network diagram based on the transfer feature, while narrowing the feature gap between similar nodes and increasing the feature gap between dissimilar nodes, so as to achieve accurate classification of nodes and improve the accuracy of node classification. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] Figure 1 An application environment diagram of a node classification method in an embodiment;
[0048] Figure 2 A schematic diagram of a process flow of a node classification method in one embodiment;
[0049] Figure 3 A schematic diagram of a process for determining a feature difference between a target node and an adjacent node in one embodiment;
[0050] Figure 4 A schematic diagram of a flow chart of determining a transfer feature transferred from a first feature to a current round in one embodiment;
[0051] Figure 5 A block diagram of a principle for classifying each node in a network diagram by using a node classification model in one embodiment;
[0052] Figure 6 is a flowchart of a node classification method in another embodiment;
[0053] Figure 7 is a structural block diagram of a node classification device in one embodiment;
[0054] Figure 8 is a structural block diagram of a node classification device in another embodiment;
[0055] Fig. 9 is an internal structure diagram of a computer device in one embodiment;
[0056] Fig.10 FIG. 4 is a diagram showing the internal structure of a computer device in another embodiment. DETAILED DESCRIPTION
[0057] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0058] The node classification method provided in this application can be applied to Figure 1 In the application environment shown. Among them, the terminal 102 communicates with the server 104 through the network. Among them, the terminal 102 can be but not limited to various personal computers, laptops, smart phones, tablet computers, portable wearable devices and vehicle-mounted terminals, and the server 104 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms. The terminal 102 and the server 104 can be directly or indirectly connected by wired or wireless communication, and this application is not limited here.
[0059] During this round of feature transfer, for each target node in the network diagram, the server 104 can determine the feature difference between the target node and the adjacent node. The feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer. The server 104 determines the feature transfer coefficient of the target node in this round based on the feature difference and the initial feature similarity between the target node and the adjacent node. Based on the feature transfer coefficient of this round, the server 104 determines the transfer feature transferred from the first feature to this round, and fuses the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after this round of feature transfer. The server 104 takes the next round as this round, returns to the step of determining the feature difference between the target node and the adjacent node for each target node in the network diagram to iterate until the iteration stop condition is reached, and obtains the target feature of each node in the network diagram after the last round of feature transfer. The server 104 classifies each node based on the target feature of each node in the network diagram to obtain a node classification result.
[0060] It is understood that the terminal 102 can provide a network diagram, and the server 104 can determine the feature difference between each target node and the adjacent nodes in the network diagram during the current round of feature transmission. It is understood that the server 104 can also obtain the network diagram locally. This embodiment does not limit this. It is understood that Figure 1 The application scenarios are only for illustration and are not limited to this.
[0061] In one embodiment, Figure 2 As shown, a node classification method is provided, which can be applied to a computer device, which can be a terminal or a server, and can be executed by the terminal or the server itself alone, or can be implemented through the interaction between the terminal and the server. The method includes the following steps:
[0062] Step 202, during this round of feature transfer, for each target node in the network graph, determine the feature difference between the target node and the adjacent node; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer.
[0063] Among them, the network diagram includes multiple nodes and multiple edges connecting the nodes. The nodes are used to represent objects, and the edges are used to connect any two nodes with a constraint relationship. The target node is the node used as the target in each node of the network diagram. It can be understood that each node in the network diagram can be used as a target node. The adjacent node is the node adjacent to the target node in the network diagram. It can be understood that the adjacent node is the node connected to the target node through an edge in the network diagram. It should be noted that the number of adjacent nodes is at least one. The first feature is the feature of the target node after the previous round of feature transfer. The second feature is the feature of the adjacent node after the previous round of feature transfer.
[0064] Specifically, the number of rounds of feature transfer may be multiple rounds. During this round of feature transfer, for each target node in the network graph, the computer device may obtain the first feature of the target node after the previous round of feature transfer, and obtain the second feature of the adjacent node of the target node after the previous round of feature transfer. The computer device may determine the feature difference between the target node and the adjacent node based on the first feature and the second feature.
[0065] In one embodiment, the computer device may determine the difference between the first feature and the second feature, and directly use the difference between the first feature and the second feature as the feature difference between the target node and the adjacent node.
[0066] In one embodiment, the computer device may adjust the first feature and the second feature respectively, and determine the difference between the feature after the first feature is adjusted and the feature after the second feature is adjusted. The computer device may use the difference between the feature after the first feature is adjusted and the feature after the second feature is adjusted as the feature difference between the target node and the adjacent node.
[0067] Step 204, based on the feature difference and the initial feature similarity between the target node and the adjacent nodes, determine the feature transfer coefficient of the target node in this round.
[0068] Among them, the initial feature similarity is the feature similarity determined based on the target initial feature of the node. It can be understood that the initial feature similarity between the target node and the adjacent node is the feature similarity determined based on the target initial feature of the target node and the target initial feature of the adjacent node. The target initial feature is the feature of the object represented by the node before the feature iterative transfer. The feature transfer coefficient is the coefficient used to characterize the amount of feature transfer during the feature transfer process of the node. The current round feature transfer coefficient is the feature transfer coefficient of the node during the current round of feature transfer.
[0069] Specifically, the computer device may obtain the target initial feature of the target node and the target initial feature of the adjacent node. The computer device may determine the initial feature similarity between the target node and the adjacent node based on the target initial feature of the target node and the target initial feature of the adjacent node. Furthermore, the computer device may determine the current round feature transfer coefficient of the target node based on the feature difference and the initial feature similarity between the target node and the adjacent node.
[0070] In one embodiment, the computer device may directly use the product of the initial feature similarity and feature difference between the target node and the adjacent nodes as the feature transfer coefficient of the target node in this round.
[0071] In one embodiment, the computer device may first determine the initial feature transfer coefficient of the target node in this round based on the feature difference and the initial feature similarity between the target node and the adjacent nodes. Furthermore, the computer device may determine the feature transfer coefficient of the target node in this round based on the initial feature transfer coefficient of the target node in this round. The initial feature transfer coefficient is an initial coefficient used to characterize the amount of feature transfer during the feature transfer process of the node. The initial feature transfer coefficient of this round is the initial feature transfer coefficient of the node in the feature transfer process of this round.
[0072] Step 206, based on the feature transfer coefficient of this round, determine the transfer feature transferred from the first feature to this round, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the feature transfer of this round.
[0073] Among them, the transfer feature is the feature transferred from the first feature to the current round. It can be understood that the transfer feature is the feature actually obtained by the target node from the first feature. It can be understood that the first feature can be transferred to the current round in its entirety or only in part. The part of the feature transferred to the current round is the transfer feature.
[0074] Specifically, the computer device may process the first feature of the target node after the previous round of feature transfer based on the current round feature transfer coefficient of the target node, and use the processed feature as the transfer feature transferred from the first feature to the current round. The computer device may fuse the transfer feature of the target node with the target initial feature of the object represented by the target node, and use the fused feature as the feature of the target node after the current round of feature transfer.
[0075] In one embodiment, the computer device may perform a weighted operation on the first feature of the target node after the previous round of feature transfer based on the current round feature transfer coefficient of the target node. Furthermore, the computer device may directly use the feature after the weighted operation as the transfer feature transferred from the first feature to the current round. Furthermore, the computer device may fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the current round of feature transfer.
[0076] In one embodiment, the computer device may determine the transfer feature transferred from the first feature to the current round based on the feature transfer coefficient of the current round. Then, the computer device may weightedly fuse the transfer feature with the target initial feature of the object represented by the target node, and use the weighted fused feature as the feature of the target node after the feature transfer of the current round.
[0077] In one embodiment, the computer device may perform a weighted operation on the first feature of the target node after the previous round of feature transfer based on the current round feature transfer coefficient of the target node, and directly use the weighted feature as the transfer feature transferred from the first feature to the current round. Furthermore, the computer device may perform a weighted fusion of the transfer feature and the target initial feature of the object represented by the target node, and use the weighted fusion feature as the feature of the target node after the current round of feature transfer.
[0078] Step 208, taking the next round as the current round, returns to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph to iterate until the iteration stop condition is reached, and obtains the target features of each node in the network graph after the last round of feature transfer.
[0079] The iteration stop condition is the condition that stops the feature iteration transfer process. The target feature is the feature used as the target. It can be understood that the target feature is the feature output after the last round of feature transfer when the feature iteration transfer process stops.
[0080] Specifically, the computer device may take the next round as the current round, and return to determine the feature difference between the target node and the adjacent nodes for each target node in the network diagram, determine the feature transfer coefficient of the target node in this round based on the feature difference and the initial feature similarity between the target node and the adjacent nodes, determine the transfer feature transferred from the first feature to this round based on the feature transfer coefficient of this round, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the feature transfer in this round, so as to perform feature iterative transfer until the iteration stop condition is reached, and obtain the target feature of each node in the network diagram after the last round of feature transfer.
[0081] In one embodiment, the iteration stopping condition may be that the number of iterations reaches a preset number of iterations, or that the features of each node in the network graph are no longer updated.
[0082] Step 210, classify each node based on the target feature of each node in the network graph to obtain a node classification result.
[0083] Here, classifying each node refers to determining the category to which each node belongs.
[0084] Specifically, the computer device may classify each node in the network diagram based on the target features of each node in the network diagram to determine the category to which each node in the network diagram belongs. The computer device may generate a node classification result for each node in the network diagram according to the category to which each node in the network diagram belongs.
[0085] In one embodiment, the computer device may input the target features of each node in the network diagram into a trained node classification model, so as to classify each node based on the input target features through the trained node classification model to obtain a node classification result.
[0086] In one embodiment, classifying each node may include predicting a label for the node, and the node classification result may include a node label prediction result. The computer device may predict a label for each node based on the target features of each node in the network graph to obtain a node label prediction result.
[0087] In the above node classification method, during the process of this round of feature transfer, for each target node in the network diagram, the feature difference between the target node and the adjacent node is determined; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer. Based on the feature difference and the initial feature similarity between the target node and the adjacent node, the feature transfer coefficient of the target node in this round can be determined. Based on the feature transfer coefficient of this round, the transfer feature transferred from the first feature to this round can be determined, and the transfer feature can be fused with the target initial feature of the object represented by the target node to obtain the feature of the target node after this round of feature transfer. Take the next round as this round, return to the step of determining the feature difference between the target node and the adjacent node for each target node in the network diagram to iterate until the iteration stop condition is reached, and the target feature of each node in the network diagram after the last round of feature transfer can be obtained. Based on the target feature of each node in the network diagram, each node is classified to obtain the node classification result. Compared with the traditional method of directly classifying nodes based on the similarity between the inherent features of the objects represented by the nodes, the present application can continuously update the initial feature similarity between the target node and the adjacent nodes based on the feature difference between the target node and the adjacent nodes, so as to obtain the feature transfer coefficient of each round of the target node, and then determine the transfer feature of each round based on the feature transfer coefficient of each round, so as to continuously update the features of each node in the network diagram based on the transfer feature, while narrowing the feature gap between similar nodes and increasing the feature gap between dissimilar nodes, so as to achieve accurate classification of nodes and improve the accuracy of node classification.
[0088] In addition, the traditional node classification method, because it directly classifies nodes based on the similarity between the inherent features of the objects represented by the nodes, it can be understood that the traditional node classification method pre-defaults that the network diagram satisfies the same-kinship assumption. Therefore, it is only applicable to the node classification of the same-kinship network diagram, and cannot achieve a good classification effect on the node classification of the heterogeneous network diagram. Compared with the traditional node classification method, the present application continuously updates the initial feature similarity between the target node and the adjacent nodes based on the feature difference between the target node and the adjacent nodes, and does not pre-default that the network diagram satisfies the same-kinship assumption. Therefore, the node classification method of the present application can be applied to the node classification of both the same-kinship network diagram and the heterogeneous network diagram, and can achieve accurate classification of nodes.
[0089] In one embodiment, the target initial feature of the object represented by the target node is the first initial feature; the method includes: obtaining the second initial feature of the object represented by the adjacent node; calculating the similarity between the first initial feature and the second initial feature to obtain the initial feature similarity between the target node and the adjacent node.
[0090] The first initial feature is the target initial feature of the object represented by the target node, and the second initial feature is the target initial feature of the object represented by the adjacent node.
[0091] Specifically, the computer device may obtain the target initial feature of the object represented by the target node, that is, the first initial feature, and obtain the target initial feature of the object represented by the adjacent node, that is, the second initial feature. The computer device may calculate the similarity between the first initial feature and the second initial feature to obtain the initial feature similarity between the target node and the adjacent node.
[0092] In one embodiment, the computer device may obtain the object behavior data of the object represented by the target node, and obtain the object behavior data of the object represented by the adjacent node. Furthermore, the computer device may extract the target initial feature of the object represented by the target node based on the object behavior data of the object represented by the target node, i.e., the first initial feature, and extract the target initial feature of the object represented by the adjacent node based on the object behavior data of the object represented by the adjacent node, i.e., the second initial feature.
[0093] In the above embodiment, by calculating the similarity between the first initial feature of the object represented by the target node and the second initial feature of the object represented by the adjacent node, the initial feature similarity between the target node and the adjacent node can be accurately obtained, thereby improving the accuracy of the initial feature similarity between the target node and the adjacent node.
[0094] In one embodiment, Figure 3 As shown, in this round of feature transfer, for each target node in the network graph, the feature difference between the target node and the adjacent nodes is determined, including the following processing steps:
[0095] Step 302, obtaining the first feature of the target node after the last round of feature transfer, and obtaining the second feature of the adjacent node after the last round of feature transfer; the adjacent node is a node in the network graph connected to the target node through an edge; there is at least one adjacent node.
[0096] Specifically, for a target node in a network graph, the number of its adjacent nodes is at least one, and it can be understood that there is at least one node in the network graph connected to the target node through an edge. During this round of feature transfer, the computer device can obtain the first feature of the target node after the previous round of feature transfer, and obtain the second feature of the adjacent node after the previous round of feature transfer.
[0097] Step 304, for each adjacent node, determine a first adjustment coefficient for the target node and a second adjustment coefficient for the adjacent node; the first adjustment coefficient is determined based on the correlation between the adjacent node and the target node compared to the first reference node; the first reference node is a node adjacent to the target node and other than the adjacent node; the second adjustment coefficient is determined based on the correlation between the target node and the adjacent node compared to the second reference node; the second reference node is a node adjacent to the adjacent node and other than the target node.
[0098] Among them, the stronger the correlation between the adjacent node and the target node is compared to the first reference node, the larger the first adjustment coefficient is, and vice versa. It can be understood that the first reference node is a node connected to the target node by an edge, except the adjacent node. The stronger the correlation between the target node and the adjacent node is compared to the second reference node, the larger the second adjustment coefficient is, and vice versa. It can be understood that the second reference node is a node connected to the adjacent node by an edge, except the target node.
[0099] Specifically, for each neighboring node, the computer device may determine a first adjustment coefficient for the target node, and determine a second adjustment coefficient for the neighboring node.
[0100] Step 306: Adjust the first feature according to the first adjustment coefficient to obtain a first adjusted feature of the target node.
[0101] Specifically, the computer device may adjust the first feature of the target node after the previous round of feature transfer according to the first adjustment coefficient, and use the adjusted feature as the first adjusted feature of the target node.
[0102] Step 308: Adjust the second feature according to the second adjustment coefficient to obtain a second adjusted feature of the adjacent node.
[0103] The first adjusted feature is a feature obtained by adjusting the first feature according to the first adjustment coefficient. Specifically, the computer device can adjust the second feature of the adjacent node after the previous round of feature transfer according to the second adjustment coefficient, and use the adjusted feature as the second adjusted feature of the adjacent node.
[0104] Step 310: Determine the feature difference between the target node and the adjacent nodes according to the first adjustment feature and the second adjustment feature.
[0105] The second adjusted feature is a feature obtained by adjusting the second feature according to the second adjustment coefficient. Specifically, the computer device may use the difference between the first adjusted feature and the second adjusted feature as the feature difference between the target node and the adjacent node.
[0106] In the above embodiment, for each adjacent node, the first feature is adjusted according to the first adjustment coefficient for the target node to obtain the first adjusted feature of the target node, and the second feature is adjusted according to the second adjustment coefficient for the adjacent node to obtain the second adjusted feature of the adjacent node. Then, based on the first adjustment feature and the second adjustment feature, the feature difference between the target node and the adjacent node can be accurately determined, thereby improving the accuracy of the feature difference between the target node and the adjacent node.
[0107] In one embodiment, the initial feature similarity between the target node and the adjacent nodes is the first initial feature similarity; for each adjacent node, a first adjustment coefficient for the target node and a second adjustment coefficient for the adjacent node are determined, including: obtaining a first similarity comprehensive value of the target node; the first similarity comprehensive value is determined based on the first initial feature similarity between the target node and each adjacent node; for each adjacent node, obtaining a second similarity comprehensive value of the adjacent node; the second similarity comprehensive value is determined based on the second initial feature similarity between the adjacent node and each target adjacent node; the target adjacent node is a node connected to the adjacent node by an edge in the network graph; according to the ratio of the first initial feature similarity to the first similarity comprehensive value, the first adjustment coefficient for the target node is determined; according to the ratio of the first initial feature similarity to the second similarity comprehensive value, the second adjustment coefficient for the adjacent node is determined.
[0108] The first initial feature similarity is the initial feature similarity between the target node and the adjacent nodes, and the second initial feature similarity is the initial feature similarity between the adjacent nodes and each target adjacent node.
[0109] Specifically, the target node has at least one adjacent node, and the adjacent node has at least one target adjacent node. The computer device may determine the first similarity comprehensive value of the target node based on the first initial feature similarity between the target node and each adjacent node. For each adjacent node, the computer device may determine the second similarity comprehensive value of the adjacent node based on the second initial feature similarity between the adjacent node and each target adjacent node. The computer device may determine the first adjustment coefficient for the target node based on the ratio of the first initial feature similarity to the first similarity comprehensive value, and determine the second adjustment coefficient for the adjacent node based on the ratio of the first initial feature similarity to the second similarity comprehensive value.
[0110] In one embodiment, the computer device may perform an addition operation on the first initial feature similarities between the target node and each adjacent node, and use the added result as the first similarity comprehensive value of the target node.
[0111] In one embodiment, for each adjacent node, the computer device may perform an addition operation on the second initial feature similarities between the adjacent node and each target adjacent node, and use the added result as the second similarity comprehensive value of the adjacent node.
[0112] In one embodiment, the computer device may use the ratio of the first initial feature similarity to the first similarity comprehensive value directly as the first adjustment coefficient for the target node, and use the ratio of the first initial feature similarity to the second similarity comprehensive value directly as the second adjustment coefficient for the adjacent node.
[0113] In the above embodiment, for each adjacent node, the first adjustment coefficient for the target node can be accurately determined by the ratio of the first initial feature similarity to the first similarity comprehensive value of the target node, thereby improving the accuracy of the first adjustment coefficient. At the same time, the second adjustment coefficient for the adjacent node can be accurately determined by the ratio of the first initial feature similarity to the second similarity comprehensive value of the adjacent node, thereby improving the accuracy of the second adjustment coefficient.
[0114] In one embodiment, based on feature differences and initial feature similarities between the target node and adjacent nodes, the feature transfer coefficient of this round of the target node is determined; including: based on feature differences and initial feature similarities between the target node and adjacent nodes, the initial feature transfer coefficient of this round of the target node is determined; according to a first similarity comprehensive value, the initial feature transfer coefficient of this round is adjusted to obtain the feature transfer coefficient of this round of the target node; the first similarity comprehensive value is determined based on the initial feature similarities between the target node and each adjacent node.
[0115] Specifically, the computer device may first determine the current round initial feature transfer coefficient of the target node based on the feature difference and the initial feature similarity between the target node and the adjacent nodes. Then, the computer device may determine a first similarity comprehensive value according to the initial feature similarity between the target node and each adjacent node, and adjust the current round initial feature transfer coefficient according to the first similarity comprehensive value to obtain the current round feature transfer coefficient of the target node.
[0116] In one embodiment, the computer device may use the first similarity comprehensive value as the weight of the current round initial feature transfer coefficient to perform a weighted operation on the current round initial feature transfer coefficient to obtain the current round feature transfer coefficient of the target node.
[0117] In the above embodiment, the initial feature transfer coefficient of the target node in this round can be accurately determined through feature differences and the initial feature similarities between the target node and the adjacent nodes. The initial feature transfer coefficient of this round can be adjusted according to the first similarity comprehensive value to obtain the feature transfer coefficient of this round of the target node. In this way, the accuracy of the feature transfer coefficient of this round can be improved.
[0118] In one embodiment, Figure 4 As shown, based on the feature transfer coefficient of this round, determining the transfer feature transferred from the first feature to this round includes the following processing steps:
[0119] Step 402: determine a first weighting coefficient for a first feature.
[0120] Step 404: adjust the first weighting coefficient based on the characteristic transfer coefficient of this round to obtain a second weighting coefficient.
[0121] Step 406: adjust the first feature according to the second weighting coefficient, and use the adjusted feature as the transfer feature transferred from the first feature to the current round.
[0122] The first weighting coefficient is a coefficient used as an initial weight of the first feature, and the second weighting coefficient is a coefficient used as a final weight of the first feature.
[0123] Specifically, the computer device may determine a first weighting coefficient for the first feature, and adjust the first weighting coefficient based on the feature transfer coefficient of this round to obtain a second weighting coefficient. Furthermore, the computer device may use the second weighting coefficient as the weight of the first feature to perform weighted calculation on the first feature, and use the weighted calculated feature as the transfer feature transferred from the first feature to this round.
[0124] In the above embodiment, the first weighting coefficient for the first feature can be adjusted through the feature transfer coefficient of this round to obtain the second weighting coefficient. The first feature can be adjusted through the second weighting coefficient, and the adjusted feature can be used as the transfer feature transferred from the first feature to this round. In this way, the accuracy of the transfer feature can be improved, thereby further improving the accuracy of node classification.
[0125] In one embodiment, determining a first weighting coefficient for a first feature includes: determining a ratio of a feature transfer coefficient of this round to a first similarity comprehensive value; the first similarity comprehensive value is determined based on an initial feature similarity between a target node and each adjacent node; determining a first weighting coefficient for the first feature based on the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value and a preset feature transfer hyperparameter.
[0126] Among them, the preset feature transfer hyperparameters are parameters that are pre-set during the feature iterative transfer process.
[0127] Specifically, the computer device may determine the first similarity comprehensive value according to the initial feature similarity between the target node and each adjacent node. Further, the computer device may determine the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value, and determine the first weighting coefficient for the first feature according to the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value and the preset feature transfer hyperparameter.
[0128] In one embodiment, the computer device may add the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value and a preset feature transfer hyperparameter, and use the result of the addition as the first weighting coefficient for the first feature.
[0129] In the above embodiment, the first weighting coefficient for the first feature can be accurately determined through the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value and the preset feature transfer hyperparameters, thereby further improving the node classification accuracy.
[0130] In one embodiment, the transferred features are fused with the target initial features of the object represented by the target node to obtain the features of the target node after the current round of feature transfer, including: determining a third weighting coefficient for the target initial features of the object represented by the target node; adjusting the target initial features according to the third weighting coefficient to obtain the retained features transferred from the target initial features to the current round; and fusing the transferred features with the retained features to obtain the features of the target node after the current round of feature transfer.
[0131] Among them, the third weighting coefficient is the coefficient used as the weight of the target initial feature. The retained feature is the feature that the target initial feature transfers to this round. It can be understood that the retained feature is the feature that the target node actually obtains from the target initial feature. It can be understood that the target initial feature can be fully transferred to this round, or only part of it can be transferred to this round. The part of the feature transferred to this round is the retained feature.
[0132] Specifically, the computer device may determine a third weighting coefficient of the target initial feature of the object represented by the target node. The computer device may use the third weighting coefficient as the weight of the target initial feature to perform a weighted operation on the target initial feature, and use the result of the weighted operation as the retained feature transferred from the target initial feature to the current round. Furthermore, the computer device may fuse the transferred feature with the retained feature to obtain the feature of the target node after the feature transfer in this round.
[0133] In one embodiment, the computer device may add the transferred features to the retained features, and use the added result as the feature of the target node after the current round of feature transfer.
[0134] In the above embodiment, the target initial feature can be adjusted by the third weighting coefficient of the target initial feature of the object represented by the target node to obtain the retained feature transferred from the target initial feature to the current round. By fusing the transferred feature with the retained feature, the feature of the target node after the feature transfer in the current round can be obtained, so that the accuracy of the feature of the target node after the feature transfer in the current round can be improved.
[0135] In one embodiment, determining a third weighting coefficient for a target initial feature of an object represented by a target node includes: adjusting the first weighting coefficient according to a preset feature transfer hyperparameter to obtain a third weighting coefficient for the target initial feature of the object represented by the target node.
[0136] Specifically, the computer device may use the preset feature transfer hyperparameter as the weight of the first weighting coefficient to perform a weighted operation on the first weighting coefficient, and use the result of the weighted operation as the third weighting coefficient of the target initial feature of the object represented by the target node.
[0137] In the above embodiment, by adjusting the first weighting coefficient through the preset feature transfer hyperparameter, a third weighting coefficient for the target initial feature of the object represented by the target node can be obtained, thereby improving the accuracy of the third weighting coefficient.
[0138] In one embodiment, the node classification method of the present application may involve a feature transfer mechanism, through which feature iterative transfer can be implemented to obtain target features of each node in the network graph. The feature iterative transfer can be expressed by the following formula:
[0139] F (k+1) =α (k) D -1 / 2 M (k) D -1 / 2 F (k) +β (k) X,k=0,1,2,..,K
[0140] Among them, K represents the number of iterations of feature transfer, F (k) represents the feature of the node after the kth round of feature transfer, F (k+1) represents the feature of the node after the k+1th round of feature transfer, X represents the target initial feature of the object represented by the node, and M (k) represents the characteristic transfer coefficient of the kth round, α (k) represents the first weighted coefficient of the node feature after the kth round of feature transfer, β (k) represents the third weighted coefficient of the target initial feature of the object represented by the node after the kth round of feature transfer, and D represents the first similarity comprehensive value. It can be understood that if F(k+1) represents the transmission characteristics of the node in this round, then F (k) Represents the first feature of the node after the previous round of feature transfer.
[0141] In one embodiment, the node's feature transfer coefficient M in the kth round (k) , can be calculated by the following formula:
[0142]
[0143] Among them, i represents the target node, j represents the adjacent node of the target node i, represents the features of target node i after the kth round of feature transfer, represents the features of the neighboring node j after the kth round of feature transfer, W i,j represents the initial feature similarity between the target node i and the adjacent node j, p represents a pre-set hyperparameter, and p is a constant.
[0144] In one embodiment, the first weight coefficient α of the feature of the target node i after the kth round of feature transfer is (k) , can be calculated by the following formula:
[0145]
[0146] Where N represents the total number of neighboring nodes j, μ represents a pre-set hyperparameter, and μ is a constant.
[0147] In one embodiment, after the kth round of feature transfer, the third weighting coefficient β of the target initial feature of the object represented by the target node i is (k) , can be calculated by the following formula:
[0148]
[0149] In one embodiment, the node classification result is predicted by a trained node classification model; the node classification model includes a feature extraction network and a classification prediction network with a first network parameter; taking the next round as the current round, returning to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network diagram for iteration until the iteration stop condition is reached, and obtaining the target feature of each node in the network diagram after the last round of feature transfer, including: through the feature extraction network, taking the next round as the current round, returning to the step of determining the feature difference between the target node and the adjacent nodes for iteration until the iteration stop condition is reached, and outputting the target feature of each node in the network diagram after the last round of feature transfer; based on the target feature of each node in the network diagram, classifying each node to obtain a node classification result, including: inputting the target feature of each node in the network diagram into the classification prediction network to adjust the target feature based on the first network parameter, and classifying each node based on the adjusted feature to obtain a node classification result.
[0150] The feature extraction network is a network used to extract the features of each node in the network graph. The classification prediction network is a network used to classify each node in the network graph. The first network parameter is a network parameter in the classification prediction network.
[0151] Specifically, the computer device can use the feature extraction network to take the next round as the current round, return to each target node in the network diagram, determine the feature difference between the target node and the adjacent nodes, and determine the current round feature transfer coefficient of the target node based on the feature difference and the initial feature similarity between the target node and the adjacent nodes; based on the current round feature transfer coefficient, determine the transfer feature transferred from the first feature to the current round, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the current round feature transfer, and iterate until the iteration stop condition is reached, and the feature extraction network can output the target feature of each node in the network diagram after the last round of feature transfer. The computer device can input the target feature of each node in the network diagram into the classification prediction network to adjust the target feature based on the first network parameter, and classify each node based on the adjusted feature to obtain a node classification result.
[0152] In the above embodiment, through the feature extraction network, the next round can be used as the current round, and the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network diagram can be returned to iterate until the iteration stop condition is reached, and the target features of each node in the network diagram after the last round of feature transfer can be output to improve the accuracy of the target features. At the same time, by inputting the target features of each node in the network diagram into the classification prediction network, the target features can be adjusted based on the first network parameters, and each node can be classified based on the adjusted features, so that a more accurate node classification result can be obtained, further improving the accuracy of node classification.
[0153] In one embodiment, the network parameters of the feature extraction network include a second network parameter; the second network parameter is a network parameter used to initialize the feature; the method also includes: obtaining the initial features of the object represented by the target node; inputting the initial features into the feature extraction network to adjust the initial features based on the second network parameter to obtain the target initial features of the object represented by the target node.
[0154] The second network parameter is a network parameter in the feature extraction network. The initial feature is the most initial feature of the object represented by the node. It can be understood that the initial feature is a feature obtained by extracting features based on the object behavior data of the object represented by the node.
[0155] Specifically, the computer device may obtain the object behavior data of the object represented by the node, and perform feature extraction based on the object behavior data of the object represented by the node to obtain the initial features of the object represented by the target node. Furthermore, the computer device may input the initial features into the feature extraction network to adjust the initial features based on the second network parameters to obtain the target initial features of the object represented by the target node.
[0156] In the above embodiment, by inputting the initial features of the object represented by the target node into the feature extraction network, the initial features can be adjusted based on the second network parameters to obtain the target initial features of the object represented by the target node, thereby improving the accuracy of the target initial features.
[0157] In one embodiment, the node classification model can be constructed based on the above-mentioned feature transfer mechanism, and the model architecture of the node classification model can be expressed as:
[0158] F (0) =ReLU(XΘ (1) ),
[0159] F (k+1) =α (k) D -1 / 2 M (k) D -1 / 2 F (k) +β(k) F (0) ,k=0,1,…,K-1,
[0160] Z = softmax(F (K) Θ (2) )
[0161] Among them, ReLU() represents the feature extraction network, softmax() represents the classification prediction network, and F (0) represents the target initial feature of the node, F (K) represents the target feature of the node after the last round of feature transfer, Θ (1) represents the network parameters of the feature extraction network, i.e., the second network parameters, Θ (2) It represents the network parameters of the classification prediction network, that is, the first network parameters, and Z represents the node classification result.
[0162] In one embodiment, Figure 5 As shown, the computer device can obtain the initial features of the objects represented by each node in the network diagram, and input the initial features into the feature extraction network in the node classification model, so as to adjust the initial features based on the second network parameters of the feature extraction network, and obtain the target initial features of the objects represented by each node. The computer device can calculate the feature transfer coefficient, the first weighting coefficient and the third weighting coefficient of each round in the feature iterative transfer process, so as to determine the features of each node after each round of feature transfer, until the iteration stop condition is reached, and obtain the target features of each node in the network diagram after the last round of feature transfer. The computer device can input the target features of each node in the network diagram into the classification prediction network in the node classification model, so as to adjust the target features based on the first network parameters of the classification prediction network, and classify each node based on the adjusted features to obtain the node classification results.
[0163] like Figure 6 As shown, in one embodiment, a node classification method is provided, and the method specifically includes the following steps:
[0164] Step 602: Obtain initial features of the object represented by the target node in the network graph.
[0165] Step 604: input the initial features into a feature extraction network in the node classification model and having second network parameters, so as to adjust the initial features based on the second network parameters to obtain target initial features of the object represented by the target node.
[0166] It can be understood that after the initial features of the target are determined, multiple rounds of feature transfer iterative processing can be performed according to steps 606 to 626.
[0167] Step 606, during this round of feature transfer, the first feature of the target node after the previous round of feature transfer is obtained through the feature extraction network, and the second feature of the adjacent node after the previous round of feature transfer is obtained; the adjacent node is a node in the network graph that is connected to the target node through an edge; there is at least one adjacent node.
[0168] Step 608, for each adjacent node, determine a first adjustment coefficient for the target node and a second adjustment coefficient for the adjacent node; the first adjustment coefficient is determined based on the correlation between the adjacent node and the target node compared to the first reference node; the first reference node is a node adjacent to the target node and other than the adjacent node; the second adjustment coefficient is determined based on the correlation between the target node and the adjacent node compared to the second reference node; the second reference node is a node adjacent to the adjacent node and other than the target node.
[0169] Step 610: adjust the first feature according to the first adjustment coefficient to obtain the first adjusted feature of the target node; and adjust the second feature according to the second adjustment coefficient to obtain the second adjusted feature of the adjacent node.
[0170] Step 612, determining the feature difference between the target node and the adjacent node based on the first adjustment feature and the second adjustment feature; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer.
[0171] Step 614, based on the feature difference and the initial feature similarity between the target node and the adjacent nodes, determine the initial feature transfer coefficient of the target node in this round.
[0172] Step 616, adjusting the initial feature transfer coefficient of this round according to the first similarity comprehensive value to obtain the feature transfer coefficient of this round of the target node; the first similarity comprehensive value is determined based on the initial feature similarities between the target node and each adjacent node.
[0173] Step 618, determine a first weighting coefficient for the first feature; adjust the first weighting coefficient based on the feature transfer coefficient of this round to obtain a second weighting coefficient.
[0174] Step 620, adjusting the first feature according to the second weighting coefficient, and using the adjusted feature as the transfer feature transferred from the first feature to the current round.
[0175] Step 622, determining a third weighting coefficient of the target initial feature of the object represented by the target node; adjusting the target initial feature according to the third weighting coefficient to obtain a retained feature transferred from the target initial feature to this round.
[0176] Step 624, the transferred features are merged with the retained features to obtain the features of the target node after this round of feature transfer.
[0177] Step 626, taking the next round as the current round, returns to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph to iterate until the iteration stop condition is reached, and obtains the target features of each node in the network graph after the last round of feature transfer.
[0178] Step 628, input the target features of each node in the network diagram into the classification prediction network in the node classification model and having the first network parameters, so as to adjust the target features based on the first network parameters, and classify each node based on the adjusted features to obtain the node classification results.
[0179] The present application also provides an application scenario, which applies the above-mentioned node classification method. Specifically, the node classification method can be applied to the scenario of classifying each node in the heterogeneous network diagram. It can be understood that the heterogeneous network diagram does not pre-default to satisfy the same-kinship assumption, that is, the two nodes connected by edges in the heterogeneous network diagram are most likely not similar. The computer device can obtain the initial features of the object represented by the target node in the heterogeneous network diagram. The initial features are input into a feature extraction network with a second network parameter in the node classification model to adjust the initial features based on the second network parameter to obtain the target initial features of the object represented by the target node.
[0180] Through the feature extraction network, the first feature of the target node after the last round of feature transfer is obtained, and the second feature of the adjacent node after the last round of feature transfer is obtained; the adjacent node is a node connected to the target node through an edge in the heterogeneous network diagram; there is at least one adjacent node. For each adjacent node, a first adjustment coefficient for the target node and a second adjustment coefficient for the adjacent node are determined; the first adjustment coefficient is determined based on the correlation between the adjacent node and the target node compared with the first reference node; the first reference node is a node adjacent to the target node and other than the adjacent node; the second adjustment coefficient is determined based on the correlation between the target node and the adjacent node compared with the second reference node; the second reference node is a node adjacent to the adjacent node and other than the target node. According to the first adjustment coefficient, the first feature is adjusted to obtain the first adjusted feature of the target node; according to the second adjustment coefficient, the second feature is adjusted to obtain the second adjusted feature of the adjacent node. According to the first adjustment feature and the second adjustment feature, the feature difference between the target node and the adjacent node is determined; the feature difference is the difference between the first feature of the target node after the last round of feature transfer and the second feature of the adjacent node after the last round of feature transfer.
[0181] Based on the feature difference and the initial feature similarity between the target node and the adjacent nodes, the initial feature transfer coefficient of the target node in this round is determined. The initial feature transfer coefficient of this round is adjusted according to the first similarity comprehensive value to obtain the feature transfer coefficient of the target node in this round; the first similarity comprehensive value is determined based on the initial feature similarity between the target node and each adjacent node. Determine the first weighting coefficient for the first feature; adjust the first weighting coefficient based on the feature transfer coefficient of this round to obtain the second weighting coefficient. Adjust the first feature according to the second weighting coefficient, and use the adjusted feature as the transfer feature transferred from the first feature to this round. Determine the third weighting coefficient of the target initial feature of the object represented by the target node; adjust the target initial feature according to the third weighting coefficient to obtain the retained feature transferred from the target initial feature to this round. Fuse the transferred feature with the retained feature to obtain the feature of the target node after the feature transfer in this round.
[0182] The next round is taken as the current round, and the step of determining the feature difference between the target node and the adjacent nodes for each target node in the heterogeneous network diagram is returned to iterate until the iteration stop condition is reached, and the target feature of each node in the heterogeneous network diagram after the last round of feature transfer is obtained. The target feature of each node in the heterogeneous network diagram is input into the classification prediction network with the first network parameter in the node classification model, so as to adjust the target feature based on the first network parameter, and classify each node in the heterogeneous network diagram based on the adjusted feature, so as to obtain the node classification result in the heterogeneous network diagram.
[0183] It can be understood that due to the particularity of heterogeneous network graphs, the substantive contents represented by adjacent nodes in heterogeneous network graphs are likely to be dissimilar. However, the initial feature similarity between adjacent nodes in heterogeneous network graphs is often relatively high. Therefore, if the nodes in the heterogeneous network graph are directly classified based on the initial feature similarity of each node in the heterogeneous network graph, the accuracy of node classification will be relatively low. Taking the network link graph as an example, for links belonging to the same parent web page, the nodes corresponding to these links will build edges and become adjacent nodes. Since they all belong to the same parent web page, the initial feature similarity between these adjacent nodes will also be relatively high. However, in fact, the contents of the sub-web pages corresponding to these links may be very different or even completely different. In this case, if the network link graph is classified by the initial feature similarity, the node classification will be inaccurate. Compared with the traditional method of directly classifying each node in the heterogeneous network diagram based on the initial feature similarity between the inherent features of the objects represented by each node in the heterogeneous network diagram, the present application does not directly classify each node in the heterogeneous network diagram based on the initial feature similarity between the inherent features of the objects represented by each node in the heterogeneous network diagram, but first based on the feature difference between the feature of the target node in the heterogeneous network diagram after the previous round of feature transfer and the feature of the adjacent node in the heterogeneous network diagram after the previous round of feature transfer, the initial feature similarity between the target node and the adjacent node is continuously updated to obtain the feature transfer coefficient of each round of the target node, and then the transfer feature of each round is determined based on the feature transfer coefficient of each round, and the feature of each node in the heterogeneous network diagram is continuously updated based on the transfer feature. That is, the node classification of the heterogeneous network diagram is creatively performed by iteratively transferring node features, which can effectively narrow the feature gap between similar nodes and increase the feature gap between dissimilar nodes, and then the node classification is performed based on the final feature of each node after the iterative transfer stops, which can significantly improve the accuracy of node classification of the heterogeneous network diagram.
[0184] The present application also provides an application scenario, which applies the above-mentioned node classification method. Specifically, the node classification method can be applied to the scenario of classifying each node in the same-kinship network diagram. It can be understood that the same-kinship assumption has been pre-defaulted for the same-kinship network diagram, that is, the two nodes connected by an edge in the same-kinship network diagram have a higher similarity. Through the node classification method of the present application, a computer device can obtain the initial features of the object represented by the target node in the same-kinship network diagram. The initial features are input into a feature extraction network with a second network parameter in the node classification model to adjust the initial features based on the second network parameter to obtain the target initial features of the object represented by the target node.
[0185] The computer device can obtain the first feature of the target node after the last round of feature transfer and the second feature of the adjacent node after the last round of feature transfer through the feature extraction network; the adjacent node is a node connected to the target node through an edge in the same-kinship network diagram; there is at least one adjacent node. For each adjacent node, determine the first adjustment coefficient for the target node and the second adjustment coefficient for the adjacent node; the first adjustment coefficient is determined based on the correlation between the adjacent node and the target node compared with the first reference node; the first reference node is a node adjacent to the target node and other than the adjacent node; the second adjustment coefficient is determined based on the correlation between the target node and the adjacent node compared with the second reference node; the second reference node is a node adjacent to the adjacent node and other than the target node. According to the first adjustment coefficient, adjust the first feature to obtain the first adjusted feature of the target node; according to the second adjustment coefficient, adjust the second feature to obtain the second adjusted feature of the adjacent node. According to the first adjustment feature and the second adjustment feature, determine the feature difference between the target node and the adjacent node; the feature difference is the difference between the first feature of the target node after the last round of feature transfer and the second feature of the adjacent node after the last round of feature transfer.
[0186] The computer device can determine the initial feature transfer coefficient of the target node in this round based on the feature difference and the initial feature similarity between the target node and the adjacent nodes. The initial feature transfer coefficient of this round is adjusted according to the first similarity comprehensive value to obtain the feature transfer coefficient of the target node in this round; the first similarity comprehensive value is determined according to the initial feature similarity between the target node and each adjacent node. Determine the first weighting coefficient for the first feature; adjust the first weighting coefficient based on the feature transfer coefficient of this round to obtain the second weighting coefficient. Adjust the first feature according to the second weighting coefficient, and use the adjusted feature as the transfer feature transferred from the first feature to this round. Determine the third weighting coefficient of the target initial feature of the object represented by the target node; adjust the target initial feature according to the third weighting coefficient to obtain the retained feature transferred from the target initial feature to this round. Fuse the transferred feature with the retained feature to obtain the feature of the target node after the feature transfer in this round.
[0187] The computer device can use the next round as the current round, return to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the same-kinship network diagram to iterate until the iteration stop condition is reached, and obtain the target feature of each node in the same-kinship network diagram after the last round of feature transfer. The target feature of each node in the same-kinship network diagram is input into a classification prediction network with a first network parameter in a node classification model to adjust the target feature based on the first network parameter, and classify each node in the same-kinship network diagram based on the adjusted feature to obtain a node classification result in the same-kinship network diagram.
[0188] It can be understood that, because the initial feature similarity between the inherent features of the objects represented by each node in the same-kinship network diagram may not be accurate enough due to some reasons, if each node in the same-kinship network diagram is directly classified based on the initial feature similarity between the inherent features of the objects represented by each node in the same-kinship network diagram, the classification accuracy of each node in the same-kinship network diagram is low. Compared with the traditional method of directly classifying each node in the same-kinship network diagram based on the initial feature similarity between the inherent features of the objects represented by each node in the same-kinship network diagram, the present application does not directly classify each node in the same-kinship network diagram based on the initial feature similarity between the inherent features of the objects represented by each node in the same-kinship network diagram, but first based on the feature difference between the feature of the target node in the same-kinship network diagram after the previous round of feature transfer and the feature of the adjacent node in the same-kinship network diagram after the previous round of feature transfer, the initial feature similarity between the target node and the adjacent node is continuously updated to obtain the feature transfer coefficient of each round of the target node, and then the transfer feature of each round is determined based on the feature transfer coefficient of each round, and the features of each node in the same-kinship network diagram are continuously updated based on the transfer feature. That is, creatively classifying nodes in the kinship network graph by iteratively transmitting node features can effectively narrow the feature gap between similar nodes and increase the feature gap between dissimilar nodes, and then classifying nodes based on the final features of each node after the iterative transmission stops, which can significantly improve the accuracy of node classification in the kinship network graph.
[0189] It can be understood that the network diagram in each embodiment of the present application can be at least one of a literature citation network diagram, a protein network diagram or a web link network diagram, etc. The node classification method in each embodiment of the present application can accurately classify objects such as literature, proteins and network links, thereby playing an important role in literature research, protein analysis and Internet information search, etc. Among them, the literature citation network belongs to the same-kinship network diagram, and the protein network and the web link network belong to the different-kinship network diagram.
[0190] It should be understood that, although each step in the flow chart of the above-mentioned embodiments is shown in order, these steps are not necessarily performed in order. Unless there is a clear explanation in this article, the execution of these steps does not have strict order restrictions, and these steps can be performed in other orders. Moreover, at least a portion of the steps in the above-mentioned embodiments may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these sub-steps or stages is not necessarily performed in order, but can be performed in turn or alternately with at least a portion of other steps or sub-steps or stages of other steps.
[0191] In one embodiment, Figure 7 As shown, a node classification device 700 is provided. The device can adopt a software module or a hardware module, or a combination of the two to become a part of a computer device. The device specifically includes:
[0192] Determination module 702 is used to determine the feature difference between the target node and the adjacent nodes for each target node in the network diagram during this round of feature transfer; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer; based on the feature difference and the initial feature similarity between the target node and the adjacent node, determine the feature transfer coefficient of the target node in this round.
[0193] The fusion module 704 is used to determine the transfer feature transferred from the first feature to the current round based on the feature transfer coefficient of the current round, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the feature transfer of the current round.
[0194] The determination module 702 is also used to take the next round as the current round, return to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network diagram for iteration until the iteration stop condition is reached, and obtain the target features of each node in the network diagram after the last round of feature transfer.
[0195] The classification module 706 is used to classify each node based on the target features of each node in the network graph to obtain a node classification result.
[0196] In one embodiment, the target initial feature of the object represented by the target node is a first initial feature; and the device further includes:
[0197] The calculation module 708 is used to obtain the second initial feature of the object represented by the adjacent node; perform similarity calculation on the first initial feature and the second initial feature to obtain the initial feature similarity between the target node and the adjacent node.
[0198] In one embodiment, the determination module 702 is also used to obtain the first feature of the target node after the previous round of feature transfer, and to obtain the second feature of the adjacent node after the previous round of feature transfer; the adjacent node is a node in the network graph that is connected to the target node through an edge; there is at least one adjacent node; for each adjacent node, a first adjustment coefficient for the target node and a second adjustment coefficient for the adjacent node are determined; the first adjustment coefficient is determined based on the correlation between the adjacent node and the target node compared with the first reference node; the first reference node is a node adjacent to the target node and other than the adjacent node; the second adjustment coefficient is determined based on the correlation between the target node and the adjacent node compared with the second reference node; the second reference node is a node adjacent to the adjacent node and other than the target node; according to the first adjustment coefficient, the first feature is adjusted to obtain the first adjusted feature of the target node; according to the second adjustment coefficient, the second feature is adjusted to obtain the second adjusted feature of the adjacent node; according to the first adjustment feature and the second adjustment feature, the feature difference between the target node and the adjacent node is determined.
[0199] In one embodiment, the initial feature similarity between the target node and the adjacent nodes is the first initial feature similarity; the determination module 702 is also used to obtain a first similarity comprehensive value of the target node; the first similarity comprehensive value is determined based on the first initial feature similarity between the target node and each adjacent node; for each adjacent node, a second similarity comprehensive value of the adjacent node is obtained; the second similarity comprehensive value is determined based on the second initial feature similarity between the adjacent node and each target adjacent node; the target adjacent node is a node connected to the adjacent node through an edge in the network graph; according to the ratio of the first initial feature similarity to the first similarity comprehensive value, a first adjustment coefficient for the target node is determined; according to the ratio of the first initial feature similarity to the second similarity comprehensive value, a second adjustment coefficient for the adjacent node is determined.
[0200] In one embodiment, the determination module 702 is also used to determine the current round initial feature transfer coefficient of the target node based on the feature difference and the initial feature similarity between the target node and the adjacent nodes; adjust the current round initial feature transfer coefficient according to the first similarity comprehensive value to obtain the current round feature transfer coefficient of the target node; the first similarity comprehensive value is determined based on the initial feature similarity between the target node and each adjacent node.
[0201] In one embodiment, the fusion module 704 is also used to determine a first weighting coefficient for the first feature; adjust the first weighting coefficient based on the feature transfer coefficient of this round to obtain a second weighting coefficient; adjust the first feature according to the second weighting coefficient, and use the adjusted feature as the transfer feature transferred from the first feature to this round.
[0202] In one embodiment, the fusion module 704 is also used to determine the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value; the first similarity comprehensive value is determined based on the initial feature similarity between the target node and each adjacent node; based on the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value, and the preset feature transfer hyperparameters, determine the first weighting coefficient for the first feature.
[0203] In one embodiment, the fusion module 704 is also used to determine a third weighting coefficient of the target initial feature of the object represented by the target node; adjust the target initial feature according to the third weighting coefficient to obtain the retained feature transferred from the target initial feature to this round; and fuse the transferred feature with the retained feature to obtain the feature of the target node after the feature transfer in this round.
[0204] In one embodiment, the fusion module 704 is further configured to adjust the first weighting coefficient according to a preset feature transfer hyperparameter to obtain a third weighting coefficient for the target initial feature of the object represented by the target node.
[0205] In one embodiment, the node classification result is predicted by a trained node classification model; the node classification model includes a feature extraction network and a classification prediction network with a first network parameter; the determination module 702 is also used to use the feature extraction network to take the next round as the current round, return to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network diagram for iteration until the iteration stop condition is reached, and output the target feature of each node in the network diagram after the last round of feature transfer; the classification module 706 is also used to input the target feature of each node in the network diagram into the classification prediction network to adjust the target feature based on the first network parameter, and classify each node based on the adjusted feature to obtain the node classification result.
[0206] In one embodiment, the network parameters of the feature extraction network include a second network parameter; the second network parameter is a network parameter used to initialize the feature; the device further includes:
[0207] The acquisition module 710 is used to acquire the initial features of the object represented by the target node; input the initial features into the feature extraction network to adjust the initial features based on the second network parameters to obtain the target initial features of the object represented by the target node.
[0208] In one embodiment, reference Figure 8 The node classification device 700 also includes a calculation module 708 and an acquisition module 710.
[0209] The node classification device, in the process of this round of feature transfer, determines the feature difference between the target node and the adjacent nodes for each target node in the network diagram; the feature difference is the difference between the first feature of the target node after the previous round of feature transfer and the second feature of the adjacent node after the previous round of feature transfer. Based on the feature difference and the initial feature similarity between the target node and the adjacent node, the feature transfer coefficient of the target node in this round can be determined. Based on the feature transfer coefficient of this round, the transfer feature transferred from the first feature to this round can be determined, and the transfer feature can be fused with the target initial feature of the object represented by the target node to obtain the feature of the target node after this round of feature transfer. The next round is taken as this round, and the step of determining the feature difference between the target node and the adjacent node for each target node in the network diagram is returned to iterate until the iteration stop condition is reached, and the target feature of each node in the network diagram after the last round of feature transfer can be obtained. Based on the target feature of each node in the network diagram, each node is classified to obtain the node classification result. Compared with the traditional method of directly classifying nodes based on the similarity between the inherent features of the objects represented by the nodes, the present application can continuously update the initial feature similarity between the target node and the adjacent nodes based on the feature difference between the target node and the adjacent nodes, so as to obtain the feature transfer coefficient of each round of the target node, and then determine the transfer feature of each round based on the feature transfer coefficient of each round, so as to continuously update the features of each node in the network diagram based on the transfer feature, while narrowing the feature gap between similar nodes and increasing the feature gap between dissimilar nodes, so as to achieve accurate classification of nodes and improve the accuracy of node classification.
[0210] Each module in the above-mentioned node classification device can be implemented in whole or in part by software, hardware and a combination thereof. Each of the above-mentioned modules can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to each of the above modules.
[0211] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Fig. 9As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a node classification method is implemented.
[0212] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Fig.10 As shown. The computer device includes a processor, a memory, an input / output interface, a communication interface, a display unit and an input device. The processor, the memory and the input / output interface are connected via a system bus, and the communication interface, the display unit and the input device are connected to the system bus via the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be implemented through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a node classification method is implemented. The display unit of the computer device is used to form a visually visible image, and can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen. The input device of the computer device can be a touch layer covered on the display screen, or a button, trackball or touchpad set on the computer device casing, or an external keyboard, touchpad or mouse, etc.
[0213] Those skilled in the art will understand that Fig. 9 and Fig.10The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0214] In one embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above method embodiments when executing the computer program.
[0215] In one embodiment, a computer-readable storage medium is provided, storing a computer program, which implements the steps in the above method embodiments when executed by a processor.
[0216] In one embodiment, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.
[0217] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.
[0218] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory or optical memory, etc. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).
[0219] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0220] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.
Claims
1. A node classification method, characterized in that: The method comprises: In the process of this round of feature transfer, for each target node in the network graph, the first feature of the target node after the previous round of feature transfer is obtained, and the second feature of the adjacent node after the previous round of feature transfer is obtained; the adjacent node is a node in the network graph connected to the target node through an edge; there is at least one adjacent node; For each adjacent node, the feature difference between the target node and the adjacent node is determined according to the first adjustment feature of the target node and the second adjustment feature of the adjacent node; the first adjustment feature of the target node is obtained by adjusting the first feature according to a first adjustment coefficient; the first adjustment coefficient is determined according to the correlation between the adjacent node and the target node compared with a first reference node; the first reference node is a node adjacent to the target node and other than the adjacent node; the second adjustment feature of the adjacent node is obtained by adjusting the second feature according to a second adjustment coefficient; the second adjustment coefficient is determined according to the correlation between the target node and the adjacent node compared with a second reference node; the second reference node is a node adjacent to the adjacent node and other than the target node; Based on the feature difference and the initial feature similarity between the target node and the adjacent nodes, determine the current round feature transfer coefficient of the target node; wherein the current round feature transfer coefficient is the feature transfer coefficient of the node in the current round feature transfer process, and the feature transfer coefficient is used to characterize the amount of feature transfer; Based on the feature transfer coefficient of this round, determine the transfer feature transferred from the first feature to this round, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the feature transfer of this round; Taking the next round as the current round, returning to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph to iterate until the iteration stop condition is reached, and obtaining the target feature of each node in the network graph after the last round of feature transfer; Based on the target features of each node in the network graph, each node is classified to obtain a node classification result.
2. The method according to claim 1, characterized in that The target initial feature of the object represented by the target node is a first initial feature; the method comprises: Acquire a second initial feature of the object represented by the adjacent node; Similarity calculation is performed on the first initial feature and the second initial feature to obtain the initial feature similarity between the target node and the adjacent node.
3. The method according to claim 1, characterized in that The initial feature similarity between the target node and the adjacent node is a first initial feature similarity; the method further includes: For each target node, a first similarity comprehensive value of the target node is obtained; the first similarity comprehensive value is determined based on the first initial feature similarities between the target node and each of the adjacent nodes; For each adjacent node, a second similarity comprehensive value of the adjacent node is obtained; the second similarity comprehensive value is determined based on the second initial feature similarity between the adjacent node and each target adjacent node; the target adjacent node is a node in the network graph that is connected to the adjacent node through an edge; Determining a first adjustment coefficient for the target node according to a ratio of the first initial feature similarity to the first similarity comprehensive value; A second adjustment coefficient for the adjacent node is determined according to a ratio of the first initial feature similarity to the second similarity comprehensive value.
4. The method according to claim 1, characterized in that: The determining, based on the feature difference and the initial feature similarity between the target node and the adjacent node, a feature transfer coefficient of the target node in this round includes: Determine the initial feature transfer coefficient of the target node in this round based on the feature difference and the initial feature similarity between the target node and the adjacent nodes; The initial feature transfer coefficient of this round is adjusted according to the first similarity comprehensive value to obtain the feature transfer coefficient of this round of the target node; the first similarity comprehensive value is determined based on the initial feature similarity between the target node and each of the adjacent nodes.
5. The method according to claim 1, characterized in that The determining, based on the current round feature transfer coefficient, a transfer feature transferred from the first feature to the current round includes: determining a first weighting coefficient for the first feature; Adjusting the first weighting coefficient based on the current round characteristic transfer coefficient to obtain a second weighting coefficient; The first feature is adjusted according to the second weighting coefficient, and the adjusted feature is used as a transfer feature transmitted from the first feature to the current round.
6. The method according to claim 5, characterized in that The determining a first weighting coefficient for the first feature includes: Determine a ratio of the feature transfer coefficient of this round to a first similarity comprehensive value; the first similarity comprehensive value is determined based on the initial feature similarities between the target node and each of the adjacent nodes; A first weighting coefficient for the first feature is determined according to a ratio of the feature transfer coefficient of this round to the first similarity comprehensive value and a preset feature transfer hyperparameter.
7. The method according to claim 1, characterized in that The step of fusing the transferred features with the target initial features of the object represented by the target node to obtain the features of the target node after the current round of feature transfer includes: Determining a third weighting coefficient of a target initial feature of an object represented by the target node; Adjusting the target initial feature according to the third weighting coefficient to obtain a retained feature transferred from the target initial feature to this round; The transferred features are merged with the retained features to obtain the features of the target node after this round of feature transfer.
8. The method according to claim 7, characterized in that The determining of a third weighting coefficient of the target initial feature of the object represented by the target node comprises: The first weighting coefficient for the first feature is adjusted according to a preset feature transfer hyperparameter to obtain a third weighting coefficient for the target initial feature of the object represented by the target node.
9. The method according to any one of claims 1 to 8, characterized in that The node classification result is predicted by a trained node classification model; the node classification model includes a feature extraction network and a classification prediction network having a first network parameter; The step of taking the next round as the current round, returning to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph for iteration until the iteration stop condition is reached, and obtaining the target features of each node in the network graph after the last round of feature transfer, includes: Through the feature extraction network, the next round is taken as the current round, and the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph is returned to iterate until the iteration stop condition is reached, and the target features of each node in the network graph after the last round of feature transfer are output; The step of classifying each node based on the target feature of each node in the network graph to obtain a node classification result includes: The target features of each node in the network diagram are input into the classification prediction network to adjust the target features based on the first network parameters, and each node is classified based on the adjusted features to obtain a node classification result.
10. The method according to claim 9, characterized in that The network parameters of the feature extraction network include a second network parameter; the second network parameter is a network parameter used to initialize the feature; the method further includes: Acquire initial features of the object represented by the target node; The initial feature is input into the feature extraction network to adjust the initial feature based on the second network parameter to obtain the target initial feature of the object represented by the target node.
11. A node classification device, characterized in that: The device comprises: A determination module is used to obtain, for each target node in the network graph during this round of feature transfer, a first feature of the target node after the previous round of feature transfer, and obtain a second feature of an adjacent node after the previous round of feature transfer; the adjacent node is a node in the network graph connected to the target node through an edge; there is at least one adjacent node; For each adjacent node, the feature difference between the target node and the adjacent node is determined according to the first adjustment feature of the target node and the second adjustment feature of the adjacent node; the first adjustment feature of the target node is obtained by adjusting the first feature according to the first adjustment coefficient; the first adjustment coefficient is determined according to the correlation between the adjacent node and the target node compared with the first reference node; the first reference node is a node adjacent to the target node and other than the adjacent node; the second adjustment feature of the adjacent node is obtained by adjusting the second feature according to the second adjustment coefficient; the second adjustment coefficient is determined according to the correlation between the target node and the adjacent node compared with the second reference node; the second reference node is a node adjacent to the adjacent node and other than the target node; based on the feature difference and the initial feature similarity between the target node and the adjacent node, the current round feature transfer coefficient of the target node is determined; wherein the current round feature transfer coefficient is the feature transfer coefficient of the node in the current round feature transfer process, and the feature transfer coefficient is used to characterize the amount of feature transfer; A fusion module, used to determine the transfer feature transferred from the first feature to the current round based on the current round feature transfer coefficient, and fuse the transfer feature with the target initial feature of the object represented by the target node to obtain the feature of the target node after the current round feature transfer; The determination module is further configured to use the next round as the current round, return to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph to iterate until the iteration stop condition is reached, and obtain the target feature of each node in the network graph after the last round of feature transfer; The classification module is used to classify each node in the network diagram based on the target features of each node to obtain a node classification result.
12. The device according to claim 11, characterized in that The target initial feature of the object represented by the target node is a first initial feature; the device comprises: A calculation module is used to obtain a second initial feature of the object represented by the adjacent node; perform similarity calculation on the first initial feature and the second initial feature to obtain the initial feature similarity between the target node and the adjacent node.
13. The device according to claim 11, characterized in that The initial feature similarity between the target node and the adjacent nodes is a first initial feature similarity; the determination module is further used to obtain a first similarity comprehensive value of the target node for each target node; The first similarity comprehensive value is determined based on the first initial feature similarity between the target node and each of the adjacent nodes; For each adjacent node, obtaining a second similarity comprehensive value of the adjacent node; The second similarity comprehensive value is determined based on the second initial feature similarity between the adjacent node and each target adjacent node; the target adjacent node is a node in the network graph connected to the adjacent node through an edge; based on the ratio of the first initial feature similarity to the first similarity comprehensive value, a first adjustment coefficient for the target node is determined; based on the ratio of the first initial feature similarity to the second similarity comprehensive value, a second adjustment coefficient for the adjacent node is determined.
14. The device according to claim 11, characterized in that The determination module is also used to determine the current round initial feature transfer coefficient of the target node based on the feature difference and the initial feature similarity between the target node and the adjacent nodes; adjust the current round initial feature transfer coefficient according to a first similarity comprehensive value to obtain the current round feature transfer coefficient of the target node; the first similarity comprehensive value is determined based on the initial feature similarity between the target node and each of the adjacent nodes.
15. The device according to claim 11, characterized in that The fusion module is also used to determine a first weighting coefficient for the first feature; adjust the first weighting coefficient based on the feature transfer coefficient of this round to obtain a second weighting coefficient; adjust the first feature according to the second weighting coefficient, and use the adjusted feature as the transfer feature transferred from the first feature to this round.
16. The device according to claim 15, characterized in that The fusion module is also used to determine the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value; the first similarity comprehensive value is determined based on the initial feature similarity between the target node and each of the adjacent nodes; based on the ratio of the feature transfer coefficient of this round to the first similarity comprehensive value, and the preset feature transfer hyperparameters, determine the first weighting coefficient for the first feature.
17. The device according to claim 11, characterized in that The fusion module is also used to determine a third weighting coefficient of the target initial feature of the object represented by the target node; adjust the target initial feature according to the third weighting coefficient to obtain the retained feature transferred from the target initial feature to this round; and fuse the transferred feature with the retained feature to obtain the feature of the target node after the feature transfer in this round.
18. The device according to claim 17, characterized in that The fusion module is also used to adjust the first weighting coefficient for the first feature according to a preset feature transfer hyperparameter to obtain a third weighting coefficient for the target initial feature of the object represented by the target node.
19. The device according to any one of claims 11 to 18, characterized in that The node classification result is predicted by a trained node classification model; the node classification model includes a feature extraction network and a classification prediction network having a first network parameter; The determination module is also used to use the feature extraction network to return to the step of determining the feature difference between the target node and the adjacent nodes for each target node in the network graph to iterate until the iteration stop condition is reached, and output the target feature of each node in the network graph after the last round of feature transfer; The classification module is also used to input the target features of each node in the network diagram into the classification prediction network to adjust the target features based on the first network parameters, and classify each node based on the adjusted features to obtain a node classification result.
20. The device according to claim 19, characterized in that The network parameters of the feature extraction network include a second network parameter; the second network parameter is a network parameter used to initialize the feature; the device also includes: An acquisition module is used to acquire the initial features of the object represented by the target node; the initial features are input into the feature extraction network to adjust the initial features based on the second network parameters to obtain the target initial features of the object represented by the target node.
21. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 10 are implemented.
22. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 10 are implemented.
23. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 10 are implemented.
