Skip to main content

Questions tagged [osmnx]

OSMnx is a Python package to download, model, analyze, and visualize street networks and other geospatial features from OpenStreetMap. You can download and model walking, driving, or biking networks with a single line of code then easily analyze and visualize them. You can just as easily work with urban amenities/points of interest, building footprints, transit stops, elevation data, street orientations, speed/travel time, and routing.

283 questions with no upvoted or accepted answers
3 votes
0 answers
84 views

Is there a way to approximate a polygon to a polygon in a road network

I'm working with polygons in maps. I have a df, df_polygons, each row in the df refers to a different polygon. And df_polygons['polygon'] retrieves a specific polygon, defined by a set of ordered ...
Beatriz Santos's user avatar
3 votes
0 answers
966 views

how to select a subgraph from an omsnx graph?

I have extracted the road network from Haiti using osmnx impor omsmnx as ox place = ox.gdf_from_place('Haiti', which_result=2) coords = place.geometry.total_bounds G = ox.graph_from_bbox(coords[3], ...
emax's user avatar
  • 7,175
3 votes
1 answer
4k views

Osmnx: creating a graph from a shapefile/XML

I'm learning how to do Network Analysis for road networks of countries. I already have the shapefiles. I have been trying to convert them to networkx without much success so I'm trying to use the ox....
himabhima's user avatar
2 votes
0 answers
1k views

How do you get all roads (including private and service roads) in osmnx?

I am using the follwing command in osmnx to downlaod roads from the OSM server: osmnx.graph.graph_from_polygon(polygon, network_type='all_private', simplify=True, retain_all=False, truncate_by_edge=...
jtam's user avatar
  • 884
2 votes
1 answer
366 views

Osmnx save big graph as graphml

I am downloading a big street network (Berlin). When I try to save it to the disc my laptop just do nothing for hours. Is that normal? My Code: ox.save_graphml(G,“some_place.graphml“)
Määäx's user avatar
2 votes
0 answers
706 views

How to plot osmnx geometries on top of graph?

I started playing with the osmnx Python package and have to questions: Is the following minimal working example the correct way to plot additional geometries on top of my graph G or are there better ...
N8_Coder's user avatar
  • 793
2 votes
0 answers
2k views

Convert a geodataframe into an OSMNX graph?

I have a road network shapefile with a few different attributes. I want to study the network orientation by filtering shapefile based on these attributes. I can do the filtering in geopandas but didnt ...
PPillai's user avatar
  • 21
2 votes
0 answers
171 views

Railway length with OSMNX

I am a total beginner with OSMNX, and I was wondering if (and how) I could get the length of an electrified railway that connects two specific cities, eg. Hambug and Hannover, in Python. I am looking ...
Natassa's user avatar
  • 29
2 votes
0 answers
434 views

Use of non-OSM data in OSMnx

I really like the functions of OSMnx, thank you! Nevertheless sometimes OSM-data is limited, especially for human powered modes like walking and cycling. I am working on a project for Zuerich, ...
jonas_2021's user avatar
2 votes
0 answers
704 views

OSMNX graph to distance matrix and DBSCAN

I'm having troubles programming to get the distance matrix from a Graph of coordinates (LAT,LON). I want to connect an arbitrarily group of points (let's say, 200.000 firms), get their nearests ...
arioboo's user avatar
  • 195
2 votes
0 answers
433 views

Creating new nodes using redistribute_vertices

I am working on a graph flow model in the context of transport networks. I have the position of sensors (lat/lon) and would like to associate these sensors with nodes on a graph retrieved using osmnx. ...
Joseph Redfern's user avatar
2 votes
0 answers
2k views

Open Street Map using OSMNX: how to retrieve bus routes?

import osmnx as ox ox.__version__ # '0.13.0' I would like to show the bus routes from the Open Street Map for Hannover on a map using OSMNX by retrieving them as ".graph...". E.g.: G = ox....
Wouter's user avatar
  • 1,316
2 votes
1 answer
936 views

Nearest points to an edge within a distances using osmnx in Python

I'm trying to associate a set of points (lat, long) to an edge using osmnx library in Python. I would like to find the nearest points to an edge within a distance x. I have an edge and I would like ...
Mateo Valencia's user avatar
2 votes
0 answers
274 views

Adding color gradient legend for visualizing the node centrality

I am a beginner at using osmnx package in python. From the examples in https://github.com/gboeing/osmnx-examples/blob/master/notebooks/08-example-line-graph.ipynbin I am trying to visualize network ...
shri's user avatar
  • 21
2 votes
0 answers
941 views

OSMNX - visualizing waterway together with footprints and ground

I am trying to plot waterway together with ground (street network/map) and footprints (buildings). My problem is that the waterways are large closed polygon areas, which means instead of plotting a ...
Magnus Persson's user avatar

15 30 50 per page
1
2 3 4 5
19