Skip to main content
QUICK REVIEW

[Paper Review] GLSearch: Maximum Common Subgraph Detection via Learning to Search

Yunsheng Bai, Derek Xu|arXiv (Cornell University)|Feb 8, 2020
Advanced Graph Neural NetworksComputer Science11 citations
TL;DR

GLSearch proposes a GNN-based deep reinforcement learning framework that replaces heuristic node selection in branch-and-bound search for Maximum Common Subgraph (MCS) detection. By using a GNN-enhanced Deep Q-Network (DQN) to learn optimal search strategies, GLSearch achieves significantly larger MCS results than state-of-the-art solvers under the same computation budget, especially on large and real-world graphs.

ABSTRACT

Detecting the Maximum Common Subgraph (MCS) between two input graphs is fundamental for applications in drug synthesis, malware detection, cloud computing, etc. However, MCS computation is NP-hard, and state-of-the-art MCS solvers rely on heuristic search algorithms which in practice cannot find good solution for large graph pairs given a limited computation budget. We propose GLSearch, a Graph Neural Network (GNN) based learning to search model. Our model is built upon the branch and bound algorithm, which selects one pair of nodes from the two input graphs to expand at a time. Instead of using heuristics, we propose a novel GNN-based Deep Q-Network (DQN) to select the node pair, allowing the search process faster and more adaptive. To further enhance the training of DQN, we leverage the search process to provide supervision in a pre-training stage and guide our agent during an imitation learning stage. Experiments on synthetic and real-world large graph pairs demonstrate that our model learns a search strategy that is able to detect significantly larger common subgraphs given the same computation budget. Our GLSearch can be potentially extended to solve many other combinatorial problems with constraints on graphs.

Motivation & Objective

  • Address the challenge of detecting the Maximum Common Subgraph (MCS) between two graphs, a fundamental but NP-hard problem in graph similarity analysis.
  • Overcome the limitations of heuristic-based branch-and-bound solvers, which often fail to find high-quality MCS solutions within practical computation budgets.
  • Develop a learnable search policy that adapts to graph structure and topology, improving search efficiency and solution quality.
  • Reduce reliance on expensive pre-computed MCS labels by leveraging self-supervision and imitation learning during training.
  • Enable scalable MCS detection on large real-world graphs, including million-node graphs, where exact solvers are infeasible.

Proposed method

  • Formulates MCS detection as a sequential decision-making problem within a branch-and-bound framework, where each step selects a pair of nodes to expand.
  • Introduces a GNN-based Deep Q-Network (DQN) to replace hand-crafted heuristics for node pair selection, capturing structural and neighborhood features.
  • Reformulates the DQN to operate on node-pair embeddings, enabling the agent to evaluate the long-term impact of each selection on isomorphism and subgraph size.
  • Employs a two-stage training pipeline: pre-training using supervised signals from search trajectories, followed by imitation learning to refine the policy.
  • Uses graph neural networks to encode k-hop neighborhood structures around candidate node pairs, improving representation quality.
  • Leverages the search process itself to generate supervision signals, enabling end-to-end training without requiring ground-truth MCS labels during inference.

Experimental results

Research questions

  • RQ1Can a learned search policy outperform hand-crafted heuristics in finding larger common subgraphs under a fixed computation budget?
  • RQ2To what extent can a GNN-enhanced DQN model generalize across diverse graph types (e.g., chemical, road, circuit, social networks) in MCS detection?
  • RQ3How effective is the combination of pre-training and imitation learning in improving DQN policy performance without relying on labeled MCS instances?
  • RQ4Can the learned policy identify 'critical' nodes (e.g., high-degree or structurally central nodes) that significantly influence MCS size and isomorphism?
  • RQ5Does the model scale effectively to large graphs (e.g., million-node graphs) where traditional solvers fail due to exponential complexity?

Key findings

  • GLSearch detects significantly larger induced common subgraphs than state-of-the-art solvers like McSp on both synthetic and real-world graph pairs, especially under tight computation budgets.
  • On the Nci109 dataset, GLSearch achieves a higher average MCS size than McSp, with visualizations showing more complete and connected subgraphs.
  • In road network graphs (Road), GLSearch outperforms McSp by selecting low-degree nodes first, which better aligns with the chain-like structure of the true MCS.
  • On circuit graphs (Circ), GLSearch correctly matches three high-degree nodes that McSp fails to match due to incorrect node-pair scoring, preserving isomorphism.
  • The learned policy in GLSearch identifies structurally critical nodes and prioritizes them, leading to faster convergence to larger MCS solutions.
  • Ablation studies show that both pre-training and imitation learning stages are essential for achieving high performance, with the GNN-based DQN outperforming simpler models.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.