TL;DR
This paper argues that graph homophily (the tendency for connected nodes to be similar) is the key to why graph contrastive learning (GCL) works well even without data augmentation, unlike in computer vision. They propose HomoGCL, a framework that explicitly leverages homophily by expanding positive pairs to include neighbors, significantly improving GCL performance across various datasets and methods.
What Problem Does This Paper Address?
Self-supervised learning on graphs, particularly using contrastive learning (CL), has become a dominant paradigm. The standard CL approach involves creating two augmented views of the data and learning to make their representations similar while pushing apart representations of different data points. However, a curious observation in graph CL is that it performs reasonably well even without data augmentation, a stark contrast to computer vision CL where augmentation is crucial. This raises a question: what makes graph CL so robust to the absence of augmentation? The authors hypothesize that graph homophily, the principle that "like attracts like" (connected nodes tend to share similar attributes or labels), is the underlying reason. Existing GCL methods implicitly leverage homophily through message passing in Graph Neural Networks (GNNs), but this paper aims to explicitly harness this property to further enhance GCL performance.
Methods
The core of HomoGCL lies in its ability to explicitly leverage graph homophily by intelligently expanding the set of "positive pairs" in the contrastive learning objective. Instead of just considering two augmented views of the same node as a positive pair, HomoGCL also considers neighboring nodes as potential positive pairs.
Here's a breakdown of their approach:
- Homophily-Aware Positive Pair Expansion: The key challenge is that not all neighbors are equally good positive examples. Nodes near decision boundaries might be connected to nodes from different classes (heterophily), leading to "false positives" if treated indiscriminately. HomoGCL addresses this by:
- Soft Clustering: Using a Gaussian Mixture Model (GMM) on node embeddings, they obtain soft cluster assignments for each node. This allows for a probabilistic understanding of node groupings, rather than hard assignments.
- Saliency Calculation: Based on these soft cluster assignments, they compute a "saliency" score for each edge. This saliency represents the estimated probability that two connected nodes are indeed from the same class (i.e., a true positive connection).
- Weighted Contrastive Loss: The standard contrastive loss is modified to incorporate these saliency scores. Edges with higher saliency contribute more to the positive pair similarity, effectively prioritizing intra-class neighbors.
- Homophily Loss: In addition to the contrastive loss, HomoGCL also incorporates an explicit homophily loss. This loss encourages the soft cluster assignments of connected nodes to be similar, further reinforcing the homophily assumption.
- Model-Agnostic Framework: HomoGCL is designed to be a plug-and-play module. It can be combined with existing GCL frameworks (like GRACE, BGRL) by modifying their loss functions to include the saliency-weighted positive pairs and the homophily loss. This means it doesn't require a new GNN architecture but rather enhances existing ones.
- Theoretical Guarantee: The authors provide theoretical analysis showing that their modified contrastive loss (Lcont) is a stricter lower bound of the mutual information between raw node features and learned embeddings compared to standard GCL losses. This provides a theoretical foundation for why HomoGCL improves performance.
Datasets
The paper evaluates HomoGCL on six publicly available real-world benchmark datasets:
- Citation Networks: Cora, CiteSeer, PubMed
- Co-purchase Networks: Amazon-Photo (Photo), Amazon-Computers (Computer)
- Large-scale Citation Network: ogbn-arXiv (arXiv)
These datasets represent a variety of graph structures and sizes, allowing for a comprehensive evaluation of the proposed method.
Key Insights and Ideas
- Homophily is the Unsung Hero of Graph CL: The paper convincingly argues that homophily, not just data augmentation, is the primary reason for the success of graph contrastive learning, especially in scenarios where augmentation is absent. This shifts the focus from complex augmentation strategies to understanding intrinsic graph properties.
- Explicitly Leveraging Homophily is Powerful: By directly incorporating homophily through neighbor-based positive pairs and a dedicated homophily loss, HomoGCL significantly boosts performance beyond existing methods. This suggests that implicit reliance on homophily via GNN message passing might not be fully exploiting this crucial property.
- Distinguishing True vs. False Positives is Key: The paper highlights that simply treating all neighbors as positive is suboptimal. HomoGCL's ability to estimate the probability of a neighbor being a "true positive" using soft clustering and saliency is crucial for avoiding performance degradation.
- Model-Agnosticism is a Major Advantage: HomoGCL's plug-and-play nature makes it highly practical. It can be easily integrated with various existing GCL frameworks, including those that don't rely on negative samples, demonstrating its versatility and broad applicability.
- Augmentation Might Be Overemphasized in GCL: The consistent improvements HomoGCL brings, even to methods that use simple augmentations, suggest that the complexity of graph augmentation might be less critical than previously thought, especially when homophily is explicitly leveraged.
Key Results
- State-of-the-Art Performance: HomoGCL consistently outperforms existing state-of-the-art GCL methods on node classification tasks across five datasets (Cora, CiteSeer, PubMed, Photo, Computer), achieving significant gains, e.g., a 3% accuracy improvement on Cora.
- Improved Node Clustering: HomoGCL also demonstrates superior performance on node clustering tasks on the Photo and Computer datasets, achieving large margins on NMI and ARI metrics.
- Consistent Boost for Existing Methods: When applied as a patch to existing GCL frameworks like GRACE and BGRL, HomoGCL consistently yields notable performance improvements. For instance, it boosts BGRL's accuracy by over 1% on PubMed and Computer.
- Scalability: HomoGCL, when combined with scalable methods like BGRL, shows promising performance on the large-scale ogbn-arXiv dataset, even outperforming other methods and avoiding Out-of-Memory (OOM) issues that plague some other approaches.
- Parameter Insensitivity: Hyperparameter analysis shows that HomoGCL is relatively stable with respect to the number of clusters and the homophily loss coefficient, making it easy to tune and deploy.
- Improved Embeddings: Visualizations of node embeddings using t-SNE reveal that HomoGCL-learned representations exhibit clearer class boundaries and more compact intra-class structures compared to baseline methods.
Limitations and Future Work
- Focus on Homophily: The paper primarily focuses on homophilous graphs, acknowledging that heterophilous graphs (where connected nodes tend to be dissimilar) exist and are a more challenging scenario. While the current work is consistent with prior GCL research in this regard, extending HomoGCL to handle heterophily would be a valuable future direction.
- Computational Overhead: While HomoGCL is described as lightweight, the introduction of k-means clustering and saliency calculation does add some computational overhead compared to base GCL models. The paper analyzes this overhead and finds it to be manageable, but for extremely large graphs, further optimization might be considered.
- Dataset Splits: The paper notes that for some datasets (Photo, Computer), they used random splits due to the absence of publicly accessible ones. While this is a common practice, it's worth noting that performance can sometimes be sensitive to the specific split.
The authors suggest that HomoGCL's model-agnostic nature and its ability to boost performance make it a promising direction for future research in graph contrastive learning. The explicit leveraging of graph properties like homophily appears to be a fruitful avenue for developing more effective and robust GCL methods.
Summary updated