Residual error-attention cooperation mechanism-based graph neural network feature fusion method

Through the graph neural network feature fusion method of the residual-attention collaborative mechanism, the problems of node feature smoothing and information loss in traditional graph neural networks in processing complex graph structure data are solved, and efficient representation and stable training of complex graph data are achieved.

CN120766079APending Publication Date: 2025-10-10HUNAN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510886140.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-30
Publication Date
2025-10-10

AI Technical Summary

Technical Problem

Traditional graph neural networks are prone to node feature smoothing and long-range dependency information loss when processing complex graph structure data, which limits the model's ability to represent complex graph structures.

Method used

A graph neural network feature fusion method based on the residual-attention collaborative mechanism is adopted. The graph input information is input into the graph neural network module and the multi-layer perceptron module of the multi-head attention mechanism respectively to obtain local and global vector representations, and the final node representation is generated through fusion, linear transformation and residual connection, thereby enhancing the model's modeling ability for complex graph data.

Benefits of technology

The model's expressiveness and training stability for complex graph data are improved, and deep information is retained and transmitted to shallow networks through residual connections, while reducing the gradient vanishing problem, dynamically screening key features and improving computational efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120766079A_ABST
    Figure CN120766079A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a graph neural network feature fusion method based on a residual-attention collaboration mechanism. The method comprises the following steps: respectively inputting graph input information into a multi-head attention mechanism-based graph neural network GNN module and a multi-layer perceptron MLP module to obtain local vector representation and global vector representation; performing fusion processing on the local vector representation and the global vector representation to obtain a fused node vector representation; performing linear transformation processing on the global vector representation to obtain a residual signal vector; and adding the fused node vector representation and the residual signal vector to obtain a final node representation. According to the method provided by the embodiment of the invention, the modeling capability and the calculation efficiency of the model for the complex graph data can be effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] Embodiments of the present application relate to the field of graph neural networks, and particularly relate to a graph neural network feature fusion method based on a residual-attention collaborative mechanism. BACKGROUND

[0002] In recent years, graph neural networks (GNN) have been widely applied in social network analysis, recommendation systems, and biochemistry molecular representation due to their strong graph structure data modeling capabilities. However, traditional GNN methods usually rely on a message passing mechanism to aggregate local neighbor information, which can easily lead to node feature over-smoothing or loss of long-range dependency information, limiting the model's ability to represent complex graph structures. SUMMARY

[0003] Therefore, embodiments of the present application provide a graph neural network feature fusion method based on a residual-attention collaborative mechanism, which can effectively improve the model's ability to model complex graph data and computational efficiency.

[0004] In a first aspect, a graph neural network feature fusion method based on a residual-attention collaborative mechanism is provided, including: inputting graph input information into a graph neural network (GNN) module based on a multi-head attention mechanism and a multi-layer perception (MLP) module, respectively, to obtain local vector representations and global vector representations; performing fusion processing on the local vector representations and the global vector representations to obtain fused node vector representations; performing linear transformation processing on the global vector representations to obtain a residual signal vector; and summing the fused node vector representations and the residual signal vector to obtain final node representations.

[0005] In one possible implementation, the fusion processing of the local vector representations and the global vector representations to obtain the fused node vector representations includes: in a case where the size of the graph input information is greater than a first threshold, performing feature concatenation on the local vector representations and the global vector representations to obtain a concatenated vector representation; and inputting the concatenated vector representation into a feed-forward neural network (FFN) module to obtain the fused node vector representations.

[0006] In one possible implementation, the inputting of the concatenated vector representation into the FFN module to obtain the fused node vector representations includes: sequentially performing linear mapping processing, activation function processing, and any one of regularization processing and channel weighting processing on the concatenated vector representation to obtain the fused node vector representations.

[0007] In a possible implementation, the fusion module is specifically configured to: in a case where the scale of the graph input information is greater than the first threshold, perform feature concatenation on the local vector representation and the global vector representation to obtain a concatenated vector representation; and input the concatenated vector representation into a feed-forward neural network (FFN) model to obtain the fused node vector representation.

