Skip to content

Commit

Permalink
BEW->DFS
Browse files Browse the repository at this point in the history
  • Loading branch information
michielbdejong committed Oct 18, 2024
1 parent ff8d33b commit 3908882
Show file tree
Hide file tree
Showing 5 changed files with 59,555 additions and 7 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ node ./build/src/sarafu-to-debt.js ../Sarafu2021_UKdb_submission/sarafu_xDAI/sar
python -m pip install ortools
python mcf.py > flow.csv
node build/src/subtractFlow.js ./debt.csv ./flow.csv ./mcf-out.csv
node build/src/birdsEyeChallenge.js debt.csv dfs.csv
node build/src/birdsEyeChallenge.js mcf-out.csv mcf-dfs.csv
node build/src/dfs.js debt.csv dfs.csv
node build/src/dfs.js mcf-out.csv mcf-dfs.csv
node ./build/src/analyse-sarafu-challenge-solution.js ./debt.csv ./dfs.csv
node ./build/src/analyse-sarafu-challenge-solution.js ./debt.csv ./mcf-dfs.csv
```
Expand Down Expand Up @@ -88,18 +88,18 @@ node ./build/src/analyse-sarafu-challenge-solution.js ./debt.csv ./solution.csv
```

# Contestants
## Bird's Eye Worm ('BEW')
## Depth First Search ('DFS')
This centralized algorithm does a repeated depth-first search, stringing together paths through the graph similar to the 'Snake' game that was popular on feature phones in the 1990s.
```
node build/src/birdsEyeChallenge.js
node build/src/dfs.js
```

## MCF+BEW
## MCF+DFS
We run a minimum-cost flow algorithm in python, followed by BEW, which leads to a slightly better performance:
```
python -m pip install ortools
python mcf.py
node build/src/birdsEyeChallenge.js mcf-out.csv
node build/src/dfs.js mcf-out.csv
```


Expand Down
Loading

0 comments on commit 3908882

Please sign in to comment.