如何在Python中将GeoPy设置为一个特定的国家?i、 e.英国

2024-10-04 07:36:58 发布

您现在位置:Python中文网/ 问答频道 /正文

我很难将GEOPY具体设置为一个国家。例如,当我使用GEOPY给我格拉哥的长/纬度坐标时,它返回美国的格拉斯哥!你知道吗

>>> print(location.address)
Potsdamer Platz, Mitte, Berlin, 10117, Deutschland, European Union
>>> print((location.latitude, location.longitude))
(52.5094982, 13.3765983)

Tags: addresslocation国家printunioneuropeangeopyberlin