Agent-based traffic simulation model (Mesa + UXsim) #101
Replies: 2 comments 1 reply
-
Thanks for sharing, this is an ambitious project!
If you need travel time only (not route), you may use This may be out of the scope, but it would be possible to formulate this as a day-to-day model, in which the "Travel time & price lookup" is came from previous day's experience so that it does not require significant external variables. |
Beta Was this translation helpful? Give feedback.
-
Quick update: Model is running and has reached minimal-viable product status, with a latest interaction bug between Mesa and UXsim resolved (correct bookkeeping of time in both is important): EwoutH/urban-self-driving-effects@2a702c3 The modal is simulating traffic in a ~half a million city during a full day, with up to 50 thousand vehicles simultaneously in UXsim. Each 900 seconds the model recalculates all travel times between all nodes on which allows Agents to take new mode choice decisions. First traffic patterns are following expectations. Lot's of "magic numbers" of course, tomorrow is data collection, aggregation, plotting and validation day. Goal is to determine where to refine more. Then it's taking a step back to the original research goals to see which questions we can exactly answer, what we need to be able to do that, which are unfeasible. |
Beta Was this translation helpful? Give feedback.
-
I'm developing a hybrid Agent-based traffic simulation model, using Mesa en UXsim. It's based on a real-world road network extracted and processed with OSMnx. It's in very early stages, but development can be followed here:
The initialisation of the UXsim world is in traffic.py, and adding demand, retrieving travel times and executing the simulation will happen in model.py (mainly in the
step
function).First two TODOs:
Once it's in further stages I will describe it more extensively, and probably open a PR to add it as an example. But for now a quick share for anyone interested to follow.
CC @toruseo
Early conceptual model
Beta Was this translation helpful? Give feedback.
All reactions