|
20 | 20 | "metadata": {}, |
21 | 21 | "source": [ |
22 | 22 | "## Quick example\n", |
23 | | - "Here we provide a quick example of an impact calculation with CLIMADA and OSM data.\n", |
| 23 | + "Here we provide a quick example of an impact calculation with CLIMADA and OpenStreetMap (OSM) data.\n", |
24 | 24 | "We use in this example main roads in Honduras as exposures, and historical tropical cyclones\n", |
25 | | - "as hazard. We load the osm data using `osm-flex` and disaggregate the exposures, \n", |
| 25 | + "as hazard. We load the OSM data using `osm-flex` and disaggregate the exposures, \n", |
26 | 26 | "compute the damages, and reaggregate the exposures to their original shape using the \n", |
27 | 27 | "function `calc_geom_impact` from the util module `lines_polys_handler`. \n", |
28 | 28 | "For more details on the `lines_polys_handler` module, please refer to the [documentation](https://climada-python.readthedocs.io/en/latest/tutorial/climada_entity_Exposures_polygons_lines.html)." |
|
65 | 65 | "metadata": {}, |
66 | 66 | "source": [ |
67 | 67 | "The first step is to download a raw osm.pbf file (\"data dump\") for Honduras from geofabrik.de \n", |
68 | | - "and extract the layer of interest (here roads), but other layers can be calculated (see CLIMADA and OpenStreetMap [section](#climada-and-openstreetmap))" |
| 68 | + "and extract the layer of interest (here roads). See the set-up CLIMADA exposures from OpenStreetMap [section](#set-up-climada-exposures-from-openstreetmap) for more details." |
69 | 69 | ] |
70 | 70 | }, |
71 | 71 | { |
|
148 | 148 | }, |
149 | 149 | { |
150 | 150 | "cell_type": "code", |
151 | | - "execution_count": 5, |
| 151 | + "execution_count": 20, |
152 | 152 | "metadata": {}, |
153 | 153 | "outputs": [], |
154 | 154 | "source": [ |
155 | 155 | "# disaggregate in the same CRS as the exposures are defined (here meters), resolution 500m\n", |
156 | | - "# divide values on points\n", |
| 156 | + "# replicate values on points\n", |
157 | 157 | "# aggregate by summing\n", |
158 | 158 | "\n", |
159 | 159 | "impact = u_lp.calc_geom_impact(\n", |
|
224 | 224 | "3. **Pre-process**; apply pre-processing steps as e.g. clipping, simplifying, or reprojecting the retrieved layer.\n", |
225 | 225 | "4. **Cast** the geodataframe into a CLIMADA `Exposures` object.\n", |
226 | 226 | "5. **Disagreggate** complex shapes exposures into points for impact calculation.\n", |
| 227 | + "\n", |
227 | 228 | "Once those 5 steps are completed, one can proceed with the impact calculation. For more details on \n", |
228 | 229 | "how to use lines and polygons as exposures within CLIMADA, please refer to the [documentation](https://climada-python.readthedocs.io/en/latest/tutorial/climada_entity_Exposures_polygons_lines.html).\n", |
229 | 230 | "\n", |
230 | | - "In the following, we illustrate how to obtain different exposures types such as healthcare facilities,\n", |
231 | | - "road networks, or forests and how to use them within CLIMADA as points, lines,\n", |
232 | | - "and polygons exposures. We also briefly illustrate the use of the `clip` and `simplify` modules\n", |
| 231 | + "In the following, we illustrate how to obtain different exposures types such as forests or \n", |
| 232 | + "healthcare facilities, and how to use them within CLIMADA as points, lines,\n", |
| 233 | + "and polygons exposures. We also briefly illustrate the use of the `simplify` module\n", |
233 | 234 | "available within the `osm-flex` package." |
234 | 235 | ] |
235 | 236 | }, |
|
239 | 240 | "source": [ |
240 | 241 | "#### Download a raw osm.pbf file (\"data dump\")\n", |
241 | 242 | "First, we need to select a specific country and download its data from geofabrik.de. It is possible to\n", |
242 | | - "download data from specific countries using iso3 codes or for regions directly." |
| 243 | + "download data from specific countries using iso3 codes or from regions directly." |
243 | 244 | ] |
244 | 245 | }, |
245 | 246 | { |
|
269 | 270 | "#### Extract the features of interest\n", |
270 | 271 | "\n", |
271 | 272 | "We next extract the exposures data of interest from OSM using the `extract()` method which\n", |
272 | | - "allows us to query any tags available on openstreetmap.\n", |
273 | | - "Two variables have to be specified: `osm_keys`, a list with all the columns to report in the gdf, and `osm_query`, a string of key-value constraints to apply during the search. We illustrate its use by querying the download of forests for Honduras." |
| 273 | + "allows us to query any tags available on OpenStreetMap.\n", |
| 274 | + "Two variables have to be specified: `osm_keys`, a list with all the columns to report in the GeoDataFrame, and `osm_query`, a string of key-value constraints to apply during the search. We illustrate its use by querying the download of forests for Honduras." |
274 | 275 | ] |
275 | 276 | }, |
276 | 277 | { |
|
0 commit comments