Hi Hans-Jörg,<div><br></div><div>I am not aware that Barcelona (the city?) has a very open geodata strategy, but that certainly would be nice. If you know of anyone in the area who might know more, I am more than willing to contact them. </div>
<div><br></div><div>I have the addresses, do you mean the coordinates? The address format is not ideal, but I am pretty happy with them, as they seem to geocode well in the tests I have done.</div><div><br></div><div>The Yahoo API allows geocoding of 50k addresses a day, which is plenty for what I need. I am going to try to use that.</div>
<div><br></div><div>Cheers,</div><div>JP<br><br></div><div><br><div class="gmail_quote">On Fri, Feb 4, 2011 at 3:26 PM, Stark Hans-Jörg <span dir="ltr"><<a href="mailto:hansjoerg.stark@fhnw.ch">hansjoerg.stark@fhnw.ch</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div lang="DE-CH" link="blue" vlink="purple"><div><p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">Hi JP</span></p><p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p><p class="MsoNormal">
<span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">Barcelona is unfortunately not well covered yet in OA. But I thought that Spain has a very “open” strategy in terms of providing geodata. If you manage to get Barcelona addresses (perhaps from council or any other “official body”) the OA team will insert these into OA and then you can use the REST service.</span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> </span></p><p class="MsoNormal"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">Good luck!</span></p><p class="MsoNormal"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">-hj</span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> </span></p><p class="MsoNormal" style="margin-left:35.4pt"><b><span lang="DE" style="font-size:10.0pt">Von:</span></b><span lang="DE" style="font-size:10.0pt"> <a href="mailto:discuss-bounces@lists.osgeo.org" target="_blank">discuss-bounces@lists.osgeo.org</a> [mailto:<a href="mailto:discuss-bounces@lists.osgeo.org" target="_blank">discuss-bounces@lists.osgeo.org</a>] <b>Im Auftrag von </b>JP Glutting<br>
<b>Gesendet:</b> Freitag, 4. Februar 2011 15:24<br><b>An:</b> OSGeo Discussions<br><b>Betreff:</b> Re: [OSGeo-Discuss] Batch geocoding</span></p><div><div></div><div class="h5"><p class="MsoNormal" style="margin-left:35.4pt">
 </p><p class="MsoNormal" style="margin-left:35.4pt">Thanks for all the responses! I will track them all down and see how they work. </p><div><p class="MsoNormal" style="margin-left:35.4pt"> </p></div><div><p class="MsoNormal" style="margin-left:35.4pt">
Stark, I have 146,472 addresses in the city of Barcelona. Many of them are duplicates, but at the very least I have 31,514 that need to be coded, although that would leave out many that I want to use. I am in the process of developing filters to clean out apartment numbers, etc., to be able to pull a single coordinate for a whole set of addresses, and there are at least 6,000 that are invalid (from the original 146k, so 140k). It is a lot. I will take a look at openaddresses and do some testing. </p>
</div><div><p class="MsoNormal" style="margin-left:35.4pt"> </p></div><div><p class="MsoNormal" style="margin-left:35.4pt">Thanks!</p></div><div><p class="MsoNormal" style="margin-right:0cm;margin-bottom:12.0pt;margin-left:35.4pt">
JP<br><br></p><div><p class="MsoNormal" style="margin-left:35.4pt">On Fri, Feb 4, 2011 at 3:10 PM, Stark Hans-Jörg <<a href="mailto:hansjoerg.stark@fhnw.ch" target="_blank">hansjoerg.stark@fhnw.ch</a>> wrote:</p><div>
<div><p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">The OpenAddresses project (</span><span style="font-size:11.0pt;color:#1F497D"><a href="http://www.openaddresses.org" target="_blank"><span lang="EN-GB">www.openaddresses.org</span></a></span><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">) is supposed to solve exactly your problem.</span></p>
<p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">You can use the provided geocoding services (</span><a href="http://code.google.com/p/openaddresses/wiki/RESTService" target="_blank"><span lang="EN-GB">http://code.google.com/p/openaddresses/wiki/RESTService</span></a><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">)</span></p>
<p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> </span></p><p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">OpenAddresses has some regions where data was donated – there you will get high-quality results. Unfortunately this is not yet globally available…</span></p>
<p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> </span></p><p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">Hth</span></p>
<p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">-hj</span></p><div><p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> </span></p>
<p class="MsoNormal" style="margin-left:70.8pt"><b><span lang="DE" style="font-size:10.0pt">Von:</span></b><span lang="DE" style="font-size:10.0pt"> <a href="mailto:discuss-bounces@lists.osgeo.org" target="_blank">discuss-bounces@lists.osgeo.org</a> [mailto:<a href="mailto:discuss-bounces@lists.osgeo.org" target="_blank">discuss-bounces@lists.osgeo.org</a>] <b>Im Auftrag von </b>JP Glutting<br>
<b>Gesendet:</b> Freitag, 4. Februar 2011 14:34<br><b>An:</b> <a href="mailto:discuss@lists.osgeo.org" target="_blank">discuss@lists.osgeo.org</a><br><b>Betreff:</b> [OSGeo-Discuss] Batch geocoding</span></p><p class="MsoNormal" style="margin-left:70.8pt">
 </p></div><p class="MsoNormal" style="margin-left:70.8pt">Hello, </p><div><div><div><p class="MsoNormal" style="margin-left:70.8pt"> </p></div><div><p class="MsoNormal" style="margin-left:70.8pt">I have a large set of addresses (around 150k) that I need to geocode for a study (my Masters thesis on heat-related mortality). I am looking into different solutions, but I can't find anything that seems like it would work properly.</p>