[0008] In a possible implementation, the GNN module is specifically configured to: input the graph input information into each attention head module to respectively generate Q vectors, K vectors and V vectors; calculate, in each attention head module, an attention score based on the Q vector and the K vector of each node and its neighbor nodes in the graph input information; perform a Softmax normalization operation on all neighbor attention scores of the each node; and combine the output after the normalization operation into the local vector representation through concatenation or averaging.

[0009] In a second aspect, a device for feature fusion of a graph neural network based on a residual-attention collaborative mechanism is provided, which includes: a GNN module based on a multi-head attention mechanism, configured to convert graph input information into a local vector representation; an MLP module, configured to convert the graph input information into a global vector representation; a fusion module, configured to fuse the local vector representation and the global vector representation to obtain a fused node vector representation; a residual projection module, configured to perform linear transformation processing on the global vector representation to obtain a residual signal vector; and an enhancement module, configured to add the fused node vector representation and the residual signal vector to obtain a final node representation.

[0010] In a possible implementation, the fusion module is specifically configured to: in a case where the scale of the graph input information is greater than the first threshold, perform feature concatenation on the local vector representation and the global vector representation to obtain a concatenated vector representation; and input the concatenated vector representation into a feed-forward neural network (FFN) model to obtain the fused node vector representation.

[0011] In a possible implementation, the fusion module is configured to input the concatenated vector representation into the FFN model to obtain the fused node vector representation, including: sequentially performing linear mapping processing, activation function processing, and any one of regularization processing and channel weighting processing on the concatenated vector representation to obtain the fused node vector representation.

[0012] In a possible implementation, the fusion module is specifically configured to: when the scale of the graph input information is less than or equal to a first threshold, add the local vector representation and the global vector representation to obtain the fused node vector representation.

[0013] In one possible implementation, the graph neural network (GNN) module based on the multi-head attention mechanism is specifically used to: input the graph input information into each attention head module respectively, and generate a Q vector, a K vector and a V vector respectively; for each node and its neighbor nodes in the graph input information, calculate the attention score based on its Q vector and K vector in each attention head module; perform a Softmax normalization operation on the attention scores of all neighbors of each node; and merge the output after the normalization operation into the local vector representation by splicing or averaging.

[0014] In a third aspect, a computer device is provided, comprising: a processor, and a memory communicatively connected to the processor, wherein the memory stores program instructions executable by the processor, and the processor calls the program instructions to execute the graph neural network feature fusion method based on the residual-attention collaborative mechanism of the first aspect and any possible implementation of the first aspect.

[0015] In a fourth aspect, a computer-readable storage medium is provided, which includes a stored program, wherein when the program is run, the device where the computer-readable storage medium is located is controlled to execute a graph neural network feature fusion method based on the residual-attention collaborative mechanism such as the first aspect and any possible implementation method of the first aspect.

[0016] Based on the above technical solution, the outputs of at least one GNN model and one MLP model are fused through residual connections. In this process, the residual connection ensures that the deep information of the model can be effectively transmitted to the shallower network layers while retaining the shallow features. Specifically, the GNN model is mainly responsible for capturing the structural information of nodes and edges in the graph data, while the MLP focuses on deep learning of the attributes of the nodes. The outputs of the two are added together through the residual structure, so that the output of each layer can retain the deep information from the previous layer, while the residual structure reduces the possible gradient vanishing problem. By fusing the different characteristics of GNN and MLP, this step can take advantage of the advantages of both and improve the model's ability to express complex graph data and training stability. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments of the present application. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the drawings without creative work.

[0018] Figure 1 A schematic block diagram of a graph neural network feature fusion method based on a residual-attention collaborative mechanism in an embodiment of the present application is shown.

[0019] Figure 2 Another schematic block diagram of the graph neural network feature fusion method based on the residual-attention collaborative mechanism of an embodiment of the present application is shown.

[0020] Figure 3 Another schematic block diagram of the graph neural network feature fusion method based on the residual-attention collaborative mechanism of an embodiment of the present application is shown.

