[GIS] extract amenity from pbf file using osmosis

openstreetmaposmosis

I want to extract some amenity(atm) from a pbf file.
Here is what i've found.

osmosis –read-pbf myfile.pbf –tf accept-nodes amenity=atm –write-xml atm.osm

Myfile.pbf is a file for Paris area (France). It's 211Mo.
The atm.osm file is 1.8Go I think it's really big for only ATM of Paris.
So is it the good way to extract atm?
I also tried with rarely amenity and it's always a 1.8Go file.
Is there a way to read atm.osm to know if the data is good?
If I'm not on the right way I want to extract ATM from the data to insert it in the future in a database.

Best Answer

I found a different query :

osmosis --read-pbf myfile.pbf --node-key-value keyValueList='amenity.atm' --write-xml atm.osm

I got a 250ko xml file with all the atm. Hope it can help other peolple

Related Question