Each of us has the perfect formula for our commute: If we leave at this precise time, we’ll avoid jams on the busiest city arteries or beat the crowds on public transport. Yet a good hunch can only take you so far — especially if you’re in the transport and logistics industry.
Is it possible to make highly accurate traffic predictions? Yes, with the right technologies in place.
What is traffic prediction?
Traffic prediction is a modeling technique for creating traffic projections using a mix of historical and real-time data points on traffic volumes, travel patterns, and weather conditions.
Modern traffic prediction systems like those employed by Google Maps or TomTom can precisely estimate traffic congestion in a matter of seconds — and signal drivers to choose an alternative route.
But stressed drivers aren’t the only ones to benefit from predictive traffic information. Such insights are even more important for:
- National and local authorities in charge of planning public transportation within controlled areas and planning new infrastructure projects
- Logistics and transportation companies in need of precise estimated times of arrival (ETAs) to run better fleet management operations and delight customers with fast deliveries
- Mobility as a service (MaaS) providers that are plotting new multi-modal transportation routes and seeking integrations with other ecosystem partners
The global intelligent traffic management system market size is set to reach $27.92 billion by 2030, growing at a CAGR of 13.1% annually — that’s a ripe market opportunity to capitalize on!
Why can’t we solve traffic congestion (yet)?
Yet the most-used word for describing traffic remains “chaotic.”
Despite tremendous progress and an unprecedented degree of connectivity, we still struggle to coax clarity out of the chaotic systems of urban parking, intricate public transport route planning, or multimodal freight transportation.
How come? Well, traffic systems are indeed chaotic in a scientific sense.
A classic chaotic system is one that is highly sensitive to initial conditions. Think of your regular commute: route layout, timing, and weather dictate how long it will take. But unplanned events can also wreak havoc on your trip: a stalled car, a driver cruising for parking, a kitty crossing the street. All these events form a daisy chain of traffic flow disruptions — and traffic gets chaotic.
As counterintuitive as it sounds, chaos is actually a good thing for traffic.
This is because chaotic systems are deterministic systems — and therefore predictable to a large extent. If you can capture and analyze the initial conditions and track their evolution in real time, you can predict future traffic with high accuracy.
That said, traffic predictions are no walk in the park (and not even a leisurely drive along the coast).
First of all, we can’t always control the initial conditions. Road rules and infrastructure work to keep drivers in harmony, but then some minor event — be it sudden hail or an accident — creates dissonance.
And even when traffic flows appear normal, traffic jams still emerge. As MIT scientists explain:
A chain of equidistant vehicles that move all with the same velocity will not remain in this nice configuration. Instead, a small perturbation grows and builds up to become a wave of high vehicle density. This phenomenon is called phantom traffic jam, since it arises in free-flowing traffic, without any obvious reason, such as obstacles, bottlenecks, etc.
Phantom jams increase traffic density, slow down throughput at bottleneck areas, and often result in accidents as aggressive drivers fail to adjust to the new road conditions.
To tame traffic, you first need to understand it. Then you need to use this knowledge to model likely future traffic conditions.
How to calculate accurate traffic predictions
Traffic predictions are complex because there are many variables. Some of them are deterministic, such as urban road layout. Others change in real time, such as weather conditions and driving styles.
Therefore, to predict traffic, your solution needs three elements:
- Access to historical and real-time data
- Machine learning and deep learning algorithms
- Commitment to continuous validation and testing
Let’s consider each of them.
Traffic management software development
Infuse predictive capabilities into your software with an expert team
Data sources for traffic predictions
To make any sort of prediction, you need to understand the past and the present. Unless you plan to use a crystal ball, your traffic prediction app needs access to a steady stream of historical traffic data and real-time traffic insights.
The scientific community suggests filling your traffic database with the following data:
- Historical traffic volumes (vehicle count)
- Standard traffic flows
- Accident rates
- Traffic speed
Sources: Road sensors, connected CCTV cameras, open statistical surveys, license plate recognition systems, government-supplied databases, public datasets
- GPS trajectory data
- Floating car data (FCD)
- Location-based services data
- Mapping data
Transactional transport data
- Ticket purchases
- Transport use data
- Origin-destination data
- Electronic toll collection (ETC) data
Sources: Automatic fare collection (AFC) systems, MaaS apps, smart transport cards, electronic toll systems
- Historical and current weather conditions
- Road icing
- Road heating
Do you need all of these data points to make an adequate traffic projection? No. But having more data points increases the precision and relevance of your future traffic predictions.
Take it from TomTom, a leader in mapping and geolocation technology. They have a multi-vector traffic data collection process. To get accurate predictions, TomTom fuses data from smartphone partners, ride-hailing and navigation apps, vehicles, and fleet management systems, plus proprietary hardware and software apps. Their robust data processing engine adds fresh data on traffic patterns to their system every 30 seconds. Then it issues updated traffic flow predictions.
All advanced traffic prediction services are powered by a robust traffic data collection engine and a data governance framework for securely processing the raw intel.
Sample data processing system for traffic prediction
Source: SpringerLink — A Survey of Traffic Prediction: From Spatio-Temporal Data to Intelligent Transportation.
Machine learning and deep learning algorithms for traffic prediction
Once you have configured your IT architecture to collect and process data, you’re set to build a predictive algorithm.
There’s no shortage of fit-for-purpose machine learning (ML) and deep learning (DL) methods for traffic predictions.
Source: arXiv.org — Deep Learning on Traffic Prediction: Methods, Analysis and Future Directions.
Depending on the task at hand and available data, you can choose between:
- Statistical approaches
- Machine learning approaches
- Deep learning approaches
Each of these approaches has its merits. Statistical and machine learning models are easier to implement. Training neural networks for predicting travel times, estimated times of arrival, or traffic flows requires more computing resources and a longer execution time, but neural networks produce more complex and precise predictions and traffic simulations.
Overall, the two most common methods of traffic predictions are convolutional neural networks (CNN) and long short-term memory (LSTM) neural networks.
Both allow for forecasting real-time traffic information and making advanced traffic flow predictions, but they also require large datasets, tedious training, and ongoing validation in production environments.
Model validation and testing
Deep learning — a subset of machine learning focused on creating multi-layer data processing models (neural networks) — allows you to create self-evolving predictive algorithms.
DL models get “educated” by consuming more traffic data. Within that data, they attempt to identify patterns and decipher correlations among variables. Then they churn out a conclusive output. For example, they can determine what else might affect the estimated traffic time apart from given insights such as historical travel times, average throughput of certain roads, or traffic signals.
The above is called “model training.” For DL traffic prediction systems, training can be supervised, semi-supervised, or unsupervised.
- Supervised — The model receives labeled data and attempts to arrive at the programmed output by mapping correlations among that data. For example, a supervised model can analyze historical traffic estimates to calculate the predictive traffic baseline.
- Semi-supervised — The model receives partially labeled data (e.g. road congestion on rainy days) and is tasked with producing a predictive output for road congestion on both rainy and sunny days.
- Unsupervised — The model receives a known input such as current ETAs for one fleet configuration. Then it attempts to calculate predictive ETAs for another type of fleet configuration.
In each case, the model requires validation and continuous testing to ensure it’s moving in the right direction. For state-of-the-art traffic prediction models, the training and validation stage takes much longer than developing the model itself.
For example, DeepMind recently partnered with Google Maps to build a better predictive estimated times of arrival (ETAs) model. Jointly, they’ve developed a Graph Neural Network model that predicts ETAs for different road segments.
When the teams brought this model to production, they found a huge degree of variability in results produced during training versus those delivered in real-world conditions. This forced them to further enhance their training process and adjust the training parameters to improve the model’s performance.
Yet, they are far from calling it a day: Now, the teams want to implement the MetaGradient technique to further optimize model training and reduce the error rate.
The bottom line: Traffic prediction is a continuous process rather than a code it once and forget it type of solution. You need a competent data science and machine learning team to continue improving your model’s performance — and scale it across new use cases. Speaking of which…
Traffic prediction use cases
Because deep learning and machine learning architectures for traffic prediction are plentiful, you can equip your solution with a wide range of predictive capabilities.
To help you shape your product backlog, we’ve made a list of popular traffic prediction features for commercial traffic management systems or routing engines.
Public transport ETA predictions
To reduce traffic congestion, you need more people to use public transport. But according to research published in the Journal of Transport and Land Use, people are more willing to use public transport when it’s faster than going by car.
Therefore, a good bulk of urban transportation planning efforts are concentrated on creating demand-based, flexible public transport schedules with precise ETAs. Likewise, accurate ETA data is integral to optimized route planning and transportation scheduling.
Demand for transportation solutions is consistently high. The challenge is making the calculations.
Take it from TransitApp — a route planner with traffic prediction features offering urban transit planning directions in some 175 cities. Originally, TransitApp relied on city-supplied data or crowd-sourced information to provide real-time transport ETAs. Understandably, the ETA accuracy wasn’t always the best.
So in 2019, TransitApp switched to using machine learning for traffic predictions. They provided algorithms with all historical data available on bus travel times in Montréal. This included GPS-based vehicle locations, travel times, historical disparities between scheduled and actual departure times, and so on. Then they tasked the model to come up with the best ETA formula.
Next, they fine-tuned the model’s performance through extra adjustments during the training stages — plus, they supplied some extra variables. As a result, the team improved ETA predictions for buses by 15%, and they hope to harness extra improvements as the machine learning model improves automatically over time.
Dynamic route planning
Dynamic route planning and optimization is essential for the logistics sector, especially as disruptions pervade global supply chains. The recent traffic jam in the Port of Los Angeles is a prime example of how one bottleneck can cause seismic disruptions, causing consumer prices to rise across the US.
On a smaller scale, last-mile deliveries are regularly affected by intra-city traffic jams as well as congestion along main suburban arteries. Each of these factors results in higher operational expenses for fleet managers and lower customer satisfaction with the transportation provider.
Dynamic route planning, backed by big data analytics, can help logistics operators adjust itineraries in real time using a combination of location-based services, GPS data, and in-vehicle telematics.
Learn more about ETA predictions for commercial fleets
Road traffic simulations and visualization
Accurate traffic simulations are essential for urban planning. Whether you’re mapping new public transportation routes, scheduling construction work, or updating traffic rules, you need to understand the implications of your decisions.
Future traffic predictions can help planners estimate how proposed changes will affect traffic flows and figure out which actions could lead to desired outcomes such as lower accident rates or faster throughput in a specific area.
Using advanced traffic prediction methods, you can explore different research questions such as:
- How do changes in land use affect traffic conditions and quality of life?
- How will new public transport routes affect traffic flows?
- What would happen if a certain area were covered by a private company?
Public transport route planning
By pinpointing the most congested areas, city planners can optimize public transport routes around these constraints. For example, they can re-route buses out of congested areas. Or, on the contrary, they can task public transport with curbing private vehicle use.
Also, ML and DL models can analyze transport demand across nodes, days, and times to create a clear picture of urban travel patterns. Based on this knowledge, operators can optimize fleet and staff use.
AI applied to the data that we are already collecting can pinpoint changes and trends in more detail and in shorter time frames than we were able to with previous methods.
Case in point: Urbi Mobilidade Urbana, a public transportation operator in Brazil, struggled with managing its large bus fleet. In the face of COVID-19, they were pressed to maintain high service levels, plus add extra route coverage. But their operational resources were stretched thin.
Urbi approached Optibus, an end-to-end transport planning and scheduling platform powered by machine learning. Using Optibus’s solution, Urbi switched from managing some 900 routes manually to codifying dynamic rules and schedules in a matter of minutes. Urbi managed to develop better routes in half the usual time while significantly trimming operating costs.
To pack even more value into such public transport solutions, you can integrate them with a MaaS platform and enlist private players to cover some of the service gaps.
Learn more about the power of MaaS ecosystems
Traffic congestion breeds more road accidents. A recent analysis of LATAM traffic congestion patterns suggests that a mere 10% reduction in traffic delays can reduce accidents by 3.4% (equivalent to over 72,000 traffic accidents).
Big data analytics can help you understand why accidents occur in the first place, while traffic prediction models can suggest new ways for mitigating them.
For example, by pairing mobile-generated big data on urban traffic with a fixed-effect Poisson regression model, you can identify correlations between urban congestion and accident volumes. Then you can codify this knowledge into better traffic management rules in your ITSM, plus implement extra controls on the ground.
Finally, a smart road traffic estimator can steer drivers away from congested areas and provide real-time accident alerts.
Learn more about adopting AI in transportation
Producing order out of traffic chaos
Capture, analyze, implement — these are the three principles of building effective traffic prediction systems. First, you need to develop a robust data collection and aggregation process for fusing raw intel from multiple sources. Then you must strategize the optimal ML or DL data modeling approaches based on available data sources and selected use cases. Finally, you need to continuously train your models, adjusting parameters and progressively incorporating new insights to give them extra wits. And just like that, you can supply your customers with exact, real-time traffic predictions, visualized reports, and analytics dashboards.
Contact Intellias to learn more about our traffic management software development consultancy and services!