Rendering maps without Database Thomas Skowron Previously (if you - - PowerPoint PPT Presentation

rendering maps without database
SMART_READER_LITE
LIVE PREVIEW

Rendering maps without Database Thomas Skowron Previously (if you - - PowerPoint PPT Presentation

Rendering maps without Database Thomas Skowron Previously (if you happen to speak German) berblick ber Pipelinebasierte Rendering-Techniken Erzeugung von und So fu ware Karten FOSSGIS-Konferenz 2017 FOSSGIS-Konferenz 2018


slide-1
SLIDE 1

Rendering maps without Database

Thomas Skowron

slide-2
SLIDE 2

Previously

(if you happen to speak German)

„Überblick über Rendering-Techniken und Sofuware“

FOSSGIS-Konferenz 2017

„Pipelinebasierte Erzeugung von Karten“

FOSSGIS-Konferenz 2018

slide-3
SLIDE 3

Turning OSM Data into a graphical map

slide-4
SLIDE 4

Bitmap/Vector Tiles, Maps with larger extent, …

slide-5
SLIDE 5

State of the art

slide-6
SLIDE 6

OSM Planet PostgreSQL Renderer

Bottleneck Bottleneck Bottleneck Awesome, powerful stuff

slide-7
SLIDE 7

PostgreSQL

Do we really need all of that stuff?

+ SQL + ACID, MVCC & transactions + Indexes + Role permission management + scriptable + fail over + …

  • Performance (PostGIS)
  • operational cost
  • memory consumption
slide-8
SLIDE 8

Attempts to improve
 the situation…

slide-9
SLIDE 9

OSM Planet PostgreSQL Vector File “Renderer“

Bottleneck Bottleneck Bottleneck

Client Based Renderer

slide-10
SLIDE 10

Pre-rendered Vector Tiles Client Based Renderer

All features already baked in, flexibility mostly gone

slide-11
SLIDE 11

Alternative Approaches

slide-12
SLIDE 12

tippecanoe

slide-13
SLIDE 13

OSM File mbtiles vector tile set

slide-14
SLIDE 14

Clever features to keep vector tiles small

slide-15
SLIDE 15

has a gazillion of options

slide-16
SLIDE 16

still very limited to filtering

slide-17
SLIDE 17

Tilemaker

slide-18
SLIDE 18

flexibility through lua scripting

slide-19
SLIDE 19

not scalable to larger extracts

slide-20
SLIDE 20

But why does one tool needs to do everything?

slide-21
SLIDE 21

Generally, we are all doing almost the same stuff.

slide-22
SLIDE 22

Step 1

Convert OSM data into geo data

slide-23
SLIDE 23

Step 2

Filter

slide-24
SLIDE 24

Step 3

Transform/map data

slide-25
SLIDE 25

Step 4

Convert into target format

slide-26
SLIDE 26

Suggestion:

parse | map-reduce | render

slide-27
SLIDE 27

But how?

slide-28
SLIDE 28

With Tools, which each do

  • ne thing well
slide-29
SLIDE 29

and a portable data format

slide-30
SLIDE 30

Let’s do Shapefiles!

slide-31
SLIDE 31

Let’s do Shapefiles!

slide-32
SLIDE 32

Let’s do OSMPBF!

slide-33
SLIDE 33

Let’s do OSMPBF!

slide-34
SLIDE 34

What does a suitable file format need?

slide-35
SLIDE 35

Performance

linear writes, parallelizable reads

slide-36
SLIDE 36

Scalable

small to huge data sets

slide-37
SLIDE 37

Tag structures

No tables no more!

slide-38
SLIDE 38

Future proof

adaptable to change

slide-39
SLIDE 39

Shapefile

Performance moderate Scalable no, 2 GB size limit Tag Strucutre no Future Proof no

slide-40
SLIDE 40

GeoJSON

Performance moderate Scalable moderately, single threaded Tag Structure yes Future Proof limited

slide-41
SLIDE 41

GeoPackage

Performance bad (SQLite) Scalable moderately Tag Structure yes Future Proof yes

slide-42
SLIDE 42

Performance Flexibility

slide-43
SLIDE 43

We need something new

There is no progress without change

slide-44
SLIDE 44

How would a new file format look like?

  • binary
  • blocks, streamable
  • single stream, not multiple files
  • not SQLite
  • not overly obscure
  • open and extendable
slide-45
SLIDE 45

Suggestion

slide-46
SLIDE 46
slide-47
SLIDE 47

Based on Protocol Buffers and WKB

slide-48
SLIDE 48

Open Spec on


https://thomas.skowron.eu/spaten/

slide-49
SLIDE 49

Reference implementation in Go

github.com/thomersch/grandine/lib/spaten

slide-50
SLIDE 50

Around 50% smaller than GeoJSON*

* YMMV

slide-51
SLIDE 51

Version 0

slide-52
SLIDE 52

Feedback and Ideas are welcome

slide-53
SLIDE 53

What could we do with it?

slide-54
SLIDE 54

grandine-spatialize -in planet.osm.pbf -mapping roads.yml | grandine-tiler -out tiles/roads/ -zoom 14

slide-55
SLIDE 55
  • smium export -f spaten planet.osm.pbf |

gradine-converter -mapping roads.yml | grandine-tiler -out tiles/roads/ -zoom 14

(not yet)

slide-56
SLIDE 56
  • smium export -f spaten planet.osm.pbf |

your-tool-here -fancify | magic-renderer

(not yet)

slide-57
SLIDE 57

Interchangeable tools

slide-58
SLIDE 58

Future

slide-59
SLIDE 59

Greater flexibility with less programming work

slide-60
SLIDE 60

Faster processing with less hardware

slide-61
SLIDE 61

Less points of failure

slide-62
SLIDE 62

There is still lots to do

Data format, tools, markup, …

slide-63
SLIDE 63

Let’s build the future together!

slide-64
SLIDE 64

And now let’s discuss!