Team OSRM is happy to announce a new data analysis feature for OpenStreetmap data based on OSRMs great routing capabilities. Over the past weeks, we at Team OSRM received a number of complaints that a certain part of the road network was not route-able and were asked for help. We observed that some of these error were not caused by obviously invalid tagging, but by connectivity issues such as unconnected islands of the road network, sources and sinks. Think of the latter two as one-ways where you can drive in but not out, and vice-versa. There are in fact 1,074,201 such way segments today.
For the impatient: head to OSRMs demo site and activate the ‘small components’ layer or use the routing view of Geofabriks great OSM Inspector to see the visualization.
Big thanks go to Geofabrik for hosting the tile layer that we use.
Strongly connected components
One assumption in reality is that the road network is a strongly connected component. It is a technical term, but in essence it means that you should be able to go from one intersection of the road network to every other intersection [*]. Especially, you should not get stuck in a street that you can’t get out of.
We implemented a standard algorithm for this problem, known as Tarjan’s SCC algorithm to automatically detect all ways that have these problems each time we update our routing data.
Right now, there are about a million way segments planet-wide that bear connectivity issues. While this number seems large at first, about 60% of these problems shall be fixable by editing a single segment only.
What kind of problems are visualized?
The following list will show you the problems that will be detected:
Unconnected islands
Here, we have a road that looks like a car could drive on it, but it is unconnected to the rest of the road network. Most probably, it is missing a tag that indicates access rules.
Sources and Sinks
Here, a one-way street just ends. Any car that enters this street would be trapped according to the data. This can be caused by faulty tags or perhaps also by missing data. It may be an indicator that there is a street missing.
Here we have a source of traffic. How should a car ever get to the upper-left corner if traffic always goes in the other direction?
False Positives?
There is a limited number of false positives. Either there is an accidental problem in our parsing or on purpose. Most notably, piers. Most ferry connections go through piers although the ferry carries cars. And in the early days of OSRM we allowed them to connect continental main land and islands in the sea.
And of course, someone might have just already fixed the problem. * * * # Links:
- OSRM Demo Site: http://map.project-osrm.org/
- OSRM Bug Tracker: https://github.com/DennisOSRM/Project-OSRM/issues
- Small Components on OSM Inspector: http://tools.geofabrik.de/osmi/?view=routing
[*] Technical Note: we implemented an iterative version of the seminal algorithm.
討論
由 maning 於 2012年10月 9日 09時32分 發表的評論
Great! Any plans for a worldwide coverage?
由 AMosm 於 2012年10月 9日 10時50分 發表的評論
A (oneway) highway(=service) starting/ending in a node amenity=parking + parking=underground or amenity=parking_entrance IS a source/end and perhaps should not be extra marked as unconnected. Example: osm.org/browse/way/134837754
由 DennisL 於 2012年10月 9日 11時38分 發表的評論
It has world-wide coverage. The renderer seems a bit over-whelmed at the moment.
由 Pink Duck 於 2012年10月 9日 14時10分 發表的評論
There seems to be a large number of highlighted segments that are attached to highway=service closed-ways with area=yes. The routing does not seem able to use highway=track, tracktype=grade1.
由 dcp 於 2012年10月 9日 16時16分 發表的評論
Great work, lads (and Ladies if any are involved). I have a street connected to an area=yes; highway=residential which is connected to a street. All have the same name. Is this an mapping error or a false positive?
由 DennisL 於 2012年10月 9日 17時11分 發表的評論
Thanks!
Areas are not routed through (yet).
由 Zverik 於 2012年10月 9日 17時19分 發表的評論
Dennis, is it possible to create such component maps not only for all highways, but for highways with level >= residential/unclassified, highway >= tertiary etc?
In Russia we have such validator http://peirce.gis-lab.info/qa/RU/routing-map , but it is not scalable :(
由 DennisL 於 2012年10月 9日 18時14分 發表的評論
Well, yes and no. At the moment our capacity is rather limited. But we may implement that feature in the future.
由 Pierre-Alain Dorange 於 2012年10月 9日 20時17分 發表的評論
I try optimize data for routing in my local city (their was small components signaled) but majority its was false positive for me : generally real noexit road (tagged noexit=yes). It the old town at Cognac (France) we got many of those noexit street, because the city is old and some street are strange and because some street has become “pedestrian only” so side street became “noexit”…
Do OSRM small component miss “noexit” tag or do i miss someting ?
由 DennisL 於 2012年10月 9日 20時19分 發表的評論
Do you have an example to look at?
由 amm 於 2012年10月10日 00時54分 發表的評論
What happens to cars that enter into a oneway street that has noexit? Either you are allowed to drive in both directions (in which case the oneway tag would be wrong), there is a valid exit, or you are not allowed to drive into that road at all. (Or the traffic planner in your city is mad and/or has a hatred for cars… ;-))
由 harendra_7 於 2012年10月10日 05時48分 發表的評論
Satellite images are not enough clear in some areas to draw and connect the roads.
由 malenki 於 2012年10月17日 20時53分 發表的評論
I found a bug which isn’t marked with the new feature, yay! ;) See http://osrm.at/1xY
由 DennisL 於 2012年10月23日 12時16分 發表的評論
Malenki, this is not an error that get’s visualized in the layer. if you move the markers along then you see that everything is connected, but there is a detour. The problem is not reachability but the detour.
由 Pierre-Alain Dorange 於 2012年10月23日 17時13分 發表的評論
@DennisL, my example are my town where i live : Cognac, France. I got lot of small island error here : http://tools.geofabrik.de/osmi/?view=routing&lon=-0.32778&lat=45.69423&zoom=17
It was mostly related to street that end on “pedestrian-only” streets. I tag tham “noexit=yes” bit there were reported as “island”, i probably miss something ? I re-inspect and one street was probably bad tagged (i change that just now) but the others seems OK for me.
由 DennisL 於 2012年10月24日 08時08分 發表的評論
@Pierre-Alain Dorange, your examples are pretty obvious. One-way streets either start or end at ways where car traffic is not allowed.
由 mcld 於 2012年10月28日 09時48分 發表的評論
Dennis, this visualisation is SUPER-helpful! It led me to fix many wonky things: streets mis-labeled as footways, oneways going the wrong way, etc.
(Some things are unfixable, such as one-way roads leading into carpark buildings. It might be good to ignore sources/sinks that terminate it building entrances etc?)
I guess the computation is heavy, but are you planning to have the data refreshed? I have been hacking away at various patches, and it will be hard to remember what has been fixed and what hasn’t.
由 DennisL 於 2012年10月28日 11時35分 發表的評論
@mlcd Thanks for your comments. The layer is updated daily (with a few exceptions).