OpenStreetMap

Richard's Diary

Recent diary entries

cycle.travel now has OSM-powered bike routing for Western Europe

Posted by Richard on 17 July 2014 in English. Last updated on 18 July 2014.

I’ve been working on this for a while and am delighted to be able to unveil it!

cycle.travel, my OSM-powered cycling site, now has bike routing for Western Europe: France, the Netherlands, Belgium, Germany, Denmark, Czech Republic, Slovenia, Austria, Italy, Spain, Portugal, the UK and Ireland.

You can try it at cycle.travel/map.

It’s built with (patched) OSRM and a complex custom profile. It takes account of elevation, cycle routes, surface quality and more. All routes are fully draggable; you can export to GPX, TCX, and PDF, and save routes if you create an account. The cartography is specially designed for the site.

Here’s a ride along the Rhine:

Rhine cycleway

Or if you fancy cycling over Mont Ventoux:

Mont Ventoux

Routing details

If it doesn’t follow a route you’d expect it to take, this is usually because surface tags are missing.

For example, here in France, the canalside path is tagged as ‘highway=path’ with no surface tags. cycle.travel guesses that paths in rural areas have poor quality surfaces, so will try not to route along them. Adding a ‘surface=gravel’ tag to this path, which the aerial imagery suggests, will make the router like it. (Access tags are also good.)

Miscellaneous notes

  • The tileserver is a little slow - please be gentle!
  • There are occasional inconsistencies in the tiles - old styles that haven’t refreshed yet.
  • You can’t route between the UK and mainland Europe (there’s a big lake in the way. Only Chris Froome is allowed to cycle through the tunnel and look how far it got him)
  • I’m planning on weekly updates but it’ll be less often at first.
  • Known issue with highway=trunk, bicycle=yes getting undue prominence.
  • Known issue with fahrradstrassen/fietsstraten not being prioritised.
  • You can switch from miles to km if you create an account and set user preferences. It’ll be a bit smarter about defaulting to km for Europe soon, but I need to do a bit of work to enable that. Edit: Now defaults to km for routes in Europe.

Still lots to improve but I hope you like it - and, as ever, thanks to all the mappers who have contributed all the lovely data.

You can post comments/bugs/suggestions here, of course, or on the site forum itself.

What does the path say?

Posted by Richard on 7 November 2013 in English.

Cycleway goes whoosh:

cycleway

Bridleway goes splush:

bridleway

Footway goes plod:

(urban) urban footway

(rural) rural footway

BUT WHAT DOES THE PATH SAY?

Any and all of the above. Tarmackytarmackytarmackytar. Grassy grassy grass grass grass. Cobble cobble cobble cobble. Narrow broad narrow broad. Gra-gra-gra-gra-gra-gra-gravel.

Like the moo of a cow, everyone knows what a highway=cycleway means. Yes, there are variations. Lots of them. But in the absence of any other supporting information (like a surface tag), you can make an assumption that the above pic probably won’t be too far wrong.

But just like no-one has heard a fox, no-one knows what a highway=path means. It could be anything.

So if you are using highway=path because “it makes it easier for data consumers”, it doesn’t. It makes it a pain in the arse for data consumers. Right now I am consuming data for a cycling router and highway=path is the bane of my life. When I see “highway=cycleway” it’s a safe bet I can route a bike down there, whereas when I see “highway=path; bicycle=yes” then maybe a bike might want to go there, or maybe it’s a steep drop over a precipice with a rocky surface but, by some quirk of arcane legislation, bikes are allowed.

For the love of God, if you must use highway=path, please, please, please, please add a surface tag with a commonly-used value.

And then we’ll actually know what the path says.

The other week Development Seed posted some fresh new data for Jalisco, Mexico, together with instructions on how to use JOSM to get it into OpenStreetMap.

Of course, like most good things, it’s much easier and shinier to do it in Potlatch. At which point you might ask “What? You can open .osm files in Potlatch?”. Yes, you can, and here’s how you do it.

