Vegvarsel.no — a ML approach to avoid mountain road closures

Thomas Hillesøy
5 min readNov 12, 2021

--

The publicly available service https://vegvarsel.no is a prototype machine learning service which predicts the likelihood for a mountain crossing to close due to bad weather.

About the service and how to interpret it

In the northern part of Norway mountain crossings regularly close every winter due to bad weather. These closures are estimated to cost at least 90 million NOK each year, especially inflicting losses on the transport companies. As a driver it is both troublesome and cold to sit and wait multiple hours for the weather to improve.

Currently, both the public and businesses have limited information on whether a mountain crossing will close or not. Weather forecasts and updated traffic messages are the main sources of information. There is a great need for an easily accessible system making everyday life more predictable than today.

Norway’s Government have in their National Transport Plan 2022–2033 listed a more digitalized and data-driven transport sector as a goal, and in the National Strategy for Artificial Intelligence they want “… Norway to take a leading position in exploiting the innovation potential in applying artificial intelligence.”

The publicly available service vegvarsel.no is an answer to an information demand, and also aligns with the Government’s goals for using data and artificial intelligence. The service presents the predicted probabilities for road closure for three crucial mountain crossings, presented in color coded 6-hour intervals for the next 48 hours.

Each predicted probability of closure in color coded 6-hour intervals

Each six hour interval is color coded according to the probability that the crossing will close to easier interpret the risk. E.g. if the model predicts a 80% chance of closure in the next six hours, the corresponding interval will be shown in red.

Predictive model walkthrough — What makes the predictions

Disclaimer: This will be a high level description of the data and model and not be technical. If you are interested in a deeper, technical walkthrough then look out for another article later on.

Data

Predicting closure due to bad weather implies the need for weather data, and the service uses open data provided by The National Public Road Administration and the Norwegian Meteorological Institute.

The weather data is collected and combined into data rows where each column represents an input feature to the machine learning algorithm. It uses the combined feature values and calculates the probability of the road to close.

High level overview of data used to calculate the probability for closure.

The model

The service is using a tree-based machine learning classification model.
Take a breath and each part of that sentence will be explained.

Tree-based
A decision tree starts with a top (or root) node and “branches” downwards, dividing into natural groups each containing subsets of all the data. Then starting at the top you answer yes/no questions to some data’s belonging, and eventually end up at a leaf node with a class prediction.

Simple decision tree to classify animals

The tree can be more or less complex depending on how many branches (the depth of the tree) you have before ending at a leaf node.
Think of it as a structured way of playing “20 questions”.

Machine learning
The study of computer algorithms and building of a model based on historical data, in order to predict something specific. The historic data is used to train the model in optimizing it’s performance towards predicting a specific feature — the target. During training the model finds and remembers correlations predicts the target based on those findings.

The target for this model is closed/not-closed, which is given as a percentage.

This is also all it can do. As all ML models, it can only predict the thing it has been trained to predict. It cannot be used to predict if the stock is going to go up or down tomorrow, or if it will snow. Likewise will it not understand any other inputs other than weather data.

Classification
A way of saying that the model predicts a class (fish/bird/mammal) rather than a number (e.g. a predicted temperature). The model predicts a probability between 0–100% that the road will close, and this is color coded into low, medium and high risk of closure based on set thresholds.

How well does it work?

Evaluating a ML model has to be done by comparing it to the current method in use. And as of today, the only way the public can estimate the likelihood of a mountain crossing to close is by watching the weather forecast, checking traffic messages and doing their own interpretations based on local knowledge and memories of previous events.

The NPRA has acknowledged this problem and awarded a contract in 2020 to SINTEF to develop a similar service named “Den digitale fjellovergang”. At the time of this writing no public service has been made available from that project.

One way to evaluate the model by is looking at it’s hit rate; a measure of how often it predicted correct on the historic training data.

The hit rate shows that the model will predict a closed road correctly 7.5 out of 10 times. A better way to evaluate if it works well is by calculating how much money can be saved using it.

In 2020 Menon Economics wrote a report on the “Socio-economic costs associated with road delays in North Norway” focusing on fish transportation, and it presents a model for calculating hourly costs due to road delays. Combining that with the predictive model’s performance estimates total transportation losses of around 3 million NOK per winter season; a quarter of the loss compared to not using a predictive model.

With these potential economic savings the model shows promising potential, and is certainly a step up from today’s intuition-based method of deciding to drive or not.

Thanks for reading!

Interested in finding a ML problem to solve on your own?
Read the article Machine Learning in the business context — how to find a viable project to get tips and tricks for how to think about and evaluate analytical problems.

--

--