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.4k forks source link

Netedit does not handle detectors on internal lanes #5072

Open jprk opened 5 years ago

jprk commented 5 years ago

In my model I have a quite a number of cases where detectors are placed on internal lanes of an intersection. Trying to edit these models in netedit (and, for example, verify the detector placement) including the detectors is not possible, as whenever a detector on an internal lane is encountered, netedit does not know how to handle it, despite the lanes are being shown in connection edit mode:

Warning: The lane ':gneJ1_1_0' to use within the e1Detector 'e1_internal' is not known.

sumo-gui seems to handle the detector correctly.

namdre commented 5 years ago

Placing detectors on internal lanes is a somewhat 'unofficial' feature, hence we did not yet consider how to support it in Netedit. But I guess we should.

jprk commented 5 years ago

I see. Well, if it is not official (I have to admit I did not check the documentation) we have to live with that.

My current impression is that shapes and names of internal lanes are not guaranteed to survive a network edit (what happens if you recompute an intersection due to changing its shape, or its lane connections?), so probably a lot of effort would have to go into implementing this in a transparent way...

namdre commented 5 years ago

The ids of internal lanes are based on a clockwise numbering of all connections at the intersection. Thus, they are quite volatile when modifying connections. You could write a script that uses sumolib to figure out the internal lane id for a connection specified as (fromEdge, fromLane, toEdge, toLane) and generated the appropriate additional file.