OpenStreetMap-embleem OpenStreetMap

Rethinking OSM tagging/positioning - from an OSM layman point of view

Plasing deur ThePromenader op 13 April 2011 in English. Laas opgedateer op 14 April 2011.

Hello,

I've been using OSM since around a month now, and would like to make a few suggestions, and please feel free to make any clarifications if I have missed anything.

First off, from a data point of view, I find it a bit confusing that there can be no overlapping polygons: If I was to place, for example, the middle of a city block, I would either a) have to make the building an 'inner' member of a multipolygon (the city block), or b) cut a building-shaped hole in the city block polygon (making it a multipolygon) and place the building exactly upon it. a) is more data-friendly but not at all logical (from an architecture point of view), and can create confusion in certain rendering circumstances (whereas building data would become inseparable from the land around it, according to the OSM 'member id' system in place, and b) would require much more work, plus placing the same polygon (building + its corresponding hole) into the database twice.

The simplest solution I can think of is: allow overlapping polygons. This would be best from both a data and land-logic point of view. This would be possible if there existed a default 'layer' logic to how the land is used, and key attributions could stem from there. It would be even better to think in three dimensions - this would both serve the logic of our mapping and future developments (3d!) of OSM.

Let's take the basic 'human logic' of land use; the lowest on the list below would be drawn first below all other elements higher above:

7) any labels, tags or indicators pertaining to any of the below.
6) buildings
5) man-made structures (fences, roads, barriers, stairs, etc - rooted to elevation data)
4) ground covering (grass, sidewalk, crops, concrete - rooted to elevation data)
3) land use (property, bridge, city block, administrative region -rooted to elevation data)
2) water ('poured' into land data, with or without elevation information)
1) the land itself (with or without elevation information)

Arguably, 5 and 6 could be merged. Only water in the above is problematic, but any 'unnatural' water areas (say in fountains, building-tops, and reservoirs) could be a 'man-made' subclass - in fact, it would be nice that if a "building" had a man-made structure on it (say, a fountain) indicated by a later key, it would be drawn on top of (after) it. Anyhow, if each of the above were a key, it could 'default' to a certain colour, yet the key's value would determine rendering.

What led me most to think the above was OSM's (often mis-)use of the "highway" tag: the "highway=pedestrian" tag describes almost every city block within Paris, along with the (seemingly pointless?) "area=yes" tag. This use seems to have stemmed more from the 'development logic' of OSM itself, rather than any 'human logic' plan-related determination.

A road (highway) often describes the separation of properties and city blocks, but the road itself is rarely regular in breadth: in fact, with Paris in mind, it is the 'city block' form that determines the shape and path of a road, and this changes from block to block, so there the idea of a "highway" line (way) is almost moot in itself.

I like the French "Ilot" (road-divided 'block') concept - it is an entity in itself for French Civil Engineers (and available under an OmDB licence at http://opendata.paris.fr), and has been in use since forever for civil engineers the world over; why not here?

Let me give an example: say for example I want to draw a city block containing a park, I would draw:

7) building addresses and street names
6) buildings (and things upon them)
5) man-made structures (fences, stairs, fountains, etc)
4) land covering (the park would have grass polygons with perhaps 'tree' node info and perhaps 'lake')
3) the city block
1) on existing land data (elevation or no)

Forgive my digression, but it would be actually possible to have ~any~ key (road, land covering) be rendered 'on top' of another just by indicating its 'membership' (in relation, not in form) to another object, by id number: grass on a building could be rendered after the building, if the only link to the grass polygon was through the building itself.

So my basic idea is to provide first a) allow overlapping polygons and b) think of a new basic 'land use' logic to keys. And perhaps re-think the "relation" concept in a way that is more "object" than "shape".

I hope I was clear in my presentation - and if there is something I missed already in place, please forgive my oversight - and please let me know about it!

Best,

ThePromenader

Ligging: Quartier Saint-Germain-l'Auxerrois, 1st Arrondissement, Paris, Ile-de-France, Metropolitan France, 75001, France
Email icon Bluesky Icon Facebook Icon LinkedIn Icon Mastodon Icon Telegram Icon X Icon

Discussion

Kommentaar van Andy Allan op 13 April 2011 om 10:21

Your basic premise of the whole discussion is false - you can certainly have overlapping polygons in OSM, and I've no idea why you would think otherwise.