[0021] Figure 4 Another schematic block diagram of the graph neural network feature fusion method based on the residual-attention collaborative mechanism of an embodiment of the present application is shown.

[0022] Figure 5 A schematic block diagram of a training method based on collaborative optimization of tile sampling and video memory cache according to an embodiment of the present application is shown.

[0023] Figure 6 A schematic block diagram of a graph neural network feature fusion device method based on a residual-attention collaborative mechanism in an embodiment of the present application is shown. DETAILED DESCRIPTION

[0024] To make the purpose, technical solutions, and advantages of the embodiments of this application more clear, the technical solutions in the embodiments of this application will be clearly described below in conjunction with the drawings in the embodiments of this application. Obviously, the described embodiments are part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0025] Current graph neural networks (GNNs) face three core challenges when processing non-Euclidean data: deep model degradation, static weight assignment, and information redundancy. First, while residual connections effectively mitigate vanishing gradients, their fixed skipping structure prevents dynamic filtering of key features and easily carries redundant information to deeper layers. Second, attention mechanisms (such as the Graph Attention Network (GAT)) achieve dynamic neighbor weighting through self-attention, but this often weakens the preservation of fine-grained information in shallow layers, and deep stacking still suffers from issues such as oversmoothing and gradient decay. Third, while feature concatenation can expand spatial representation, simple concatenation along channels leads to high-dimensional redundancy and dimensionality explosion, increasing computational and storage burdens. Although mechanisms such as JKNet, MLP Aggregation, and GINEConv have partially improved aggregation methods, existing methods mostly rely on module stacking, and a unified fusion framework has yet to emerge. The reduce = "ff" structure in the Residual Graph Neural Network (ResidualGNN) enhances representation through concatenation and aggregation with a feedforward neural network (FFN), but still lacks a three-pathway collaborative design. Therefore, it is urgent to organically integrate residual connections, attention mechanisms and splicing operations to build a graph neural network architecture that can perform dynamic screening, stable transmission and spatial expansion.

[0026] Figure 1 A schematic block diagram of a graph neural network feature fusion method based on the residual-attention collaborative mechanism is shown. Optionally, the method can be executed by a processor, for example, by a central processing unit (CPU), or by a graphics processing unit (GPU). Figure 1 As shown, the method 100 may include some or all of the following contents.

[0027] S110, inputting the graph input information into the graph neural network (GNN) module based on the multi-head attention mechanism and the multi-layer perceptron (MLP) module respectively to obtain a local vector representation and a global vector representation;

[0028] S120, fusing the local vector representation and the global vector representation to obtain a fused node vector representation;

[0029] S130, performing linear transformation processing on the global vector representation to obtain a residual signal vector;

[0030] S140 , adding the fused node vector representation and the residual signal vector to obtain a final node representation.

[0031] In S110, the following technical terms are involved:

[0032] Graph input information is usually expressed as G = (V, E, X), where V is a set of nodes, and each node v i With initial feature x i ; E is the edge set; X is the node feature matrix, the dimension is |V|*d, d is the feature dimension.

[0033] The GNN module based on the multi-head attention mechanism is a variant of the graph attention network (GAT), which adaptively aggregates neighbor node information through attention weights, where for node i, its local vector is represented as h i_CNN =Multihead(h i ,{h j} j∈N(i) ), N(i) is the neighbor set of node i, MultiHead represents the multi-head attention function, which usually includes multiple attention heads that are computed in parallel and then concatenated.

[0034] The Multi-Layer Perceptron (MLP) module is used to extract the global features of nodes without relying on the graph structure. Its mathematical expression is h i_MLP =MLP(x i ), where MLP is a neural network consisting of multiple fully connected layers and activation functions.

