Deep Learning on Graphs: A Survey

Ziwei Zhang, Peng Cui, Wenwu Zhu

Introduction

Over the past decade, deep learning has become the “crown jewel” of artificial intelligence and machine learning , showing superior performance in acoustics , images and natural language processing , etc. The expressive power of deep learning to extract complex patterns from underlying data is well recognized. On the other hand, graphsGraphs are also called networks such as in social networks. In this paper, we use two terms interchangeably. are ubiquitous in the real world, representing objects and their relationships in varied domains, including social networks, e-commerce networks, biology networks, traffic networks, and so on. Graphs are also known to have complicated structures that can contain rich underlying values . As a result, how to utilize deep learning methods to analyze graph data has attracted considerable research attention over the past few years. This problem is non-trivial because several challenges exist in applying traditional deep learning architectures to graphs:

Irregular structures of graphs. Unlike images, audio, and text, which have a clear grid structure, graphs have irregular structures, making it hard to generalize some of the basic mathematical operations to graphs . For example, defining convolution and pooling operations, which are the fundamental operations in convolutional neural networks (CNNs), for graph data is not straightforward. This problem is often referred to as the geometric deep learning problem .

Heterogeneity and diversity of graphs. A graph itself can be complicated, containing diverse types and properties. For example, graphs can be heterogeneous or homogenous, weighted or unweighted, and signed or unsigned. In addition, the tasks of graphs also vary widely, ranging from node-focused problems such as node classification and link prediction to graph-focused problems such as graph classification and graph generation. These diverse types, properties, and tasks require different model architectures to tackle specific problems.

Large-scale graphs. In the big-data era, real graphs can easily have millions or billions of nodes and edges; some well-known examples are social networks and e-commerce networks . Therefore, how to design scalable models, preferably models that have a linear time complexity with respect to the graph size, is a key problem.

Incorporating interdisciplinary knowledge. Graphs are often connected to other disciplines, such as biology, chemistry, and social sciences. This interdisciplinary nature provides both opportunities and challenges: domain knowledge can be leveraged to solve specific problems but integrating domain knowledge can complicate model designs. For example, when generating molecular graphs, the objective function and chemical constraints are often non-differentiable; therefore gradient-based training methods cannot easily be applied.

To tackle these challenges, tremendous efforts have been made in this area, resulting in a rich literature of related papers and methods. The adopted architectures and training strategies also vary greatly, ranging from supervised to unsupervised and from convolutional to recursive. However, to the best of our knowledge, little effort has been made to systematically summarize the differences and connections between these diverse methods.

In this paper, we try to fill this knowledge gap by comprehensively reviewing deep learning methods on graphs. Specifically, as shown in Figure 1, we divide the existing methods into five categories based on their model architectures and training strategies: graph recurrent neural networks (Graph RNNs), graph convolutional networks (GCNs), graph autoencoders (GAEs), graph reinforcement learning (Graph RL), and graph adversarial methods. We summarize some of the main characteristics of these categories in Table I based on the following high-level distinctions. Graph RNNs capture recursive and sequential patterns of graphs by modeling states at either the node-level or the graph-level. GCNs define convolution and readout operations on irregular graph structures to capture common local and global structural patterns. GAEs assume low-rank graph structures and adopt unsupervised methods for node representation learning. Graph RL defines graph-based actions and rewards to obtain feedbacks on graph tasks while following constraints. Graph adversarial methods adopt adversarial training techniques to enhance the generalization ability of graph-based models and test their robustness by adversarial attacks.

In the following sections, we provide a comprehensive and detailed overview of these methods, mainly by following their development history and the various ways these methods solve the challenges posed by graphs. We also analyze the differences between these models and delve into how to composite different architectures. Finally, we briefly outline the applications of these models, introduce several open libraries, and discuss potential future research directions. In the appendix, we provide a source code repository, analyze the time complexity of various methods discussed in the paper, and summarize some common applications.

Related works. Several previous surveys are related to our paper. Bronstein et al. summarized some early GCN methods as well as CNNs on manifolds and studied them comprehensively through geometric deep learning. Battaglia et al. summarized how to use GNNs and GCNs for relational reasoning using a unified framework called graph networks, Lee et al. reviewed the attention models for graphs, Zhang et al. summarized some GCNs, and Sun et al. briefly surveyed adversarial attacks on graphs. Our work differs from these previous works in that we systematically and comprehensively review different deep learning architectures on graphs rather than focusing on one specific branch. Concurrent to our work, Zhou et al. and Wu et al. surveyed this field from different viewpoints and categorizations. Specifically, neither of their works consider graph reinforcement learning or graph adversarial methods, which are covered in this paper.

Another closely related topic is network embedding, aiming to embed nodes into a low-dimensional vector space . The main distinction between network embedding and our paper is that we focus on how different deep learning models are applied to graphs, and network embedding can be recognized as a concrete application example that uses some of these models (and it uses non-deep-learning methods as well).

The rest of this paper is organized as follows. In Section 2, we introduce the notations used in this paper and provide preliminaries. Then, we review Graph RNNs, GCNs, GAEs, Graph RL, and graph adversarial methods in Section 3 to 7, respectively. We conclude with a discussion in Section 8.

Notations and Preliminaries

To better illustrate the notations, we take social networks as an example. Each node vi∈Vv_{i}\in V corresponds to a user, and the edges EE correspond to relations between users. The profiles of users (e.g., age, gender, and location) can be represented as node features FV\mathbf{F}^{V} and interaction data (e.g., sending messages and comments) can be represented as edge features FE\mathbf{F}^{E}.

The tasks for learning a deep model on graphs can be broadly divided into two categories:

Node-focused tasks: These tasks are associated with individual nodes in the graph. Examples include node classification, link prediction, and node recommendation.

Graph-focused tasks: These tasks are associated with the entire graph. Examples include graph classification, estimating various graph properties, and generating graphs.

Note that such distinctions are more conceptually than mathematically rigorous. Some existing tasks are associated with mesoscopic structures such as community detection . In addition, node-focused problems can sometimes be studied as graph-focused problems by transforming the former into egocentric networks . Nevertheless, we will explain the differences in algorithm designs for these two categories when necessary.

Graph Recurrent Neural Networks

Recurrent neural networks (RNNs) such as gated recurrent units (GRU) or long short-term memory (LSTM) are de facto standards in modeling sequential data. In this section, we review Graph RNNs which can capture recursive and sequential patterns of graphs. Graph RNNs can be broadly divided into two categories: node-level RNNs and graph-level RNNs. The main distinction lies in whether the patterns lie at the node-level and are modeled by node states, or at the graph-level and are modeled by a common graph state. The main characteristics of the methods surveyed are summarized in Table III.

Node-level RNNs for graphs, which are also referred to as graph neural networks (GNNs)Recently, GNNs have also been used to refer to general neural networks for graph data. We follow the traditional naming convention and use GNNs to refer to this specific type of Graph RNNs., can be dated back to the ”pre-deep-learning” era . The idea behind a GNN is simple: to encode graph structural information, each node viv_{i} is represented by a low-dimensional state vector si\mathbf{s}_{i}. Motivated by recursive neural networks , a recursive definition of states is adopted :

where F(⋅)\mathcal{F}(\cdot) is a parametric function to be learned. After obtaining si\mathbf{s}_{i}, another function O(⋅)\mathcal{O}(\cdot) is applied to get the final outputs:

For graph-focused tasks, the authors of suggested adding a special node with unique attributes to represent the entire graph. To learn the model parameters, the following semi-supervisedIt is called semi-supervised because all the graph structures and some subset of the node or graph labels is used during training. method is adopted: after iteratively solving Eq. (1) to a stable point using the Jacobi method , one gradient descent step is performed using the Almeida-Pineda algorithm to minimize a task-specific objective function, for example, the squared loss between the predicted values and the ground-truth for regression tasks; then, this process is repeated until convergence.

Using the two simple equations in Eqs. (1)(2), GNN plays two important roles. In retrospect, a GNN unifies some of the early methods used for processing graph data, such as recursive neural networks and Markov chains . Looking toward the future, the general idea underlying GNNs has profound inspirations: as will be shown later, many state-of-the-art GCNs actually have a formulation similar to Eq. (1) and follow the same framework of exchanging information within the immediate node neighborhoods. In fact, GNNs and GCNs can be unified into some common frameworks, and a GNN is equivalent to a GCN that uses identical layers to reach stable states. More discussion will be provided in Section 4.

