[postgis-users] Geocoding cross streets?

Stephen Woodbridge woodbri at swoodbridge.com
Tue Nov 29 08:07:03 PST 2011


On 11/29/2011 12:20 AM, Stephen Frost wrote:
> Steve,
>
> * Stephen Woodbridge (woodbri at swoodbridge.com) wrote:
>> This is probably a fairly clean and only little more complex than
>> hello world, but not majorly so, if you want to try your hand at it.
>
> Pretty sure that I could manage it- but I'm curious..  Do you use an
> external sources or bits of information to do this parsing?  Part of the
> tiger geocoder routines, today anyway, include a 'normalize' function
> which actually uses data in the database to do that normalization
> (looking up locations and whatnot).  Does your code do any of that?
> Perhaps we don't need to do what we're doing in the geocoder today...
> I'm certainly interested in alternative ways of parsing addresses that
> are faster/better/more accurate than what we've got.

I currently have some lists of names that are converted to optimized 
pcre regular expressions. I uses these to help separate the street from 
the city name. The lists are only used to create header files that 
contain the regular expressions that get compiled into the code. The 
idea being that these names are reasonably static for a given data set.

I also wanted to keep this code fairly simple, in that I did not want to 
build a geocoder parser to split the a single line into fields.

Source code is here:
http://pagc.svn.sourceforge.net/viewvc/pagc/branches/parseaddress/parseaddress/

-Steve



More information about the postgis-users mailing list