NewportDataProject / osm-analysis

Working with OpenStreetMap data
0 stars 0 forks source link

Get all OSM tags using osmnx #1

Closed paulopperman closed 7 years ago

paulopperman commented 7 years ago

Need to figure out a way to pull all tags from OSM and work with them in the osmnx, like sidewalks and lit. Unsure if osmnx supports it, but I can't find where it is stripping them off, if it does.

paulopperman commented 7 years ago

I think this approach might work, although its inelegant: G = ox.graph_from_place('Newport, RI') Get list of ways from G by looping through each edge, reading the osmid attribute, call OsmApi.WaysGet(edge_list) and then iterate back through the original list of edges and writing new attributes.

paulopperman commented 7 years ago

It is possible to get additional tags by calling ox.config(useful_tags_path=my_tags) where my_tags is a list of tag names.