Although they are conceptually important, GNNs have several drawbacks. First, to ensure that Eq. (1) has a unique solution, F(⋅)\mathcal{F}(\cdot) must be a “contraction map” , i.e., ∃μ,0<μ<1\exists\mu,0<\mu<1 so that

Intuitively, a “contraction map” requires that the distance between any two points can only “contract” after the F(⋅)\mathcal{F}(\cdot) operation, which severely limits the modeling ability. Second, because many iterations are needed to reach a stable state between gradient descend steps, GNNs are computationally expensive. Because of these drawbacks and perhaps a lack of computational power (e.g., the graphics processing unit, GPU, was not widely used for deep learning in those days) and lack of research interests, GNNs did not become a focus of general research.

A notable improvement to GNNs is gated graph sequence neural networks (GGS-NNs) with the following modifications. Most importantly, the authors replaced the recursive definition in Eq. (1) with a GRU, thus removing the “contraction map” requirement and supporting modern optimization techniques. Specifically, Eq. (1) is adapted as follows:

where z\mathbf{z} is calculated by the update gate, s~\widetilde{\mathbf{s}} is the candidate for updating, and tt is the pseudo time. Second, the authors proposed using several such networks operating in sequence to produce sequence outputs and showed that their method could be applied to sequence-based tasks such as program verification .

SSE took a similar approach as Eq. (4). However, instead of using a GRU in the calculation, SSE adopted stochastic fixed-point gradient descent to accelerate the training process. This scheme basically alternates between calculating steady node states using local neighborhoods and optimizing the model parameters, with both calculations in stochastic mini-batches.

2 Graph-level RNNs

In this subsection, we review how to apply RNNs to capture graph-level patterns, e.g., temporal patterns of dynamic graphs or sequential patterns at different levels of graph granularities. In graph-level RNNs, instead of applying one RNN to each node to learn the node states, a single RNN is applied to the entire graph to encode the graph states.

You et al. applied Graph RNNs to the graph generation problem. Specifically, they adopted two RNNs: one to generate new nodes and the other to generate edges for the newly added node in an autoregressive manner. They showed that such hierarchical RNN architectures learn more effectively from input graphs than do the traditional rule-based graph generative models while having a reasonable time complexity.

To capture the temporal information of dynamic graphs, dynamic graph neural network (DGNN) was proposed that used a time-aware LSTM to learn node representations. When a new edge is established, DGNN used the LSTM to update the representation of the two interacting nodes as well as their immediate neighbors, i.e., considering the one-step propagation effect. The authors showed that the time-aware LSTM could model the establishing orders and time intervals of edge formations well, which in turn benefited a range of graph applications.

Graph RNN can also be combined with other architectures, such as GCNs or GAEs. For example, aiming to tackle the graph sparsity problem, RMGCNN applied an LSTM to the results of GCNs to progressively reconstruct a graph as illustrated in Figure 2. By using an LSTM, the information from different parts of the graph can diffuse across long ranges without requiring as many GCN layers. Dynamic GCN applied an LSTM to gather the results of GCNs from different time slices in dynamic networks to capture both the spatial and temporal graph information.

Graph Convolutional Networks

Graph convolutional networks (GCNs) are inarguably the hottest topic in graph-based deep learning. Mimicking CNNs, modern GCNs learn the common local and global structural patterns of graphs through designed convolution and readout functions. Because most GCNs can be trained with task-specific loss via backpropagation (with a few exceptions such as the unsupervised training method in ), we focus on the adopted architectures. We first discuss the convolution operations, then move to the readout operations and some other improvements. We summarize the main characteristics of GCNs surveyed in this paper in Table IV.

Graph convolutions can be divided into two groups: spectral convolutions, which perform convolution by transforming node representations into the spectral domain using the graph Fourier transform or its extensions, and spatial convolutions, which perform convolution by considering node neighborhoods. Note that these two groups can overlap, for example, when using a polynomial spectral kernel (please refer to Section 4.1.2 for details).

Convolution is the most fundamental operation in CNNs. However, the standard convolution operation used for images or text cannot be directly applied to graphs because graphs lack a grid structure . Bruna et al. first introduced convolution for graph data from the spectral domain using the graph Laplacian matrix L\mathbf{L} , which plays a similar role as the Fourier basis in signal processing . The graph convolution operation, ∗G*_{G}, is defined as follows:

However, directly using Eq. (7) requires learning O(N)O(N) parameters, which may not be feasible in practice. Besides, the filters in the spectral domain may not be localized in the spatial domain, i.e., each node may be affected by all the other nodes rather than only the nodes in a small region. To alleviate these problems, Bruna et al. suggested using the following smoothing filters:

where K\mathcal{K} is a fixed interpolation kernel and αl,i,j\alpha_{l,i,j} are learnable interpolation coefficients. The authors also generalized this idea to the setting where the graph is not given but constructed from raw features using either a supervised or an unsupervised method .

However, two fundamental problems remain unsolved. First, because the full eigenvectors of the Laplacian matrix are needed during each calculation, the time complexity is at least O(N2)O(N^{2}) for each forward and backward pass, not to mention the O(N3)O(N^{3}) complexity required to calculate the eigendecomposition, meaning that this approach is not scalable to large-scale graphs. Second, because the filters depend on the eigenbasis Q\mathbf{Q} of the graph, the parameters cannot be shared across multiple graphs with different sizes and structures.

Next, we review two lines of works trying to solve these limitations and then unify them using some common frameworks.

1.2 The Efficiency Aspect

To solve the efficiency problem, ChebNet was proposed to use a polynomial filter as follows:

where θ0,...,θK\theta_{0},...,\theta_{K} are the learnable parameters and KK is the polynomial order. Then, instead of performing the eigendecomposition, the authors rewrote Eq. (9) using the Chebyshev expansion :

Kipf and Welling further simplified the filtering by using only the first-order neighbors:

An important insight of ChebNet and its extension is that they connect the spectral graph convolution with the spatial architecture. Specifically, they show that when the spectral convolution function is polynomial or first-order, the spectral graph convolution is equivalent to a spatial convolution. In addition, the convolution in Eq. (13) is highly similar to the state definition in a GNN in Eq. (1), except that the convolution definition replaces the recursive definition. From this aspect, a GNN can be regarded as a GCN with a large number of identical layers to reach stable states , i.e., a GNN uses a fixed function with fixed parameters to iteratively update the node hidden states until reaching an equilibrium, while a GCN has a preset number of layers and each layer contains different parameters.

Some spectral methods have also been proposed to solve the efficiency problem. For example, instead of using the Chebyshev expansion as in Eq. (10), CayleyNet adopted Cayley polynomials to define graph convolutions:

where i=−1i=\sqrt{-1} denotes the imaginary unit and θh\theta_{h} is another spectral zoom parameter. In addition to showing that CayleyNet is as efficient as ChebNet, the authors demonstrated that the Cayley polynomials can detect “narrow frequency bands of importance” to achieve better results. Graph wavelet neural network (GWNN) was further proposed to replace the Fourier transform in spectral filters by the graph wavelet transform by rewriting Eq. (5) as follows:

where ψ\mathbf{\psi} denotes the graph wavelet bases. By using fast approximating algorithms to calculate ψ\mathbf{\psi} and ψ−1\mathbf{\psi}^{-1}, GWNN’s computational complexity is also O(KM)O(KM), i.e., linear with respect to the number of edges.

1.3 The Aspect of Multiple Graphs

A parallel series of works has focuses on generalizing graph convolutions to multiple graphs of arbitrary sizes. Neural FPs proposed a spatial method that also used the first-order neighbors:

Because the parameters Θ\mathbf{\Theta} can be shared across different graphs and are independent of the graph size, Neural FPs can handle multiple graphs of arbitrary sizes. Note that Eq. (17) is very similar to Eq. (13). However, instead of considering the influence of node degree by adding a normalization term, Neural FPs proposed learning different parameters Θ\mathbf{\Theta} for nodes with different degrees. This strategy performed well for small graphs such as molecular graphs (i.e., atoms as nodes and bonds as edges), but may not be scalable to larger graphs.

