This is a static archive of our old OpenStreetMap Help Site. Please post any new questions and answers at community.osm.org.

Osmium - filter by bounding box

2

Hi there,

I am wondering if Osmium would be a good tool to use to filter by bounding box? I had a poke around in the documentation but it seems more geared up for tag filtering and I could not find any examples.

Stephen

asked 10 Sep '15, 16:51

stev's gravatar image

stev
51337
accept rate: 0%


2 Answers:

4

Osmium is first an foremost a library and not a tool; there's a couple command-line programs (notably osmium-tool) that make use of some of Osmium's capabilities but mostly Osmium is for programmers. You could implement a bounding box filter with Osmium - but why not use what is already there, namely Osmosis (written in Java), osmconvert (in C), or osm-history-splitter (C++ and based on the older version of Osmium).

answered 10 Sep '15, 19:37

Frederik%20Ramm's gravatar image

Frederik Ramm ♦
82.5k927201273
accept rate: 23%

OK, thanks, just checking that I hadn't missed something. I wanted to use a "best-in-class" tool (performance-wise) to compare with what I'm doing on scaling out with Hadoop etc. And I think Osmium could be that but I'll take a look at the older tools. Thanks.

(13 Sep '15, 11:19) stev

1

The other answer ist by a bit outdated. Osmium tool provides an "extract" command which will filter by bounding box (or polygon).

answered 16 Dec '21, 18:56

Jochen%20Topf's gravatar image

Jochen Topf
5.2k55074
accept rate: 31%

Source code available on GitHub .