Home

Awesome

GFlowNet-CombOpt

Pytorch implementation for our paper

Let the Flows Tell: Solving Graph Combinatorial Optimization Problems with GFlowNets.

Dinghuai Zhang, Hanjun Dai, Nikolay Malkin, Aaron Courville, Yoshua Bengio, Ling Pan.

<!-- <p align="center"> --> <img src="https://s1.ax1x.com/2023/05/30/p9jE7P1.png" border="0" width=60% class="center" /> <!-- </p> -->

We formulate a set of graph combinatorial optimization problems as sequential decision-making sampling problems, and design efficient GFlowNet algorithms to tackle them.

Dependency

pip install hydra-core==1.1.0 omegaconf submitit hydra-submitit-launcher
pip install dgl==0.6.1

Data generation

cd data/
python rbgraph_generator.py --num_graph 4000 --save_dir rb200-300/train
python rbgraph_generator.py --num_graph 500 --save_dir rb200-300/test  

Training

cd gflownet/
python main.py input=rb200-300 alg=fl bsit=8