Download - OpenStreetMap : Open Licensed GeoData
![Page 1: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/1.jpg)
Harry Wood
OpenStreetMap : Open Licensed Geo DataBritish Computer Society : Monday 27th April 2009
![Page 2: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/2.jpg)
Topics●OpenStreetMap purpose and premise
●Data structures: Nodes, Ways ,Tags etc
●Editor demo
●OpenStreetMap servers and architecture
●Rendering and map displays
●The license
●CloudMade products and services
●Imports and other mapping techniques
●Getting Involved
NOTE:Ran out of time for these topics on the day. The slides for these have also been removed from this deck. Could present them on another occasion!
![Page 3: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/3.jpg)
Free as in Freedom
●Open license:–Creative Commons Attribution Share-alike
●“Open Content” like “Open Source”●Contributors retain ownership of copyright●People and commercial companies can use the maps for free under this license.
–Details of license requirements?... coming up
![Page 4: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/4.jpg)
Getting an Open Licensed Map●Can't copy copyrighted maps
● Not allowed to import copyrighted data● Not allowed to copy from copyrighted maps● Not allowed to trace over copyrighted maps● Not allowed to “derive”
●Can copy some maps, but only...● Public domain. Unrestricted (incl. relicensing)● Get permission to release with an open license (big ask)
●Can create maps completely from scratch● crazy idea?
![Page 5: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/5.jpg)
GPS traces
● How it started. Gadgets!● Cheap consumer GPS units or location-aware mobiles● Record a line of dots
![Page 6: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/6.jpg)
Record many lines of dots....
Looks like a street map. Kind of
![Page 7: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/7.jpg)
Recording dataNames of streets
Types of streets (trunk, residential, motorway)
One-way restrictions
Footpaths, tracks, pedestrian, rivers, railways
Parks, woodland, industrial areas, cemeteries
POI (pubs, cash machines, post offices, post boxes, bus stops, toilets, supermarkets, restaurants, kebab shops, monuments, hotels, picnic sites, barriers, light houses, piers, sports centres, petrol stations, playgrounds, cinemas, car parks, universities, bicycle parking, tourist information, etc etc etc
![Page 8: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/8.jpg)
Mapping Techniques●Photo Mapping (geo-located photos)
●Audio mapping●Taking notes
●
●Ditch the GPS● Taking notes ● Local knowledge!● Yahoo Aerial Imagery
![Page 9: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/9.jpg)
Mapping: A lot of effort
●Gather data ● GPS traces and other information
●Input data● using OSM “editor” software
●Requires a lot of effort● Requires a lot of people!
![Page 10: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/10.jpg)
Community Contribution●Built by a large online community●Many hands make light work●Openly editable (and easy)●Poor quality contributions?
● Gradual refinement● Assume good faith ● Monitoring and correction
....Remarkably it works!
Sounds familiar?
![Page 11: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/11.jpg)
Wikipedia●Large community coming together to build something great!●Wikipedia Principles● Openly editable● Open content license● Gradual refinement● Assume good faith ● “Soft Security” Monitoring and correction
![Page 12: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/12.jpg)
looks like wikipedia
OpenStreetMap = The wikipedia of maps
![Page 13: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/13.jpg)
Community
It's big. 100,000 registered users
![Page 14: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/14.jpg)
Community
Increasing editing activity
![Page 15: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/15.jpg)
CommunityVery Active
0 1000 2000 3000 4000 5000 6000 7000 8000 9000
User rank
Less Active
Lopsided
Long tail of less active users
![Page 16: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/16.jpg)
![Page 17: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/17.jpg)
![Page 18: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/18.jpg)
![Page 19: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/19.jpg)
![Page 20: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/20.jpg)
![Page 21: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/21.jpg)
![Page 22: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/22.jpg)
![Page 23: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/23.jpg)
![Page 24: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/24.jpg)
![Page 25: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/25.jpg)
![Page 26: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/26.jpg)
![Page 27: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/27.jpg)
![Page 28: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/28.jpg)
![Page 29: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/29.jpg)
![Page 30: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/30.jpg)
Cambridge
![Page 31: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/31.jpg)
![Page 32: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/32.jpg)
![Page 33: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/33.jpg)
Global Project!
![Page 34: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/34.jpg)
![Page 35: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/35.jpg)
![Page 36: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/36.jpg)
![Page 37: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/37.jpg)
![Page 38: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/38.jpg)
![Page 39: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/39.jpg)
![Page 40: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/40.jpg)
![Page 41: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/41.jpg)
![Page 42: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/42.jpg)
![Page 43: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/43.jpg)
Open Licensed Data
A copyrighted map
...is a justification for OpenStreetMap (It can't be used freely therefore OSM is better)
...cannot be a source for openstreetmap
Existing maps are very rarely free
![Page 44: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/44.jpg)
Ordnance Survey●Wonderful data in the UK
●OS license use of maps (and charge ££££££)
●Never allow re-distributing with a different license
●Very strict about copying and their definition of “derived” work
![Page 45: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/45.jpg)
Guardian 'Free Our Data' Campaign● Lobbying government
● Tax paid for data collection● Tax still pays indirectly● Economic benefits of free
● Slow progress● OS might release
● low quality data first● less-than-free license
● Or might be privatised!● Whine about it or take action?
![Page 46: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/46.jpg)
OSM and Ordnance Survey
£many
£0
Low quality High quality
OS
OSM
![Page 47: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/47.jpg)
● We can't can't use google maps● License their data from teleatlas● ...who license data from Navteq / Teleatlas● ...Ordnance Survey!● No access to underlying data● Google terms & conditions● Don't allow deriving data from their maps● Don't allow copying & re-distributing with a different license● Wonderful hi-res aerial imagery● T&Cs do not allow deriving maps (tracing)● Bought in (licensed) from multiple suppliers
Google Maps
![Page 48: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/48.jpg)
Why not use Google Maps?Wonderful “free” (beer) mash-up API but...
●Errors and omissions●Car centric. Footpaths and other details●Cycle routes and Pistes●Colours / branding - Google maps fatigue●SVG export. Custom cartography●Underlying data access!● Details of OSM map access coming up
●Help OpenStreetMap!
![Page 49: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/49.jpg)
Oxford University Website
OSM has better maps of Oxford
Encourages the OSM community
Other uses coming up...
![Page 50: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/50.jpg)
Nodes, Ways, Relations
Node
Has latitude and longitude
Can stand alone, or form part of a way
Way
Joins together several nodes
Direction sometimes matters
Can form a 'closed way' (area)
Relation
For complex things such as routes
![Page 51: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/51.jpg)
Tags
Applied to the Nodes, Ways, & Relations
Key value pairs
amenity=pubname=Hare & Hounds
highway=residentialname=Court Street
![Page 52: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/52.jpg)
http://www.openstreetmap.org/?lat=53.548078&lon=-2.004771&zoom=18
Data Browser demo
![Page 53: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/53.jpg)
Data Browser
![Page 54: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/54.jpg)
Permalink
![Page 55: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/55.jpg)
JOSM demo
![Page 56: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/56.jpg)
JOSM demo
![Page 57: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/57.jpg)
OpenStreetMap Servers
Hosted in UCL
Loads of bandwidth
~10 servers:
Where does the data go?
http://wiki.openstreetmap.org/wiki/Servers
![Page 58: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/58.jpg)
OpenStreetMap Foundation
Custodian of servers and sysadmin access
Oversees funding and vehicle for fund raising
Protection from copyright and liability suits
![Page 59: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/59.jpg)
Database ServerMotherboard Supermicro X7DWN+ motherboard with Intel 5400 (Seaburg) Chipset
CPU 2x Intel Xeon Processor E5420 Quad Core 2.5Ghz
Memory 32GB DDR2 667 ECC
Disk 2x 73GB (3.5) SAS 15K
10x 450GB (3.5) SAS 15K
donate.openstreetmap.org
Raised £10,000 in 2 days
![Page 60: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/60.jpg)
![Page 61: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/61.jpg)
API
● REST web service● HTTP GET & PUT● Get elements at URLs
http://www.openstreetmap.org/api/0.6/node/297556642
● No bloated request payloads
● Ruby on Rails
![Page 62: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/62.jpg)
Ruby on Rails● It's easy. Web + REST● Fashionable. Developers like it
● Developers are our most limited resource.
● It's what SteveC used
● Problems?● Can't stream data from db● Memory hungry and leaks somewhere● Maybe use something else for core API
![Page 63: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/63.jpg)
Nodeshttp://www.openstreetmap.org/api/0.6/node/297556642
<node id="297556642"lat="53.548223"lon="-2.0056012"version="2"changeset="648346"user="Guy"uid="10983"visible="true"timestamp="2008-09-16T20:42:44Z">
<tag k="name" v="Hare & Hounds"/> <tag k="created_by" v="Potlatch 0.10b"/> <tag k="amenity" v="pub"/></node>
![Page 64: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/64.jpg)
Wayshttp://www.openstreetmap.org/api/0.6/way/27120827 <way id="27120827" visible="true" timestamp="2008-09-19T13:19:53Z" version="2" changeset="664390" user="Guy" uid="10983"> <nd ref="298116100"/> <nd ref="297555192"/> <nd ref="297555193"/> <nd ref="297555194"/> <tag k="name" v="Court Street"/> <tag k="created_by" v="Potlatch 0.10b"/> <tag k="highway" v="residential"/></way>
![Page 65: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/65.jpg)
Other API calls
GET a map
All elements within a bounding boxhttp://api.openstreetmap.org/api/0.6/map?bbox=11.54,48.14,11.543,48.145
PUT elements
Now requires “changeset open” request
Various other operations
History and changeset access
Get GPS points/tracks
![Page 66: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/66.jpg)
Some database details
Switched from MySQL to Postgres last weekend!
Rails migrations in theory
In practice. C++ scripts running all weekend
Why the switch?
Lots of other planned restructuring
including new DB hardware
Good time to do it
![Page 67: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/67.jpg)
MySQLGenerally fast and scalable enough
● Quadtile indexing extension
Several annoying flaws:● schema changes cause table copies● different features on different db engines● (transactions on InnoDB, spatial on MyISAM)● silently accepts invalid utf8● constraints can't be deferred● some non-standard SQL syntax
![Page 68: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/68.jpg)
Postgres
● Addresses a lot of MySQL flaws:● Faster schema changes● Better support for transactions, utf8, etc
● Personal preference of our sysops
![Page 69: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/69.jpg)
Full Revision History
Store a full history edits to elements
Essential wiki-like feature
Ideally provide simple roll-back
Access old versions of an element
Difficult to reconstruct old version of a map
![Page 70: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/70.jpg)
Changesets
● Brand new feature● Every edit belongs in a change set● Every numbered version of every object
belongs in one particular changeset● Changesets have comments
● Great for monitoring
![Page 71: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/71.jpg)
Changeset Displayshttp://www.openstreetmap.org/browse/changesets
![Page 72: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/72.jpg)
Changeset revert?
● Reverting is still a difficult problem● Changesets are not atomic
● Changeset 1 User:Sam Node 12345 v1● Changeset 2 User:SallyNode 12345 v2● Changeset 3 User:Sid Node 12345 v3● Changeset 4 User:SallyNode 12345 v3● Changeset 1 User:Sam Node 12345 v4● Changeset 1 User:Sam Node 12345 v5
● Many interlinked elements
![Page 73: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/73.jpg)
Conflicts
● Two users editing the same element– Rarely happens actually
● Version mismatch now reported– “Optimistic locking”
● Editors (should) do CVS style conflict resolution● Download reveals conflict● Upload not allowed until resolved
![Page 75: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/75.jpg)
planet.osm● Snapshot of the OpenStreetMap database● Entire planet. Every node, way, relation, tag● Only 'current' data. Not history● XML formatted .osm file● 5.2 GB with bzip2 compression● Uncompressed... 150 GB● Takes several hours to dump. Every Wednesday● Important part of Openness. Ensures longevity.
![Page 76: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/76.jpg)
Osmosis
● Java toolkit for OpenStreetMap● Various data transformations● Minutely, Hourly, Daily diffs .osc.gz files● Created by Osmosis. Consumed by osmosis● Streamable changes
![Page 77: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/77.jpg)
Open Tagging
● Mentioned tags briefly– amenity=pub highway=residential
● Free-form open tagging. Any tags you like!● Agree on standards● Main openstreetmap.org map rendering uses
one set of tags● Other map renderers, other tools, can use other
tagging schemes
![Page 78: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/78.jpg)
'Map Features' wiki page
● BIG list of tags
Which tags go on this page?
● Wiki proposal process
● Wiki discussion and voting
● Wiki dabates (& blazing rows!)
– Different ways of tagging the same thing.
– Things which should not be tagged● Wiki documentation
![Page 79: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/79.jpg)
Smoothness Debate● Vehement Objections
– Too subjective
– Verifiability
– Poor english
● Disruption– Disregarding vote
– Wiki fiddlers
vs Mappers
– Wiki edit wars
– New process?● Lock down?
![Page 80: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/80.jpg)
The wrong way to think about tags
● Come up with lots of ideas for new tags● Submit proposals, organise votes, generally
fiddle with the OSM wiki a lot● Pester people to use tags in map renderings
...oh and maybe do a bit of actual mapping
![Page 81: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/81.jpg)
The right way to think about tags● Do mapping!● Found something without a documented tag?
– Search thoroughly (in mailing list too)
– Use a less specific tag and qualify with type=
– Use a note= tag
– Just invent a tag
● Do more mapping!● Discuss politely. Improve existing docs.● maybe... possibly.... do a proposal● Focus on mapping. Don't worry about rendering
![Page 82: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/82.jpg)
TagWatch
● Tag usage stats● Split by country● Tags used in
conjunction
![Page 83: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/83.jpg)
Rendering● Topic follows on although...
tagging is not just about rendering● Go from geodata (nodes, ways, relations & tags)
to rasterized map images
Rendering
![Page 84: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/84.jpg)
Which tags to render?
● Thousands of different tags in the DB● Can't show them all● Choose features to show at different
zoom levels– Cartography!
● What do you want to emphasise?
![Page 85: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/85.jpg)
Rendering Toolchain
Slippy MapDisplay
![Page 86: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/86.jpg)
Mapnik● Open Source rendering software● Fast!● C++● Requires PostGIS database
![Page 87: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/87.jpg)
Mapnik Stylesheet
● XML format● 'styles', 'filters' and 'rules' ● >7000 lines long
● Pre-processing steps– Cascadenik
– and also...
![Page 88: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/88.jpg)
osm2pgsql
● Step before using Mapnik (& stylesheet)● load OSM data into a Postgres database● Lossy conversion. Only take tags of interest● nodes and ways → linestrings and polygons
Slippy MapDisplay
![Page 89: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/89.jpg)
● Open Source JavaScript library● Dynamic slippy map on your website● WMS layers● Tile based map layers● Transparent overlay layers● Markers, Boxes, Polygons, Click events
In the end we want a map display...
![Page 90: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/90.jpg)
Tiles
● Small map images● Cacheable● Fast loading● Sized to optimize speed
– Too big. Unneeded map area
– Too small. Too many requests
– 255x255pixels
![Page 91: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/91.jpg)
Tile Naming
● Slice the world into tiles at each zoom level● Tiles are always 255x255 pixels● Represent different sized area of the world at
different zoom levels
![Page 92: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/92.jpg)
Tile Naming
Zoom level 0 has only one tile (whole world):
![Page 93: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/93.jpg)
Tile Naming
Zoom level 1 has 2x2 tiles
![Page 94: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/94.jpg)
Tile Naming
● Zoom level 2 has 4x4 tiles● Zoom level 3 has 8x8 tiles● Zoom level 4 has 16x16 tiles
...● Zoom level n has 2nx2n tiles
...● Zoom level 18 has
262144 x 262144 tiles
![Page 95: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/95.jpg)
Tile Naming● Every tile has a URL
http://tile.openstreetmap.org/12/2047/1362.png
yZoom Level
(0-18) x
● Tile naming scheme followed by OpenLayers● Same used by google maps● Looks like filesystem URL
![Page 96: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/96.jpg)
Tiles =High Performance Computing
262144 x 262144 = 68,719,476,736 tiles
inode problem!
5 kB each = 320 terabytes
But then there's zoom 17.... another 80 terabytes
etc...
![Page 97: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/97.jpg)
Tiles =High Performance Computing
OpenStreetMap updates?● Apply diffs● Re-render tile images!● CPU problem!
![Page 98: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/98.jpg)
Caching and mod_tile
● mod_tile– Apache module. Very fast
– Render-on-demand if necessary
– Clever caching
– Serves old cached images and labels as dirty
– Dirty tiles get re-rendered by render daemon
Slippy MapDisplay
![Page 99: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/99.jpg)
Bandwidth
● Serving terrabytes of tile data. High bandwidth● UCL
![Page 100: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/100.jpg)
OpenCycleMap.org
● Using OpenStreetMap– Presenting special interest map
– Same data. Different cartographic choices
● Toolchain running on another server– Updates fed in
– Passionate sub-set of the OSM community
![Page 101: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/101.jpg)
Route relations, Cycle Parking, Bike Shops, Drink
![Page 102: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/102.jpg)
Relief maps!
![Page 103: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/103.jpg)
SRTM
● NASA - Shuttle Radar Tomography Mission● Public Domain● Problems
– Spot heights – not contours
– Course grid
– Voids and other anomalies
![Page 104: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/104.jpg)
CycleMap tool chain● Downloads weekly planet dump● SRTM. More steps in the chain!
● Bandwidth problems. Now hosted by CloudMade
![Page 105: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/105.jpg)
OpenPisteMap
![Page 106: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/106.jpg)
Hiking Map
![Page 107: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/107.jpg)
Whitewater Map
![Page 108: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/108.jpg)
Bus map
![Page 109: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/109.jpg)
Kosmos● .NET (windows only)● Desktop app● Can generate tiles● wiki based
style config
![Page 110: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/110.jpg)
osmarender
● First good OSM renderer● Used to be the only way to get SVG
● Complex perl XSLT ● Generates SVG (XML vector graphics format)● Feed in .osm file and style config
● Can't be used to generate tiles.... or can it?
![Page 111: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/111.jpg)
'osmarender' layer
![Page 112: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/112.jpg)
tiles@home● Distributed tile rendering
– Instructions dished out from tiles@home server
– Many clients download via API and upload images
● 'osmarender' layer– Used to provide the fastest updates
● XSLT transforms & inkscape SVG rendering– Eats massive amounts of CPU
– Mapnik more sensible. ...no need to distribute
![Page 113: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/113.jpg)
Other renderers?
● Plenty of scope to develop but..● high performance problem● Complex graphics problem● e.g. phprender
Needs a bit of
work!
![Page 114: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/114.jpg)
We want people to be free to use our maps!
OSM License Requirements
● Free to bring maps into “collective” works– Must give “attribution”
● Free to create “derivative” works– must share-alike
● Awkward complications:– What exactly counts as “derivative work”?
– How do you give credit to the “authors”?
![Page 115: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/115.jpg)
ODbL + ODC-Factual
● Open Data Commons● Open Database License● Factual Information License● Benefits:
– copyright, database right, and contract
– Expressly written for data
– More strict about underlying data (forcing sharing), but less strict about end products
![Page 116: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/116.jpg)
Commercial use is allowed!● OSM destroys business models ...or does it?
– Destroys monopolies on geo data
● Allowed to charge for distribution– Can't disallow further distribution
– Monetary value tends towards zero
● Allowed to charge for services– Distribute different formats / renderings
● Solve difficult problems (+time dependant problems)● Hosting
– Consulting services
● Just use maps. Core business not in geo-data
![Page 117: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/117.jpg)
Flickr
![Page 118: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/118.jpg)
Nestoria
![Page 119: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/119.jpg)
'Trails' iPhone app
![Page 120: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/120.jpg)
Get Involved!
http://wiki.openstreetmap.org/http://lists.openstreetmap.org/
irc://irc.oftc.net #osmhttp://trac.openstreetmap.org
![Page 121: OpenStreetMap : Open Licensed GeoData](https://reader034.vdocuments.us/reader034/viewer/2022042614/55a2bdac1a28ab6f268b4602/html5/thumbnails/121.jpg)
Harry Wood worked as an enterprise integration consultant for 8 years, but led a secret double-life as addicted contributer to wikipedia and other collaborative open content projects. He got involved in OpenStreetMap three years ago, as a mapper, wiki gardener, and developer. Since January this year (2009) he has worked for CloudMade, as a full time OpenStreetMap developer
CloudMade is a company providing products and services around OpenStreetMap.
More information at http://cloudmade.com
These slides are (of course) freely re-usable under the Creative Commons Attribution-ShareAlike 2.0 License