[0035] The local vector representation captures the local structural information of the node (such as neighbor node characteristics and connection patterns), while the global vector representation captures the inherent properties of the node (such as the node's own characteristics) and does not rely on the graph structure relationship.

[0036] In S110, the GNN model can use a graph attention network structure based on a multi-head attention mechanism. Multiple attention heads are used to calculate the strength of associations between adjacent nodes and weightedly aggregate neighbor features to obtain a local vector representation that reflects the local structural relationships of the nodes. Meanwhile, the MLP model can use a modular Block_MLP structure, stacking multiple nonlinear transformation units in layers to independently process the original attribute features of each node, thereby generating a global vector representation that is independent of the graph structure.

[0037] The multi-head attention mechanism is adopted to dynamically learn the spatio-temporal correlation weight between nodes. Specifically, the multi-head attention mechanism assigns different weights to the neighbor nodes of each node through multiple independent attention heads, and these weights play a crucial role in the aggregation process of node features. Each attention head calculates the relationship between adjacent nodes through independently learned weights, thereby enhancing the model's ability to perceive key features. To further optimize the performance of the model, the weights of the neighbor nodes can also be adaptively assigned to ensure that important neighbor nodes have a greater impact on the features of the current node, while unimportant nodes are suppressed, avoiding the loss of shallow information. This step enables the graph neural network to automatically adjust the learning strategy according to the changes in the graph structure, thereby improving the modeling capability for complex graph data.

[0038] Specifically, as shown in Figure 2 S110, the graph input information is input into the graph neural network GNN module based on the multi-head attention mechanism to obtain a local vector representation, which specifically includes:

[0039] S111, the graph input information is input into each attention head module to generate Q vectors, K vectors, and V vectors respectively;

[0040] S112, for each node and its neighbor nodes in the graph input information, the attention score is calculated in each attention head module based on the Q vector and the K vector of each node;

[0041] S113, performing Softmax normalization operation on all neighbor attention scores of each node;

[0042] S114, merging the output after the normalization operation into the local vector representation by concatenation or averaging.

[0043] In S111, first in each attention head, the node features are mapped to the query (Query), key (Key), and value (Value) space for subsequent attention calculation. The Q vector represents the "demand" of the current node, which is used to calculate its attention degree to other nodes. The K vector represents the "attention" attribute of the neighbor nodes, which is used to match the query. The V vector contains the actual information of the neighbor nodes, which is used for weighted aggregation. Specifically, for the node feature matrix X |V|*d , each attention head k (e.g., 8 heads in total) applies a learnable weight matrix: Q k = XW k Q , K k = XW k K , V k = XW k V .

[0044] In S112, for example, dot product attention is used to perform attention on node v i and its neighbor node v j Calculate the unnormalized attention score: e ij k =(q i k ) T k j k , where q i and k j Q k and K k The i-th and j-th rows of . Optionally, the dot product attention can be further scaled. The score e ij k The higher the value, the higher the node v i For neighbor node v j The stronger the attention.

[0045] In S113, the attention scores are converted into probability distributions to ensure that the sum of the weights of all neighbors is 1. For example, for node v i All neighbor nodes v j Apply the softmax function and output the normalized attention weight α ij k ∈[0,1].

[0046] In S114, for each attention head k, use the attention weight α ij k The value vector V of the weighted aggregated neighbors k Then, the outputs of all attention heads are concatenated and the dimensions are adjusted through a linear layer, or the outputs of multiple attention heads are directly averaged to finally obtain a local vector representation.

[0047] In this embodiment, the attention mechanism is implemented by calling the StochasticGAT module, using two layers of GATConv operators, each containing 8 attention heads. Each attention head calculates the attention score of the target node and its neighbor nodes in a specific subspace, and then performs a weighted average of the neighbor features to form a multi-angle neighbor feature representation.

[0048] The StochasticGAT model has the ability to support block structure input, combines a hierarchical neighbor sampling strategy, and can dynamically construct a local subgraph during the training process, improving the scalability and resource adaptation capability of the model in large-scale graph data processing scenarios. The attention module can be used as a sub-model in the ResidualGNN framework and participate in feature fusion with other feature extraction modules. The system supports attention weight adjustment and regularization processing, prevents overfitting through the Dropout mechanism, and uses head splicing to improve the expression space and feature diversity of the model. For large-scale heterogeneous graph data, the system can also extend the introduction of edge timestamps and other timing information to model the dynamic relationship between nodes over time, thereby improving the semantic modeling capability and robustness of the system in heterogeneous and dynamic graph environments.

[0049] In S120, the fusion processing involved mainly includes two types of splicing method and summation method.

[0050] Optionally, in the embodiment of the present application, before the local vector representation and the global vector representation are fused, it can be judged whether to use the splicing method or the summation method based on the size of the graph input information. For example, in the case where the size of the graph input information is greater than a first threshold, the local vector representation and the global vector representation are first spliced in feature, and then input into a Feedforward Neural Network (FFN) to obtain the fused node vector representation. For another example, in the case where the size of the graph input information is less than or equal to the first threshold, the local vector representation and the global vector representation are directly summed to obtain the fused node vector representation.

[0051] That is, as shown in the figure, the fusion mechanism can flexibly configure the fusion strategy according to the task expression complexity and resource constraints: in the task with higher expression ability requirement, the "splicing + feedforward network" structure is adopted to improve the semantic modeling accuracy; in the lightweight or inference efficiency priority scene, the element-level summation strategy can be selected to reduce the calculation overhead. Figure 3

[0052] Specifically, the reduce parameter of the ResidualGNN module can be used for unified management: when reduce="ff", the splicing and feedforward fusion path is executed; when reduce="sum", the summation strategy is enabled to complete the lightweight fusion operation without introducing additional calculation amount. The user can flexibly adjust the intermediate dimension size of the FFN layer by setting the ff_size parameter to adapt to different input dimension and model capacity requirements.

[0053] ​In the fusion stage, the node feature vectors output from the two sub-models will be spliced along the feature dimension to generate a unified high-dimensional feature representation. The spliced vector is input into the FFN module to perform nonlinear mapping and dimension compression to generate the intermediate representation after fusion. The FFN fusion mechanism has fault tolerance capability for cross-model heterogeneous dimension input, supports adjustable parameter dimension size and nonlinear activation function (such as ReLU) combination, thereby enhancing the adaptability and expressiveness of the fusion representation to the task semantics. Further, any one of linear mapping processing, activation function processing, and regularization processing and channel weighting processing can be performed on the spliced vector representation in turn to obtain the fused node vector representation. Specifically, after obtaining the local vector representation R d1 and the global vector representation R d2 , the spliced vector representation h _concat ∈R d1 +R d2 can be generated through feature concatenation operation; then, h _concat is input into the linear mapping layer nn.Linear(d1+d2,dff) of the FFN to generate an intermediate feature vector; then, ReLU or LeakyReLU activation function is used to enhance the nonlinear modeling capability to generate nonlinear transformation result; finally, Dropout or channel attention mechanism can be optionally introduced to perform regularization or channel weighting on the fused feature to improve the model generalization capability.

[0054] To realize the unified fusion and dimension reduction compression of multi-model features, the application adopts a nonlinear fusion strategy based on feature splicing and FFN. This mechanism effectively improves the flexibility and robustness of the fusion representation by uniformly splicing the output of heterogeneous models and using a trainable feedforward mapping structure to complete feature compression and nonlinear transformation. In this embodiment, the system first executes the GNN model and the multi-layer perceptron MLP model respectively to obtain the embedding representation of each node in the structure space and the attribute space. Then, the above two embedding vectors are spliced along the feature dimension to generate a fusion input vector, which is input into the FFN module for a series of nonlinear processing to output the fusion vector representation.

[0055] To further alleviate the feature degradation problem that may be caused by deep nonlinear transformation, the system introduces a residual connection mechanism in the above fusion path. As shown in Figure 4 , while performing FFN fusion processing, an original input path (usually the shallow MLP output or feature projection vector) is reserved and superimposed with the FFN fusion output. This residual path design ensures the co-preservation of shallow semantics and deep semantics, and improves the convergence efficiency of the model through gradient stability in the training process. Specifically, the global vector representation can be first linearly mapped by the fully connected layer, r i =W r ·hi_MLP +b r . wherein r i is the generated residual signal vector, W r is the weight matrix, and b r is the bias vector. r i represents the "information increment" of the global vector after linear transformation, and optionally, an activation function can be added after linear transformation.

[0056] In S140, a fixed summation strategy can be used to perform element-wise summation between the fused node vector representation and the residual signal vector, generating the final node representation. This operation is performed in the model forward propagation stage and automatically passes the gradient to the residual path, ensuring that shallow features continuously receive effective feedback during training.

[0057] In the embodiments of the present application, to improve the training stability and feature information retention capability of the fusion model, a residual connection-based fusion mechanism is introduced in the multi-model integration framework. This mechanism builds a main nonlinear fusion path and a bypass residual signal path, selectively preserving and strengthening shallow features at deep layers of the model, especially suitable for complex graph learning tasks that model structural features and attribute features collaboratively.

[0058] To improve the adaptability and deployment flexibility of the model, an automatic combination and registration mechanism is further introduced, which supports dynamically loading and combining different types of sub-models, including but not limited to GNN models (such as GraphSAGE, GAT, VGAE, etc.) and MLP models, through unified model construction parameters, and automatically registering them in the fusion framework. The ResidualGNN module serves as a unified encapsulation interface, supporting automatic combination and registration of multiple sub-models. Users only need to configure the model name and fusion strategy to automatically construct the fusion model and integrate it into the training process without modifying the underlying code logic, significantly improving the model deployment efficiency and modular adaptation capability.

[0059] In the embodiments of the present application, the outputs of at least one GNN model and one MLP model are fused through residual connection. In this process, the residual connection ensures that the deep information of the model can be effectively passed to the shallower network layers while preserving the shallow features. Specifically, the GNN model is mainly responsible for capturing the structural information of nodes and edges in the graph data, while the MLP focuses on deep learning of node attributes. The outputs of the two are added through the residual structure, so that the output of each layer can retain the deep information from the previous layer, while the residual structure reduces the possible gradient vanishing problem. This step can utilize the advantages of both GNN and MLP by fusing their different characteristics, improving the model's expression ability and training stability for complex graph data.

[0060] Optionally, during the training process, the final node representation can also be passed to the subsequent classification or prediction module. Since the residual path is explicitly calculated as part of the subgraph block in the graph learning framework, the system supports a block-based backpropagation mechanism, making both GNN and MLP paths available for complete gradient signals.

[0061] The residual fusion strategy is implemented internally by the ResidualGNN module and can be enabled by setting the fusion parameter reduce="ff". Unlike traditional fixed additive residual designs, the present application uses an adjustable fusion weight structure, allowing the system to automatically learn the optimal residual signal ratio during actual training, achieving adaptive balance between feature preservation and deep expression. This mechanism adapts to heterogeneous model combination inputs, with higher expression flexibility and cross-structure migration ability.

[0062] To improve resource utilization and operational efficiency in training large-scale graph data, the embodiments of the present application also construct a training method 200 based on Mini-batch Block Sampling and GPU cache co-optimization, as shown in Figure 5 The mechanism supports efficient training scheduling under a graph structure with tens of millions of nodes, especially suitable for online iterative learning of deep graph neural networks.

[0063] Specifically, the method 200 can include the following steps:

[0064] S210, constructing a multi-hop neighbor sampler (Multi-Hop NeighborSampler).

[0065] Specifically, the Mini-batch Block Sampler can be constructed based on the MultiLayerNeighborSampler of the Deep Graph Library (DGL) framework. In each training step, the target node and its several-hop neighbors are sampled to form a block structure, and the block size is controlled by setting the sampling number of each layer (such as [15, 10]) to avoid the problem of memory occupation caused by loading the entire graph, and to realize on-demand batch training.

[0066] S220, introducing a task-oriented edge sampling mechanism.

[0067] To adapt to link prediction and other edge-level supervised tasks, a positive and negative edge sampling module is introduced during the training data construction phase, combining the training edges to generate negative sample pairs for the supervised model. This mechanism generates a set of positive and negative sample edges through static preprocessing, and combines the Mini-batch Block Sampler to load the required edge information on demand, thereby improving the efficiency of training data organization and reducing invalid edge input.

[0068] S230, GPU cache optimization strategy design.

[0069] During training, the DGL framework's use_uva=True and gpu_cache parameters are combined to support early migration of some high-frequency node features to GPU memory, reducing latency caused by frequent data exchange between the CPU and GPU. Node feature page locking is implemented through pin_memory(), further improving data loading efficiency and reducing memory paging overhead.

[0070] S240, asynchronous loading scheduling of tiles and features.

[0071] In the main training loop, the system uses DGL's graph data loader to synchronize the tile structure and node features. Combined with the prefetch_node_feats and gpu_cache parameter configurations, it enables efficient intra-batch feature prefetching and tile loading during training, ensuring efficient collaborative execution of model calculations and data transmission.

[0072] Finally, the training scheduling path constructed by the above method is as follows: Figure 5 As shown in the figure, the system achieves the coordinated execution of tile sampling, edge sampling, and feature loading modules. In each round of training, the system sequentially generates the tile structure, organizes positive and negative edge labels, loads the required node features, and relies on video memory caching and streaming mechanisms to complete feature fusion, loss calculation, and backpropagation operations, effectively improving overall training efficiency and model scalability.

[0073] Figure 6 The schematic block diagram of the graph neural network feature fusion device based on the residual-attention collaborative mechanism of the embodiment of the present application is shown. Figure 6 As shown, the device 300 includes some or all of the following contents.

[0074] The graph neural network GNN module 310 based on the multi-head attention mechanism is used to convert graph input information into local vector representation.

[0075] The multi-layer perceptron (MLP) module 320 is configured to convert the graph input information into a global vector representation.

[0076] The fusion module 330 is configured to fuse the local vector representation and the global vector representation to obtain a fused node vector representation.

[0077] The residual projection module 340 is used to perform linear transformation processing on the global vector representation to obtain a residual signal vector; the enhancement module is used to add the fused node vector representation and the residual signal vector to obtain a final node representation.

[0078] In one possible implementation, the fusion module 330 is specifically used to: when the scale of the graph input information is greater than a first threshold, perform feature splicing on the local vector representation and the global vector representation to obtain a spliced ​​vector representation; input the spliced ​​vector representation into a feedforward neural network FFN model to obtain the fused node vector representation.

[0079] In one possible implementation, the fusion module 330 is used to input the spliced ​​vector representation into a feed-forward neural network FFN model to obtain the fused node vector representation, including: performing linear mapping processing, activation function processing, and any one of regularization processing and channel weighting processing on the spliced ​​vector representation in sequence to obtain the fused node vector representation.

[0080] In a possible implementation, the fusion module 330 is specifically configured to: when the scale of the graph input information is less than or equal to a first threshold, add the local vector representation and the global vector representation to obtain the fused node vector representation.

[0081] In one possible implementation, the graph neural network GNN module 310 based on the multi-head attention mechanism is specifically used to: input the graph input information into each attention head module respectively, and generate a Q vector, a K vector and a V vector respectively; for each node and its neighbor nodes in the graph input information, calculate the attention score based on its Q vector and K vector in each attention head module; perform a Softmax normalization operation on the attention scores of all neighbors of each node; and merge the outputs of the attention head modules into the local vector representation by splicing or averaging.

[0082] Based on the same concept, an embodiment of the present application further provides a computer device, which includes a memory for storing computer program instructions and a processor for executing the program instructions, wherein when the program instructions are executed by the processor, the computer device executes the various apparatus embodiments described above.

[0083] It should be noted that the detailed content of the device side embodiment can be found in the device side embodiment, and for the sake of brevity, it will not be repeated here.

[0084] Based on the same idea, an embodiment of the present application also provides a computer-readable storage medium, which includes a stored program, wherein when the program is run, the device where the computer-readable storage medium is located is controlled to execute the above-mentioned various device embodiments.

[0085] Although the present application has been described with reference to preferred embodiments, various modifications may be made thereto and components may be substituted with equivalents without departing from the scope of the present application. In particular, the various technical features described in the various embodiments may be combined in any manner as long as there are no structural conflicts. The present application is not limited to the specific embodiments disclosed herein, but encompasses all technical solutions within the scope of the claims.

Claims

1. A graph neural network feature fusion method based on residual-attention collaborative mechanism, characterized by: include: The graph input information is input into the graph neural network (GNN) module based on the multi-head attention mechanism and the multi-layer perceptron (MLP) module respectively to obtain local vector representation and global vector representation; Fusing the local vector representation and the global vector representation to obtain a fused node vector representation; Performing linear transformation on the global vector representation to obtain a residual signal vector; The fused node vector representation and the residual signal vector are added together to obtain a final node representation.

2. The method according to claim 1, characterized in that The fusing the local vector representation and the global vector representation to obtain a fused node vector representation includes: When the scale of the graph input information is greater than a first threshold, performing feature splicing on the local vector representation and the global vector representation to obtain a spliced ​​vector representation; The concatenated vector representation is input into a feed-forward neural network (FFN) module to obtain the fused node vector representation.

3. The method according to claim 2, characterized in that Inputting the concatenated vector representation into a feed-forward neural network (FFN) module to obtain the fused node vector representation includes: The concatenated vector representation is sequentially subjected to linear mapping processing, activation function processing, and any one of regularization processing and channel weighting processing to obtain the fused node vector representation.

4. The method according to claim 1, wherein The fusing the local vector representation and the global vector representation to obtain a fused node vector representation includes: When the scale of the graph input information is less than or equal to a first threshold, the local vector representation and the global vector representation are added to obtain the fused node vector representation.

5. The method according to claim 1, wherein The graph input information is input into the graph neural network GNN module based on the multi-head attention mechanism to obtain a local vector representation, including: Input the graph input information into each attention head module to generate Q vector, K vector and V vector respectively; For each node and its neighboring nodes in the graph input information, calculating an attention score based on its Q vector and K vector in each attention head module; Perform a Softmax normalization operation on the attention scores of all neighbors of each node; The outputs after the normalization operation are combined into the local vector representation by splicing or averaging.

6. A graph neural network feature fusion device based on residual-attention collaborative mechanism, characterized in that: include: A graph neural network (GNN) module based on a multi-head attention mechanism, which is used to convert graph input information into local vector representations; A multi-layer perceptron (MLP) module is used to convert the graph input information into a global vector representation; a fusion module, configured to fuse the local vector representation and the global vector representation to obtain a fused node vector representation; A residual projection module, configured to perform a linear transformation on the global vector representation to obtain a residual signal vector; The enhancement module is used to add the fused node vector representation and the residual signal vector to obtain a final node representation.

7. The device according to claim 6, characterized in that The fusion module is specifically used for: When the scale of the graph input information is greater than a first threshold, performing feature splicing on the local vector representation and the global vector representation to obtain a spliced ​​vector representation; The concatenated vector representation is input into a feed-forward neural network (FFN) model to obtain the fused node vector representation.

8. The device according to claim 7, characterized in that The fusion module is used to input the concatenated vector representation into a feed-forward neural network (FFN) model to obtain the fused node vector representation, including: The concatenated vector representation is sequentially subjected to linear mapping processing, activation function processing, and any one of regularization processing and channel weighting processing to obtain the fused node vector representation.

9. The device according to claim 6, characterized in that The fusion module is specifically used for: When the scale of the graph input information is less than or equal to a first threshold, the local vector representation and the global vector representation are added to obtain the fused node vector representation.

10. The device according to claim 6, characterized in that The graph neural network (GNN) module based on the multi-head attention mechanism is specifically used to: Input the graph input information into each attention head module to generate Q vector, K vector and V vector respectively; For each node and its neighboring nodes in the graph input information, calculating an attention score based on its Q vector and K vector in each attention head module; Perform a Softmax normalization operation on the attention scores of all neighbors of each node; The outputs after the normalization operation are combined into the local vector representation by splicing or averaging.