<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<br>
<div class="moz-cite-prefix">On 22/07/12 03:49, Kai Krueger wrote:<br>
</div>
<blockquote cite="mid:500B783A.20508@gmail.com" type="cite">
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<div class="moz-cite-prefix">On 07/21/2012 04:56 PM, Svavar
Kjarrval wrote:<br>
</div>
<blockquote class=" cite" id="mid_500B33A0_1000005_kjarrval_is"
cite="mid:500B33A0.1000005@kjarrval.is" type="cite">
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
<br>
<div class="moz-cite-prefix">On 21/07/12 21:21, Kai Krueger
wrote:<br>
</div>
<blockquote class=" cite" id="mid_500B1D58_4060907_gmail_com"
cite="mid:500B1D58.4060907@gmail.com" type="cite">
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<div class="moz-cite-prefix">On 07/21/2012 01:05 PM, Simone
Cortesi wrote:<br>
</div>
<blockquote class=" cite"
id="mid_CABgMo2zL_Dd87i3Z2mP5cKyDwSk2ABoFZF_O3TQ7dFFhBa89ZQ_mail_gmail_com"
cite="mid:CABgMo2zL+Dd87i3Z2mP5cKyDwSk2ABoFZF_O3TQ7dFFhBa89ZQ@mail.gmail.com"
type="cite">
<pre wrap="">Yes please,
I would like to do the same too...
-S
On Sat, Jul 21, 2012 at 8:56 PM, Svavar Kjarrval <a moz-do-not-send="true" class="moz-txt-link-rfc2396E" href="mailto:svavar@kjarrval.is"><svavar@kjarrval.is></a> wrote:
</pre>
<blockquote class=" cite" id="Cite_0" type="cite">
<pre wrap="">I want to make a similar routing table file for my country. Any chance
of giving us instructions on how to generate such routing grids of our own?
- Svavar Kjarrval</pre>
</blockquote>
</blockquote>
<br>
I have now pushed the code I used to generate those tables to
github. (
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<a moz-do-not-send="true"
href="https://github.com/apmon/RoutingGrid">https://github.com/apmon/RoutingGrid</a>
)<br>
<br>
It is a little java program that takes in a list of
coordinates and city names and generates the html file for the
routing grid.<br>
<br>
You can easily run it on your own list of coordinates /
cities.<br>
<br>
Dennis, who is responsible for the OSRM server, was OK with me
running the code against his server, and I suspect he wouldn't
mind if others do the same.<br>
<br>
It uses Google's directions API as a reference, so it is
subject to their terms. Currently they seem to allow 2500
requests per day, which would correspond to a maximum sized
grid of 50 cities. It can cache the results from Google in a
reference list, so you only need to query google once per city
list.<br>
<br>
Kai<br>
</blockquote>
<br>
Thanks a lot! I had an idea of a larger list of co-ordinates and
could use this code to make a databased version. I'd probably
have to host my own OSRM instance so I wouldn't bombard the main
one with so many queries in a short time interval.<br>
</blockquote>
OSRM really is amazingly fast (assuming you have a server with
sufficient ram to convert the data into a routing db in the first
place), so I don't see too much issue in principle in
significantly expanding the routing grid. Calculating a route from
New York to Los Angeles takes 500ms and that includes network
round trip time across the Atlantic (ping time to the server from
here is 150 ms). Depending on how far you want to expand it, you
might even still be able to use the current instance, although you
would have to ask Dennis about that.<br>
<br>
</blockquote>
<br>
I was thinking about expanding the grid to every town in Iceland,
which are at least 75. With Google's limit of 2500 queries a day,
I'd have to make a program which makes regular queries and is
careful about not going over that limit. And this is only the towns.
This does not take into account addresses within them. Surely, I
won't do this for every town as most of them are only a few streets
but nontheless, it would generate a big queue of queries against
Google. I don't know how the OSRM will react to such a large number
of queries on a regular basis as I need to refresh the OSRM
distances.<br>
<br>
<blockquote cite="mid:500B783A.20508@gmail.com" type="cite"> <br>
If there is interest, I will try and expand the routing grid my
self over the next couple of days, either to new countries or to
more cities in a country.<br>
<br>
With the current code, the bigger short term issue is that it uses
Google as a reference source and its limited allowance. However,
once the routing problems are fixed again in OSM, there is no
reason to not use a known good snapshot of OSM data as a reference
in future and use it in quality assurance to check for any new
broken routes. You could also use a snapshot from before the bot
ran if you have access to it.<br>
</blockquote>
<blockquote cite="mid:500B783A.20508@gmail.com" type="cite">
Overall, this is really only a very small "script" that I hacked
together in a couple of hours yesterday of which most of the time
was spend in getting the coordinates for the cities list. So if
you are planning to make too many changes, you might be better of
writing it from scratch. <br>
</blockquote>
<br>
It does give me ideas and I'll probably convert it anyway to another
programming language. The command flow will give me neat ideas.<br>
<br>
<blockquote cite="mid:500B783A.20508@gmail.com" type="cite">
<blockquote class=" cite" id="mid_500B33A0_1000005_kjarrval_is"
cite="mid:500B33A0.1000005@kjarrval.is" type="cite"> <br>
It would be a kind of a quality assurance checker where I'd not
only check links between cities/towns, but also links between
some of the addresses inside them. Maybe add important POIs in
the country as well. I really want the map to be of superior
quality.<br>
</blockquote>
<br>
You would likely need to go about it a bit different than to
display routes in a grid (so the current code probably isn't a
great basis), but the idea of automated quality control by
generating a large set of routes between cities/towns/POIs has
been floating around for quite a while. It is one of the reasons
why there is still a debate about getting OSMF to operate a
routing server itself to support these kind of QA checks.<br>
<br>
Personally, however, I suspect that an automated system will only
every be able to check a fraction of the most prominent (and
important) routes / roads and it will be more important to expose
as many mappers as possible to the routing interface for them to
try their own local routes for which they know the optimal
solution.<br>
<br>
Kai<br>
<br>
<blockquote class=" cite" id="mid_500B33A0_1000005_kjarrval_is"
cite="mid:500B33A0.1000005@kjarrval.is" type="cite"> <br>
- Svavar Kjarrval<br>
<br>
<blockquote class=" cite" id="mid_500B1D58_4060907_gmail_com"
cite="mid:500B1D58.4060907@gmail.com" type="cite"> <br>
<blockquote class=" cite"
id="mid_CABgMo2zL_Dd87i3Z2mP5cKyDwSk2ABoFZF_O3TQ7dFFhBa89ZQ_mail_gmail_com"
cite="mid:CABgMo2zL+Dd87i3Z2mP5cKyDwSk2ABoFZF_O3TQ7dFFhBa89ZQ@mail.gmail.com"
type="cite">
<blockquote class=" cite" id="Cite_0" type="cite">
<pre wrap="">On 21/07/12 18:32, Kai Krueger wrote:
</pre>
<blockquote class=" cite" id="Cite_1" type="cite">
<pre wrap="">Hello everyone,
Inspired by the US 250 cities routing grid[1] used in the original TIGER
cleanup in 2009, I have now created a similar routing grid for the USA
and Australia.
Australia: <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://apmon.dev.openstreetmap.org/aus_routing_grid.html">http://apmon.dev.openstreetmap.org/aus_routing_grid.html</a>
USA: <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://apmon.dev.openstreetmap.org/us_routing_grid.html">http://apmon.dev.openstreetmap.org/us_routing_grid.html</a>
It takes the top cities of the country and calculates the routing
distances between them and displays the result in a routing grid. It
allows to check the top tear inter city road network. Unusually long
routes are likely caused by broken data and indicates where things need
fixing.
In the grid, all routes that are more than 5% longer or slower than
expected* are show in red, otherwise they are considered as
superficially OK. The reference values are in brackets. If you click on
the link, you will be sent to the detailed routing information.
Unfortunately the situation, particularly in Australia, is pretty bad.
In Australlia currently non of the routes between the top ten cities
pass this criterion and in fact most of the routes can't be calculated
at all any more due to disconnectedness of the road network.
So for all those who are finished remapping their own area and are
looking to help with a bit of armchair mapping, trying to get more of
these routes green could be a good idea for arm chair mappers. Let's see
how quickly we can get all of them green!
The routing information is calculated using the Open Source Routing
Machine ( <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://map.project-osrm.org/">http://map.project-osrm.org/</a> ) and if I am not mistaken,
updates its data once a day. I will equally try and recreate those grids
on a daily basis to help track progress on the remapping.
Happy remapping,
Kai
* The time and distance that is expected is currently determined using
google's directions API. Although not perfect by any means, it is
probably the most reliable source for now as a reference.
[1] <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://wiki.openstreetmap.org/wiki/TIGER_fixup/250_cities/routing_grid">http://wiki.openstreetmap.org/wiki/TIGER_fixup/250_cities/routing_grid</a>
_______________________________________________
talk mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:talk@openstreetmap.org">talk@openstreetmap.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.openstreetmap.org/listinfo/talk">http://lists.openstreetmap.org/listinfo/talk</a>
</pre>
</blockquote>
<pre wrap="">_______________________________________________
talk mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:talk@openstreetmap.org">talk@openstreetmap.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.openstreetmap.org/listinfo/talk">http://lists.openstreetmap.org/listinfo/talk</a>
</pre>
</blockquote>
</blockquote>
<br>
<br>
</blockquote>
<br>
<br>
</blockquote>
<br>
<br>
</blockquote>
<br>
<br>
</body>
</html>