Why not ask your question on the new OpenStreetMap Community Forum?

Hi all

I'm trying to extract only waterbodies from a .osm file using osmosis. I'm almost there, but my command is returning islands and islets as water and I can't figure out how to get only water!

Here's the command I'm using:

osmosis --read-xml swedencity.osm --tf accept-relations natural=water landuse=basin,reservoir --tf reject-relations intermittent=yes --used-way --used-node --write-pbf swedencity-waterbody-relations.osm.pbf

This returns the water I want, but also returns features with place=island and islet, as well as a ton of smaller islands w/o any place tag. Is there a way to eliminate all of these? My attempts to reject island relations have failed so far...

Any help is much appreciated! Thanks so much.

asked 10 Apr '18, 18:41

kellya's gravatar image

accept rate: 0%

edited 11 Apr '18, 22:29

aseerel4c26's gravatar image

aseerel4c26 ♦


They are likely inner members of water relations; that's how water is modeled in OSM, with islands as holes in the water.

(11 Apr '18, 01:55) maxerickson
Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 10 Apr '18, 18:41

question was seen: 1,664 times

last updated: 11 Apr '18, 22:29

powered by OSQA