Facebook empowers OpenStreetMap community with AI-enhanced tools

If we’re going to map the world, we’re not going to do it with ever-greater volumes of elbow grease. There’s just too much work to do. AI and computer vision are helpful assistants in this task, however, as a Facebook effort has shown, laying down hundreds of thousands of miles of previously unmapped roads in Thailand and other less well-covered countries.

The problem is simply that there’s a whole lot of Earth and only a handful of people actually making maps of it. Sure, Google and Apple have dueling products — but their focus is on businesses in cities and accurate navigation, not including every dirt path and gravel road.

Yet for millions of people, those dirt paths and gravel roads are important thoroughfares, and ought to be clearly marked on maps so that they can be reached by other modern services or, you know, get directions. With thousands and thousands of miles not just unmarked but difficult to make out, the mapping community has its work cut out for it.

“Most modern algorithms, training sets, and techniques were invented to work for the areas with highly developed infrastructure. In the developing world — for example, Africa, Southeast Asia, Latin America — where roads are not well-defined, maintained, or developed, even the best-trained human eye can struggle to identify and properly classify features,” said Dmitry Kuzhanov, a mapping expert in the ridesharing industry, in a Facebook blog post about the AI-powered effort.

Facebook, of course, wants these far-flung folks to engage with its modern services. Over the last year and a half the company has mapped more than 300,000 miles of roads in Thailand, contributing them to the OpenStreetMap project. The Map With AI effort resulted in RapiD, a machine learning-enhanced labeling tool that vastly accelerates the process of laying computer-readable roads on top of satellite imagery.

As you can see in the first part of the video below, creating a road in the OSM system (called iD) ordinarily involves basically drawing the road on top of the satellite imagery using simple lines and curves. The second half of the video shows how in RapiD, the AI has already filled in what it suspects are roads, and the human’s job is more to confirm, negate or slightly adjust them.

Facebook AI researchers and engineers have developed a new method for using deep learning and weakly supervised training to predict road networks from commercially available high-resolution satellite imagery. The resulting model sets a new bar for the state of the art for accuracy, and the data is now publicly available through Map With AI (https://mapwith.ai/). This video shows Map With AI's RapiD editor interface.

Clearly the latter method is considerably faster, even though the machine learning agent that labels the roads is far from perfect. The team estimated that they did maybe five years of elbow-grease work in 18 months.

The system they created for mapping the missing roads of Thailand was robust and outperformed other street-detecting AIs out there, but the researchers found that it lost a lot of accuracy when applied to other countries. Makes sense — the features and cues that reliably define roads in one country or region may be totally absent in another. Ultimately they had to give the agent slightly fuzzier logic than that which the Thailand-centric approach had arrived at.

The deep learning techniques employed to create that improved agent are detailed in a semi-technical way in these twoFacebook blog posts (much more technical information can be found in their paper). The system was trained on a huge number of map tiles from OSM’s already mapped areas, each known to have visible and semi-visible roads on them. It learned the features that define a small road and not, say, a retaining wall or creek bed; you can imagine how from orbit those might look similar.

The fuzzy logic approach panned out and the resulting model works well at a global scale; to show it, the project is releasing AI-powered street grids for Afghanistan, Bangladesh, Indonesia, Mexico, Nigeria, Tanzania and Uganda, with more on the way.

The RapiD tool will be provided for the OSM community to use as well, of course. And it’s hard to put it better than Martijn van Exel, a frequent contributor to the project, who provided the following encomium for Facebook’s post:

The tool strikes a good balance between suggesting machine-generated features and manual mapping. It gives mappers the final say in what ends up in the map, but helps just enough to both be useful and draw attention to undermapped places. This is definitely going to be a key part of the future of OSM. We can never map the world, and keep it mapped, without assistance from machines. The trick is to find the sweet spot. OSM is a people project, and the map is a reflection of mappers’ interests, skills, biases, etc. That core tenet can never be lost, but it can and must travel along with new horizons in mapping.

Of course, unless you want to leave it all to Apple and Google, you could join the ranks of OSM yourself and literally help put some places on the map.