Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Fork of subversion geobase2osm tool
Python
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
LICENSE
README
addnames_statscan.py
geobase2osm.py
roadmatchertools.py

README

-------------
-- STATUS: --
-------------

This tool has been used to import data in Alberta and Ontario and British 
Columbia.

Each provincial dataset differs slightly.  Please review the data
before importing additional provinces.


Introduction:
-------------
This tool is designed to take a Canadian Geobase GML file (or files) and 
convert it to the representative OSM stucture.

This tool is designed to be compatible with the 0.5 API.

How to use:
-----------

python geobase2osm.py -i NRN_GEOM.gml [-a NRN_ADDR.gml] [-o output.osm] [--pretty] [--quiet]

-i filename = The National Road Network Geometry input file
-a filename = The National Road Network Address input file (optional)
-o filename = The file to save to
--pretty    = Create a indented and neatly formatted output file (can add a fair bit of whitespace)
--quiet     = Don't display any messages while processing
-b filename = This option allows you to exclude portions of the GEOM file from
	      being processed. boundsfile.txt should contain a EWKT type 
	      geometry of the area that should be processed. For example 
	      POLYGON(-120 54,-121 55,-122 56,-122 55,-120 54)
-e filename = If this option is specified then RoadMatcherResult.jml should be 
	      a results file genereated from the road matcher application. 
	      geobase2osm will generate two additional output files. 
	      outfile.osm.standalone.osm will only have roads marked as 
	      StandAlone. outfile.osm.excluded.osm will contain the roads 
	      excluded from the .standalone file.



Requirements:
-------------
Python 2.5 or higher
cElementTree (Note: you can use the native python ElementTree but its much slower. To 
do so change the relevant import line in the script)
Shapely
Python gdal bindings

Notes:
-------------
This is a very memory intensive process for some of the larger Geobase datasets. Things will
be optimized in the future, currently processing requires roughly 10 times the datafile size 
of memory.


Contributors:
-------------
Jason Reid   - Initial script development
Steve Singer - OGR integration, junction processing
Something went wrong with that request. Please try again.