First of all, go to https://github.com/mapbox/osm-jalisco/downloads and grab the .osm files. Camino_2011 doesn’t download when I try it, but the other two are fine.

Now open Potlatch in the part of Mexico which you want to edit. Here’s a handy link.

Go to the “Background” menu, and click “Vector file…”:

The background menu

At the bottom, select “OSM”, then “File: Open…” to load your .osm file. Do this for each one:

Adding a new layer

You’ll see them appear as layers in the list. By default they’re shown in ‘Potlatch’ style, which means they look the same as the rest of the map. You can choose any currently-loaded stylesheet to show them in, but I like to use ‘GPS’, which displays them as a clear cyan line:

Setting the style

Close the window and go back to the map. Look! Your .osm file is being displayed!

It’s being shown as a background layer. In other words, it won’t be uploaded next time you save. (Because unthinking imports are bad, right kids?) So to add it to the map, you need to pull it through from the background layer to the main map.

Couldn’t be easier. Just alt-click. (Or, if you’re using a Linux system that reserves alt for its own nefarious purposes, shift-control-click.)

Et voila

And that really is all there is to it.

Even more awesome

This is just scratching the surface, but there’s lots more you can do with vector background layers. Basically, Potlatch does the hard work of making data usable, so you don’t have to faff around with a bunch of preprocessing scripts.

You can open from local disc (like this) or fetch from the Internet. You can open .osm, .gpx, .kml or - yes - even shapefiles. (If loading from local disc, put the .shp, .dbf and .shx files in a .zip).

Wrong projection? No problem: P2 can reproject from OSGB or NAD83 (and we’re happy to add new projections if needs be).

Data too dense? Just enable the ‘Simplify’ button and Potlatch will run a Douglas-Peucker line simplification over it, at the strength you’ve specified in the Options dialogue.

And the cleverest thing of all: MapCSS-based tag transformations. You can supply a stylesheet-like text file that tells Potlatch how to map tags in the source data to OSM standards. Use MapCSS selectors as normal, and the special ‘set’ and ‘delete’ instructions to control the output. It’s best expressed through an example, so here’s one I used for OS VectorMap District data.

switch2osm.org

Posted by Richard on 25 January 2012 in English.

Lots of you will have seen the interest recently in switching from proprietary mapping providers to OpenStreetMap - blog postings by Nestoria and StreetEasy, Wired's article, and so on. We started a Twitter hashtag, #switch2osm, and it's rather taken off.

So I'm delighted to announce the launch of a new site: http://switch2osm.org/ .

It's a one-stop shop for would-be switchers, showing them how to get started with using and generating OSM tiles; _why_ they might want to; and where to look for more information.

Huge thanks to Harry, Kai, and lots of other people who've helped with this (and especially Matt for the layout). We'll be continuing to refine the site in the forthcoming weeks, but we're happy that it's ready to launch now. So - OSM army, get to it and promote it :)

The trouble with imports (translated)

Posted by Richard on 9 November 2010 in English.

Paris mapper Pieren has written an excellent half angry, half regretful diary entry that sums up why unthinking imports are such a curse to OSM. For those that don't speak French, I'm posting a (slightly loose) translation here. Apologies for any errors of translation.

[start quote]

I sadly discovered today that the import of buildings in the 16th arrondissement [district of Paris] has been brutally completed by someone else, by means of the simple import of a file.

I'd been working on this area for several weeks and yes, that might seem too slow for some. But if I was progressing slowly, that’s because I was taking the time to check names and one-way streets on the ground, block by block; to clean up errors (disappeared names and POIs); to add extra information such as traffic lights, missing vélib [cycle hire] points, missing names, barriers, other POIs, addresses. Everything that a semi-automatic import doesn’t do (after all, I could have done the import myself in 15 minutes long ago).

I've already carried out this work for other arrondissements (smaller ones, true) over a long period. You only have to read my OSM diary to see the list. I was three-quarters of the way through working on this arrondissement, but here I'm stopping, disgusted. I shall leave the work of completing the missing information to others, so that the arrondissement may be consistent in a far future (if ever), as well as the other arrondissements of Paris.

