Commit Graph

4 Commits

Author SHA1 Message Date
Gael-de-Sailly
f0dddee33c Lakes map: keep initial height (reduces file size)
Lake height is calculated for every basin, and there is a lake if lake height is higher than ground height. If it is lower, there is no lake.
In that case, it was previously raised to ground level, but since this can be done in Lua, we can write initial lakes height in the files.
This has the advantage of reducing file size, since there are bigger areas of equal values, that are more efficiently compressed.
2020-12-24 14:48:17 +01:00
Gael-de-Sailly
ecd2c7d3f9 Completely change flow routing algorithm,
use a local flow calculation, determine depressions, and link them using a minimum spanning tree (Boruvka's algorithm).
This is based on a paper by Cordonnier et al, 2019.
2020-12-24 14:48:17 +01:00
Gael-de-Sailly
40098d6be3 Use standard int instead of uint8, int32, etc.
Much faster with NumPy.
2020-12-24 14:48:17 +01:00
Gael-de-Sailly
d93234c9b7 Moved Python files inside a folder (package), except the 2 that are directly executable 2020-11-14 17:35:27 +01:00