Wrong micro commands on intersection on turn:lanes:forward

80 views
Skip to first unread message

damian....@gmail.com

unread,
Apr 10, 2021, 4:53:12 AM4/10/21
to OsmAnd
Hello,
Recently I noticed that OsmAnd gives wrong micro commands for this trip:


OsmAnd shows that I should turn right, but there is only ability go to through.
I think that OsmAnd and also OSMR has problem with interpretationof this tag: turn:lanes:forward
Screenshot_20210409-194817034.jpg

damian....@gmail.com

unread,
Apr 10, 2021, 4:59:40 AM4/10/21
to OsmAnd
There is also second problem later on this road.

This route and commands from Graphhopper looks ok:
but osmand shows that you should turn right to go through:

2.jpg
I think that this lane has problem with tags:
becuase the left turn ends  and the lane should be over.

Xavier

unread,
Apr 10, 2021, 10:23:36 AM4/10/21
to OsmAnd
><https://wiki.openstreetmap.org/wiki/Key:turn:lanes:forward?uselang=pl>
>[image: Screenshot_20210409-194817034.jpg]

From OsmAnd's viewpoint, I would say that stating "right turn" is
proper, given the data OsmAnd has to use to decide what to signal.

Do keep in mind that the *only* data OsmAnd has are the OpenStreetMap
ways and the tags thereupon. It does not know how the aerial image of
the intersection appears, nor does it know how a human mind would
interpret the same intersection.

Looking at the OpenStreetMap data, what OsmAnd sees is a single line
(Francuska) denoting the "center" [1] of this road. It is tagged as
three lanes and residential, but the geometry that OsmAnd sees is a
perfectly straight three lane road where all three lanes end at an
intersection with Ceglana and the continuation of Francuska as a
tertiary road.

Rough human eyeball guess of the angle of intersection between the
residential way and the tertiary way, I'd guess it to be about 75-85
degrees (i.e., nearly a perfect 90 degree T style intersection).

So OsmAnd sees three lanes, intersecting with another road at about an
80 degree angle, and all three lanes intersecting at the exact point
where the residential way connects to the tertiary way. I.e., nothing
in the OpenStreetMap data would allow OsmAnd to deduce that there is
really only one lane intersecting at 80 degrees (the left lane,
presumably marked "left only", but the Bing images were taken with cars
covering the roadbed) and a second, slip lane, that forks off from the
residential road and smoothly rejoins the tertiary portion of Francuska.
Humans see that, because we interpret the visual aspect of the world in
that spot. OsmAnd has only the OpenStreetMap data, which says three
lanes go arrow straight until they join the tertiary road at a single
point, and at about an 80 degree angle.

So given the near 80 degree angle of intersection, if the only data you
have available is "three lanes, intersecting at a point, at an 80
degree angle" and nothing else, this looks like a typical "right turn"
intersection. Therefore I am not at all surprised that OsmAnd picked
to say "turn right".

