Abstract
Hypergraphs are a generalization of graphs in which a hyperedge can connect any number of vertices, allowing for the description of n-ary relationships and high-order information. This paper addresses the fundamental problem of subhypergraph matching. Traditional methods often extend vertex-centric subgraph matching algorithms to hypergraphs, which delays hyperedge verification and underutilizes high-order information, resulting in large search spaces and high costs. We propose HGMatch, an efficient and parallel system that introduces a novel match-by-hyperedge framework. By utilizing hyperedge signatures and set operations for candidate generation, and employing a task-based parallel execution engine with dynamic work stealing, HGMatch achieves bounded memory execution and superior load balancing. Experimental results on 10 real-world datasets demonstrate that HGMatch outperforms state-of-the-art baselines by up to five orders of magnitude while exhibiting near-linear scalability.
Introduction
Hypergraphs provide a robust mathematical framework for modeling complex interactions where relationships involve more than two entities, such as protein complexes or multi-user social interactions. Finding a specific pattern (a query) within a massive data hypergraph is known as subhypergraph matching, an NP-hard problem.
Existing solutions typically adapt "match-by-vertex" algorithms from standard graph theory. These map query vertices to data vertices sequentially, only checking hyperedge constraints after mappings are made. This leads to massive search spaces and redundant computations. HGMatch addresses these inefficiencies by shifting the fundamental matching unit from the vertex to the hyperedge.
Methodology
HGMatch is built upon a "match-by-hyperedge" framework that leverages high-order information early in the search process to prune the search space effectively.
System Architecture
The system is divided into offline preprocessing and online processing phases. During preprocessing, the data hypergraph is indexed based on hyperedge signatures—multisets of labels of the vertices they contain. This allows the online engine to skip irrelevant data partitions entirely.
Key Technical Innovations
- Match-by-Hyperedge Framework: Instead of adding vertices one by one, HGMatch expands partial matches by adding entire hyperedges. This validates multiple vertex relationships simultaneously, transforming a vertex-mapping problem into a significantly smaller edge-mapping problem.
- Set-Based Candidate Generation: Using a lightweight inverted index, the system generates candidate hyperedges through efficient set operations (intersection, union, and difference), which are highly optimized for modern CPU architectures.
- Vertex Profiles: To ensure isomorphic matches without expensive backtracking, HGMatch uses "Vertex Profiles" (a combination of a vertex's label and its incident hyperedges) for fast, hash-based validation.
- Parallel Execution Engine: The engine utilizes a dataflow model with a task-based scheduler. It employs a Last-In-First-Out (LIFO) scheduling strategy to mimic Depth-First Search (DFS) in a parallel context, preventing memory explosion. Dynamic work stealing is used to balance the load across CPU cores and eliminate "straggler" threads.
Experimental Evaluation
The authors evaluated HGMatch on 10 real-world datasets, including biological networks (House Committees), social interactions (StackOverflow), and massive retail logs (Amazon Reviews with over 4.2 million hyperedges).
Performance Highlights
- Speed: In single-threaded tests, HGMatch outperformed extended versions of state-of-the-art algorithms like CFL, DAF, and CECI by an average of five orders of magnitude.
- Robustness: HGMatch was the only system capable of completing all queries on the largest datasets within a one-hour time limit.
- Scalability: The system demonstrated near-perfect linear scalability up to 20 threads, achieving approximately a 20x speedup compared to single-threaded execution.
Conclusion
HGMatch represents a significant shift in subhypergraph matching by prioritizing high-order hyperedge information over traditional vertex-centric approaches. Its combination of signature-based indexing, set-based candidate generation, and a memory-efficient parallel engine makes it uniquely suited for processing massive, complex hypergraphs. Future work will focus on NUMA-aware optimizations to further enhance scalability on multi-socket server architectures.
Summary updated