H-GLow: Accelerating Graph Generation via Hazard-Guided Discrete Flow Matching
Organizations: School of Computation, Information and Technology, Technical University of Munich · Munich Data Science Institute & Munich Center for Machine Learning
Abstract
Discrete flow matching (DFM) offers a promising approach to graph generation; however, generating high-quality graphs with few steps remains challenging due to the strong dependencies between nodes and edges. Although DFM decouples training from sampling, enabling flexible sampling strategies without retraining, existing graph DFM samplers often rely on task-specific heuristics, substantially expanding the hyperparameter space. Moreover, graph DFM models still require sampling budgets comparable to those of diffusion-based approaches, leaving their potential for accelerating graph generation only partially realized. In this work, we introduce H-Glow, a hazard-guided framework for accelerating graph generation built on the decomposition of Continuous-Time Markov chain (CTMC) generators into hazards and conditional jump distributions. H-Glow leverages these quantities to plan graph edits and dynamically adjust the sampling time to graph activity. H-Glow can be adapted to pretrained graph DFM models, substantially improving the generation quality with fewer steps. We further introduce a novel graph DFM model based on the conditional generator matching framework, which directly predicts hazards and conditional jumps, and show that its training objective decomposes exactly into hazard matching and hazard-weighted jump prediction. Experiments on molecular and synthetic graph benchmarks demonstrate improved generation quality with substantially fewer sampling steps.
Figures & tables
| Model | Steps (NFE) | Valid | Relaxed Validity | Unique | FCD |
|---|---|---|---|---|---|
| Training set | – | ||||
| DiGress ( Vignac et al., 2022 ) | 500 (500 0.0) | – | – | ||
| CatFlow ( Eijkelboom et al., 2024 ) | – | – | |||
| DisCo ( Xu et al., 2024 ) | 500 (500 0.0) | – | – | – | |
| Cometh ( Siraudin et al., 2024 ) | 500 (500 0.0) | – | |||
| SID ( Boget, 2025 ) | 500 (500 0.0) | – | – |
| MOSES | GuacaMol | |||||||||||||
| Model | Steps (NFE) | Val. | Unique. | Novelty | Filters | FCD | SNN | Scaf. | Steps (NFE) | Val. | V.U. | V.U.N. | KLD. | FCD |
| Training set | – | – | ||||||||||||
| DiGress ( Vignac et al., 2022 ) | 500 (500 0.0) | 500 (500 0.0) | ||||||||||||
| DisCo ( Xu et al., 2024 ) | 500 (500 0.0) | 500 (500 0.0) | ||||||||||||
| Cometh ( Siraudin et al., 2024 ) | 500 (500 0.0) | 500 (500 0.0) | ||||||||||||
| Cometh-PC ( Siraudin et al., 2024 ) | 500 (500 0.0) | 500 (500 0.0) | ||||||||||||
| Planar | Tree | ||||
| Model | Steps | V.U.N. | Ratio | V.U.N. | Ratio |
| Training set | – | ||||
| EDGE ( Chen et al., 2023 ) | 1000 | ||||
| DiGress ( Vignac et al., 2022 ) | 1000 | ||||
| HSpectre ( Bergmeister et al., 2024 ) | – | ||||
| GruM ( Jo et al., 2023 ) | – | – | – | ||
| Clock | V.U.N. | Ratio | V.U.N. | Ratio |
|---|---|---|---|---|
| Hazard-guided | 99.0 | 1.86 | 99.0 | 1.81 |
| Uniform | 99.5 | 23.43 | 100.0 | 49.11 |
| Polydec-2 | 100.0 | 20.20 | 100.0 | 42.62 |
| Polydec-10 | 99.5 | 5.57 | 99.5 | 12.66 |
| Polydec-20 | 95.5 | 3.88 | 99.5 | 6.08 |
| Variant | Val. | FCD | Val. | FCD |
|---|---|---|---|---|
| H-Glow | 89.5 | 0.98 | 89.9 | 0.96 |
| Hazard-only | 88.1 | 1.10 | 89.2 | 1.12 |
| w/o early stopping | 88.1 | 1.41 | 88.7 | 1.82 |
| w/o hazard annealing | 88.5 | 1.43 | 87.9 | 1.39 |
| Sampler | Val. | FCD | Val. | FCD |
|---|---|---|---|---|
| H-Glow | 89.5 | 0.98 | 89.9 | 0.96 |
| Euler | 80.3 | 1.38 | 85.8 | 1.38 |
| RVF | 86.4 | 1.03 | 87.7 | 1.08 |
Appendix figures & tables12 assets
Supplementary material from the paper’s appendix.
Appendix
| Dataset | # Graphs | Train/Val/Test | Avg. | Max. | Avg. | Max. | ||
|---|---|---|---|---|---|---|---|---|
| QM9 | 130,831 | 97,734/20,042/13,055 | 4 | 4 | 18.9 | 28 | 8.8 | 9 |
| MOSES | 1,936,962 | 1,584,663/176,225/176,074 | 4 | 8 | 46.5 | 62 | 21.7 | 27 |
| GuacaMol | 1,398,213 | 1,118,633/69,926/209,654 | 4 | 12 | 60.4 | 176 | 27.8 | 88 |
| Planar | 200 | 128/32/40 | 1 | 1 | 355.7 | 362 | 64.0 | 64 |
| Tree | 200 | 128/32/40 | 1 | 1 | 126.0 | 126 | 64.0 | 64 |
| QM9 | GuacaMol | MOSES | Planar | Tree | |
| Epochs | 1000 | 250 | 300 | 100000 | 100000 |
| Learning rate | |||||
| Optimizer | AdamW | AdamW | AdamW | AdamW | AdamW |
| AMSGrad | Yes | Yes | Yes | Yes | Yes |
| RRWP steps | 12 | 20 | 20 | 32 | 128 |
| Number of layers | 9 | 12 | 12 | 10 | 10 |
| Model | Sampler | Val. | FCD | Val. | FCD | Val. | FCD |
|---|---|---|---|---|---|---|---|
| Denoiser | Euler | 97.0 | 0.75 | 98.9 | 0.28 | 99.4 | 0.14 |
| H-Glow | Euler | 96.7 | 0.66 | 99.2 | 0.24 | 99.5 | 0.13 |
| Denoiser | H-Glow | 98.9 | 0.31 | 99.0 | 0.21 | 99.0 | 0.11 |
| H-Glow | H-Glow | 99.2 | 0.37 | 99.1 | 0.10 | 99.2 | 0.10 |
| Dataset | Steps | NFE | |
| QM9 | 19.9 | 0.4 | |
| QM9 | 22.4 | 2.3 | |
| MOSES | 35.9 | 7.0 | |
| MOSES | 47.1 | 15.7 | |
| MOSES | 57.2 | 14.2 | |
| GuacaMol | 40.4 | 8.1 | |
| Sampler | Validity | Unique | Novelty | Filters | FCD | |
|---|---|---|---|---|---|---|
| 50 | RVF (default) | 86.4 | 100.0 | 94.6 | 99.1 | 1.03 |
| 50 | DeFoG (default) | 80.3 | 100.0 | 95.3 | 98.0 | 1.38 |
| 50 | HGLow (ours) | 89.5 | 100.0 | 94.4 | 99.1 | 0.98 |
| 100 | RVF (default) | 87.7 | 100.0 | 94.2 | 99.2 | 1.08 |
| 100 | DeFoG (default) | 85.8 | 100.0 | 90.7 | 99.4 | 1.38 |
| 100 | HGLow (ours) | 89.9 | 99.9 | 93.0 | 99.2 | 0.96 |
| MOSES | GuacaMol | |||||||||||||
| Model | Class | Steps | Val. | Unique. | Novelty | Filters | FCD | SNN | Scaf. | Val. | V.U. | V.U.N. | KLD. | FCD |
| Training set | – | – | ||||||||||||
| DiGress ( Vignac et al., 2022 ) | Diff. | 500 | ||||||||||||
| DisCo ( Xu et al., 2024 ) | Diff. | 500 | ||||||||||||
| Cometh ( Siraudin et al., 2024 ) | Diff. | 500 | ||||||||||||
| Cometh-PC ( Siraudin et al., 2024 ) | Diff. | 500 | ||||||||||||
| Planar | Tree | |||||
| Model | Class | Steps | V.U.N. | Ratio | V.U.N. | Ratio |
| Training set | – | – | ||||
| GraphRNN ( You et al., 2018 ) | AR | – | ||||
| GRAN ( Liao et al., 2019 ) | AR | – | ||||
| BiGG ( Dai et al., 2020 ) | AR | – | ||||
| GraphGen ( Goyal et al., 2020 ) | AR | – | ||||
Graph Generation
Graph generation builds models and algorithms that create graphs with desired structures, properties, or distributions.
See all 67 papers