update README and docs
This commit is contained in:
parent
696a1c268b
commit
657461b818
38
README.md
38
README.md
@ -1,13 +1,20 @@
|
|||||||
Wang–Müller algorithm in PostGIS
|
Wang–Müller algorithm in PostGIS
|
||||||
--------------------------------
|
--------------------------------
|
||||||
|
|
||||||
This is a work-in-progress implementation following "Line generalization based
|
This is Wang–Müller line generalization algorithm implementation in PostGIS.
|
||||||
on analysis of shape characteristics" by Wang and Müller, 1998.
|
Following "Line generalization based on analysis of shape characteristics" by
|
||||||
|
the same author, 1998.
|
||||||
|
|
||||||
|
Status
|
||||||
|
------
|
||||||
|
|
||||||
|
It mostly works. Read `mj-msc-full.pdf` for visual examples and possible
|
||||||
|
gotchas.
|
||||||
|
|
||||||
Structure
|
Structure
|
||||||
---------
|
---------
|
||||||
|
|
||||||
There will be 2 deliverables from this folder:
|
There are be 2 deliverables:
|
||||||
|
|
||||||
- `wm.sql`, the implementation.
|
- `wm.sql`, the implementation.
|
||||||
- paper `mj-msc-full.pdf`, a MSc thesis, explaining it.
|
- paper `mj-msc-full.pdf`, a MSc thesis, explaining it.
|
||||||
@ -49,6 +56,10 @@ To execute the algorithm, run:
|
|||||||
data source (e.g. use a different country instead of Lithuania) by changing
|
data source (e.g. use a different country instead of Lithuania) by changing
|
||||||
the `Makefile` and the test files. Left as an exercise for the reader.
|
the `Makefile` and the test files. Left as an exercise for the reader.
|
||||||
|
|
||||||
|
N.B. the `make test-rivers` fails (see `test-rivers.sql`), because with higher
|
||||||
|
`dhalfcircle` values, the unionized river (`salvis`) is going on top of itself,
|
||||||
|
making the resulting geometry invalid.
|
||||||
|
|
||||||
Building the paper (pdf)
|
Building the paper (pdf)
|
||||||
------------------------
|
------------------------
|
||||||
|
|
||||||
@ -57,24 +68,19 @@ Building the paper (pdf)
|
|||||||
```
|
```
|
||||||
|
|
||||||
`mj-msc.tex` results in `mj-msc-full.pdf`, which will be at some point
|
`mj-msc.tex` results in `mj-msc-full.pdf`, which will be at some point
|
||||||
published. It needs quite a few dependencies, including a functioning Docker
|
published to this repo. It needs quite a few dependencies, including a
|
||||||
environment, postgresql client, geopandas, pygments, osm2pgsql, poppler, and a
|
functioning Docker environment, postgresql client, geopandas, pygments,
|
||||||
"quite extensive" LaTeX installation. This was tested on Debian 11.
|
osm2pgsql, poppler, and a "quite extensive" LaTeX installation. Tested on
|
||||||
|
Debian 11.
|
||||||
|
|
||||||
Contributing
|
Contributing
|
||||||
------------
|
------------
|
||||||
|
|
||||||
Please reach out to me before contributing. As of writing, this is not ready to
|
This repository is frozen and will not accept contributions. Please fork it.
|
||||||
accept broader contributions, TODO:
|
If fork has improved the algorithm substantially, feel free to ping me, I will
|
||||||
|
link to it in this README.
|
||||||
- [x] Elimination operator.
|
|
||||||
- [x] Exaggeration operator.
|
|
||||||
- [ ] Combination operator.
|
|
||||||
- [ ] CI (unlikely to happen).
|
|
||||||
- [x] Known bug in `wm_self_crossing`: the program crashes with a river in
|
|
||||||
Lithuania.
|
|
||||||
|
|
||||||
License
|
License
|
||||||
-------
|
-------
|
||||||
|
|
||||||
GPL 2.0 or later, same as PostGIS.
|
GPLv2 or later.
|
||||||
|
@ -1,7 +1,16 @@
|
|||||||
\set ON_ERROR_STOP on
|
\set ON_ERROR_STOP on
|
||||||
SET plpgsql.extra_errors TO 'all';
|
SET plpgsql.extra_errors TO 'all';
|
||||||
|
|
||||||
-- This fails with real rivers since dcf4c02307baeece51470a961a113a8fad68fad5
|
-- This fails with real rivers since this:
|
||||||
|
-- commit dcf4c02307baeece51470a961a113a8fad68fad5
|
||||||
|
-- Merge: 44ee741 3638033
|
||||||
|
-- Author: Motiejus Jakštys <motiejus@uber.com>
|
||||||
|
-- Date: Tue May 11 20:29:41 2021 +0300
|
||||||
|
--
|
||||||
|
-- Merge branch 'gdb10lt'
|
||||||
|
--
|
||||||
|
-- This breaks "test-rivers" for Nemunas.
|
||||||
|
--
|
||||||
-- (adding GDB10LT data). The same rivers from OpenStreetMaps work.
|
-- (adding GDB10LT data). The same rivers from OpenStreetMaps work.
|
||||||
-- There seems to be a bug in wm_exaggeration.
|
-- There seems to be a bug in wm_exaggeration.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user