helper.city_graph_generator

helper.city_graph_generator(city)[source]

Generate an OSMnx graph of city.

Graph modified to be undirected, weighted, and meeting the triangle inequality.

Parameters:city (str) – The city to query road network from. ‘City, Country’.
Returns:G – OSMnx generated graph of city. Graph is weighted, undirected, and satisfies the triangle inequality.
Return type:graph
Raises:AssertionError – If city is not a string.