I want to extract some information from a .osm.pbf
file. I looked through OpenStreetMapX.jl
package but didn't find a function to read this data. I am wondering if anyone know a method to read this data. Alternatively is there a way to convert .osm.pbf
to .osm
file so that I found just use the get_map_data()
method offered by OpenStreetMapX
package
Reading .osm.pbf or converting .osm.pbf to .osm
Asked Answered
I would use Osmosis for that:
osmosis --read-pbf myFile.osm.pbf --write-xml myFile.osm
Additional tip - when working with larger maps always run it through OSM filter (wiki.openstreetmap.org/wiki/Osmfilter) before processing with OpenStreetMapX –
Solomon
The wiki says osmosis won't continue development, one should look into new tools especially when first learning them. –
Unvoice
I would use osmium to do this:
osmium cat myFile.osm.pbf -o myFile.osm
© 2022 - 2024 — McMap. All rights reserved.
osmconvert myfile.osm.pbf > myfile.osm
. – Butt