eli5 – How do applications like Google Maps and Apple Maps know when there is a traffic jam? Where does the information come from?



eli5 – How do applications like Google Maps and Apple Maps know when there is a traffic jam? Where does the information come from?

In: Technology

Most people have phones with location sharing enabled. They can tell what traffic is like based on how many phones are on the road and how fast they are moving. This works especially well for highways.

They also have a lot of historical data to work with and a lot of mathematical models that show how traffic usually forms and how long it tends to last based on the roads and the number of people caught in traffic. This gives them the ability to make some general predictions about how much the traffic may slow you down.

Of course it isn’t perfect! Sometimes traffic is caused by an accident and no model can predict that an accident will occur or guess how long it will take to clear the road and get people moving again. There are many factors that can cause the algorithm to guess wrong and take a longer path sometimes. That’s why some people prefer to use their own intuition and sense of direction instead of a map app.

People in cars use their devices for navigation. Their devices transfer data on their location to application servers. The server part of the application analyzes this data and figures out the average current speed of users depending on location. Places with low speed and many users are currently jammed.

As others explained, they use the data from the mobile phones of the general public… Which might sound like conspiracy theory BS, but it has been tested and proven.

Here is the story of a guy with 99 phones and no car: https://www.abc.net.au/news/2020-02-04/man-creates-fake-traffic-jam-on-google-maps-by-carting-99-phones/11929136

In the commercial space, there are many companies that offer fleet tracking services. These typically include a small GPS/cellular transmitter device that sends data about the vehicle on a relatively short interval (@90 seconds). The data sent includes the coordinates, speed, direction, and often additional sensor data such as hard braking, hard acceleration, hard cornering, ignition state, etc.

After using this data in support of the tracking service, it is often anonymized and re-sold to companies that specialize in aggregating traffic data. These companies then use the data to establish the average typical speed of a road segment at various times of day. With this knowledge, they can then look at what the near real-time data is indicating to detect whether traffic is slower than this average and by how much. The direction (or heading) data further identifies which lane of traffic is impacted.

While cell-phone data may certainly be part of the data collected, user privacy preferences, and battery life likely mean it’s a smaller fraction of the overall data being analyzed.

I know this because I was a lead developer for a major tracking platform and was involved with the integration with a traffic monitoring company. In our case, it was a trade as the traffic company returned the posted speed data for a given road segment which we could then use to identify speeding events for our tracked vehicles.

All kinds of sources.

In the UK, and most countries, there are traffic monitoring systems on the roads, information is collated from ordinary people (e.g. mobile phone locations, and even satnav device/apps that tell a central company their current position/speed), and tied in with information on roadworks, closures, police incidents, etc.

This is often then available as TMC information to the general public, pulled into everything from digital signage on motorway stations (to let you know there’s delays on that road and it’s better to wait, etc.) to the online map websites, to the satnav company’s data feeds, to public radio (TMC-RDS) which your car radio can use to “switch” your music briefly to the traffic channel for an announcement if there’s something in your area (many older car radio still have “traffic” or “TA” settings to switch to this channel if there’s an announcement, and it’s broadcast usually on a strong FM radio station that also carries normal radio the rest of the time).

It helps the traffic management system work, a little like an air traffic control really, your satnav detects and is able to route around traffic on your path, and there’s a ton of statistics and metrics for town-planners, utility suppliers, cellular networks, road maintainers, etc. on how best to plan their expansions based on traffic volumes, busy times of day, vehicle types, etc. etc.

Everything is data nowadays, and that data is used to make even more data, and that data used to decide how to use other data.

My CoPilot app on my phone, for instance, lets me send my current speed/position to the company, who – with millions of customers – then has a good map of where traffic is slow or static. Which they then use to tell me that there’s a traffic jam ahead.

That app replaces my old TomTom device which has TMC-RDS and would tune in (via its own aerial) to the digital traffic update accompanying the radio station (Classic FM in the UK, I believe) and receive a constant rolling broadcast of what major roads are busy and should be avoided, and it would route around them.

TL;DR from what other commenters have said:

The Maps apps use people’s location data to know when there are a bunch of people moving slowly on a certain street.