Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] sumo-meso: sequence of lane indices

I strongly advise against editing the .net.xml file directly: https://sumo.dlr.de/docs/FAQ.html#i_made_changes_to_the_netxml-file_but_it_did_not_work_as_expected_why
For editing a network programmatically (still using netconvert), see https://sumo.dlr.de/docs/Tutorials/ScenarioGuide.html#modifying_node_positions_with_the_help_of_sumolib
If you can give more insights about why you'd rather not use netconvert, I may be able to offer additional advice.

- the lane indices need to be numbered continuously starting at 0. When loading a <delete> element will netconvert, the remaining names will automatically be renumbered.
- the lane ids and indices have to match (netconvert will ensure this)

Am Mi., 11. Juni 2025 um 23:02 Uhr schrieb Carolina Osorio via sumo-user <sumo-user@xxxxxxxxxxx>:
Hi folks, 

Main question: When using sumo in meso mode with meso-junction-control, do the lane indices need to be a complete sequence of integers? In other words,  for a segment with n lanes, should  the sequence of lane indices contain all integers in [0, n-1]? 

Context: I am removing a lane and want to update the network xml file accordingly. Sumo has a way to delete edges/lanes without having to change the edge/lane attributes in the network xml file (see here), but I'd like to edit/update the network xml file directly. 
Say a segment has n lanes, and I want to remove lane j (with j<n). If I simply remove the <lane> entry in the xml file of lane j. Then the edge will have lanes with lane indices that will not be a complete sequence of integers in [0,n-1] because index j will be missing. I wonder if that has any implications in meso mode?

Secondary question, is it recommended to update lane id's after a lane index is changed, so that the lane id reflects the new lane index, or can there be inconsistencies between lane ids and indices? Example of an inconsistency: an edge with lanes ids ('lane_0', 'lane_2', 'lane_3') and lane indices (0,1,2), so the indices do not match the suffix of the lane ids. 

Thanks in advance for any insights or ideas, 
Carolina 
 
_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/sumo-user

Back to the top