-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathaccra.html
137 lines (122 loc) · 5.47 KB
/
accra.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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
---
layout: city-gl
title: Accra
description: Ghana
permalink: /accra/
zoom: 12
center-x: -0.1870
center-y: 5.6037
export: c650a0eb-4870-49ac-9e14-492544e21c40
---
<div id='intro'>
<p>Greater Accra is subject to chronic flooding, the impacts of which are increasing due to climate change and population increase. About 60% of Accra’s population lives within the Odaw basin; where frequent and severe urban flooding is a major issue. The World Bank is working to support resilient, clean, and inclusive development in the Greater Accra Region under its Greater Accra Resilience and Integrated Development (GARID) Project.</p>
<p>Open Cities Accra will support the GARID project through the creation of map data to inform participatory solid waste management, and informal settlement upgrading, in these flood prone areas. The Open Cities Accra Project will focus on the neighborhood of Alogboshie and its environs. The project will also involve the remote mapping of Nima, Akweteman and Alajo. Alogboshie is a community that is plagued by perennial flooding, with peaks during the rainy season during June and July. The effects of flooding on human life here is significant; with regular displacement and loss of property. The community is also prone to disease outbreaks.</p>
<p>Open Cities Accra will create a detailed and accurate map of these areas, as well as build the capacity of stakeholders within government institutions. These stakeholders include the Accra Metropolitan Assembly, the Ghana Statistical Services, the Metropolitan and Municipal District Assemblies, the Ministry of Inner Cities Development and Zongos, and the National Disaster Management Organization. This project will help government stakeholders to make data-driven decisions to improve the lives of local populations. This will include informed planning decisions, and improved disaster response capabilities.</p>
</div>
<div id='map'></div>
<p><span id="aerial"></span> {% include download-data.html %}</p>
{% include mapping-progress.html %}
<iframe src="https://osm-analytics.org/#/compare/gist:c59a6d985eb9da176fdbea63a123ce11/2018...now/buildings/embed/opendri" scrolling="no" width="100%" height="600" ></iframe>
{% include data-quality.html %}
<iframe src="https://osm-analytics.org/#/gaps/gist:c59a6d985eb9da176fdbea63a123ce11/buildings-vs-ghs/embed/opendri" scrolling="no" width="100%" height="600" ></iframe>
{% include osm-community-dynamics.html %}
<script>
mapboxgl.accessToken = 'pk.eyJ1IjoicGFvbG9wYXNxdWFsaSIsImEiOiJoVU9zSE9VIn0.O8Cehs_li5LA2aLurdEDJQ';
var map = new mapboxgl.Map({
container: 'map',
style: 'mapbox://styles/mapbox/streets-v11',
zoom: 14,
center: [-0.225, 5.61]
});
map.on('load', function() {
map.addLayer({
'id': 'one',
'type': 'raster',
'source': {
'type': 'raster',
'tiles': [
'https://tiles.openaerialmap.org/5be9bb18080ac000051474fd/0/5be9bb18080ac000051474fe/{z}/{x}/{y}'
],
'tileSize': 256
},
'layout': {
'visibility': 'none'
},
'paint': {}
}, '');
map.addLayer({
'id': 'two',
'type': 'raster',
'source': {
'type': 'raster',
'tiles': [
'https://tiles.openaerialmap.org/5b694a0f4b87366cc0f0fa70/0/5b694a0f4b8736ebfff0fa71/{z}/{x}/{y}',
],
'tileSize': 256
},
'layout': {
'visibility': 'none'
},
'paint': {}
}, '');
map.addLayer({
'id': 'three',
'type': 'raster',
'source': {
'type': 'raster',
'tiles': [
'https://tiles.openaerialmap.org/5bb9323e9ed15b0006d24f33/0/5bb9323e9ed15b0006d24f34/{z}/{x}/{y}'
],
'tileSize': 256
},
'layout': {
'visibility': 'none'
},
'paint': {}
}, '');
map.addLayer({
'id': 'four',
'type': 'raster',
'source': {
'type': 'raster',
'tiles': [
'https://tiles.openaerialmap.org/5d2d0ab4f416f40006cffcc1/0/5d2d0ab4f416f40006cffcc2/{z}/{x}/{y}'
],
'tileSize': 256
},
'layout': {
'visibility': 'none'
},
'paint': {}
}, '');
});
map.addControl(new mapboxgl.NavigationControl(),'top-left');
map.dragRotate.disable();
map.touchZoomRotate.disableRotation();
map.scrollZoom.disable();
toggleLayer(['one', 'two', 'three', 'four'], 'aerial');
function toggleLayer(ids, name) {
var link = document.createElement('a');
link.href = '#';
link.className = 'button special';
link.textContent = 'View Aerial Imagery';
link.onclick = function (e) {
e.preventDefault();
e.stopPropagation();
for (layers in ids){
var visibility = map.getLayoutProperty(ids[layers], 'visibility');
if (visibility === 'visible') {
map.setLayoutProperty(ids[layers], 'visibility', 'none');
this.className = 'button special';
this.textContent = 'View Aerial Imagery';
} else {
this.className = 'button special';
map.setLayoutProperty(ids[layers], 'visibility', 'visible');
this.textContent = 'Hide Aerial Imagery';
}
}
};
var layers = document.getElementById('aerial');
layers.appendChild(link);
}
</script>