0
点赞
收藏
分享

微信扫一扫

osm2gmns | Convert map.osm data to GMNS format

一点读书 2022-02-09 阅读 86

Notes: The following notes are learned from the user guide for osm2gmns found at osm2gmns — osm2gmns 0.2.0 documentation. 

Input: map.osm

Output: link.csv, node.csv, poi.csv

Quick Start

Step1: Download map.osm file from OpenStreetMap (OpenStreetMap)

  1. Search the location of interest and click on the “Export” button on the top.
  2. Obtain the latitude and longitude coordinates (users can “manually select a different area”).
  3. Click on the “Export” button found in the middle of the navigator to download an OSM data file.
  4. For a very large area of interest, users need to click the link of “Overpass API” to obtain a map file.

Step2: Execute OSM2GMNS to get network files in GMNS format

Use OSM2GMNS to convert the map.osm file in OSM format into a network file in GMNS format.

import osm2gmns as og 

net = og.getNetFromOSMFile('./Tempe/map.osm', network_type=('auto', 'bike', 'walk'), POIs=True, default_lanes=True, default_speed=True)

og.connectPOIWithNet(net)

og.consolidateComplexIntersections(net)

og.outputNetToCSV(net, 'Tempe')

举报

相关推荐

0 条评论