PATCHY-SAN adopted a different idea. It assigned a unique node order using a graph labeling procedure such as the Weisfeiler-Lehman kernel and then arranged node neighbors in a line using this pre-defined order. In addition, PATCHY-SAN defined a “receptive field” for each node viv_{i} by selecting a fixed number of nodes from its kk-step neighborhoods Nk(i)\mathcal{N}_{k}(i). Then a standard 1-D CNN with proper normalization was adopted. Using this approach, nodes in different graphs all have a “receptive field” with a fixed size and order; thus, PATCHY-SAN can learn from multiple graphs like normal CNNs learn from multiple images. The drawbacks are that the convolution depends heavily on the graph labeling procedure which is a preprocessing step that is not learned. LGCN further proposed to simplify the sorting process by using a lexicographical order (i.e., sorting neighbors based on their hidden representation in the final layer HL\mathbf{H}^{L}). Instead of using a single order, the authors sorted different channels of HL\mathbf{H}^{L} separately. SortPooling took a similar approach, but rather than sorting the neighbors of each node, the authors proposed to sort all the nodes (i.e., using a single order for all the neighborhoods). Despite the differences among these methods, enforcing a 1-D node order may not be a natural choice for graphs.

DCNN adopted another approach by replacing the eigenbasis of the graph convolution with a diffusion-basis, i.e., the neighborhoods of nodes were determined by the diffusion transition probability between nodes. Specifically, the convolution was defined as follows:

where PK=(P)K\mathbf{P}^{K}=\left(\mathbf{P}\right)^{K} is the transition probability of a length-KK diffusion process (i.e., random walks), KK is a preset diffusion length, and Θl\mathbf{\Theta}^{l} are learnable parameters. Because only PK\mathbf{P}^{K} depends on the graph structure, the parameters Θl\mathbf{\Theta}^{l} can be shared across graphs of arbitrary sizes. However, calculating PK\mathbf{P}^{K} has a time complexity of O(N2K)O\left(N^{2}K\right); thus, this method is not scalable to large graphs.

DGCN was further proposed to jointly adopt the diffusion and the adjacency bases using a dual graph convolutional network. Specifically, DGCN used two convolutions: one was Eq. (14), and the other replaced the adjacency matrix with the positive pointwise mutual information (PPMI) matrix of the transition probability as follows:

where XP\mathbf{X}_{P} is the PPMI matrix calculated as:

and DP(i,i)=∑jXP(i,j)\mathbf{D}_{P}(i,i)=\sum_{j}\mathbf{X}_{P}(i,j) is the diagonal degree matrix of XP\mathbf{X}_{P}. Then, these two convolutions were ensembled by minimizing the mean square differences between H\mathbf{H} and Z\mathbf{Z}. DGCN adopted a random walk sampling technique to accelerate the transition probability calculation. The experiments demonstrated that such dual convolutions were effective even for single-graph problems.

1.4 Frameworks

Based on the above two lines of works, MPNNs were proposed as a unified framework for the graph convolution operation in the spatial domain using message-passing functions:

where Fl(⋅)\mathcal{F}^{l}(\cdot) and Gl(⋅)\mathcal{G}^{l}(\cdot) are the message functions and vertex update functions to be learned, respectively, and ml\mathbf{m}^{l} denotes the “messages” passed between nodes. Conceptually, MPNNs are a framework in which each node sends messages based on its states and updates its states based on messages received from the immediate neighbors. The authors showed that the above framework had included many existing methods such as GGS-NNs , Bruna et al. , Henaff et al. , Neural FPs , Kipf and Welling and Kearnes et al. as special cases. In addition, the authors proposed adding a “master” node that was connected to all the nodes to accelerate the message-passing across long distances, and they split the hidden representations into different “towers” to improve the generalization ability. The authors showed that a specific variant of MPNNs could achieve state-of-the-art performance in predicting molecular properties.

Concurrently, GraphSAGE took a similar idea as Eq. (21) using multiple aggregating functions as follows:

where [⋅,⋅]\left[\cdot,\cdot\right] is the concatenation operation and AGGREGATE(⋅)\text{AGGREGATE}(\cdot) represents the aggregating function. The authors suggested three aggregating functions: the element-wise mean, an LSTM, and max-pooling as follows:

where Θpool\mathbf{\Theta}_{\text{pool}} and bpool\mathbf{b}_{\text{pool}} are the parameters to be learned and max⁡{⋅}\max\left\{\cdot\right\} is the element-wise maximum. For the LSTM aggregating function, because an neighbors order is needed, the authors adopted a simple random order.

Mixture model network (MoNet) also tried to unify the existing GCN models as well as CNNs for manifolds into a common framework using “template matching”:

where u(i,j)\mathbf{u}(i,j) are the pseudo-coordinates of the node pair (vi,vj)(v_{i},v_{j}), Fkl(u)\mathcal{F}^{l}_{k}(\mathbf{u}) is a parametric function to be learned, and hiklh^{l}_{ik} is the kthk^{th} dimension of hil\mathbf{h}^{l}_{i}. In other words, Fkl(u)\mathcal{F}^{l}_{k}(\mathbf{u}) served as a weighting kernel for combining neighborhoods. Then, MoNet adopted the following Gaussian kernel:

where μkl\bm{\mu}^{l}_{k} and Σkl\mathbf{\Sigma}^{l}_{k} are the mean vectors and diagonal covariance matrices to be learned, respectively. The pseudo-coordinates were degrees as in Kipf and Welling , i.e.,

Graph networks (GNs) proposed a more general framework for both GCNs and GNNs that learned three sets of representations: hil,eijl\mathbf{h}_{i}^{l},\mathbf{e}_{ij}^{l}, and zl\mathbf{z}^{l} as the representation for nodes, edges, and the entire graph, respectively. These representations were learned using three aggregation and three updating functions:

In summary, the convolution operations have evolved from the spectral domain to the spatial domain and from multistep neighbors to the immediate neighbors. Currently, gathering information from the immediate neighbors (as in Eq. (14)) and following the framework of Eqs. (21)(22)(27) are the most common choices for graph convolution operations.

2 Readout Operations

Using graph convolution operations, useful node features can be learned to solve many node-focused tasks. However, to tackle graph-focused tasks, node information needs to be aggregated to form a graph-level representation. In the literature, such procedures are usually called the readout operationsReadout operations are also related to graph coarsening, i.e., reducing a large graph to a smaller graph, because a graph-level representation can be obtained by coarsening the graph to a single node. Some papers use these two terms interchangeably.. Based on a regular and local neighborhood, standard CNNs conduct multiple stride convolutions or poolings to gradually reduce the resolution. Since graphs lack a grid structure, these existing methods cannot be used directly.

Order invariance. A critical requirement for the graph readout operations is that the operation should be invariant to the node order, i.e., if we change the indices of nodes and edges using a bijective function between two node sets, the representation of the entire graph should not change. For example, whether a drug can treat certain diseases depends on its inherent structure; thus, we should get identical results if we represent the drug using different node indices. Note that because this problem is related to the graph isomorphism problem, of which the best-known algorithm is quasipolynomial , we only can find a function that is order-invariant but not vice versa in a polynomial time, i.e., even two structurally different graphs may have the same representation.

The most basic order-invariant operations involve simple statistics such as summation, averaging or max-pooling , i.e.,

where hG\mathbf{h}_{G} is the representation of the graph GG and hiL\mathbf{h}^{L}_{i} is the representation of node viv_{i} in the final layer LL. However, such first-moment statistics may not be sufficiently representative to distinguish different graphs.

Kearnes et al. suggested considering the distribution of node representations by using fuzzy histograms . The basic idea behind fuzzy histograms is to construct several “histogram bins” and then calculate the memberships of hiL\mathbf{h}^{L}_{i} to these bins, i.e., by regarding node representations as samples and matching them to some pre-defined templates, and finally return the concatenation of the final histograms. In this way, nodes with the same sum/average/maximum but with different distributions can be distinguished.

Another commonly used approach for aggregating node representation is to add a fully connected (FC) layer as the final layer , i.e.,

2.2 Hierarchical Clustering

Rather than a dichotomy between node and graph level structures, graphs are known to exhibit rich hierarchical structures , which can be explored by hierarchical clustering methods as shown in Figure 4. For example, a density-based agglomerative clustering was used in Bruna et al. and multi-resolution spectral clustering was used in Henaff et al. . ChebNet and MoNet adopted another greedy hierarchical clustering algorithm, Graclus , to merge two nodes at a time, along with a fast pooling method to rearrange the nodes into a balanced binary tree. ECC adopted another hierarchical clustering method by performing eigendecomposition . However, these hierarchical clustering methods are all independent of the graph convolutions (i.e., they can be performed as a preprocessing step and are not trained in an end-to-end fashion).

