Learning Shortest Paths with Generative Flow Networks
Organizations: HSE University · CMAP, CNRS, École polytechnique · LMO, Université Paris-Saclay
Abstract
In this paper, we present a novel learning framework for finding shortest paths in graphs utilizing Generative Flow Networks (GFlowNets). First, we examine theoretical properties of GFlowNets in non-acyclic environments in relation to shortest paths. We prove that, if the total flow is minimized, forward and backward policies traverse the environment graph exclusively along shortest paths between the initial and terminal states. Building on this result, we reduce shortest-path finding in an arbitrary unweighted graph to finding a non-acyclic GFlowNet with minimal total flow, and approximate it in practice by training with flow regularization. We experimentally demonstrate the performance of our method in pathfinding in permutation environments and in solving Rubik's Cubes of various sizes. For the latter problems, our approach shows competitive results with state-of-the-art machine learning approaches designed specifically for this task in terms of the solution length, while requiring smaller search budget at test-time.
Figures & tables
| 2x2x2 Rubik’s Cube | 3x3x3 Rubik’s Cube | 4x4x4 Rubik’s Cube | ||||||||||||
| Ours | CayleyPy | Ours | CayleyPy | Ours | CayleyPy | |||||||||
| Beam size | Avg. length | Solve rate | Avg. length | Solve rate | Beam size | Avg. length | Solve rate | Avg. length | Solve rate | Beam size | Avg. length | Solve rate | Avg. length | Solve rate |
| 11.62 | 1.00 | x | 0.00 | x | 0.471 | x | 0.000 | x | 0.07 | x | 0.00 | |||
| 11.24 | 1.00 | x | 0.00 | x | 0.984 | x | 0.001 | x | 0.27 | x | 0.00 | |||
| 10.78 | 1.00 | x | 0.00 | 25.33 | 1.000 | x | 0.687 | x | 0.74 | x | 0.00 | |||
| 10.64 | 1.00 | x | 0.06 | 23.49 | 1.000 | 24.34 | 1.000 | 64.09 | 1.00 | x | 0.16 | |||
Appendix figures & tables1 asset
Supplementary material from the paper’s appendix.
Appendix
Graph-Based Planning
Graph-Based Planning represents states, tasks, or environments as nodes and edges to search for feasible, low-cost action sequences.
See all 99 papers