As for the grass on a building thing, that's fine, just use the layer tag to describe how objects are related vertically.

Kommentaar van Vincent de Phily op 13 April 2011 om 10:56

Perhaps there's a confusion between 'best practice' and 'technical restriction'. There are quite a few cases where "no overlaping polygon" is good advice to mappers, even if it's just for data consistency purposes.

Kommentaar van ThePromenader op 13 April 2011 om 17:58

I knew I missed something: Okay, if we can have overlapping polygons, a) why do I get a warning everytime I place a polygon over another, and b) even if I did that in spite of the warning, how can I ensure that a polygon remain on 'top'? Are 'building' keys, for example, already programmed to appear on top of everything else? I find little documentation about this sort of subject anywhere.

Kommentaar van JoshD op 13 April 2011 om 18:13

Those warnings are put there usually to notify beginning mappers that they may be doing something incorrectly. However sometimes those warnings should be completely ignored.

As far as buildings being on top of everything else, this is something that individual data consumers determine. All consumers I know of (Mapnik, Osmarender, etc) draw buildings on top of almost everything else. You can give a hint to the consumer with the layer tag in case you have some feature on top of a building that would normally be covered by the building when rendered.

The data producers and consumers themselves determine how this data is treated. If a group of contributors map a huge area in a particular way, and then a renderer adds support for it, it has essentially be come accepted practice. We get a sense of how data producers are doing things with Tagwatch/Taginfo/etc, which give information on how the data is actually tagged. What we need now is a similar service that summarizes how data consumers treat that data.

Kommentaar van ThePromenader op 13 April 2011 om 18:33

Thanks for your reply. If that is the case, I don't understand the "relation" concept currently at use in OSM - some contributors add buildings as an 'inner' member of a landuse multipolygon; others draw buildings as independent elements. Already I have run into problems with this in just experimenting with OSM data. If the usage of this concept is so varied, how can the end-user determine 'what belongs to what' and 'what goes where'? It is (seemingly) OSM itself that determines this. Is there really no coherent system?

Kommentaar van ToeBee op 14 April 2011 om 04:53

Relations are only needed in certain circumstances to describe areas/polygons. If you are mapping a building with a hole in it, you need a relation:
http://www.openstreetmap.org/browse/relation/1530467

If two objects share a border they CAN be mapped as a relation. For example, county boundaries are often mapped as relations. The way that describes the border between two counties is a member of two different relations. Example:
http://www.openstreetmap.org/browse/way/67976026
is a member of both Riley county and Marshall County.

But you can also just make the two objects share nodes, in effect overlapping the ways on top of each other where they touch. Which way to do it is kind of up to you. There are valid arguments and situations for both ways.

If the boundary of an area is made up of separate mappable things. For example if a grave yard has a fence around part of it and hedges around another part, you could map the fence and hedge separately using ways and then put the fence and hedge ways into a relation that describes the whole grave yard area.

If an object is too big to be a single way. Ways can only have up to 2,000 nodes in them. If something is too big to map in 2,000 nodes (like lakes) then you have to split the way into smaller chunks and add them all to a relation.

Cutting hold into landuse areas seems silly to me. I could see it being appropriate in very specific cases but in general, it is silly.

Here is an apartment complex in my city. If you look at it in edit mode, you will see it has nested polygons.
http://www.openstreetmap.org/?lat=39.206869&lon=-96.618048&zoom=18&layers=M

Kommentaar van ThePromenader op 14 April 2011 om 06:50

Thanks for the example, ToeBee.

Gotcha for a single way to be mapped between two relations - makes sense, especially from a data (load) point of view.

After reading up on the "landuse" tag, perhaps I shouldn't have used that term. "Land covering" would be closer to what I was trying to say, but I think my ideas on that are clearer now.

In your last example, I see that the buildings are nicely overlaying your "block" polygon (blowing apart my "no overlapping polygons" misconception), but what purpose does the "outer" polygon in the overall multipolygon have?

Kommentaar van ToeBee op 14 April 2011 om 07:25

*sigh* it is late. Apparently I forgot to close the link tag at the end of my first paragraph. It should read "it is from this polygon"

Kommentaar van ThePromenader op 14 April 2011 om 08:21

Thank you for your quite clear explanation. I'll try to recreate that error later today. Take care!

Meld aan om kommentaar te lewer