Skip to content

Commit 9c1f716

Browse files
authored
Update README.md
1 parent ee19296 commit 9c1f716

File tree

1 file changed

+17
-15
lines changed

1 file changed

+17
-15
lines changed

README.md

Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,23 @@ Currently, Traveling Salesman Problems and Vehicle Routing Problems are supporte
1010
* pytorch=0.4.1
1111
* matplotlib
1212

13+
# To Run
14+
15+
Run by calling ```python trainer.py```
16+
17+
Tasks and complexity can be changed through the "task" and "nodes" flag:
18+
19+
```python trainer.py --task=vrp --nodes=10```
20+
21+
To restore a checkpoint, you must specify the path to a folder that has "actor.pt" and "critic.pt" checkpoints. Sample weights can be found [here](https://drive.google.com/open?id=1wxccGStVglspW-qIpUeMPXAGHh2HsFpF)
22+
23+
```python trainer.py --task=vrp --nodes=10 --checkpoint=vrp10```
24+
## Differences from paper:
25+
26+
* Uses a GRU instead of LSTM for the decoder network
27+
* Critic takes the raw static and dynamic input states and predicts a reward
28+
* Here we use demand scaling (MAX_DEMAND / MAX_VEHICLE_CAPACITY), and give the depot for the VRP a negative value proportionaly to the missing capacity (Unsure if used or not)
29+
1330
## TSP Sample Tours:
1431

1532
__Left__: TSP with 20 cities
@@ -33,22 +50,7 @@ __Right__: VRP with 20 cities + load 30
3350
</p>
3451

3552

36-
# To Run
37-
38-
Run by calling ```python trainer.py```
39-
40-
Tasks and complexity can be changed through the "task" and "nodes" flag:
41-
42-
```python trainer.py --task=vrp --nodes=10```
4353

44-
To restore a checkpoint, you must specify the path to a folder that has "actor.pt" and "critic.pt" checkpoints. Sample weights can be found [here](https://drive.google.com/open?id=1wxccGStVglspW-qIpUeMPXAGHh2HsFpF)
45-
46-
```python trainer.py --task=vrp --nodes=10 --checkpoint=vrp10```
47-
## Differences from paper:
48-
49-
* Uses a GRU instead of LSTM for the decoder network
50-
* Critic takes the raw static and dynamic input states and predicts a reward
51-
* (Unsure) Here we use demand scaling (MAX_DEMAND / MAX_VEHICLE_CAPACITY), and give the depot for the VRP a negative value proportionaly to the missing capacity
5254

5355
# TSP
5456

0 commit comments

Comments
 (0)