经纬度解析转换工具(Geographic location analysis and conversion tool)
Project description
经纬度解析转换库
pip安装
pip install geo_tool
1.百度经纬度解析
from geo_tool import BaiduGeo
baidu_map_key = 'xxxxxxxxxxxx'
print(BaiduGeo(baidu_map_key).geo2address(22.52955, 113.93078))
print(BaiduGeo(baidu_map_key).get_city_name_by_geo(22.52955, 113.93078))
print(BaiduGeo(baidu_map_key).address2geo('北京市海淀区上地十街10号'))
2.高德经纬度解析
from geo_tool import GaodeGeo
gaode_map_key = 'xxxxxxxx'
print(GaodeGeo(gaode_map_key).geo2address(22.52955, 113.93078))
print(GaodeGeo(gaode_map_key).address2geo("广东省深圳市南山区"))
print(GaodeGeo(gaode_map_key).get_city_name_by_geo(22.52955, 113.93078))
3.谷歌经纬度解析
from geo_tool import GoogelGeo
google_key = 'xxxxxx'
print(GoogelGeo(google_key).address2geo('深圳市南山区'))
4.经纬度互相转换
from geo_tool import GeoTransform
baidu_lng = '114.126496'
baidu_lat = '22.538926'
print(GeoTransform(lng=baidu_lng, lat=baidu_lat).baidu2google())
google_lng = 114.12008298963123
google_lat = 22.53258746867191
print(GeoTransform(lng=google_lng, lat=google_lat).google2baidu())
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
geo_tool-1.1.2.tar.gz
(4.9 kB
view details)
Built Distribution
File details
Details for the file geo_tool-1.1.2.tar.gz
.
File metadata
- Download URL: geo_tool-1.1.2.tar.gz
- Upload date:
- Size: 4.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/2.0.0 pkginfo/1.4.2 requests/2.24.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e5564a9969fb208768f994115ba7e62fcf6ef8cab8c97fbe2e3d5b0e76ca4729 |
|
MD5 | 2f95e06982676177b2de6b10c6376f95 |
|
BLAKE2b-256 | b6fa5bd0c6faead5a2ce60c20f66500d32ace353a32291064d2d55f134502201 |
File details
Details for the file geo_tool-1.1.2-py3-none-any.whl
.
File metadata
- Download URL: geo_tool-1.1.2-py3-none-any.whl
- Upload date:
- Size: 7.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/2.0.0 pkginfo/1.4.2 requests/2.24.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8da6447e0b1a84be69402224a14c813daa913a72767e998f362d2b02a4178061 |
|
MD5 | 5ebb3f239bd475d2be34dc0c0ddf1c64 |
|
BLAKE2b-256 | 48e70255f0974485cbc6321663a6baa94a11e1260879783da5256c24e7de0bd5 |