OpenStreetMap 로고 OpenStreetMap

Deep Dive: natural=coastline

bdon님이 English로 2019년 12월 28일에 게시함. 최근 2019년 12월 29일에 업데이트됨.

I have made several edits around the world related to the OSM coastline. My goal is to enable small-scale derivation of land and ocean polygons without resorting to global preprocessed continent geometries assembled from programs like OSMCoastline.

As a primer, the coastline should be mapped as ways with natural=coastline, with land on the left side and ocean on the right side. This is specified on the OSM wiki: Tag:natural=coastline. “Land” in this instance is defined as the non-ocean parts of the world, not solid ground in general; for example, the Great Lakes are represented not by coastlines but as water body features inside “land”.

There are a few implications to this design:

The ocean should be one polygon in the OGC Simple Features sense: it has one outer ring in the clockwise (CW) direction, and a counter-clockwise (CCW) inner ring for every continent and island. The Caspian Sea is the one exception to this single polygon as stated on the Wiki.

The complement of the global ocean polygon is thousands of land polygons representing continents and islands. Each polygon has a single CCW outer ring and zero inner rings. Again, the one exception is that the Eurasian continent polygon has a CW inner ring representing the Caspian Sea.

In theory, this specification should be enough to infer land and ocean polygons from orientation even within a small geographic extract. I discovered and corrected several dozen places where a violation of this specification arises. The image below is an example of data that needs to be corrected:

example error

These problems are sometimes simply mistagged islands within inland water bodies (Changeset 78960812), but can arise even when mappers are mindful of oceans and way orientation. From edit histories this seem to happen because:

A mapper correctly adds island A based on satellite imagery. Years later, a mapper has access to higher resolution imagery and adds island B (way 677293895). However, B is wholly contained within A: the ocean defined by B’s boundary contradicts the land defined by A’s boundary.

example island in island

Changeset 78947512 : A case where a hydrological feature has been changed from part of the Single Ocean Polygon to a more detailed object, such as a river delta, estuary or bay multipolygon. The outer ring of the Single Ocean Polygon recedes, but now its islands are no longer contained.

example new multi

I have corrected most occurrences of this problem as of December 2019, which should enable more flexible land and ocean mapping from raw OSM extracts! Inevitably these issues will crop up again as the global coastline is better digitized, so I hope this post can help mappers fix them.

위치: Prospect Heights, Brooklyn, Kings County, New York, 11238, United States
이메일 아이콘 Bluesky 아이콘 Facebook 아이콘 LinkedIn 아이콘 마스토돈 아이콘 텔레그램 아이콘 X 아이콘

토론

2019년 12월 29일 08:12Warin61님의 의견

I’d think ‘land’ does not include waterways, lakes etc. Using the coastline to define ‘land’ would include these water features. Many coastlines do not follow rivers ‘inland’ but have simple lines across their mouths to define the coastline. As an approximation it works .. but at a fine scale it misses things.

2019년 12월 29일 15:28bdon님의 의견

Yes, in this case “land” should be interpreted as non-ocean shapes; most freshwater areas are and should be mapped on top of this “land”. I’ll edit the post above to clarify this.

2019년 12월 29일 16:58giggls님의 의견

OSM Inspector provides a Coastline view https://tools.geofabrik.de/osmi/ generated from the osmcoastline process producing the data available at https://osmdata.openstreetmap.de/

2019년 12월 29일 17:03bdon님의 의견

@giggls I don’t believe that the Coastline checker tool you link catches this class of error right now, though it may be possible to add an automated check for it by doing point-in-polygon tests.

2019년 12월 29일 17:04bdon님의 의견

One area that I haven’t attempted to fix is the area around this delta: osm.org/way/677293895#map=19/2.54713/-78.40208 which requires tracing new coastlines. It doesn’t appear in the OSM inspector view.

댓글을 남기려면 로그인하세요