Import/Catalogue/Provincia di Biella/Roads
About
This page talks about importing road data provided by the Province of Biella (Italy).
Please refer to master page for details.
Import Data
Background
Roads in most of the towns in the Province of Biella are already mapped quite well. Anyway there are some towns that are poorly mapped, especially in the mountain, such as Mezzana Mortigliengo.
Using Cygnus it is possible to conflate source data with OSM road data quite easily: http://www.openstreetmap.org/user/mvexel/diary/36746
Legal
Please refer to master page for details.
Import Type
Please refer to master page for details.
Data Preparation
Tagging Plans
The data is presented as a shapefile.
The shapefile is shipped inside the zip file named "3016623Stradario.zip" available at: http://cartografia.provincia.biella.it/on-line/Home/Repertorio/Consultazione/AT7Mobilitaetrasporti.html
This shapefile is periodically updated. This workflow has been validated with the version released on 22/02/2019 (stradario22022019.shp).
The keys and the corresponding values are described in this document provided by the Province of Biella.
The shapefile will be converted to OSM XML using ogr2osm. The projection must be specified as “EPSG:32632 (WGS 84 / UTM zone 32N)”.
Please refer to the osg2osm translation file for further info about tagging.
Dedicated upload account
Please refer to master page for details.
Changeset Tags
Changeset will be tagged with:
- source=Province of Biella Open Data
- source:license=CC-BY
- type=import
- url=https://wiki.openstreetmap.org/wiki/Import/Catalogue/Provincia_di_Biella
Data Transformation
ogr2osm will be used to convert the shapefile to OSM XML format using the above tagging plan.
ogr2osm translation file can be found at https://github.com/musuruan/osm_imports/blob/master/prov_bi/stradario.py
Data Transformation Results
OSM XML file: https://raw.githubusercontent.com/musuruan/osm_imports/master/prov_bi/Stradario/stradario22022019.osm
OSM XML file (nocygnus): https://raw.githubusercontent.com/musuruan/osm_imports/master/prov_bi/Stradario/stradario22022019-nocygnus.osm
Data Merge Workflow
See #Workflow.
Team Approach
Please refer to master page for details.
Workflow
Step by step instructions:
- Run ogr2osm to export the data in OSM XML:
ogr2osm.py --add-timestamp --add-version --positive-id -e 32632 -t stradario.py -f stradario22022019.shp
- Run osmfilter to extract data for a specific town:
osmfilter stradario22022019.osm --keep="is_in=NOME_COMUNE" --drop-tags="is_in" -o=stradario22022019-NOME_COMUNE.osm
. NB: each space character within a value must be preceded by a backslash. - Run osmconvert to convert the data to pbf (NB: the extension MUST be .osm.pbf):
osmconvert stradario22022019-NOME_COMUNE.osm --out-pbf > stradario22022019-NOME_COMUNE.osm.pbf
- Upload NOME_COMUNE.osm.pbf to http://cygnus.improve-osm.org/
- Download the conflated OSM file
- Open the conflated OSM file in JOSM
- Download OSM data for the same area in the same layer
- Use JOSM Validator to fix minor issues
- Remove the
telenav:graph-enhancer
tags - Upload the changeset in OSM
The changeset will be small enough to be uploaded at once.
In case of import problem the changeset will be reverted using the JOSM Reverter Plugin
Alternative Workflow
In this case, we won't use Cygnus for road conflation. It can be useful if Cygnus is down or if you just want to import very few roads.
Step by step instructions:
- Run ogr2osm to export the data in OSM XML:
ogr2osm.py -e 32632 -t stradario.py -f stradario22022019.shp -o stradario22022019-nocygnus.osm
- Run osmfilter to extract data for a specific town:
osmfilter stradario22022019-nocygnus.osm --keep="is_in=NOME_COMUNE" --drop-tags="is_in" -o=stradario22022019-nocygnus-NOME_COMUNE.osm
. NB: each space character within a value must be preceded by a backslash. - Open this file in JOSM
- Download OSM data for the same area in another layer
- Manually select roads you want to import
- Use "Merge selection" to copy these roads into the OSM data layer
- Manually join imported roads and existing OSM roads
- Use JOSM Validator to fix minor issues
- Upload the changeset in OSM
The changeset will 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 #Workflow.
QA
Josm validator should catch most issues prior to uploading the data.
Missing road names will be added after importing address data.