Triplinx Metrolinx Import Plan
- 1 Introduction
- 2 Goals
- 3 Schedule
- 4 Import data
- 5 Data Preparation
- 6 Data Merge Workflow
- 7 References
Metrolinx is an agency of Government of Ontario to deliver mobility solutions for the Greater Toronto and Hamilton Area (GTHA). Recently Metrolinx launched an official trip planner and transportation information resource for GTHA, called Triplinx. Triplinx is designed to give information on trips using an integrated transit system of walking, cycling, or driving. Triplinx provides the transit schedule, fare, service, and other useful information.
Triplinx currently includes transit information for the following GTHA transit agencies:
- Brampton Transit
- Burlington Transit
- Durham Region Transit
- Hamilton Street Railway (HSR)
- Oakville Transit
- Milton Transit
- MiWay (Mississauga Transit)
- Toronto Transit Commission (TTC)
- York Region Transit/Viva
- UP Express
- GO Transit
Triplinx uses OpenStreetMap data to populate the addresses in the system, as well as routing on the street network. Since GTHA is the most dynamic area in Canada which is growing very fast, missing or mistaken address ranges information are most challenging issue using OpenStreetMap (OSM). To overcome this, merging open data available from Federal or Ontario Governments is a promising approach when it has more reliability in term of precision and accuracy.
Statistics Canada (StatCan) has released a significant amount of open data. Importing the most precise information about the address ranges and roads from StatCan into OSM can provide a substantial enhancement in the performance of Triplinx trip planner as well as further usage from OSM users.
The main goal is to improve the precision of address ranges information in OSM by adding missing information or modifying mistaken features using StatCan road network dataset (StatCan 92-500-X (http://open.canada.ca)).
|Action/Due Date||Nov 2015||Dec 2015||Jan 2016||Feb 2016||Mar 2016|
|Write Plan and Receive Feedback from Community||***********|
|Data Merging and Conflation||***********||***********|
|Import Data on OSM||**********|
Address ranges will be imported from StatCan. The information will be imported by Metrolinx using JOSM software for bulk import.
Source: Open, Governmnet Data Portal, Statistics Canada, Intercensal – Road network files, 2015. This does not constitute an endorsement by Statistics Canada of this product.
Type of License
This is version 2.0 of the Open Government Licence – Canada.
Link to Permission
As part of Open Data available agreement, we have been granted access to adapt StatCan address ranges information on OpenStreetMap.
This will be a bulk import. The data will be imported, including address ranges information, JOSM will be used for import and OSM specification Validation. Only the changed/updated data will be uploaded in OpenStreetMap.
Data Reduction & Simplification
A script is developed in R, for data simplification and indexing.
- addr:street="Street Full Name"
- source="StatCan 92-500-X"
JOSM action=”modified/added/deleted” attribute is used for changeset tag.
All data is transformed in WGS84 and translated in OSM XML format by using in-house code for extracting the relevant information from StatCan. Two main elements of XML file are:
<?xml version='1.0' encoding='UTF-8'?> <osm version='0.6' upload='true' generator='JOSM'> <bounds minlat='44.672433' minlon='-77.884728' maxlat='44.905133' maxlon='-78.104225' origin='' /> <node id='-369416' visible='true' lat='43.221884' lon='-79.791287'> <tag k='addr:housenumber' v='324' /> <tag k='addr:street' v='Montmorency Drive' /> <tag k='source' v='StatCan 92-500-X' /> </node> <node id='-369414' visible='true' lat='43.221695' lon='-79.791369'> <tag k='addr:housenumber' v='330' /> <tag k='addr:street' v='Montmorency Drive' /> <tag k='source' v='StatCan 92-500-X' /> </node> <way id='-502462' visible='true'> <nd ref='-369416' /> <nd ref='-369414' /> <tag k='addr:interpolation' v='even' /> <tag k='source' v='StatCan 92-500-X' /> </way> </osm>
Data Transformation Results
Link to OSM XML files!
Data Merge Workflow
The imports will be done by Applied Research and Corporate Monitoring team of Planning and Policy division of Metrolinx trough one OSM account for Metrolinx.
The GTHA region is divided into 124 segments. For ease of importing the data through JOSM, the data will be clipped to each segment and uploaded accordingly. After the first data upload, the changes will then be uploaded as one file from the entire region. The data will be examined and checked for accuracy before being uploaded. JOSM validator will be used for any errors/warnings and be reviewed carefully under circumstance of OSM specification. The data will be frequently checked, any changes will be updated through new import along the year.
An in-house algorithm is designed and implemented for conflation of information in R environment using rgeos, rgdal, XML, RCurl libraries. A buffering algorithm is designed for investigating address ranges in Left to Right side of each road segment. Then, the intersected or crossed address ranges lines from OSM and StatCan is compared and sum up for restraining to keep, leave or adding address ranges segments in both side of road segment or not.
- Triplinx: https://www.triplinx.ca
- Metrolinx: http://www.metrolinx.com
- Open Government Licence - Canada: http://open.canada.ca/en/open-government-licence-canada
- R: https://www.r-project.org