Opened 12 years ago

Closed 7 years ago

#1622 closed defect (wontfix)

Geocoder gets different result when using limit parameter

Reported by: mikepease Owned by: robe
Priority: medium Milestone: PostGIS 2.4.0
Component: tiger geocoder Version: 1.5.X
Keywords: Cc: woodbri

Description

Here's another way to trick the normalizer/geocoder; sampled from an actual customer address list we have.

The street type and the street direction are listed in a non-standard sequence in this list of several thousand addresses;

501 7TH NW ST, ROCHESTER, MN 55901
instead of
501 7TH ST NW, ROCHESTER, MN 55901

—finds the wrong address
select (addy).*, * from geocode('501 7TH NW ST, ROCHESTER, MN 55901', 1)

—Chooses "Tomah";"Pl";"NW";"";"Rochester";"MN";"55901"
with a rating of 73 instead of the correct address with a rating of 4.

—When you remove the limit parameter geocode(addy,1), it gets the right address with a better rating of 4
select (addy).*, * from geocode('501 7TH NW ST, ROCHESTER, MN 55901')

—This gets the correct answer when the street type and direction are listed in the standard sequence;

select (addy).*, * from geocode('501 7TH ST NW, ROCHESTER, MN 55901', 1)

Change History (9)

comment:1 by robe, 12 years ago

Milestone: PostGIS 2.0.0PostGIS 2.1.0

comment:2 by robe, 12 years ago

Milestone: PostGIS 2.1.0PostGIS 2.0.1

comment:3 by robe, 12 years ago

Milestone: PostGIS 2.0.1PostGIS 2.1.0

comment:4 by woodbri, 12 years ago

Cc: woodbri added

comment:5 by woodbri, 11 years ago

The PAGC tools do the same. '7TH NW ST' standardizes to '7 NORTHWEST', 'STREET'. This could be modified by adding new rule(s) to the parser rules to recognize this pattern, but you have to be careful that a new rule does not hide another rule that you might want to apply in another case. But adding rules does not require code changes.

comment:6 by robe, 11 years ago

Milestone: PostGIS 2.1.0PostGIS Future

comment:7 by robe, 8 years ago

Milestone: PostGIS FuturePostGIS 2.3.1

Add to the list this one:

For instance:

geocoder=# select geocode('146 Southwest 169 Avenue, Miramar Pembroke Pines FL', 1);
                                                     geocode
------------------------------------------------------------------------------------------------------------------
 ("(146,S,393,""Co Hwy"",,,""Walton Beaches"",FL,32459,t)",0101000020AD10000007DBE596AB8E55C002C9CA3B625F3E40,67)
(1 row)

geocoder=# select geocode('146 Southwest 169 Avenue, Miramar Pembroke Pines FL');
                                                     geocode
------------------------------------------------------------------------------------------------------------------
 ("(146,SW,114,Ave,,,""Pembroke Pines"",FL,33025,t)",0101000020AD10000064078265381354C035907724A3013A40,24)
 ("(146,SW,169th,Ave,,,""Pembroke Pines"",FL,33027,t)",0101000020AD10000085951892EB1754C089DABB5364013A40,24)
 ("(,NW,163,Ave,,,""Pembroke Pines"",FL,33028,t)",0101000020AD10000096CB585E501754C0C71DCAB668033A40,25)
 ("(146,NW,154,Ave,,,""Pembroke Pines"",FL,33028,t)",0101000020AD100000053008B7611654C037C975C134023A40,26)
 ("(,SW,169th,Ave,,,""Southwest Ranches"",FL,33331,t)",0101000020AD100000BE44B145ED1754C06C5A2BCBD3083A40,34)
 ("(,SW,130,Ave,,,Miramar,FL,33027,t)",0101000020AD100000A9A4E81B631454C06B5E878997F53940,34)
 ("(146,S,393,""Co Hwy"",,,""Walton Beaches"",FL,32459,t)",0101000020AD10000007DBE596AB8E55C002C9CA3B625F3E40,67)
 ("(146,N,393,""Co Hwy"",,,""Walton Beaches"",FL,32459,t)",0101000020AD100000B5FC0832A08E55C063DA14287D633E40,69)
 ("(146,N,395,""Co Hwy"",,,""Walton Beaches"",FL,32459,t)",0101000020AD10000031489EC6338855C0B89153A5C95B3E40,69)
 ("(146,,98,""US Hwy"",,,""Walton Beaches"",FL,32459,t)",0101000020AD10000012204B4DEE8B55C00EE20CEE095E3E40,69)
(10 rows)


Noted in:

https://lists.osgeo.org/pipermail/postgis-users/2016-October/041636.html

comment:8 by robe, 7 years ago

Milestone: PostGIS 2.3.1PostGIS 2.4.0

comment:9 by dbaston, 7 years ago

Resolution: wontfix
Status: newclosed
Note: See TracTickets for help on using tickets.