To solve that problem, DiffPool proposed a differentiable hierarchical clustering algorithm jointly trained with the graph convolutions. Specifically, the authors proposed learning a soft cluster assignment matrix in each layer using the hidden representations as follows:

where H^l+1\hat{\mathbf{H}}^{l+1} is obtained by applying a graph convolution layer to Hl\mathbf{H}^{l}, i.e., coarsening the graph from NlN_{l} nodes to Nl+1N_{l+1} nodes in each layer after the convolution operation. The initial number of nodes is N0=NN_{0}=N and the last layer is NL=1N_{L}=1, i.e., a single node that represents the entire graph. Because the cluster assignment operation is soft, the connections between clusters are not sparse; thus the time complexity of the method is O(N2)O(N^{2}) in principle.

2.3 Imposing Orders and Others

As mentioned in Section 4.1.3, PATCHY-SAN and SortPooling took the idea of imposing a node order and then resorted to standard 1-D pooling as in CNNs. Whether these methods can preserve order invariance depends on how the order is imposed, which is another research field that we refer readers to for a survey. However, whether imposing a node order is a natural choice for graphs and if so, what the best node orders are constitute still on-going research topics.

In addition to the aforementioned methods, there are some heuristics. In GNNs , the authors suggested adding a special node connected to all nodes to represent the entire graph. Similarly, GNs proposed to directly learn the representation of the entire graph by receiving messages from all nodes and edges.

MPNNs adopted set2set , a modification of the seq2seq model. Specifically, set2set uses a “Read-Process-and-Write” model that receives all inputs simultaneously, computes internal memories using an attention mechanism and an LSTM, and then writes the outputs. Unlike seq2seq which is order-sensitive, set2set is invariant to the input order.

2.4 Summary

In short, statistics such as averaging or summation are the most simple readout operations, while hierarchical clustering algorithms jointly trained with graph convolutions are more advanced but are also more sophisticated. Other methods such as adding a pseudo node or imposing a node order have also been investigated.

3 Improvements and Discussions

Many techniques have been introduced to further improve GCNs. Note that some of these methods are general and could be applied to other deep learning models on graphs as well.

In the aforementioned GCNs, the node neighborhoods are aggregated with equal or pre-defined weights. However, the influences of neighbors can vary greatly; thus, they should be learned during training rather than being predetermined. Inspired by the attention mechanism , graph attention network (GAT) introduces the attention mechanism into GCNs by modifying the convolution operation in Eq. (13) as follows:

where αijl\alpha_{ij}^{l} is node viv_{i}’s attention to node vjv_{j} in the lthl^{th} layer:

where F(⋅,⋅)\mathcal{F}(\cdot,\cdot) is another function to be learned such as a multi-layer perceptron (MLP). To improve model capacity and stability, the authors also suggested using multiple independent attentions and concatenating the results, i.e., the multi-head attention mechanism as illustrated in Figure 5. GaAN further proposed learning different weights for different heads and applied such a method to the traffic forecasting problem.

HAN proposed a two-level attention mechanism, i.e., a node-level and a semantic-level attention mechanism, for heterogeneous graphs. Specifically, the node-level attention mechanism was similar to a GAT, but also considerd node types; therefore, it could assign different weights to aggregating meta-path-based neighbors. The semantic-level attention then learned the importance of different meta-paths and outputed the final results.

3.2 Residual and Jumping Connections

Many researches have observed that the most suitable depth for the existing GCNs is often very limited, e.g., 2 or 3 layers. This problem is potentially due to the practical difficulties involved in training deep GCNs or the over-smoothing problem, i.e., all nodes in deeper layers have the same representation . To remedy this problem, residual connections similar to ResNet can be added to GCNs. For example, Kipf and Welling added residual connections into Eq. (14) as follows:

They showed experimentally that adding such residual connections could allow the depth of the network to increase, which is similar to the results of ResNet.

Column network (CLN) adopted a similar idea by using the following residual connections with learnable weights:

where h~il+1\widetilde{\mathbf{h}}^{l+1}_{i} is calculated similar to Eq. (14) and αil\bm{\alpha}^{l}_{i} is a set of weights calculated as follows:

Inspired by personalized PageRank, PPNP defined graph convolutions with teleportation to the initial layer:

where H0=Fθ(FV)\mathbf{H}_{0}=\mathcal{F}_{\theta}(\mathbf{F}^{V}) and α\alpha is a hyper-parameter. Note that all the parameters are in Fθ(⋅)\mathcal{F}_{\theta}(\cdot) rather than in the graph convolutions.

Jumping knowledge networks (JK-Nets) proposed another architecture to connect the last layer of the network with all the lower hidden layers, i.e., by “jumping” all the representations to the final output, as illustrated in Figure 6. In this way, the model can learn to selectively exploit information from different layers. Formally, JK-Nets was formulated as follows:

where hifinal\mathbf{h}_{i}^{\text{final}} is the final representation for node viv_{i}, AGGREGATE(⋅)(\cdot) is the aggregating function, and LL is the number of hidden layers. JK-Nets used three aggregating functions similar to GraphSAGE : concatenation, max-pooling, and the LSTM attention. The experimental results showed that adding jump connections could improve the performance of multiple GCNs.

3.3 Edge Features

The aforementioned GCNs mostly focus on utilizing node features and graph structures. In this subsection, we briefly discuss how to use another important source of information: the edge features.

For simple edge features with discrete values such as the edge type, a straightforward method is to train different parameters for different edge types and aggregate the results. For example, Neural FPs trained different parameters for nodes with different degrees, which corresponds to the implicit edge feature of bond types in a molecular graph, and then summed over the results. CLN trained different parameters for different edge types in a heterogeneous graph and averaged the results. Edge-conditioned convolution (ECC) also trained different parameters based on edge types and applied them to graph classification. Relational GCNs (R-GCNs) adopted a similar idea for knowledge graphs by training different weights for different relation types. However, these methods are suitable only for a limited number of discrete edge features.

DCNN proposed another method to convert each edge into a node connected to the head and tail node of that edge. After this conversion, edge features can be treated as node features.

In other words, nodes in the line graph are directed edges in the original graph, and two nodes in the line graph are connected if information can flow through their corresponding edges in the original graph. Then, LGCN adopted two GCNs: one on the original graph and one on the line graph.

Kearnes et al. proposed an architecture using a “weave module”. Specifically, they learned representations for both nodes and edges and exchanged information between them in each weave module using four different functions: node-to-node (NN), node-to-edge (NE), edge-to-edge (EE) and edge-to-node (EN):

3.4 Sampling Methods

One critical bottleneck when training GCNs for large-scale graphs is efficiency. As shown in Section 4.1.4, many GCNs follow a neighborhood aggregation scheme. However, because many real graphs follow a power-law distribution (i.e., a few nodes have very large degrees), the number of neighbors can expand extremely quickly. To deal with this problem, two types of sampling methods have been proposed: neighborhood samplings and layer-wise samplings, as illustrated in Figure 7.

In neighborhood samplings, the sampling is performed for each node during the calculations. GraphSAGE uniformly sampled a fixed number of neighbors for each node during training. PinSage proposed sampling neighbors using random walks on graphs along with several implementation improvements including coordination between the CPU and GPU, a map-reduce inference pipeline, and so on. PinSage was shown to be capable of handling a real billion-scale graph. StochasticGCN further proposed reducing the sampling variances by using the historical activations of the last batches as a control variate, allowing for arbitrarily small sample sizes with a theoretical guarantee.

Instead of sampling neighbors of nodes, FastGCN adopted a different strategy: it sampled nodes in each convolutional layer (i.e., a layer-wise sampling) by interpreting the nodes as i.i.d. samples and the graph convolutions as integral transforms under probability measures. FastGCN also showed that sampling nodes via their normalized degrees could reduce variances and lead to better performance. Adapt further proposed sampling nodes in the lower layers conditioned on their top layer; this approach was more adaptive and applicable to explicitly reduce variances.

3.5 Inductive Setting

