-
Notifications
You must be signed in to change notification settings - Fork 6
/
historic.html
111 lines (83 loc) · 5.81 KB
/
historic.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
<!DOCTYPE html>
<html>
<head>
<link href='https://www.mapbox.com/base/latest/base.css' rel='stylesheet' />
<title>OSM QA tiles historic tilesets</title>
<style type="text/css">
body {
margin-top: 30px;
margin-bottom: 30px;
}
a {
text-transform: capitalize;
}
</style>
</head>
<body>
<div class="limiter">
<div>
<h2 class="fancy">OSM QA tiles: historic snapshots</h2>
<p class="space-top1 link">< <a href="/osm-qa-tiles/">Back</a></p>
<p class="space-top2">Historic snapshots contain OSM data as it was on a specific date in the osm-qa-tile format. </p>
<p>They are powerful datasets for comparing what OSM looked like at different points in time:</p>
<div class='align-center'>
<img height="200" src="img/london_07.jpg">
<img height="200" src="img/london_19.jpg">
</div>
<p class='space-top1'><em>OSM features present in London in 2007 compared to 2019.</em></p>
<h3 class="space-top2">Quarterly Snapshots</h3>
<p class='space-top-1'>
Previous research has used historic snapshots taken quarterly (April 1, July 1, October 1, and January 1 of each year). to show changes in object density over time. For example, <a href="https://mapbox.github.io/osm-analysis-dashboard/#lat=40.656&lon=-73.965&zoom=11.707&startYear=2013-Q3&endYear=2013-Q4&filterProperty=buildingCount_normAggArea">this comparison of the OSM building density in New York between Q3 and Q4 of 2013. </a>
</p>
<p>Historic quarterly snapshots are available for part of 2017 and 2018, but were no longer generated past 2019/01/01. Instead, see the instructions below to generate your own from the full planet history. These files are made available by the University of Colorado Boulder.</p>
</div>
<div class='space-top1'>
<table class='prose table'>
<thead>
<tr>
<th></th>
<th>First Quarter</th>
<th>Second Quarter</th>
<th>Third Quarter</th>
<th>Fourth Quarter</th>
</tr>
</thead>
<tbody>
<tr>
<th>2017</th>
<td></td>
<td></td>
<td><a href="https://s3-us-west-1.amazonaws.com/openstreetmap-analysis/osm-qa-tiles/2017-Q3-qa-tile.mbtiles">2017/10/01, 30.4 GB</a></td>
<td><a href="https://s3-us-west-1.amazonaws.com/openstreetmap-analysis/osm-qa-tiles/2017-Q4-qa-tiles.mbtiles">2018/01/01 31.7 GB</a></td>
</tr>
<tr>
<th>2018</th>
<td><a href="https://s3.amazonaws.com/mapbox/osm-qa-tiles/historic/2018-Q1-qa-tiles.mbtiles">2018/04/01, 30.0 GB</a></td>
<td><a href="https://s3.amazonaws.com/mapbox/osm-qa-tiles/historic/2018-Q2-qa-tiles.mbtiles">2018/07/01, 30.1 GB</a></td>
<td><a href="https://s3-us-west-1.amazonaws.com/openstreetmap-analysis/osm-qa-tiles/2018-Q3-qa-tile.mbtiles">2018/10/01, 32.1 GB</a></td>
<td><a href="https://s3-us-west-1.amazonaws.com/openstreetmap-analysis/osm-qa-tiles/2018-Q4-qa-tiles.mbtiles">2019/01/01 33.2 GB</a></td>
</tr>
</tbody>
</table>
</div>
<div>
<h3 id="instructions" class='space-top4'>How to generate your own historic snapshots of OSM data:</h3>
<p class="space-top1">First, create a snapshot of OSM at a specific time from the <a href="https://wiki.openstreetmap.org/wiki/Planet.osm/full">full planet history</a> using the <a href="https://osmcode.org/osmium-tool/">osmium tool</a>
</p>
<p class="space-left2 code">osmium time-filter --verbose --overwrite -o 2010-Q1.osm.pbf planet-history.osm.pbf 2010-04-01T00:00:00Z</p>
<p class="space-top1">Next, use osmium-export to convert the <span class='code'>osm.pbf</span> into GeoJSON. Use the <a style="text-transform: none;" href="https://raw.githubusercontent.com/osmlab/osm-qa-tiles/osmium/osm-qa-tile.osmiumconfig">osm-qa-tile.osmiumconfig</a> to ensure that the features match the osm-qa-tiles.
<p class="space-left2 code">osmium export -c <a style="text-transform: none;" href="https://raw.githubusercontent.com/osmlab/osm-qa-tiles/osmium/osm-qa-tile.osmiumconfig">osm-qa-tile.osmiumconfig</a> -f geojsonseq -o features.geojsonseq --progress 2010-Q1.osm.pbf</p>
<p class="space-top1">Finally, use tippecanoe to create the mbtiles file:
<p class="space-left2 code">tippecanoe -Pf -pf -pk -ps -Z12 -z12 -d20 --no-tile-stats -b0 -l osm -o 2010-Q1-qa-tile.mbtiles features.geojsonseq</p>
<p class="space-top1"> The flags ensure the following <a target="_blank" href="//github.com/mapbox/tippecanoe">(from the tippecanoe documentation):</a> </p>
<p class="space-left2"><span style="float:left; width:175px;" class="code">-Z12 -z12 -d20</span> Only generate zoom 12, with the maximum detail available at that resolution.</p>
<p class="space-left2"><span style="float:left; width:175px;" class="code">-pf -pk -ps</span> Don't limit tiles by size or feature count; don't simplify lines.</p>
<p class="space-left2"><span style="float:left; width:175px;" class="code">-b0</span> No buffer on the tile edges from which to duplicate next-door features.</p>
<p class="space-left2"><span style="float:left; width:175px;" class="code">--no-tile-stats</span>Don't generate statistics for object attributes (since these are not for rendering).</p>
<p class="space-left2"><span style="float:left; width:175px;" class="code">-l osm</span>Name the layer "osm".</p>
<hr><br>
</div>
</div>
</div>
</body>
</html>