eclipse-sumo / sumo

Eclipse SUMO is an open source, highly portable, microscopic and continuous traffic simulation package designed to handle large networks. It allows for intermodal simulation including pedestrians and comes with a large set of tools for scenario creation.
https://eclipse.dev/sumo
Eclipse Public License 2.0
2.48k stars 1.41k forks source link

Question: how does netconvert guess backward direction lane if edge present in PT lines? #15262

Open gladysmcgan opened 1 month ago

gladysmcgan commented 1 month ago

I imported an OSM network using netconvert, and I noticed that a backward bus lane was added to a oneway edge even though there were no OSM tags related to buses in the OSM way. I am thinking that it was somehow guessed from the OSM route relation / pt_lines, but I was wondering if you could explain how this is done?

And perhaps how would this guessing be affected if the route edges are not in the correct order?

Screenshot 2024-07-23 at 11 00 17 Screenshot 2024-07-23 at 10 55 34

Many thanks for your help! :)

test example here: added_bus_lane.zip

SUMO-version: v1_20_0+0668-866a7647c24

operating system: macOS

behrisch commented 1 month ago

It is exactly as you assumed. The bug is from the wrong ordering of the input data. OSM requires that the edges of a bus route are specified in the order they are driven: https://wiki.openstreetmap.org/wiki/Buses#Adding_streets_to_the_relation In your example they are not and netconvert tries to ensure that the bus can drive by adding a lane. We could an option to ignore route info even if it is present but I am not sure it would help much and maybe destroy other parts.

BTW: I would still consider it a bug that the bus lane is added to the right of the bike lane. Actually I think "upgrading" the bike lane to a combined bus/bike lane would be the right solution here.

gladysmcgan commented 1 month ago

Thanks for the explanation! Actually there isn't a bug here, I checked that the route ways ordering in this section are correct. So it worked well in this case :)

I agree that upgrading the bike lane to a combined lane is a good idea. Particularly in this case where the bike tags do not specifically indicate an exclusive bike lane.