Import/Catalogue/Address import for Anzola dell Emilia
About
This page talks about importing addresses using the data provided by the Municipality of Anzola dell'Emilia (Italy).
The import has been discussed on the Italian OSM mailing list. This wiki page is the result of consensus there.
Import Plan Outline
Goals
This import goal is to use the high-quality dataset provided by the Municipality of Anzola dell'Emilia in order to steadily improve the addresses available in OSM. It will not be a blind import, data will be checked by a local mappers.
Schedule
TBD.
Import Data
Background
Address format in Anzola dell'Emilia
House numbering in Anzola dell'Emilia follows the European scheme.
An address in Anzola dell'Emilia is determined by its streetname and housenumber.
A housenumber is also unique per street.
Housenumbers can include a subordinate. These are noted with suffix letters (e.g. in "7a", "a" is the subordinate). Subordinates usually arise when a new house is build between existing houses with subsequent housenumbers. E.g. when a house is build between numbers 7 and 9, the new house will most likely get number 7a (since even numbers are reserved for the other side).
The postal codes boundary is the same as the municipal boundary and therefore the only postcode for Anzola dell'Emilia is "40011".
Legal
Data source site: http://dati.emilia-romagna.it/catalogodati/ricerca-avanzata/dato/102-102-04-civici-shp.html
Data license: https://creativecommons.org/publicdomain/zero/1.0/legalcode
Type of license: CC0
OSM attribution: Not required
ODbL Compliance verified: yes
Import Type
The dataset will be imported as a single changeset.
The dataset will be loaded in JOSM and it will be merge with existing OpenStreetMap data manually and prior to the upload.
Data Preparation
Tagging Plans
The data is presented as a shapefile. This shapefile consists in a collection of punctual elements, one for each housenumber.
Each node has the keys:
- CivNumero: housenumber
- CivSub: subordinate, if present
- Etichett_1: street name
- Etichetta: street name with housenumber with subordinate (if present), separated by "/"
- Etichetta_: housenumber with subordinate (if present), separated by "/"
- WSKey: housenumber id
- WSKey_Vie: street id
The shapefile will be converted to OSM XML using ogr2osm. The projection is EPSG:3003 (Monte Mario / Italy zone 1).
The tags that will be used in the final upload are addr:housenumber, addr:street, addr:postcode and addr:city.
The tags will be as follows:
- addr:housenumber will contain the number in Etichetta_ converted to lowercase (for subordinates) and with "/" removed.
- addr:street will contain the street name in Etichett_1 but normalized to follow Italian conventions.
- addr:postcode will contain "40011".
- addr:city will contain "Anzola dell'Emilia".
Dedicated upload account
The account Andrea Musuruane import will be used to upload the imported data.
Changeset Tags
Changeset will be tagged with source=Comune di Anzola dell'Emilia.
Data Transformation
Ogr2osm will be used to convert the shapefile to OSM XML format using the above tagging plan.
Source scripts can be found at https://github.com/musuruan/osm_imports
Data Transformation Results
OSM XML file: https://dl.dropboxusercontent.com/u/12575912/Civici.osm
OSM XML with addresses already in OSM merged: TODO
Data Merge Workflow
Addresses already in OSM will be extracted using the following Overpass query:
<osm-script>
<query into="comune" type="area">
<has-kv k="admin_level" v="8"/>
<has-kv k="name" v="Anzola dell'Emilia"/>
</query>
<union>
<query type="node">
<area-query from="comune"/>
<has-kv k="addr:housenumber"/>
</query>
<query type="way">
<area-query from="comune" />
<has-kv k="addr:housenumber"/>
</query>
<item/>
<recurse type="down"/>
</union>
<print mode="meta" />
</osm-script>
If you perform the query, you'll see there are just a few housenumbers: 5 nodes and 2 building.
Since address data in the Municipaly of Anzola dell'Emilia data source are placed exclusively on nodes (a wise choice because a building can have different entrances and therefore different addresses) the addresses for buildings will be removed.
Addresses already present will be merged. It will done manually since they are just a few.
Team Approach
Import will be managed by Andrea Musuruane. Looking for mappers to check data on field.
Workflow
Step by step instructions:
- Run ogr2osm to export the data in OSM XML
- Run overpass query to export the existing addresses
- Merge these addresses in JOSM
- Upload the changeset in OSM
The changeset should be small enough to be uploaded at once.
In case of import problem the changeset will be reverted using the JOSM Reverter Plugin
Conflation
See #Data Merge Workflow.
QA
Street names
After the import, addr:street names could be slightly different than street names.
These differences should be catched using OSM Inspector (map already centered on Anzola dell'Emilia).
Unmarked streets
The result can be used to locate areas where streets are missing.
Missing roads will be created in JOSM using PCN 2012 areal images.
Unnamed streets
The result can be used to derive street names for unnamed streets when all the nodes along the street has the same addr:street value.
Missing road names will be identified using the OpenStreetMap NoName Map Overlay:
tms:http://tile3.poole.ch/noname/{zoom}/{x}/{y}.png
OSM Inspector can also be used to find these streets.