Another important aspect of GCNs is that whether they can be applied to an inductive setting, i.e., training on a set of nodes or graphs and testing on another unseen set of nodes or graphs. In principle, this goal is achieved by learning a mapping function on the given features that are not dependent on the graph basis and can be transferred across nodes or graphs. The inductive setting was verified in GraphSAGE , GAT , GaAN , and FastGCN . However, the existing inductive GCNs are suitable only for graphs with explicit features. How to conduct inductive learnings for graphs without explicit features, usually called the out-of-sample problem , remains largely open in the literature.

3.6 Theoretical Analysis

To understand the effectiveness of GCNs, some theoretical analyses have been proposed that can be divided into three categories: node-focused tasks, graph-focused tasks, and general analysis.

For node-focused tasks, Li et al. first analyzed the performance of GCNs by using a special form of Laplacian smoothing, which makes the features of nodes in the same cluster similar. The original Laplacian smoothing operation is formulated as follows:

where hi\mathbf{h}_{i} and hi′\mathbf{h}^{\prime}_{i} are the original and smoothed features of node viv_{i}, respectively. We can see that Eq. (41) is very similar to the graph convolution in Eq. (13). Based on this insight, Li et al. also proposed a co-training and a self-training method for GCNs.

Recently, Wu et al. analyzed GCNs from a signal processing perspective. By regarding node features as graph signals, they showed that Eq. (13) is basically a fixed low-pass filter. Using this insight, they proposed an extremely simplified graph convolution (SGC) architecture by removing all the nonlinearities and collapsing the learning parameters into one matrix:

The authors showed that such a “non-deep-learning” GCN variant achieved comparable performance to existing GCNs in many tasks. Maehara enhanced this result by showing that the low-pass filtering operation did not equip GCNs with a nonlinear manifold learning ability, and further proposed GFNN model to remedy this problem by adding a MLP after the graph convolution layers.

For graph-focused tasks, Kipf and Welling and the authors of SortPooling both considered the relationship between GCNs and graph kernels such as the Weisfeiler-Lehman (WL) kernel , which is widely used in graph isomorphism tests. They showed that GCNs are conceptually a generalization of the WL kernel because both methods iteratively aggregate information from node neighbors. Xu et al. formalized this idea by proving that the WL kernel provides an upper bound for GCNs in terms of distinguishing graph structures. Based on this analysis, they proposed graph isomorphism network (GIN) and showed that a readout operation using summation and a MLP can achieve provably maximum discriminative power, i.e., the highest training accuracy in graph classification tasks.

For general analysis, Scarselli et al. showed that the Vapnik-Chervonenkis dimension (VC-dim) of GCNs with different activation functions has the same scale as the existing RNNs. Chen et al. analyzed the optimization landscape of linear GCNs and showed that any local minimum is relatively close to the global minimum under certain simplifications. Verma and Zhang analyzed the algorithmic stability and generalization bound of GCNs. They showed that single-layer GCNs satisfy the strong notion of uniform stability if the largest absolute eigenvalue of the graph convolution filters is independent of the graph size.

Graph Autoencoders

The autoencoder (AE) and its variations have been widely applied in unsupervised learning tasks and are suitable for learning node representations for graphs. The implicit assumption is that graphs have an inherent, potentially nonlinear low-rank structure. In this section, we first elaborate graph autoencoders and then introduce graph variational autoencoders and other improvements. The main characteristics of GAEs are summarized in Table V.

The use of AEs for graphs originated from sparse autoencoder (SAE) . The basic idea is that, by regarding the adjacency matrix or its variations as the raw features of nodes, AEs can be leveraged as a dimensionality reduction technique to learn low-dimensional node representations. Specifically, SAE adopted the following L2-reconstruction loss:

Structure deep network embedding (SDNE) filled in the puzzle by showing that the L2-reconstruction loss in Eq. (43) actually corresponds to the second-order proximity between nodes, i.e., two nodes share similar latten representations if they have similar neighborhoods, which is a well-studied concept in network science known as collaborative filtering or triangle closure . Motivated by network embedding methods showing that the first-order proximity is also important , SDNE modified the objective function by adding another Laplacian eigenmaps term :

i.e., two nodes also share similar latent representations if they are directly connected. The authors also modified the L2-reconstruction loss by using the adjacency matrix and assigning different weights to zero and non-zero elements:

where hi=F(A(i,:))\mathbf{h}_{i}=\mathcal{F}\left(\mathbf{A}\left(i,:\right)\right), bij=1b_{ij}=1 if A(i,j)=0\mathbf{A}(i,j)=0; otherwise bij=β>1b_{ij}=\beta>1, and β\beta is another hyper-parameter. The overall architecture of SDNE is shown in Figure 8.

Motivated by another line of studies, a contemporary work DNGR replaced the transition matrix P\mathbf{P} in Eq. (43) with the positive pointwise mutual information (PPMI) matrix defined in Eq. (20). In this way, the raw features can be associated with some random walk probability of the graph . However, constructing the input matrix has a time complexity of O(N2)O(N^{2}), which is not scalable to large-scale graphs.

GC-MC took a different approach by using the GCN proposed by Kipf and Welling as the encoder:

and using a simple bilinear function as the decoder:

where Θde\mathbf{\Theta}_{de} are the decoder parameters. Using this approach, node features were naturally incorporated. For graphs without node features, a one-hot encoding of node IDs was utilized. The authors demonstrated the effectiveness of GC-MC on the recommendation problem on bipartite graphs.

Instead of reconstructing the adjacency matrix or its variations, DRNE proposed another modification that directly reconstructed the low-dimensional node vectors by aggregating neighborhood information using an LSTM. Specifically, DRNE adopted the following objective function:

Because an LSTM requires its inputs to be a sequence, the authors suggested ordering the node neighborhoods based on their degrees. They also adopted a neighborhood sampling technique for nodes with large degrees to prevent an overlong memory. The authors proved that such a method can preserve regular equivalence as well as many centrality measures of nodes, such as PageRank .

Unlike the above works that map nodes into a low-dimensional vector, Graph2Gauss (G2G) proposed encoding each node as a Gaussian distribution hi=N(M(i,:),diag(Σ(i,:)))\mathbf{h}_{i}=\mathcal{N}\left(\mathbf{M}(i,:),diag\left(\mathbf{\Sigma}(i,:)\right)\right) to capture the uncertainties of nodes. Specifically, the authors used a deep mapping from the node attributes to the means and variances of the Gaussian distribution as the encoder:

where FM(⋅)\mathcal{F}_{\mathbf{M}}(\cdot) and FΣ(⋅)\mathcal{F}_{\mathbf{\Sigma}}(\cdot) are the parametric functions that need to be learned. Then, instead of using an explicit decoder function, they used pairwise constraints to learn the model:

where d(i,j)d(i,j) is the shortest distance from node viv_{i} to vjv_{j} and KL(q(⋅)∣∣p(⋅))\text{KL}(q(\cdot)||p(\cdot)) is the Kullback-Leibler (KL) divergence between q(⋅)q(\cdot) and p(⋅)p(\cdot) . In other words, the constraints ensure that the KL-divergence between node representations has the same relative order as the graph distance. However, because Eq. (50) is hard to optimize, an energy-based loss was adopted as a relaxation:

where D={(i,j,j′)∣d(i,j)<d(i,j′)}\mathcal{D}=\left\{(i,j,j^{\prime})|d(i,j)<d(i,j^{\prime})\right\} and Eij=KL(hj∣∣hi)E_{ij}=\text{KL}(\mathbf{h}_{j}||\mathbf{h}_{i}). The authors further proposed an unbiased sampling strategy to accelerate the training process.

2 Variational Autoencoders

Different from the aforementioned autoencoders, variational autoencoders (VAEs) are another type of deep learning method that combines dimensionality reduction with generative models. Its potential benefits include tolerating noise and learning smooth representations . VAEs were first introduced to graph data in VGAE , where the decoder was a simple linear product:

in which the node representation was assumed to follow a Gaussian distribution q(hi∣M,Σ)=N(hi∣M(i,:),diag(Σ(i,:)))q\left(\mathbf{h}_{i}|\mathbf{M},\mathbf{\Sigma}\right)=\mathcal{N}\left(\mathbf{h}_{i}|\mathbf{M}(i,:),diag\left(\mathbf{\Sigma}(i,:)\right)\right). For the encoder of the mean and variance matrices, the authors also adopted the GCN proposed by Kipf and Welling :

