It’s happened to all of us. You’re stuck in horrible city-centre traffic jam. Everyone in the car is cranky. And the traffic light only seems to turn green for a millisecond. Edging forward slowly, you wonder, “Surely it can’t be that hard to manage traffic flow?”
Well, think again. As with many things that we take for granted in our cities, the reality is very different to our perception of it. In fact, back in 1995, a Greek mathematician Christos Papadimitriou showed that finding the optimal pattern of traffic light switching in a large complex network (like a city) is in fact computationally intractable. In terms of what that means in real-life rather than maths-speak, the solution to perfect traffic light switching does exist….in theory…. but it would take so long to solve that’s it’s not practical. Even if we could have a world-class supercomputer on every road junction in London, we would still have traffic jams. That’s not to say that we can’t do anything about jams – far from it – but, it’s not something that we can solve, just by throwing money and computing power at it. What we CAN do is optimise (rather than solve) it. And this is what all existing traffic light control strategies do – they look for a good compromise, that keeps traffic flowing as much of the time as possible.
Back in ye olden days, human traffic controllers (in the form of policemen) stood in the centre of road junctions, directing cars and no doubt, risking their lives every day. While still common in North Korea, for the most part, cities now use automated systems. They are definitely safer and, unlike even the most dedicated police officer, they never get bored.
But how do they work? Across the world, a huge number of systems exist to try to optimise traffic flow around cities, and most of them use relatively simple sensors to detect the presence of cars. I should say that some traffic lights don’t have any sensors – they work purely on a timer, so don’t waste your time on pushing the button – in the UK, the longest you’ll have to wait to cross is 2 minutes.
Anyway, I digress. Many traffic light-controlled junctions in built-up urban areas use systems like inductive loops to monitor traffic. I’ll go into these in lots more detail in the book, but for now, think of them as metal detectors set into the road surface. Because of the relationship between electricity and magnetism, when a vehicle passes over a large coil of wire under the tarmac (an inductive loop), there is a big jump in the signal from the wire coil. When the vehicle moves off, the signal drops again. Constantly monitoring the signal is very easy to do, and while not massively high-tech, the robustness of an inductive loop makes it the tool of choice in most urban centres.
But there are systems that take it beyond just monitoring. In London, a system called SCOOT (Split Cycle Off-set Optimisation Technique) coordinates traffic flow between junctions, and is now found on half of all signals in the capital. SCOOT works by using sensors to keep a tab on vehicles passing through a junction, and then adjusts signal timings, on a second-by second-basis, to manage traffic flow. According to a 2014 press release from TFL, it can reduce traffic disruption at a junction by 8 – 12%.
So, it would seems obvious that systems like SCOOT can outperform anything that a traffic cop could offer, right?
I recently spoke to Simon Box from the University of Southampton ** who is an expert on machine learning – the process by which computers are taught to solve problems by analysing existing data. He recently published a paper on the development of traffic control system that learn from humans, in order to get one step closer to optimising signal switching in large traffic networks. According to Box, his human-trained machine control (HuTMaC) system, “outperforms the other (well-established traffic-responsive) control methods.”
Now, if you read any science coverage in the media, you might be left with the impression that our days are numbered, that computers can outperform humans in most routine tasks – from driving cars to managing bank transactions. But, fear not. For tasks that are computationally intractable, machines can only go so far – really, any ‘solution’ offer is a compromise, an approximation to find as good an answer as possible. And here, humans can have a key role to play.
Simon’s work used a computer-game-like interface to simulate a road traffic network containing light-controlled junctions. The human player can watch individual vehicles driving through the simulated network, and can choose how fast or slow to run the simulation. By capturing the human player’s strategies throughout a series of games, the computer can actually learn from their responses, with that data then fed back into the traffic optimisation program. The performance of the HuTMaC system was found to compare very favourably to commercial systems like SCOOT.
HuTMaC is also pretty quick to set up – just 45 minutes of ‘training’ was needed for each road network – and seemed to be most useful in scenarios with the heaviest traffic, an environment familiar to anyone who drives in cities. Of course, HuTMaC can’t necessarily answer all of the questions of traffic control – it doesn’t make it any less intractable after all – but it may help computerised systems to find approximate solutions more efficiently. There are also limitations to the model – HuTMaC has been demonstrated only on a small network containing three junctions, whereas SCOOT is on its way to reaching 1500 junctions in London.
But, even with those limitations, it seems as if there is real potential in developing traffic lights that truly learn… with a little help from humans 🙂
** I met Simon a few years ago at the Royal Society Summer Science Exhibition, when our stands were right beside each other. Mine was all about energy harvesting (blog post here) and Simon’s was on traffic control, so when I had questions about traffic lights, I knew exactly who to go to!