论文标题
nagphormer:用于大图中节点分类的令牌化图形变压器
NAGphormer: A Tokenized Graph Transformer for Node Classification in Large Graphs
论文作者
论文摘要
图形变压器以新的体系结构出现,并在各种图挖掘任务上显示出卓越的性能。在这项工作中,我们观察到现有的图形变压器将节点视为独立的令牌,并构建由所有节点令牌组成的单个长序列,以训练变压器模型,从而使其难以扩展到大图,因为对自我注意计算的节点数量的二次复杂性。为此,我们提出了一个邻域聚集图变压器(Nagphormer),该图将每个节点视为包含由我们提出的Hop2Token模块构建的一系列令牌的序列。对于每个节点,Hop2Token将邻域特征从不同的啤酒花汇总为不同的表示形式,从而产生一系列令牌向量作为一个输入。这样,可以以迷你批量的方式对纳格剂进行训练,从而可以扩展到大图。此外,我们在数学上表明,与高级图神经网络(GNNS)类别相比,脱钩的图形卷积网络也可以从多跳社区学习更有用的节点表示形式。从小到大的基准数据集上进行了广泛的实验,以证明Nagphormer始终优于现有的图形变压器和主流GNN。代码可从https://github.com/jhl-hust/nagphormer获得。
The graph Transformer emerges as a new architecture and has shown superior performance on various graph mining tasks. In this work, we observe that existing graph Transformers treat nodes as independent tokens and construct a single long sequence composed of all node tokens so as to train the Transformer model, causing it hard to scale to large graphs due to the quadratic complexity on the number of nodes for the self-attention computation. To this end, we propose a Neighborhood Aggregation Graph Transformer (NAGphormer) that treats each node as a sequence containing a series of tokens constructed by our proposed Hop2Token module. For each node, Hop2Token aggregates the neighborhood features from different hops into different representations and thereby produces a sequence of token vectors as one input. In this way, NAGphormer could be trained in a mini-batch manner and thus could scale to large graphs. Moreover, we mathematically show that as compared to a category of advanced Graph Neural Networks (GNNs), the decoupled Graph Convolutional Network, NAGphormer could learn more informative node representations from the multi-hop neighborhoods. Extensive experiments on benchmark datasets from small to large are conducted to demonstrate that NAGphormer consistently outperforms existing graph Transformers and mainstream GNNs. Code is available at https://github.com/JHL-HUST/NAGphormer.