Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dong50252409/gbfs
A purely Elang implementation of the Greedy Best-First Search algorithm for pathfinding.
https://github.com/dong50252409/gbfs
Last synced: about 1 month ago
JSON representation
A purely Elang implementation of the Greedy Best-First Search algorithm for pathfinding.
- Host: GitHub
- URL: https://github.com/dong50252409/gbfs
- Owner: dong50252409
- License: apache-2.0
- Created: 2024-08-02T09:50:55.000Z (5 months ago)
- Default Branch: master
- Last Pushed: 2024-08-08T03:54:53.000Z (5 months ago)
- Last Synced: 2024-08-09T05:19:29.792Z (5 months ago)
- Language: Erlang
- Size: 7.81 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
gbfs
=====贪心最佳优先寻路算法,支持 4、8 方向寻路,支持限制最大搜索深度。
A purely Elang implementation of the Greedy Best-First Search algorithm for pathfinding.
构建 Build
-----$ rebar3 compile
单元测试 Eunit
----$ rebar3 eunit
如何使用 How to use
-----1> StartGrid = {1, 1}.
2> EndGrid = {50, 50}.
2> BlockList = [{47,1},{24,2}, {2,25}, {20,31}, {20,21}, {50,20}, ...].
3> ValidFun = fun({X,Y}) -> not lists:member({X,Y}, BlockList) end.
4> Options = [],
5> {max, Path} = gbfs:search(StartGrid, EndGrid, ValidFun, Options).