Hi folks,

You’ll remember that a couple of weeks ago I posted about the work I’m doing to 
look at getting the relevant bits of Transport for London’s openly licensed 
Cycle Infrastructure Database into OSM.

I’ve now pushed the in-progress code to github:

https://github.com/cyclestreets/tflcid-conversion

It takes the TfL CID files, compares them against OSM (by making queries 
against a freshly loaded Postgres database), and outputs a series of files for 
each datatype, all categorised by the type of editing that will be required to 
get them into OSM. So, for example, there’s a script that takes TfL’s cycle 
parking data and compares it against OSM, then outputs three files: one of TfL 
locations that aren’t in OSM, one of those which are in both, and one of those 
which are in OSM only.

It’s pretty in-depth stuff. The cycle parking alone is a 300+ line script. 
There are five separate scripts for different types of traffic calming, another 
300-line script for cycle lanes, and so on. The matching logic is distinct for 
each type of data - because, for example, speed bumps aren’t at junctions, but 
raised tables often are. There’s a script (.rb) and a readme (.md) for each one 
at:

https://github.com/cyclestreets/tflcid-conversion/tree/master/readers

But if you don’t fancy delving into complex Ruby/PostGIS scripts, then just 
have a look at the readmes there, and then go straight to the output data:

https://github.com/cyclestreets/tflcid-conversion/tree/master/output

It’s all in GeoJSON format (for now) for ease of loading into QGIS or similar 
tools. Plus there’s a raster tileset of the cycle lanes/tracks for easy 
reference in your editor of choice - see https://osm.cycle.travel for details 
and a browsable map.

So, where next?

As you’ll see, I’ve generally split the output between simple, uncontentious 
additions which can go into OSM fairly simply, and those objects that will 
require more work to integrate.

Much of the data can obviously only be integrated into OSM with serious manual 
editing work. This is particularly true of the cycle lanes and tracks, which 
will require adding extra tags to existing roads, splitting at start/end 
points, and so on. TfL have committed to some staff time to get much of this 
done (yay!) and Martin at CycleStreets has been training them up on OSM, but 
obviously work patterns are a bit disrupted at the moment so this won’t 
necessarily happen too soon.

Some of it can go into OSM in a more-or-less automated fashion. This is 
particularly true of the cycle parking, and of most speed bumps. Some 
crossings, chicanes, barriers, and continuous pavements (sidewalks) at 
side-roads could potentially go in. I’ll be doing a bit more work on these to 
get them into a format which could perhaps form an automated edit and would 
welcome views.

And, obviously, if you’d like to get involved in bringing the data into OSM, 
that’s great! I’m very happy to put more work in to get it into a format 
that’ll be useful for people (not really being a JOSMite myself ;) ).

cheers
Richard
_______________________________________________
Talk-GB mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/talk-gb

Reply via email to