Note, I also question (slightly) the tagging of "left|through".
"Through" is defined as "straight only"
(https://wiki.openstreetmap.org/wiki/Key:turn:lanes:forward?uselang=pl)
but if one were to continue "straight" at this intersection, one would
quickly depart the road, cross a footpath, and somewhat quickly impact
with a building (by the looks of the Bing images).

If I were to have been tagging this intersection, and only used a
single way to represent the resident ail street, I think I would have
picked "left|right" for the turn lanes tagging (due to the 80 degree
intersection with the tertiary road).

If you wanted to make fixes, I'd say the better fix would be to give
OpenStreetMap much more detail on the actual real world geometry of the
intersection. I.e., split Francuska into two ways at the point prior
to the intersection where the slip lane becomes a full lane. Reduce
the lanes count on the original straight section to two and adjust the
turn lanes tag appropriately. Then add the right side slip lane as an
additional, single lane, one-way way that smoothly breaks from the
residential road and later smoothly merges back into the tertiary road
at a point representative of where the slip lane would disappear in the
real world.

Then OsmAnd would see two "intersections" occurring at a shallow angle
(15-20 degrees?) rather than a single sharp (80 degrees) angle, and it
would have more data available to choose to say "slight right" or "keep
right" instead of "turn right".

Note -- I have only observed the existing data. I am located half a
world away from this intersection and so any edits would be better made
by someone who has, or can obtain, local knowledge from visiting this
intersection.

[1] "Center" in quotes because the way seems slightly offset in the
Bing imagery, but I have not aligned the Bing imagery for this part of
the world, so I can't say the way is not properly aligned. And the
OpenStreetMap definition is that the "way" denotes the center of a
road.

Xavier

unread,
Apr 10, 2021, 10:35:58 AM4/10/21
to OsmAnd
On Sat, Apr 10, 2021 at 01:59:40AM -0700, damian....@gmail.com wrote:

>There is also second problem later on this road.
>
>[image: 2.jpg]
>I think that this lane has problem with tags:
>https://www.openstreetmap.org/way/292304503
>becuase the left turn ends and the lane should be over.

There is a tag problem with that segment.

It says this for number of lanes:

lanes=3
lanes:backward=1
lanes:forward=2

So the tags say two forward lanes.

But the turn tagging says:

turn:lanes:forward=through|through|right

So the "forward" turn lanes tag states there should be three forward
lanes.

Note this statement in the "turn:lanes" wiki page:

If you use the ":lanes" suffix, the number of values specified
separated by vertical lines (|) must match the number of lanes
according to their direction.

damian....@gmail.com

unread,
Apr 18, 2021, 5:06:11 AM4/18/21
to OsmAnd

I see such tagging which is okay:
```
lanes:backward=1
lanes:forward=2

turn:lanes:forward=through|through;right
```
I don't see this tagging: "turn:lanes:forward=through|through|right"

I think that this segment should have such tagging:
```
lanes:backward=1
lanes:forward=1
turn:lanes:forward=through;right
```
I will go with this problem to Polish osm forum and ask them about this intersection.

damian....@gmail.com

unread,
Apr 18, 2021, 7:39:48 AM4/18/21
to OsmAnd
First issue:
I forgot to add mappilary imagery or my own, but:
https://www.mapillary.com/app/?lat=50.2427793&lng=19.0246699&z=17&pKey=d46NqdKKK3B9JckAOPAM4g&focus=photo&x=0.4892810659969685&y=0.5921736710813945&zoom=0
this intersection for me is also strange, because "go through" should be "go right", but we have such sings and we can do nothing with them.

Aerial imagery without cars:
Francuska_Ceglana.png
So you suggest to split the Francuska street at the intersection and have 2 seperate lanes at the end of Francuska.
Makes sense, but I am not an expert. I will contact the Polish community on Osm Forum.

According to the second issue I am trying to resolve it with Polish community.

Tom Crocker

unread,
Apr 18, 2021, 8:46:08 AM4/18/21
to OsmAnd
I think contacting the Polish OSM forum is a good idea. I would not suggest splitting this road as there is no physical separation (I think), and at least in the UK that is the expectation (even though there's a white lined triangle) but it may be interpreted differently in Poland. The tagging and road seem right to me, I think this is a case where osmand has assumed from the angles that the tagging is wrong, and that's why it's showing what it does. But since it gets the correct lane and shows the through arrow, and suggests to turn right which is your interpretation, I'm not sure much harm is done here.

--
You received this message because you are subscribed to the Google Groups "OsmAnd" group.
To unsubscribe from this group and stop receiving emails from it, send an email to osmand+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/osmand/6439e5a5-2f68-446b-b236-8ddce47ac26dn%40googlegroups.com.

Xavier

unread,
Apr 18, 2021, 9:56:10 AM4/18/21
to OsmAnd
On Sun, Apr 18, 2021 at 02:06:11AM -0700, damian....@gmail.com wrote:
>> On Sat, Apr 10, 2021 at 01:59:40AM -0700, damian....@gmail.com wrote:
>>
>> >There is also second problem later on this road.
>> >
>> >[image: 2.jpg]
>> >I think that this lane has problem with tags:
>> >https://www.openstreetmap.org/way/292304503
>> >becuase the left turn ends and the lane should be over.
>>
>> There is a tag problem with that segment.
>>
>> It says this for number of lanes:
>>
>> lanes=3
>> lanes:backward=1
>> lanes:forward=2
>>
>> So the tags say two forward lanes.
>>
>> But the turn tagging says:
>>
>> turn:lanes:forward=through|through|right
>>
>> So the "forward" turn lanes tag states there should be three forward
>> lanes.
>>
>> Note this statement in the "turn:lanes" wiki page:
>>
>> If you use the ":lanes" suffix, the number of values specified
>> separated by vertical lines (|) must match the number of lanes
>> according to their direction.

>You mean this segment:
>https://www.openstreetmap.org/way/292304503
>
>I see such tagging which is okay:
>```
>lanes:backward=1
>lanes:forward=2
>turn:lanes:forward=through|through;right
>```
>I don't see this tagging: "turn:lanes:forward=through|through|right"

This is because a user named "Mateusz Konieczny" removed that tag on
2021-04-18 06:03:20 (see attached screenshot).

>I think that this segment should have such tagging:
>```
>lanes:backward=1
>lanes:forward=1
>turn:lanes:forward=through;right
>```
>I will go with this problem to Polish osm forum and ask them about this
>intersection.

That is likely also incorrect, because with a single lane forward, and
allowance for through and right turns, you would be mapping a "no left
turn" in an odd way. If through and right are allowed, but left is
not, it would be properly mapped as a "no left turn" not a turn lanes.
Which is likely why user "Mateusz Konieczny" removed the tag entirely.

In any case, yes, discuss with local mappers before making any change.
way-292304503.png

Xavier

unread,
Apr 18, 2021, 10:03:58 AM4/18/21
to OsmAnd
On Sun, Apr 18, 2021 at 04:39:47AM -0700, damian....@gmail.com wrote:
>
>>> On Sat, Apr 10, 2021 at 01:59:40AM -0700, damian....@gmail.com wrote:
>>>
>>> >There is also second problem later on this road.
>>> >
>>> >[image: 2.jpg]
>>> >I think that this lane has problem with tags:
>>> >https://www.openstreetmap.org/way/292304503
>>> >becuase the left turn ends and the lane should be over.
>>>
>>> There is a tag problem with that segment.
>>>
>>> It says this for number of lanes:
>>>
>>> lanes=3
>>> lanes:backward=1
>>> lanes:forward=2
>>>
>>> So the tags say two forward lanes.
>>>
>>> But the turn tagging says:
>>>
>>> turn:lanes:forward=through|through|right
>>>
>>> So the "forward" turn lanes tag states there should be three forward
>>> lanes.
>>>
>>> Note this statement in the "turn:lanes" wiki page:
>>>
>>> If you use the ":lanes" suffix, the number of values specified
>>> separated by vertical lines (|) must match the number of lanes
>>> according to their direction.

>First issue:
>I forgot to add mappilary imagery or my own, but:
>https://www.mapillary.com/app/?lat=50.2427793&lng=19.0246699&z=17&pKey=d46NqdKKK3B9JckAOPAM4g&focus=photo&x=0.4892810659969685&y=0.5921736710813945&zoom=0
>this intersection for me is also strange, because "go through" should be
>"go right", but we have such sings and we can do nothing with them.

That sign is likely why the tags say "through" instead of "right". OSM
attempts to accurately reflect what the local on the ground signage
states, even if what the signage states is odd.

This would be a good example of why conulting with local mappers will
be best.

>Aerial imagery without cars:
>[image: Francuska_Ceglana.png]
>So you suggest to split the Francuska street at the intersection and have 2
>seperate lanes at the end of Francuska.
>Makes sense, but I am not an expert. I will contact the Polish community on
>Osm Forum.

The sign shows three total lanes, one reverse, two forward. So at the
point on the ground where there is room for three lanes, it could
either be:

1) a single OSM way, labeled as three lanes, with turn tagging to match
the signage.

or

2) split into two ways, one with two lanes (one each direction) and a
single way for the "through" part of the sign (for the segment where
there are really three lanes).

But in any case, checking with the local mapping community is best
before doing anything.

damian....@gmail.com

unread,
May 2, 2021, 10:03:21 AM5/2/21
to OsmAnd
I asked local community and as Tom suggested we only divide lanes when there is a physical obstacle.
So it shouldn't be changed.

The intersection from second problem was fixed as mentioned earlier by Mateusz Konieczny and I am waiting for update of maps to check it.

Next time I will post 2 seperate topics, because I am getting lost in current one :)

damian....@gmail.com

unread,
May 7, 2021, 12:57:12 PM5/7/21
to OsmAnd
I checked the updated version of map and currently it doesn't lost in this intersection: https://www.openstreetmap.org/#map=19/50.24502/19.02526

So the topic can be closed
Reply all
Reply to author
Forward
0 new messages