0

I tried Nominatim with GeoPy but it is missing out >80% of locations which are all in India.

I saw some APIs for specific countries such as (1) https://geocoding.geo.census.gov/ and (2) https://capap.gugik.gov.pl/app/geokodowanie/index.html

Some examples of addresses I have:

  1. 1454, Chandni Chowk Rd, near sis ganj Gurdwara, Kucha Mahajani, Chandni Chowk, New Delhi, Delhi 110006

  2. Jwala Heri Market, Paschim Vihar ARSS Mall, New Delhi, Delhi 110063

  3. Indira Gandhi International Airport, Domestic Departure, Terminal 3, New Delhi, Delhi 110037

Which geocoding API can be suggested specifically for India?

0

1 Answer 1

0

I tried several geocoders and could get some results.

adrs = [
    "1454, Chandni Chowk Rd, near sis ganj Gurdwara, Kucha Mahajani, Chandni Chowk, New Delhi, Delhi 110006",
    "Jwala Heri Market, Paschim Vihar ARSS Mall, New Delhi, Delhi 110063",
    "Indira Gandhi International Airport, Domestic Departure, Terminal 3, New Delhi, Delhi 110037"
]

# Geocoder from ArcGIS

from arcgis.gis import GIS
from arcgis.geocoding import geocode

gis = GIS("http://www.arcgis.com", "***", "***")

for adr in adrs:
    geocoded_adr = geocode(adr)
    print(geocoded_adr[0]['location'])

# Nominatim from GeoPy

from geopy.geocoders import Nominatim

geolocator = Nominatim(user_agent='india-api', timeout=10)

for adr in adrs:
    geocoded_adr = geolocator.geocode(adr)
    print(geocoded_adr)

# Bing from GeoPy
from geopy.geocoders import Bing

apikey = '***'
geolocator = Bing(api_key=apikey, timeout=10)

for adr in adrs:
    geocoded_adr = geolocator.geocode(adr)
    print(geocoded_adr.raw['point']['coordinates'])

# Here from GeoPy
from geopy.geocoders import Here

app_id = '***'
app_code = '***'

geolocator = Here(app_id=app_id, app_code=app_code, timeout=10)

for adr in adrs:
    geocoded_adr = geolocator.geocode(adr)
    print(geocoded_adr.raw['Location']['DisplayPosition'])

Geocoder from ArcGIS

{'x': 77.23159002942572, 'y': 28.656359994158322}
{'x': 77.10228000000006, 'y': 28.669680000000028}
{'x': 77.10255571400006, 'y': 28.546820000000025}

Nominatim Geocoder from GeoPy

None
None
None

Bing Geocoder from GeoPy

[28.6562448066934, 77.2321059855371]
[28.670734405517578, 77.09419250488281]
[28.563793182373047, 77.10694122314453]

Here Geocoder from GeoPy

{'Latitude': 28.65636, 'Longitude': 77.23159}
{'Latitude': 28.66856, 'Longitude': 77.10204}
{'Latitude': 28.55457, 'Longitude': 77.09139}

My subjective conclusion is to use either Geocoder from ArcGIS or one from HERE.

Point #1 : 1454, Chandni Chowk Rd, near sis ganj Gurdwara, Kucha Mahajani, Chandni Chowk, New Delhi, Delhi 110006

result1

Point #2 : Jwala Heri Market, Paschim Vihar ARSS Mall, New Delhi, Delhi 110063

result2

Point #3 : Indira Gandhi International Airport, Domestic Departure, Terminal 3, New Delhi, Delhi 110037

result3

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.