Then, the model parameters were learned by minimizing the variational lower bound :

However, because this approach required reconstructing the full graph, its time complexity is O(N2)O(N^{2}).

Motivated by SDNE and G2G, DVNE proposed another VAE for graph data that also represented each node as a Gaussian distribution. Unlike the existing works that had adopted KL-divergence as the measurement, DVNE used the Wasserstein distance to preserve the transitivity of the nodes similarities. Similar to SDNE and G2G, DVNE also preserved both the first and second-order proximity in its objective function:

where Eij=W2(hj∣∣hi)E_{ij}=W_{2}\left(\mathbf{h}_{j}||\mathbf{h}_{i}\right) is the 2nd2^{nd} Wasserstein distance between two Gaussian distributions hj\mathbf{h}_{j} and hi\mathbf{h}_{i} and D={(i,j,j′)∣j∈N(i),j′∉N(i)}\mathcal{D}=\left\{(i,j,j^{\prime})|j\in\mathcal{N}(i),j^{\prime}\notin\mathcal{N}(i)\right\} is a set of triples corresponding to the ranking loss of the first-order proximity. The reconstruction loss was defined as follows:

where P\mathbf{P} is the transition matrix and Z\mathbf{Z} represents samples drawn from H\mathbf{H}. The framework is shown in Figure 9. Using this approach, the objective function can be minimized as in conventional VAEs using the reparameterization trick .

3 Improvements and Discussions

Several improvements have also been proposed for GAEs.

An adversarial training schemeWe will discuss more adversarial methods for graphs in Section 7. was incorporated into GAEs as an additional regularization term in ARGA . The overall architecture is shown in Figure 10. Specifically, the encoder of GAEs was used as the generator while the discriminator aimed to distinguish whether a latent representation came from the generator or from a prior distribution. In this way, the autoencoder was forced to match the prior distribution as a regularization. The objective function was:

where L2\mathcal{L}_{2} is the reconstruction loss in GAEs and LGAN\mathcal{L}_{GAN} is

where G(FV,A)\mathcal{G}\left(\mathbf{F}^{V},\mathbf{A}\right) is a generator that uses the graph convolutional encoder from Eq. (53), D(⋅)\mathcal{D}(\cdot) is a discriminator based on the cross-entropy loss, and php_{\mathbf{h}} is the prior distribution. The study adopted a simple Gaussian prior, and the experimental results demonstrated the effectiveness of the adversarial training scheme.

Concurrently, NetRA also proposed using a generative adversarial network (GAN) to enhance the generalization ability of graph autoencoders. Specifically, the authors used the following objective function:

where LLE\mathcal{L}_{LE} is the Laplacian eigenmaps objective function shown in Eq. (44). In addition, the authors adopted an LSTM as the encoder to aggregate information from neighborhoods similar to Eq. (48). Instead of sampling only immediate neighbors and ordering the nodes using degrees as in DRNE , the authors used random walks to generate the input sequences. In contrast to ARGA, NetRA considered the representations in GAEs as the ground-truth and adopted random Gaussian noises followed by an MLP as the generator.

3.2 Inductive Learning

Similar to GCNs, GAEs can be applied to the inductive learning setting if node attributes are incorporated in the encoder. This can be achieved by using a GCN as the encoder, such as in GC-MC , VGAE , and VGAE , or by directly learning a mapping function from node features as in G2G . Because the edge information is utilized only when learning the parameters, the model can also be applied to nodes unseen during training. These works also show that although GCNs and GAEs are based on different architectures, it is possible to use them jointly, which we believe is a promising future direction.

3.3 Similarity Measures

In GAEs, many similarity measures have been adopted, for example, L2-reconstruction loss, Laplacian eigenmaps, and the ranking loss for graph AEs, and KL divergence and Wasserstein distance for graph VAEs. Although these similarity measures are based on different motivations, how to choose an appropriate similarity measure for a given task and model architecture remains unstudied. More research is needed to understand the underlying differences between these metrics.

Graph Reinforcement Learning

One aspect of deep learning not yet discussed is reinforcement learning (RL), which has been shown to be effective in AI tasks such as playing games . RL is known to be good at learning from feedbacks, especially when dealing with non-differentiable objectives and constraints. In this section, we review Graph RL methods. Their main characteristics are summarized in Table VI.

GCPN utilized RL to generate goal-directed molecular graphs while considering non-differential objectives and constraints. Specifically, the graph generation is modeled as a Markov decision process of adding nodes and edges, and the generative model is regarded as an RL agent operating in the graph generation environment. By treating agent actions as link predictions, using domain-specific as well as adversarial rewards, and using GCNs to learn the node representations, GCPN can be trained in an end-to-end manner using a policy gradient .

A concurrent work, MolGAN , adopted a similar idea of using RL for generating molecular graphs. However, rather than generating the graph through a sequence of actions, MolGAN proposed directly generating the full graph; this approach worked particularly well for small molecules.

GTPN adopted RL to predict chemical reaction products. Specifically, the agent acted to select node pairs in the molecule graph and predicted their new bonding types, and rewards were given both immediately and at the end based on whether the predictions were correct. GTPN used a GCN to learn the node representations and an RNN to memorize the prediction sequence.

GAM applied RL to graph classification by using random walks. The authors modeled the generation of random walks as a partially observable Markov decision process (POMDP). The agent performed two actions: first, it predicted the label of the graph; then, it selected the next node in the random walk. The reward was determined simply by whether the agent correctly classified the graph, i.e.,

where rt=1r_{t}=1 represents a correct prediction; otherwise, rt=−1r_{t}=-1. TT is the total time steps and StS_{t} is the environment.

DeepPath and MINERVA both adopted RL for knowledge graph (KG) reasoning. Specifically, DeepPath targeted at pathfinding, i.e., find the most informative path between two target nodes, while MINERVA tackled question-answering tasks, i.e., find the correct answer node given a question node and a relation. In both methods, the RL agents need to predict the next node in the path at each step and output a reasoning path in the KG. Agents receive rewards if the paths reach the correct destinations. DeepPath also added a regularization term to encourage the path diversity.

Graph Adversarial Methods

Adversarial methods such as GANs and adversarial attacks have drawn increasing attention in the machine learning community in recent years. In this section, we review how to apply adversarial methods to graphs. The main characteristics of graph adversarial methods are summarized in Table VII.

The basic idea behind a GAN is to build two linked models: a discriminator and a generator. The goal of the generator is to “fool” the discriminator by generating fake data, while the discriminator aims to distinguish whether a sample comes from real data or is generated by the generator. Subsequently, both models benefit from each other by joint training using a minimax game. Adversarial training has been shown to be effective in generative models and enhancing the generalization ability of discriminative models. In Section 5.3.1 and Section 6, we reviewed how adversarial training schemes are used in GAEs and Graph RL, respectively. Here, we review several other adversarial training methods on graphs in detail.

GraphGAN proposed using a GAN to enhance graph embedding methods with the following objective function:

The discriminator D(⋅)\mathcal{D}(\cdot) and the generator G(⋅)\mathcal{G}(\cdot) are as follows:

where dv\mathbf{d}_{v} and gv\mathbf{g}_{v} are the low-dimensional embedding vectors for node vv in the discriminator and the generator, respectively. Combining the above equations, the discriminator actually has two objectives: the node pairs in the original graph should possess large similarities, while the node pairs generated by the generator should possess small similarities. This architecture is similar to network embedding methods such as LINE , except that negative node pairs are generated by the generator G(⋅)\mathcal{G}(\cdot) instead of by random samplings. The authors showed that this method enhanced the inference abilities of the node embedding vectors.

Adversarial network embedding (ANE) also adopted an adversarial training scheme to improve network embedding methods. Similar to ARGA , ANE used a GAN as an additional regularization term to existing network embedding methods such as DeepWalk by imposing a prior distribution as the real data and regarding the embedding vectors as generated samples.

GraphSGAN used a GAN to enhance semi-supervised learning on graphs. Specifically, the authors observed that fake nodes should be generated in the density gaps between subgraphs to weaken the propagation effect across different clusters of the existing models. To achieve that goal, the authors designed a novel optimization objective with elaborate loss terms to ensure that the generator generated samples in the density gaps at equilibrium.

