警告如下图
原始代码:
推荐写法:
from pyproj import Transformer
# 参数1:坐标系WKID 天津市 WGS_1984_UTM_Zone_50N 对应 32650
# 参数2:WGS84地理坐标系统 对应 4326
transformer = Transformer.from_crs("epsg:32650", "epsg:4326")
x = 507151.9694267218
y = 4341011.913450285
lat, lon = transformer.transform(x, y)
print("x:", x, "y:", y)
print("lat:", lat, "lon:", lon)