I understand that many people work on each area, and it’s better like that. But a tiny bit of co-ordination and investigation, to check what others were doing, would seem to me to be a minimum before embarking on such an import.

[end quote]

I cycled two-thirds of the Way of the Roses, Sustrans' newest challenge cycle route, last week - from Morecambe, on the west coast, over the Dales to York. (The route continues to Bridlington, but I'm leaving the small bit of unmapped route there for our East Yorkshire correspondent to finish.)

A beautifully scenic route, well chosen, and generously signed - which is just as well, as I was cycling 'blind', the official route map not having turned up. There were some pretty strenuous hills; the worst of the lot was one on an off-piste detour I foolishly took out of Settle, having mapped the official route there already. Actually, the flattest bit (railway paths notwithstanding) was the most boring - the section from Ripon to York, which was fairly featureless countryside. The Ouse crossing on the rickety old Aldwarke Bridge was an experience, though!

It's now mapped as National Route 69, 68, 688 and 65.

Location: Halton-with-Aughton, Lancaster, Lancashire, England, United Kingdom

OSM's National Cycle Network coverage is astounding and one of the reasons why everyone loves OpenCycleMap.

With the sun finally emerging once again (yay) we've got the chance to fill some of the gaps and make it really useful. Anna and I went out on Saturday to map a recently opened section of National Route 45 (south of Worcester), and it occurred to me that a few afternoons like that would complete coverage of several high-profile routes.

So I had a look at the map and have identified a few that could be ticked off in an afternoon by nearby mappers. Obviously, some are already in hand - Gregory W cycled most of NCN 1 last year, for example, and I've got a few planned for this year.

South


  • To complete NCN 3: St Austell to Truro is only partly mapped
  • To complete NCN 4: Tiny little section in north Bristol (near Catbrain!) needs doing

Midlands


  • To complete Great Central Cycle Ride: missing section through Daventry

Wales


  • To complete Lon Teifi: NCN 82 from Cardigan to Fishguard

North


  • To complete the C2C: Forest section near Keswick - the one gap in our coverage of the NCN's most popular route!
  • To complete the Pennine Cycleway: NCN 68's alternative route via Burnley and the Leeds & Liverpool canal towpath is only partly mapped.
  • The new Way of the Roses*: a coast-to-coast route being launched this year, roughly Morecambe-Settle-Harrogate-York-Bridlington. East of York it's fully mapped. Morecambe to York is not yet fully signed. But it'd be great to have it mapped on OSM at launch.
  • Hadrian's Cycleway (NCN 72) and the Reivers Route (NCN 10) could be completed with a little effort.
  • A few gaps around Sheffield could also be completed fairly easily.

Any takers? Or any other gaps in big routes that people have spotted?