NetGAN adopted a GAN for graph generation tasks. Specifically, the authors regarded graph generation as a task to learn the distribution of biased random walks and adopted a GAN framework to generate and discriminate among random walks using an LSTM. The experiments showed that using random walks could also learn global network patterns.

2 Adversarial Attacks

Adversarial attacks are another class of adversarial methods intended to deliberately “fool” the targeted methods by adding small perturbations to data. Studying adversarial attacks can deepen our understanding of the existing models and inspire more robust architectures. We review the graph-based adversarial attacks below.

Nettack first proposed attacking node classification models such as GCNs by modifying graph structures and node attributes. Denoting the targeted node as v0v_{0} and its true class as ctruec_{true}, the targeted model as F(A,FV)\mathcal{F}(\mathbf{A},\mathbf{F}^{V}) and its loss function as LF(A,FV)\mathcal{L}_{\mathcal{F}}(\mathbf{A},\mathbf{F}^{V}), the model adopted the following objective function:

where A′\mathbf{A}^{\prime} and FV′\mathbf{F}^{V\prime} are the modified adjacency matrix and node feature matrix, respectively, Z\mathbf{Z} represents the classification probabilities predicted by F(⋅)\mathcal{F}(\cdot), and P\mathcal{P} is the space determined by the attack constraints. Simply speaking, the optimization aims to find the best legitimate changes in graph structures and node attributes to cause v0v_{0} to be misclassified. The θ∗\theta^{*} indicates that the attack is causative, i.e., the attack occurs before training the targeted model. The authors proposed several constraints for the attacks. The most important constraint is that the attack should be “unnoticeable”, i.e., it should make only small changes. Specifically, the authors proposed to preserve data characteristics such as node degree distributions and feature co-occurrences. The authors also proposed two attacking scenarios, direct attack (directly attacking v0v_{0}) and influence attack (only attacking other nodes), and several relaxations to make the optimization tractable.

Concurrently, Dai et al. studied adversarial attacks for graphs with an objective function similar to Eq. (63); however, they focused on the case in which only graph structures were changed. Instead of assuming that the attacker possessed all the information, the authors considered several settings in which different amounts of information were available. The most effective strategy, RL-S2V, adopted structure2vec to learn the node and graph representations and used reinforcement learning to solve the optimization. The experimental results showed that the attacks were effective for both node and graph classification tasks.

The aforementioned two attacks are targeted, i.e., they are intended to cause misclassification of some targeted node v0v_{0}. Zugner and Gunnemann were the first to study non-targeted attacks, which were intended to reduce the overall model performance. They treated the graph structure as hyper-parameters to be optimized and adopted meta-gradients in the optimization process, along with several techniques to approximate the meta-gradients.

Discussions and Conclusion

Thus far, we have reviewed the different graph-based deep learning architectures as well as their similarities and differences. Next, we briefly discuss their applications, implementations, and future directions before summarizing this paper.

In addition to standard graph inference tasks such as node or graph classificationA collection of methods for common tasks is listed in Appendix B., graph-based deep learning methods have also been applied to a wide range of disciplines, including modeling social influence , recommendation , chemistry and biology , physics , disease and drug prediction , gene expression , natural language processing (NLP) , computer vision , traffic forecasting , program induction , solving graph-based NP problems , and multi-agent AI systems .

A thorough review of these methods is beyond the scope of this paper due to the sheer diversity of these applications; however, we list several key inspirations. First, it is important to incorporate domain knowledge into the model when constructing a graph or choosing architectures. For example, building a graph based on the relative distance may be suitable for traffic forecasting problems, but may not work well for a weather prediction problem where the geographical location is also important. Second, a graph-based model can usually be built on top of other architectures rather than as a stand-alone model. For example, the computer vision community usually adopts CNNs for detecting objects and then uses graph-based deep learning as a reasoning module . For NLP problems, GCNs can be adopted as syntactic constraints . As a result, key key challenge is how to integrate different models. These applications also show that graph-based deep learning not only enables mining the rich value underlying the existing graph data but also helps to naturally model relational data as graphs, greatly widening the applicability of graph-based deep learning models.

2 Implementations

Recently, several open libraries have been made available for developing deep learning models on graphs. These libraries are listed in Table VIII. We also collected a list of source code (mostly from their original authors) for the studies discussed in this paper. This repository is included in Appendix A. These open implementations make it easy to learn, compare, and improve different methods. Some implementations also address the problem of distributed computing, which we do not discuss in this paper.

3 Future Directions

There are several ongoing or future research directions which are also worthy of discussion:

New models for unstudied graph structures. Due to the extremely diverse structures of graph data, the existing methods are not suitable for all of them. For example, most methods focus on homogeneous graphs, while heterogeneous graphs are seldom studied, especially those containing different modalities such as those in . Signed networks, in which negative edges represent conflicts between nodes, also have unique structures, and they pose additional challenges to the existing methods . Hypergraphs, which represent complex relations between more than two objects , are also understudied. Thus, an important next step is to design specific deep learning models to handle these types of graphs.

Compositionality of existing models. As shown multiple times in this paper, many of the existing architectures can be integrated: for example, using a GCN as a layer in GAEs or Graph RL. In addition to designing new building blocks, how to systematically composite these architectures is an interesting future direction. In this process, how to incorporate interdisciplinary knowledge in a principled way rather than on a case-by-case basis is also an open problem. One recent work, graph networks , takes the first step and focuses on using a general framework of GNNs and GCNs for relational reasoning problems. AutoML may also be helpful by reducing the human burden of assembling different components and choosing hyper-parameters .

Dynamic graphs. Most of the existing methods focus on static graphs. However, many real graphs are dynamic in nature: their nodes, edges, and features can change over time. For example, in social networks, people may establish new social relations, remove old relations, and their features, such as hobbies and occupations, can change over time. New users may join the network and existing users may leave. How to model the evolving characteristics of dynamic graphs and support incremental updates to model parameters remain largely unaddressed. Some preliminary works have obtained encouraging results by using Graph RNNs .

Interpretability and robustness. Because graphs are often related to other risk-sensitive scenarios, the ability to interpret the results of deep learning models on graphs is critical in decision-making problems. For example, in medicine or disease-related problems, interpretability is essential in transforming computer experiments into applications for clinical use. However, interpretability for graph-based deep learning is even more challenging than are other black-box models because graph nodes and edges are often heavily interconnected. In addition, because many existing deep learning models on graphs are sensitive to adversarial attacks as shown in Section 7.2, enhancing the robustness of the existing methods is another important issue. Some pioneering works regarding interpretability and robustness can be found in and , respectively.

4 Summary

The above survey shows that deep learning on graphs is a promising and fast-developing research field that both offers exciting opportunities and presents many challenges. Studying deep learning on graphs constitutes a critical building block in modeling relational data, and it is an important step towards a future with better machine learning and artificial intelligence techniques.

Acknowledgement

The authors thank Jianfei Chen, Jie Chen, William L. Hamilton, Wenbing Huang, Thomas Kipf, Federico Monti, Shirui Pan, Petar Velickovic, Keyulu Xu, Rex Ying for allowing us to use their figures. This work was supported in part by National Program on Key Basic Research Project (No. 2015CB352300), National Key R&D Program of China under Grand 2018AAA0102004, National Natural Science Foundation of China (No. U1936219, No. U1611461, No. 61772304), and Beijing Academy of Artificial Intelligence (BAAI). All opinions, findings, conclusions, and recommendations in this paper are those of the authors and do not necessarily reflect the views of the funding agencies.

References

Appendix A Source Codes

Table IX shows a collection and summary of the source code we collected for the papers discussed in this manuscript. In addition to method names and links, the table also lists the programming language used and the frameworks adopted as well as whether the code was published by the original authors of the paper.

Appendix B Applicability for Common Tasks

Table X summarizes the applicability of different models for six common graph tasks, including node clustering, node classification, network reconstruction, link prediction, graph classification, and graph generation. Note that these results are based on whether the experiments were reported in the original papers.

Appendix C Node Classification Results on Benchmark Datasets

As shown in Appendix B, node classification is the most common task for graph-based deep learning models. Here, we report the results of different methods on five node classification benchmark datasetsThese five benchmark datasets are publicly available at https://github.com/tkipf/gcn or http://snap.stanford.edu/graphsage/.:

Cora, Citeseer, PubMed : These are citation graphs with nodes representing papers, edges representing citations between papers, and papers associated with bag-of-words features and ground-truth topics as labels.

