Computational Model Library

3D Urban Traffic Simulator (ABM) in Unity (1.0.0)

The Urban Traffic Simulator is an agent-based model developed in the Unity platform. The model allows the user to simulate several autonomous vehicles (AVs) and tune granular parameters such as vehicle downforce, adherence to speed limits, top speed in mph and mass. The model allows researchers to tune these parameters, run the simulator for a given period and export data from the model for analysis (an example is provided in Jupyter Notebook).

The data the model is currently able to output are the following:

  • AgentID: the unique agent identifier.
  • xAxisPos: the x-axis position of the agent.
  • zAxisPos: the y axis position of the agent.
  • collisions: the total number of times a vehicle has collided with another.
  • topSpeed(mph): the top speed the vehicle is set to achieve throughout its drive cycle.
  • currentSpeed(mph): the current speed of the vehicle in mph.
  • distanceOfTravel(meters): the distance the vehicle has travelled over its drive cycle.
  • raycastLength: the length at which the vehicle can identify objects, 1 - very short to 10 high vision distance.
  • tractionControl: traction control initiated; some vehicles will have traction control others will not; this is entirely arbitrary.
  • VelocityMagnitude(BETA): the magnitude of the velocity for the vehicle.
  • VehicleMass: the vehicle weight in kg.
  • Downforce: the force applied to the vehicle to create more grip, 0.1 - small force to 10.0 - more force.
  • date-time: date and timestamps for each data point collected, currently its milliseconds and multiple actions by the raw physics engine can occur throughout the simulation. Therefore, large amounts of data points are collected for each run in short amounts of time.

NOTE! The simulation requires an adequate computer to run; as the number of agents increases, the computational complexity gets severe.

screenShot1.png

Release Notes

Open Code Badge

The Urban Traffic Simulator was developed in Unity 2019.3.03. The core model only requires Unity version 2019.3.03+ and the source code in the Assets folder to deploy. Unity can be downloaded here: https://unity3d.com/get-unity/download.

The following features are available:
- The simulator can run 1 to 500 autonomous vehicles in 3D space that applies physics laws.
- A menu UI is present, which allows the parameters to be tuned; these include the number of vehicles, maximum mass, maximum downforce, traction control.
- The output data is exported to a directory provided by the user post model run. These data include the current speed of vehicles in mph, velocity magnitude, top speed in mph, and distance travelled in meters.
- A Jupyter Notebook is provided, which runs some data analysis on data produced by the model for two example scenarios.
- N number of vehicles can be set NOT to adhere to speed limits. This allows the user to compare scenarios where vehicles may drive faster than other vehicles. The subsequent impact of these vehicles can be observed regarding congestion, energy expenditure, and pollution. Congestion will likely occur in the Urban Street Network if most vehicles do NOT adhere to speed limits as vehicles can collide at intersections, preventing other vehicles from continuing their journey.

Associated Publications

Olmez, S.; Douglas-Mann, L.; Manley, E.; Suchak, K.; Heppenstall, A.; Birks, D.; Whipp, A. Exploring the Impact of Driver Adherence to Speed Limits and the Interdependence of Roadside Collisions in an Urban Environment: An Agent-Based Modelling Approach. Appl. Sci. 2021, 11, 5336. https://doi.org/10.3390/app11125336

Sedar Olmez and Alison Heppenstall. Drive Cycle Data from the 3D Urban Traffic Simulator (ABM) in Unity (version 1.1.0).11 2021.doi:10.6084/m9.figshare.17099858.v1. URL https://figshare.com/articles/dataset/Drive_Cycle_Data_from_the_3D_Urban_Traffic_Simulator_ABM_in_Unity_version_1_1_0_/17099858.

Sedar Olmez, Keiran Suchak (2022) Energy Calculation Extension for the article: An Agent-Based Simulation of Heterogeneous Driver Behaviour and its Impact on Electric Energy Consumption in Urban Space. [Source Code]. https://doi.org/10.24433/CO.1407289.v1