</div><div><p class="MsoNormal" style="margin-left:70.8pt"> </p></div><div><p class="MsoNormal" style="margin-left:70.8pt">I could script a solution using Google's map API, but there is a limit of 2,500 addreses per day (I can get around them with a little patience). </p>
</div><div><p class="MsoNormal" style="margin-left:70.8pt"> </p></div><div><p class="MsoNormal" style="margin-left:70.8pt">Right now the best solution I am looking at geopy for geocoding addresses (<a href="http://code.google.com/p/geopy/" target="_blank">http://code.google.com/p/geopy/</a>). It seems like a good system, I think I can use it to pull addresses out of my database and write back coordinates. There is one thing that I am not sure, about, though, is whether I am actually allowed to use the Google API without my use being liked to a specific web page. The terms of service and form for getting a Google API key require a URL linked to a Google account. In fact, it looks like the API can only be used through a web site:</p>
</div><div><p class="MsoNormal" style="margin-left:70.8pt"> </p></div><blockquote style="margin-left:30.0pt;margin-top:5.0pt;margin-right:0cm;margin-bottom:5.0pt"><div><p class="MsoNormal" style="margin-left:70.8pt">"5.2 <u>Account Key</u>. After supplying Google with your account information and the URL of your Maps API Implementation, and accepting the Terms, you will be issued an alphanumeric key assigned to you by Google that is uniquely associated with your Google Account and the URL of your Maps API Implementation. Your Maps API Implementation must import the Google Maps APIs using this key as described in the <a href="http://code.google.com/apis/maps/documentation/" title="Maps APIs Documentation" target="_blank"><span style="color:#0000CC">Maps APIs Documentation</span></a>, and Google will block requests with an invalid key or invalid URL. You may only obtain and use a key in accordance with these Terms and the <a href="http://code.google.com/apis/maps/documentation/" title="Maps APIs Documentation" target="_blank"><span style="color:#0000CC">Maps APIs Documentation</span></a>."</p>
</div></blockquote><p class="MsoNormal" style="margin-left:70.8pt"> </p><div><p class="MsoNormal" style="margin-left:70.8pt">So it looks like I can't even get it to work without a URL. </p></div><div><p class="MsoNormal" style="margin-left:70.8pt">
 </p></div><div><p class="MsoNormal" style="margin-left:70.8pt">I can always write a script that loops through results extracted from the database, creates URLs and parses the XML results one at a time, but that seems like a fairly inelegant solution. </p>
</div><div><p class="MsoNormal" style="margin-left:70.8pt"> </p></div><div><p class="MsoNormal" style="margin-left:70.8pt">Does anyone have any good ideas about how to geocode a few thousand addresses?</p></div><div><p class="MsoNormal" style="margin-left:70.8pt">
 </p></div><div><p class="MsoNormal" style="margin-left:70.8pt">Many thanks,</p></div><div><p class="MsoNormal" style="margin-left:70.8pt">JP</p></div></div></div></div></div><p class="MsoNormal" style="margin-right:0cm;margin-bottom:12.0pt;margin-left:35.4pt">
<br>_______________________________________________<br>Discuss mailing list<br><a href="mailto:Discuss@lists.osgeo.org" target="_blank">Discuss@lists.osgeo.org</a><br><a href="http://lists.osgeo.org/mailman/listinfo/discuss" target="_blank">http://lists.osgeo.org/mailman/listinfo/discuss</a></p>
</div><p class="MsoNormal" style="margin-left:35.4pt"> </p></div></div></div></div></div><br>_______________________________________________<br>
Discuss mailing list<br>
<a href="mailto:Discuss@lists.osgeo.org">Discuss@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/discuss" target="_blank">http://lists.osgeo.org/mailman/listinfo/discuss</a><br>
<br></blockquote></div><br></div>