Reddit : Reddit is an online discussion forum in which nodes represent posts and two nodes are connected when they are commented by the same user, and each post contains a low-dimensional word vector as features and a label indicating the Reddit community in which it was posted.

PPI : PPI is a collection of protein-protein interaction graphs for different human tissues. It includes features that represent biological signatures and labels that represent the roles of proteins.

Cora, Citeseer, and Pubmed each include one graph, and the same graph structure is used for both training and testing, thus the tasks are considered transductive. In Reddit and PPI, because the training and testing graphs are different, these two datasets are considered to be inductive node classification benchmarks.

In Table XI, we report the results of different models on these benchmark datasets. The results were extracted from their original papers when a fixed dataset split was adopted. The table shows that many state-of-the-art methods achieve roughly comparable performance on these benchmarks, with differences smaller than one percent. Shchur et al. also found that a fixed dataset split can easily result in spurious comparisons. As a result, although these benchmarks have been widely adopted to compare different models, more comprehensive evaluation setups are critically needed.

Appendix D An Example of Graph Signals

To help understanding GCNs, we provide an example of graph signals and refer readers to for more comprehensive surveys.

Because the eigenvectors QT\mathbf{Q}^{T} are sorted in ascending order based on their corresponding eigenvalues, it has been shown that they form a basis for graph signals based on different “smoothness”. Specifically, eigenvectors corresponding to small eigenvalues represent smooth signals and low frequencies, while eigenvectors corresponding to large eigenvalues represent non-smooth signals and high frequencies, as shown in Fig 11 (B). Note that the smoothness is measured with respect to the graph structure, i.e., whether the signals oscillate across edges in the graph. As a result, f^\hat{\mathbf{f}} provides a spectral representation of the signal f\mathbf{f} as shown in Fig 11 (C). This is similar to the Fourier transform in Euclidean spaces. Using f^\hat{\mathbf{f}}, we can design various signal processing operations. For example, if we apply a low-pass filter, the resulted signal will be more smooth, as shown in Fig 11 (D) (in this example, we set the frequency threshold as 2, i.e., only keeping the lowest 4 frequencies).

Appendix E Time Complexity

In this section, we explain how we obtained the time complexity in all the tables. Specifically, we mainly focus on the time complexity with respect to the graph size, e.g., the number of nodes NN and the number of edges MM, and omit other factors, e.g., the number of hidden dimensions flf_{l} or the number of iterations, since the latter terms are usually set as small constants and are less dominant. Note that we focus on the theoretical results, while the exact efficiency of one algorithm also depends heavily on its implementations and techniques to reduce the constants in the time complexity.

GNN : O(MIf)O(MI_{f}), where IfI_{f} is the number of iterations for Eq. (1) to reach stable points, as shown in the paper.

GGS-NNs : O(MT)O(MT), where TT is a preset maximum pseudo time since the method utilizes all the edges in each updating.

SSE : O(davgS)O(d_{\text{avg}}S), where davgd_{\text{avg}} is the average degree and SS is the total number of samples, as shown in the paper.

You et al. : O(N2)O(N^{2}), as shown in the paper.

DGNN : O(Mdavg)O(Md_{\text{avg}}), where davgd_{\text{avg}} is the average degree since the effect of the one-step propagation of each edge is considered.

RMGCNN : O(MN)O(MN) or O(M)O(M), depending on whether an approximation technique is adopted, as shown in the paper.

Dynamic GCN : O(Mt)O(Mt), where tt denotes the number of time slices since the model runs one GCN at each time slice.

Bruna et al. and Henaff et al. : O(N3)O(N^{3}), due to the time complexity of the eigendecomposition.

ChebNet , Kipf and Welling , CayletNet , GWNN , and Neural FPs : O(M)O(M), as shown in the corresponding papers.

PATCHY-SAN : O(Mlog⁡N)O(M\log N), assuming the method adopts WL to label nodes, as shown in the paper.

LGCN : O(M)O(M) since all the neighbors of each node are sorted in the method.

SortPooling : O(M)O(M), due to the time complexity of adopted graph convolution layers.

DGCN : O(N2)O(N^{2}) since the PPMI matrix is not sparse.

GraphSAGE : O(NsL)O(Ns^{L}), where ss is the size of the sampled neighborhoods and LL is the number of layers, as shown in the paper.

MoNet : O(M)O(M) since only the existing node pairs are involved in the calculation.

GNs : O(M)O(M) since only the existing node pairs are involved in the calculation.

Kearnes et al. : O(M)O(M), since only the existing node pairs are used in the calculation.

DiffPool : O(N2)O(N^{2}) since the coarsened graph is not sparse.

GaAN : O(NsL)O(Ns^{L}), where ss is a preset maximum neighborhood length and LL is the number of layers, as shown in the paper.

HAN : O(Mϕ)O(M_{\phi}), the number of meta-path-based node pairs, as shown in the paper.

CLN : O(M)O(M) since only the existing node pairs are involved in the calculation.

JK-Nets : O(M)O(M), due to the time complexity in adopted graph convolutional layers.

R-GCNs : O(M)O(M) since the edges of different types sum up to the total number of edges of the graph.

PinSage : O(NsL)O(Ns^{L}), where ss is the size of the sampled neighborhoods and LL is the number of layers since a sampling strategy similar to that of GraphSAGE is adopted.

StochasticGCN : O(NsL)O(Ns^{L}), as shown in the paper.

FastGCN and Adapt : O(NsL)O(NsL) since the samples are drawn in each layer instead of in the neighborhoods, as shown in the paper.

Li et al. : O(M)O(M), due to the time complexity in adopted graph convolutional layers.

SGC : O(M)O(M) since the calculation is the same as Kipf and Welling by not adopting nonlinear activations.

GFNN : O(M)O(M) since the calculation is the same as SGC by adding an extra MLP layer.

GIN : O(M)O(M), due to the time complexity in adopted graph convolutional layers.

DGI : O(M)O(M), due to the time complexity in adopted graph convolutional layers.

SAE and SDNE : O(M)O(M), as shown in the corresponding papers.

DNGR : O(N2)O(N^{2}), due to the time complexity of calculating the PPMI matrix.

GC-MC : O(M)O(M) since the encoder adopts the GCN proposed by Kipf and Welling and only the non-zero elements of the graph are considered in the decoder.

DRNE : O(Ns)O(Ns), where ss is a preset maximum neighborhood length, as shown in the paper.

G2G : O(M)O(M), due to the definition of the ranking loss.

VGAE : O(N2)O(N^{2}), due to the reconstruction of all the node pairs.

DVNE : Though the original paper reported to have a time complexity of O(Mdavg)O(Md_{\text{avg}}) where davgd_{\text{avg}} is the average degree, we have confirmed that it can be easily improved to O(M)O(M) through personal communications with the authors.

ARGA/ARVGA : O(N2)O(N^{2}), due to the reconstruction of all the node pairs.

GCPN : O(MN)O(MN) since the embedding of all the nodes are used when generating each edge.

MolGAN and GTPN : O(N2)O(N^{2}) since the scores for all the node pairs have to be calculated.

GAM : O(davgsT)O(d_{\text{avg}}sT), where davgd_{\text{avg}} is the average degree, ss is the number of sampled random walks, and TT is the walk length, as shown in the paper.

DeepPath : O(davgsT+s2T)O(d_{\text{avg}}sT+s^{2}T), where davgd_{\text{avg}} is the average degree, ss is the number of sampled paths, and TT is the path length. The former term corresponds to finding paths and the latter term results from the diversity constraint.

MINERVA : O(davgsT)O(d_{\text{avg}}sT), where davgd_{\text{avg}} is the average degree, ss is the number of sampled paths, and TT is the path length, similar to the pathfinding method in DeepPath .

GraphGAN : O(MN)O(MN), as shown in the paper.

ANE : O(N)O(N), which is the extra time complexity introduced by the model in the generator and the discriminator.

GraphSGAN : O(N2)O(N^{2}), due to the time complexity in the objective function.

Nettack : O(Nd02)O(Nd_{0}^{2}), where d0d_{0} is the degree of the targeted node, as shown in the paper.

Dai et al. : O(M)O(M), which is the time complexity of the most effective strategy RL-S2V, as shown in the paper.

Zugner and Gunnemann : O(N2)O(N^{2}), as shown in the paper.