NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the 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

kellya
26112
accept rate: 0%

edited 11 Apr '18, 22:29

aseerel4c26's gravatar image

aseerel4c26 ♦
32.6k18248554

1

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

By RSS:

Answers

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:

×252
×83
×79
×68
×23

question asked: 10 Apr '18, 18:41

question was seen: 1,847 times

last updated: 11 Apr '18, 22:29

NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum