如何 create/generate 车辆从静脉而不是 SUMO

How to create/generate vehicles from veins instead of SUMO

目前,我正在从 SUMO 生成车辆并导入到静脉中。但是,现在我想使用大量的车辆(从 100 到 1000)并且我想要它们的随机生成(例如,随机开始时间和随机速度)。

任何人都可以帮助我)我怎样才能 create/generate 车辆而不是 SUMO 的静脉?和 ii) 如何随机 select 车辆的开始时间和速度?

此致, 亚西尔

您可以使用python生成具有随机seed/random开始时间的路由文件。 参考 runner.py 文件 https://github.com/eclipse/sumo/blob/master/tests/complex/tutorial/traci_tls/runner.py and to the tutorial in https://sumo.dlr.de/docs/Tutorials/TraCI4Traffic_Lights.html

这就是 https://github.com/sommer/veins/blob/veins-5.1/src/veins/modules/mobility/traci/TraCIVehicleInserter.ned 的设计目的。只要 OMNeT++ 中的活动车辆数量少于配置数量,它就会使用现有路线定义之一启动新车辆。