[postgis-users] Tiger Line 2010 - Edges

Paragon Corporation lr at pcorp.us
Tue Oct 18 13:36:40 PDT 2011

The PostGIS tiger geocoder portion still works fine with PostGIS 1.5.  In
fact for production use, we are using it against PostGIS 1.5 for some of our
Given you have loaded your data already, and if all you need is a reverse
geocoder, might be easiest to look at what we have int he reverse geocoder
function and see what you can use of it.
 I think the reverse geocoder function is fairly standalone except the
assumptions about the tables.
The tiger geocoder has loading scripts. We changed some of the field names
to be generic like stripping off those year designators in all the columns
that census found the need to add in so that we could reuse much of the
existing infrastructure from before and not have to rename the fields each
Aside form that the structure is the same as tiger.
As far as the speed of the reverse geocoder.  I haven't stress tsted it that
much and we needed it to run on commodity  windows xp boxes with about 2-4GB
ram and 3.5 GHz processor.  On those we get about 60 ms per call.  It also
varies how close the items you are geocoding are as I recall since data
already loaded in memory seems to be more easily accessible.


From: René Fournier [mailto:m5 at renefournier.com] 
Sent: Tuesday, October 18, 2011 1:53 PM
To: PostGIS Users Discussion; Paragon Corporation
Subject: Re: [postgis-users] Tiger Line 2010 - Edges

Hi Regina, 

Yes, I was looking at that project, and it looks awesome. However, I'm not
yet running PostGIS 2.0. I only really need reverse-geocoding for the US
(I've gotten it working in Canada -- thanks). Until recently, it seemed like
I was close to end -- since I can get the state and then nearest street. I'm
just missing the city/town. All the other features of the PostGIS Tiger
Geocoder aren't really needed by me.

However, it appears now that simply getting the town/city for any given
street is fairly complex due to the broken-up nature of the Tiger Line data

Which makes me wonder if I shouldn't just jump into PostGIS 2.0. A couple

1. Is the current prerelease version of PostGIS 2.0 relatively stable?

2. Since Macports doesn't yet offer PostiGIS 2.0, is there a Mac binary
distribution you can recommend? (http://www.kyngchaos.com/software/postgres
has a nice package of everything, except PostGIS 2.0...) Or should I build
from source? Although I've compiled various packages in the past, I'm trying
to avoid it now in order to simplify and automate the my MAMP-stack build
process -- which is why I'm fond of Macports.

3. I have downloaded all the Tiger Line 2010 data (~40GB compressed) -- is
it relatively easy to get all that data into a fresh PostGIS 2.0?

Now, having said I only *really* need reverse-geocoding for USA, I wouldn't
be unhappy to have forward-geocoding if it wasn't too painful to get
working. One important thing I need though is high performance
reverse-geocoding. On my Core i7 laptop, I can reverse-geocode ~500/second

Can I expect similar performance from the Tiger Geocder in PostGIS 2.0?

So for so many questions. Although I already really love the design of
Postgresql and the power of PostGIS, it's been one long learning curve
getting to this point (which I thought was near the end). Looks like there's
a ways to go.



On 2011-10-18, at 11:26 AM, Paragon Corporation wrote:


Did you see the email Leo had posted


The reverse_gecoder packaged with PostGIS  2.0 Tiger 2010 does output the
city names.

As Dan pointed out -- you need to join with the faces to get that.  Faces
also helps for determining which side of street a point falls in.

-- I've reposted Leo's email for completeness

Please let us know if anything is unclear.


--- LEO's email ---

Actually we implemented a reverse geocoding function too for tiger 2010.
That might be more what you are looking for.


The function usage is described here:


As far as installing the functions.  A lot fo the functions have
dependencies on other functions withing tiger schema.  

If you download the latest PostGIS 2.0 tar ball, that might be the easiest
way to get started. 

There is a create_geocode.sh/bat scripts that install all the functions in
the extras\tiger_geocoder\tiger_2010
 folder and a README which I think is more or less up to date detailing
installation etc.


-- END Email

-----Original Message-----
From: postgis-users-bounces at postgis.refractions.net
[mailto:postgis-users-bounces at postgis.refractions.net] On Behalf Of Dan
Sent: Tuesday, October 18, 2011 12:55 PM
To: PostGIS Users Discussion
Subject: Re: [postgis-users] Tiger Line 2010 - Edges

Hi Rene,

The edges also include TFIDL and TFIDR fields. These are the foreign keys
that identify the topological faces on the left- and right-side of an edge.
If you combine this with the attribute data of the TIGER FACE layers (the
topological faces), you can then determine the "place" 
(city, town, or Census Designated place) FIPS code associated with the
topological face that is bounded by a road edge. To get the name of the
"place", you then need to use the TIGER PLACE layers. However, many road
segments don't have road segments that fall into a "PLACE", so you need to
devise another strategy to deal with them.

All in all, working with TIGER data is not straight forward.


On 10/18/2011 09:24 AM, René Fournier wrote:

Having imported the Edges shape files, I'm able to get quickly find the

closest street to a given latlng point (reverse-geocode). From this row, I
get the street name and house number ranges, and state (FIPS code) -- but
not the city name. Any suggestions on the best way to find the town/city?



postgis-users mailing list

postgis-users at postgis.refractions.net


postgis-users mailing list
postgis-users at postgis.refractions.net

postgis-users mailing list
postgis-users at postgis.refractions.net

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20111018/888541e8/attachment.html>

More information about the postgis-users mailing list