See "DIFUSCO: Graph-based Diffusion Solvers for Combinatorial Optimization" for the paper associated with this codebase.
conda env create -f environment.yml
conda activate difusco
Running TSP experiments requires installing the additional cython package for merging the diffusion heatmap results:
cd difusco/utils/cython_merge
python setup.py build_ext --inplace
cd -
difusco/pl_meta_model.py
: the code for a meta pytorch-lightning model for training and evaluation.difusco/pl_tsp_model.py
: the code for the TSP problemdifusco/pl_mis_model.py
: the code for the MIS problemdifusco/trian.py
: the handler for training and evaluation
Please check the data
folder.
Please check the reproducing_scripts for more details.
Please download the pretrained model checkpoints from here.
If you found this codebase useful, please consider citing the paper:
@inproceedings{
sun2023difusco,
title={{DIFUSCO}: Graph-based Diffusion Solvers for Combinatorial Optimization},
author={Zhiqing Sun and Yiming Yang},
booktitle={Thirty-seventh Conference on Neural Information Processing Systems},
year={2023},
url={https://openreview.net/forum?id=JV8Ff0lgVV}
}