(I posted this to talk-gb too and there's been some discussion already.)

Location: Severn Stoke, Malvern Hills, Worcestershire, England, United Kingdom

Thought for the day

Posted by Richard on 4 February 2010 in English.

This generally splendid article is doing the rounds: http://www.guardian.co.uk/technology/2010/feb/04/mapping-open-source-victor-keegan

But much though I might like the kind words for Potlatch's drag'n'drop POIs - and much though others might giggle at NickB's new surname - this is the really important bit:

Gordon Brown, the UK prime minister, has just rediscovered cooperativism as a way of galvanising people to vote Labour. He would have been much more in tune with the times if he had widened it to include the open source movement in all its different aspects. It is one of the most interesting phenomena of our times, a kind of global mutual society.

Absolutely spot on and not something that's written about enough.

Burton-on-Trent complete

Posted by Richard on 29 September 2009 in English.

Hoorah for small down-at-heel Midlands towns, for every street in Burton-on-Trent should now be mapped.

Bob Coates has done large chunks east of the Trent (Winshill etc.); Paul Sladen made a whirlwind visit by narrowboat and coloured in the town centre and thereabouts very attractively; and I've done a whole bunch of very exciting housing estates west of the Trent, plus a load of other stuff. There's probably the odd bit missing but nothing particularly significant that I can spot.

Doubtless there's lots of landuse one could add, service drives into industrial premises, POIs (well, "interest" might be stretching it - this is Burton after all) and even postboxes for those who like that sort of thing. I'm not particularly struck on making a huge effort to do that in the absence of aerial imagery, but will probably colour in a few bits now and then - principally residential and industrial areas, I guess - in a kind of slow, incremental way.

Location: Shobnall, East Staffordshire, Staffordshire, England, United Kingdom

Google has a really enlightened guy called the Data Liberation Front. His role is to make it easy for people to get their data out of Google - rather than it being locked in.

Usually, people are locked in by the lack of an export feature, or an obscure file format. In mapping, people are locked in by licences.

In Google Maps' case, you can create your own work by tracing over aerial imagery. But you can't use this work elsewhere, because of the licences and terms of use. (The phrase "derived work" usually crops up around now.)

Google could fix this by saying that tracing from their imagery is ok - just like Yahoo have done. On my blog, I looked into the legalities of this and concluded there's nothing in law stopping them from doing so. It's entirely their decision.

So - please vote for the Data Liberation Front to fix this! Click here, sign in with a Google Account, and tick the box. And tell your friends.

National Cycle Network map for Garmin GPS

Posted by Richard on 5 July 2009 in English. Last updated on 6 July 2009.

I've been playing with mkgmap over the last week, with the aim of creating a Garmin map of the National Cycle Network from OSM data. It's effectively a new version of the one I did the other year, but with better styling (via a .TYP file), contours, and so on.

NCN mapping on OSM is coming on in leaps and bounds this year, not least due to Gregory Williams' Three Corners Cycle Ride. So I figured this was a great opportunity to make it available for GPS, and so tackle the familiar "now which way do I go here...?" problem. The screenshot above would have helped Gregory find his way out of Gloucester. :)

You can now download a prerelease version (UK-only, 240Mb file):

http://richard.dev.openstreetmap.org/garmin/gmapsupp.img

The installation procedure is the same as any such map: connect your Garmin via USB, go into Mass Storage Mode (Setup->Interface), open the Garmin folder (creating one at the top level if there's not one already) and copy gmapsupp.img in.

I'd very much like to hear comments on what could be improved, in particular with the styling, and the choice of what's rendered at each zoom level. I've not as yet paid a lot of attention to POIs and would particularly welcome suggestions and comments on that. (I think I might remove the bus-stops before NAPTAN drowns us all.)

Routing is enabled but does not consistently choose the quiet routes I'd like it to. If anyone knows how to make it suck less, let me know; the eTrex's routing algorithm is famously impenetrable. Caveat emptor. Source will be available when I get round to uploading it to svn.

Regional and Local routes are both rendered in the same blue. I'm anticipating the abolition of Regional Routes in favour of three-digit National Routes. ;) The National Byway is shown in brown (let joy be unconfined).

Many thanks to Andy Gates for his Garmin cycling map, which has been a great inspiration and especially helpful in figuring out what goes where; and also for having the generosity to release the source. Several of the icons and some colouring are taken from his work. Thanks to the Scottish Mountaineering Club for the contour files. Thanks to Andy Allan whose fault all this open cycle mapping is, and yes, you're right, taking a photo of an eTrex screen is a PITA. And thanks, of course, to Steve Radcliffe and the mkgmap community for a superb, ever-improving program - for example, shield support has just been added, which really lifts the appearance of the map - and for being consistently helpful.

Update: The source is now in svn here, and full instructions are on the wiki.

Lousy street names of the week

Posted by Richard on 17 June 2009 in English.

Cycling round yet another Burton housing estate last night, I was amused to find a cul-de-sac called Deferrers Croft. It's clearly meant to be named after De Ferrers, some local hero or other. Unfortunately the lack of a space on the street sign makes it look like a street dedicated to procrastinators.

This was topped, however, by the next cul-de-sac along: Telmah Close. Hamlet backwards. Ugh, just ugh.

Location: Stretton, East Staffordshire, Staffordshire, England, United Kingdom

xybot - just stop it

Posted by Richard on 7 May 2009 in English.

Unfortunately xybot isn't sentient, because otherwise, in the words of General Dreedle, we could take him out and shoot him.

xybot has not announced his presence on talk-gb, yet 'he' has taken it on himself, without consultation, to change "denomination=Church of England" to "denomination=church_of_england" here (and doubtless elsewhere). This similarly. Nor has he announced himself on talk-ie, yet this.

And what, pray, is this all about? User xybot, but created_by=Potlatch 0.11b? The bot knows how to work Potlatch? Blimey.

It is so, so tempting to write a xyrevertbot. If you see an automated user called General Dreedle you'll know I've succumbed.

Lon Las Cymru complete

Posted by Richard on 2 May 2009 in English.

National Cycle Network route 8, aka Lon Las Cymru, is now completely mapped on OSM.

This was the first long-distance NCN ride I ever did, from Cardiff to Holyhead. But at the time I only had a little 1500-point yellow eTrex, which would have run out of puff after about a day... so I didn't get a track. One of my main reasons for rectifying the New Popular Edition properly was so I could use it in Potlatch to trace this route from memory!

Since then, I've cycled a few bits again (notably the Taff Trail), benefited from others' GPS tracks on the same route, and walked/driven a few bits when in the vicinity, too. The other weekend, when in North Wales, I took the chance to walk the one remaining lacuna, the housing-estate route through Llanfairpwyngwyngylletc.

NCN 8 isn't just one route, though: it has "braids", or alternative routes. One is for the section from Machynlleth to Dolgellau, the other from Dolgellau to Porthmadog. When I first cycled it, I'd followed the mostly on-road routes (it was the first outing for my Ridgeback and I wasn't too confident about its off-road capabilities), via Corris and Harlech respectively. But the other week, Anna and I decided to tackle the other braids.

Holy cow they're good - but tough. Machynlleth to Dolgellau follows some lovely winding minor roads for a while, then takes the "Black Road" over the hill to the Mawddach estuary. This is exactly as foreboding as it sounds. It's a long, steep slog up to the top, where the tarmac gives out. From there it's a very exhilarating but rough descent, which was some serious stress on the brake blocks. Fortunately there's an outstanding bike shop in Dolgellau (not the posh-looking one, but the one in an old garage) which reinstated my stopping power and, better still, unbent my back wheel.

From Dolgellau, after another minor road interlude, NCN 8 goes into the mountain bike heartland of Coed-y-Brenin. For a long while it's forest tracks with MTB routes on them, all very pleasant and quite innocuous - there's even a cafe-cum-bike shop. Ok so far.

Then you start to leave the mountain bikers behind, and the track gets steeper, and rougher... and rougher. And eventually becomes what is technically known as "rough as fuck". Until then there'd only been two places on the NCN where I'd had to dismount, due to steepness (Aberllefenni on the other NCN 8 braid, and the hill out of Princes Risborough on NCN 57), but this one was definitely dismount-due-to-complete-lack-of-surface. As you can imagine we were starting to think "is this the right way?".

Turns out this is Sarn Helen, an allegedly Roman road allegedly running the length of Wales (no-one seems quite sure), and clearly no maintenance has been done on it since Roman times. Actually, though, it was great. After a bit of pushing and a picnic at the top (remind me never to buy a Spar sandwich again, they're even rougher than the track was), we got back on the saddle and really started to enjoy it. (That's the diary entry position, if you want to take a look.) The surface really picked up for the descent, happily, and it was a cracking ride down onto a little minor road to Trawsfynydd - which is a surprisingly attractive village, despite the presence of knackered old Soviet-style nuclear power station.

And we were going the right way, too. The signs at both ends confirmed it. So I've mapped what the signs say - and not the other route, which is shown on pretty much every NCN map I've seen (including the Sustrans website), but which definitely isn't where you're signposted. I note that the official Lon Las Cymru map has just, this week, been republished so it'll be interesting to see what that shows.

So it's all on there. But I haven't bothered putting most of these braids in a relation, because it turns out that, in due course, they're going to be renumbered NCN 82 as part of Sustrans' plan to remove duplicate braids on the NCN. (Quite a sensible renumbering, as it'll eventually make NCN 82 a really stunning long-distance route up the west of Wales, from Pembrokeshire to Bangor.)

Location: Trawsfynydd, Gwynedd, Wales, United Kingdom

Hoorah for the mystery cyclist

Posted by Richard on 19 February 2009 in English.

Cyclists love OSM (and OSM loves cyclists).

An anonymous happy cyclist has uploaded their tracks of National Cycle Route 8, Lon Las Cymru - the Welsh national route from Cardiff to Holyhead. I cycled this a few years back, but without GPS (I only had a yellow eTrex at the time, and the memory would have filled up too quickly), so had mapped what I could remember from NPE - in fact, wanting to do this was the initial reason I added NPE to Potlatch. Over time I've been refining it whenever I've revisited an area (Brecon last weekend, Cardiff a month or two ago) but there were still some gaps.

The mystery cyclist's GPS track has meant that it's now almost entirely complete. Only a small bit in Llanfairpwyngwyngyll (etc.) remains to be done, plus two alternative braids which we might cycle this Easter.

Thank you mystery cyclist, whoever you are.

Slimbridge

Posted by Richard on 7 February 2009 in English.

We went to see the ducks, and flamingoes, and ducks, and long-tailed tits, and ducks, at Slimbridge, where there are some ducks, last weekend. It seemed a shame not to have the GPS switched on while walking around, really. So I've made a start at mapping the place.

All the twitchers were very excited about some big white lump of a bird that was sitting on a hillock. It looked a bit pissed off to me. Maybe it was the Venezuelan grumbling bird.

Slimbridge does have a rather splendid observation tower that permits the mapper to photograph the near vicinity. Consequently the bit near the tower is better mapped than the rest...

Anyone feel like rendering leisure=bird_hide?

Location: Slimbridge, Stroud, Gloucestershire, England, United Kingdom

NCN 4 complete

Posted by Richard on 7 January 2009 in English.

Last weekend Anna and I finished cycling (in stages) from London to Fishguard on National Cycle Route 4.

The two bits we'd not covered were Swansea-Carmarthen, and Pontypridd to Newport. Very different from each other: Swansea-Carmarthen was almost entirely flat and traffic-free until the final miles, with 21km of glorious, wide 'Millennium Coastal Park', a peaceful railway path, and some judicious connections including a landmark new bridge.

Pontypridd-Newport was a more typical NCN mix. A railway path was followed by a bit of ducking and diving around housing estates to end up at Caerphilly Castle; a bit more housing estate led to some lovely new winding riverside paths, a railway line on the side of a valley (excellent views), and finally a typical NCN selection of country lanes. Oh, and a really annoying gap in the route at Newport, which we didn't know about until having tried (and failed) for about 1hr30 to find where the route had gone.

So NCN 4 is now pretty much complete on OSM - the first long-distance route to be so. Newport is obviously a lacuna; there's a 100-metre or so gap in Carmarthen, too, where the route seems a little imperfect awaiting a new section for Connect2; and there's a short gap in Pontypridd, too. On bits that others have mapped, a couple of streets are missing near Greenwich, and there's a tiny break in North Bristol. But none of these are more than very short gaps. More useful is that several 'braids' of NCN 4 are fully mapped, offering attractive alternative routes: the most significant is the North Wiltshire Rivers Route, a mostly traffic-free detour with some superb cycling along the Ridgeway.

So you can now use OSM as your free guide to cycling all the way from London to West Wales. Enjoy!

(And I took the opportunity to map the missing section of NCN 8, Lon Las Cymru, into Cardiff. Both this and the Pennine Cycleway, NCN 68, are also approaching OSM completeness.)

Location: Caerphilly, Caerphilly County Borough, Wales, United Kingdom