Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] Vehicles are overlapping

1) when you use moveToXY all safety checks are off and there is no way around this. If you just want to use lon/lat to roughly describe the route of the vehicle you can define a trip like this:
<trip fromLonLat="lon1,lat1"  viaLonLat="lon2,lat2 lon3,lat3 ..." toLonLat="lonK,latk"/>
duarouter can transform this into a vehicle route that can be loaded into the simulation.
Alternatively, you could try the script tools/route/tracemapper.py 

2) No. When we need to write routes in our scripts, we write the xml directly using print() or fileObject.write().
For writing a .sumocfg I would use
subprocess.call(['sumo', '--save-configuration', 'test.sumocfg', --option1', 'value1, ...])

regards,
Jakob

Am Di., 31. März 2020 um 17:05 Uhr schrieb Ben Redouane <mohamed.berrazouane@xxxxxxxxxxxxxxxxxx>:
Dear Community,

Thank you for your continuous support! really!

So I am using Traci to implement some vehicles based on their lon/lat
coordinates that describe their paths
the data has some issues and the vehicles sometimes overlap and drive off
the motorway as well!

First question:
I believe there is a command to make vehicle detect each other, as right now
vehicles move according to the command "traci.vehicle.moveToXY(.." but do
not prioritize their surrounding conditions or so ? I remember i read this
before but I could not find it again ^^!

Second question:
is their an command for writing route files or sumo.cfg file like there is
for additionals ?
(eg. "sumolib.files.additional.write("Detectors.add.xml", detectors)" )


Deepest gratitude,





--
Sent from: http://sumo-user-mailing-list.90755.n8.nabble.com/
_______________________________________________
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