Giter Site home page Giter Site logo

osm2gexf's Introduction

osm2gexf

converts OSM xml files to a network graph in GEXF format

Intro

This is a Python library which allows you to convert an OpenSteetMap (OSM) xml file into a GEXF file for import into Gephi, or other GEXF aware libraries.

The aim is to allow Street Network Analysis of OSM data using Gephi or other tools. This can then allow you to compute centralities, betweenness, eccentricity, etc.

An example can be found in demo.py

For larger OSM files I suggest you enable the 'network simplify', as shown in demo.py. This converts series of edges so that each series of edges between junctions is simplified to a single segment. This helps keep the network size down, at the cost of map aesthetics. For example, roundabouts with lots of line segments will be simplified into diamond shapes.

Dependencies

None on the python side, all libraries are built in

Optional but recommended : a tool or library to process gexf files Gephi - https://gephi.org/

Tips if using Gephi

If using Gephi, you'll want to install the GeoLayout optional plugin. This lets you see the network as a geographic map.

When importing the GEXF,

  • change type to 'Undirected'
  • uncheck 'add missing nodes'

When running this plugin, I suggest you use the following settings:-

  • Latitude - lat
  • Longitude - lon
  • Scale - somewhere between 500000 and 15000000 (town/city size maps)

osm2gexf's People

Contributors

stevefaeembra avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.