Olmez, Sedar, Whipp, Annabel, Marfleet, Ellie, Thompson, Jason, Suchak, Keiran, Heppenstall, Alison, & Vidanaarachchi, Rajith. (2022, April 2). Towards Modelling Energy Demand of Vehicles in Cities: An Agent-Based Method. 30th Annual Geographical Information Science Research UK (GISRUK), Liverpool, United Kingdom. https://doi.org/10.5281/zenodo.6408394

Olmez, S.; Thompson, J.; Marfleet, E.; Suchak, K.; Heppenstall, A.; Manley, E.; Whipp, A.; Vidanaarachchi, R. An Agent-Based Model of Heterogeneous Driver Behaviour and Its Impact on Energy Consumption and Costs in Urban Space. Energies 2022, 15, 4031. https://doi.org/10.3390/en15114031

This release is out-of-date. The latest version is 1.1.0

3D Urban Traffic Simulator (ABM) in Unity 1.0.0

The Urban Traffic Simulator is an agent-based model developed in the Unity platform. The model allows the user to simulate several autonomous vehicles (AVs) and tune granular parameters such as vehicle downforce, adherence to speed limits, top speed in mph and mass. The model allows researchers to tune these parameters, run the simulator for a given period and export data from the model for analysis (an example is provided in Jupyter Notebook).

The data the model is currently able to output are the following:

  • AgentID: the unique agent identifier.
  • xAxisPos: the x-axis position of the agent.
  • zAxisPos: the y axis position of the agent.
  • collisions: the total number of times a vehicle has collided with another.
  • topSpeed(mph): the top speed the vehicle is set to achieve throughout its drive cycle.
  • currentSpeed(mph): the current speed of the vehicle in mph.
  • distanceOfTravel(meters): the distance the vehicle has travelled over its drive cycle.
  • raycastLength: the length at which the vehicle can identify objects, 1 - very short to 10 high vision distance.
  • tractionControl: traction control initiated; some vehicles will have traction control others will not; this is entirely arbitrary.
  • VelocityMagnitude(BETA): the magnitude of the velocity for the vehicle.
  • VehicleMass: the vehicle weight in kg.
  • Downforce: the force applied to the vehicle to create more grip, 0.1 - small force to 10.0 - more force.
  • date-time: date and timestamps for each data point collected, currently its milliseconds and multiple actions by the raw physics engine can occur throughout the simulation. Therefore, large amounts of data points are collected for each run in short amounts of time.

NOTE! The simulation requires an adequate computer to run; as the number of agents increases, the computational complexity gets severe.

Release Notes

Open Code Badge

The Urban Traffic Simulator was developed in Unity 2019.3.03. The core model only requires Unity version 2019.3.03+ and the source code in the Assets folder to deploy. Unity can be downloaded here: https://unity3d.com/get-unity/download.

The following features are available:
- The simulator can run 1 to 500 autonomous vehicles in 3D space that applies physics laws.
- A menu UI is present, which allows the parameters to be tuned; these include the number of vehicles, maximum mass, maximum downforce, traction control.
- The output data is exported to a directory provided by the user post model run. These data include the current speed of vehicles in mph, velocity magnitude, top speed in mph, and distance travelled in meters.
- A Jupyter Notebook is provided, which runs some data analysis on data produced by the model for two example scenarios.
- N number of vehicles can be set NOT to adhere to speed limits. This allows the user to compare scenarios where vehicles may drive faster than other vehicles. The subsequent impact of these vehicles can be observed regarding congestion, energy expenditure, and pollution. Congestion will likely occur in the Urban Street Network if most vehicles do NOT adhere to speed limits as vehicles can collide at intersections, preventing other vehicles from continuing their journey.

Version Submitter First published Last modified Status
1.1.0 Sedar Olmez Mon Mar 22 15:38:03 2021 Fri Apr 23 10:58:32 2021 Published
1.0.0 Sedar Olmez Fri Jan 22 10:49:44 2021 Mon Mar 22 14:54:37 2021 Published

Discussion

This website uses cookies and Google Analytics to help us track user engagement and improve our site. If you'd like to know more information about what data we collect and why, please see our data privacy policy. If you continue to use this site, you consent to our use of cookies.
Accept