Actuellement, nous affichons notre site Web dans FR.
Voulez-vous passer à l'anglais?

Non Oui

Getting Rid of Spaghetti Road Networks 

News avril 12, 2022

Have you ever wondered how mapmakers choose which roads to draw and which ones to leave out of a map? Back in the day, cartographers manually decided which roads were important at the to-be-mapped scale. At relatively small scales, like a map of the entirety of the United States (1:50.000.000), the great majority of the road networks cannot be shown by lack of space. So, the selection is very strict: only the most important roads in the area should be shown. This depends greatly on the context, for which the cartographer needs to have a lot of information. Doing this is a very laborious task. Naturally, this led to this process now being replaced by the computer. 

But the question is: how do we make the computer do this selection automatically? 

Before we dive into this, we will first introduce you to our data source. We use OpenStreetMap, an open-source project where many volunteers all over the world spend hours mapping our planet. This is a beautiful initiative: it provides us with a global map that keeps on improving. However, it also has a downside. The quality and consistency of the data is not as high as a dataset manually curated by professional cartographers. 

Each road in OpenStreetMap has a road category. What we have been doing the last couple of years is this: at each zoom level, we define a minimal road category to be shown. This means that the further we zoom in (the larger the scale), the more roads appear. Similarly, the further we zoom out, the fewer roads are visible. 

Getting Rid of Spaghetti Road Networks
Here you can see an example of a map based on-road category. All motorways and highways are shown at this scale.

This gives good results in some areas, and poorer ones in others. As we are passionate to create the best maps possible, we were not satisfied. The images below show some situations that are not optimal. On the top, we see two areas that have so many roads close to each other, they lost their meaning. Then below, we see areas that are so sparse that we either see roads ending amid the countryside, or it looks like we have no roads at all. 

As you can see, there is a discrepancy between what we want to display (the most important roads in the road network) and what we select (the road category in OpenStreetMap). That’s why we developed an alternative selection algorithm. 

Instead of including or excluding roads depending on their category, we start with all road categories and repetitively remove roads until no area is too busy. To decide which roads to remove whenever an area is too busy, we look at the road category. Lower category roads will be removed first. Only when none of those are left in the area, higher-level roads will be removed. On top of this, roads belonging to big road networks like the e-roads in Europe or the interstate roads in the USA will be considered more important. We also remove all dead ends. This led to a road network selection that shows the most important roads in each area, depending on the context: 

Image comparison of the previous road category-based selection (left) with the improved selection algorithm (right). Grab and drag the handle to compare images. In these previously busy areas, only the most important road networks are preserved on the right.

Getting Rid of Spaghetti Road Networks
Side by side comparison of the previous road category-based selection (left) with the improved selection algorithm (right). In these previously sparse areas, important but lower category roads are now shown on the right.

As you can see, the road network is now a lot more uniform in density. In busy areas, such as the surroundings of Madrid, a selection is made so the map looks much more meaningful. In areas that were previously very sparse, such as northern Africa, we now see a connected road network that also spans areas with lower-quality roads. 

You know, by now, we are passionate to create the best maps possible. We consider that this is already a big improvement, specifically in areas that used to be either very busy or very sparse. However, there are also areas where it is questionable whether the old or the new approach is better. For example, some roads that we deem important may have been removed by the selection algorithm. So, we’re not sitting still yet. You can expect us to work hard to keep on improving this procedure and find ways to apply this algorithm to other layers. 

If you want to use this new generalized road network in your maps, and cannot find it yet in our tool, please contact our Support Team