利用python解析地址经纬度

转自:https://blog.csdn.net/weixin_30784501/article/details/97540380

解析地址经纬度:

from geopy.geocoders import Nominatim
try:
    geolocator = Nominatim()
    location = geolocator.geocode("北京大学")
    print(location.address)
    print((location.latitude, location.longitude))
    print(location.raw)
except:
    print('not found')

原文地址:https://www.cnblogs.com/zmh-980509/p/12469274.html