@@ -11,6 +11,7 @@ A small remark: Code is not a 1:1 copy of the book's. For example I built render
1111- ` AldousBroder `
1212- ` BinaryTree `
1313- ` HuntAndKill `
14+ - ` RecursiveBacktracker `
1415- ` Sidewinder `
1516- ` Wilson `
1617
@@ -96,7 +97,6 @@ Stats demo runs all available algorithms a certain number of times and gathers s
9697Sample output:
9798```
9899PYTHONPATH=. python3 demos/stats_demo.py 25 25 --pathfinding
99-
100100Rows: 25
101101columns: 25
102102Total cells: 625
@@ -105,29 +105,34 @@ Pathfinding: True
105105> running AldousBroder
106106> running BinaryTree
107107> running HuntAndKill
108+ > running RecursiveBacktracker
108109> running Sidewinder
109110> running Wilson
110111
111- Average dead-ends (desc):
112- AldousBroder: 181/625 (29.01%)
113- Wilson: 181/625 (28.97%)
114- Sidewinder: 170/625 (27.12%)
115- BinaryTree: 156/625 (24.93%)
116- HuntAndKill: 062/625 (9.86%)
112+ Average dead-ends (deadends/total-cells, sorted by % desc):
113+ AldousBroder: 182/625 (29.12%)
114+ Wilson: 181/625 (28.93%)
115+ Sidewinder: 171/625 (27.29%)
116+ BinaryTree: 156/625 (24.97%)
117+ RecursiveBacktracker: 065/625 (10.47%)
118+ HuntAndKill: 061/625 (9.73%)
117119
118120Generation speed benchmark (seconds, sorted by average desc):
119- Wilson: avg: 0.65727073 min: 0.22471986 max: 2.18292433
120- HuntAndKill: avg: 0.08903943 min: 0.07111554 max: 0.12254786
121- AldousBroder: avg: 0.03225283 min: 0.01685291 max: 0.08700121
122- Sidewinder: avg: 0.00232661 min: 0.00208164 max: 0.00273097
123- BinaryTree: avg: 0.00217227 min: 0.00209896 max: 0.00251945
121+ Wilson: avg: 0.641611 min: 0.235594 max: 2.173624
122+ HuntAndKill: avg: 0.078919 min: 0.059095 max: 0.101278
123+ AldousBroder: avg: 0.038898 min: 0.015946 max: 0.180922
124+ RecursiveBacktracker: avg: 0.005492 min: 0.005383 max: 0.006105
125+ BinaryTree: avg: 0.002130 min: 0.002074 max: 0.002359
126+ Sidewinder: avg: 0.002105 min: 0.002039 max: 0.002320
124127
125128Pathfinding speed benchmark (seconds, sorted by average desc):
126- HuntAndKill: avg: 0.01336081 min: 0.01190879 max: 0.02201122
127- Sidewinder: avg: 0.01306345 min: 0.01151913 max: 0.02009250
128- Wilson: avg: 0.01259966 min: 0.01147151 max: 0.01936247
129- AldousBroder: avg: 0.01224201 min: 0.01164555 max: 0.01713539
130- BinaryTree: avg: 0.01185717 min: 0.01154452 max: 0.01265934
129+ AldousBroder: avg: 0.014295 min: 0.011494 max: 0.035487
130+ RecursiveBacktracker: avg: 0.012775 min: 0.012238 max: 0.014378
131+ HuntAndKill: avg: 0.012100 min: 0.011589 max: 0.013740
132+ Wilson: avg: 0.011712 min: 0.011262 max: 0.013362
133+ Sidewinder: avg: 0.011641 min: 0.011314 max: 0.013308
134+ BinaryTree: avg: 0.011561 min: 0.011267 max: 0.013016
135+
131136```
132137
133138## Testing
@@ -137,3 +142,9 @@ Note: Runs also some linter tests, to conform with both `mypy` and `flake8`.
137142```
138143pytest
139144```
145+
146+ ## Roadmap & TODOs
147+
148+ - Of course finish the book and implement all main code and algorithms
149+ - Dockerize the project -> Will allow to upgrade to Python 3.6 and perform additional mypy cleanups & improvements
150+ - Implement more pathfinders -> (e.g. recursive backtracking as a maze solve algorithm)
0 commit comments