來自政府資料開放平台的鄉鎮市區界線(TWD97經緯度)
conda env create -f environment.ymlpython src/graphic.py
會產生 adjacency_record.txt 以及 graph_all_towns.png 與 graph_main_island.png
adjacency_record.txt 有鄰接矩陣以及各縣市與台灣的 polygon
要跑台北市
python src/TSP/tsp.py --county 臺北市 --output outs/tsp_taipei_dp.png不建議跑台中市或大於 25 個節點以上的縣市,因為可能會導致你的機器崩潰(我有 125GB RAM 都壞了)。
python src/TSP/gnn_tsp.py --county 臺北市 --output outs/tsp_taipei_dp.pngOS:
- Pop!_OS 22.04 LTS
Devices:
- AMD Ryzen™ 5 5500U with 4.66GB memory and 11.6GB swap
- AMD Ryzen™ 9 9950X with 125GB memory and 20GB swap