如何解决pythongdal投影坐标系转换的问题-创新互联
这篇文章主要介绍如何解决pythongdal投影坐标系转换的问题,文中介绍的非常详细,具有一定的参考价值,感兴趣的小伙伴们一定要看完!
作为一家“创意+整合+营销”的成都网站建设机构,我们在业内良好的客户口碑。创新互联公司提供从前期的网站品牌分析策划、网站设计、成都网站设计、成都网站建设、外贸网站建设、创意表现、网页制作、系统开发以及后续网站营销运营等一系列服务,帮助企业打造创新的互联网品牌经营模式与有效的网络营销方法,创造更大的价值。要将xian80地理坐标系转换成投影坐标系:
xian1980 = """GEOGCS["GCS_Xian_1980", DATUM["Xian_1980", SPHEROID["Xian_1980",6378140.0,298.257]], PRIMEM["Greenwich",0.0], UNIT["Degree",0.0174532925199433]]"""prjreference = 'PROJCS["Xian_1980_3_Degree_GK_Zone_37",GEOGCS["GCS_Xian_1980",DATUM["D_Xian_1980",SPHEROID["Xian_1980",6378140.0,298.257]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Gauss_Kruger"],PARAMETER["False_Easting",37500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",111.0],PARAMETER["Scale_Factor",1.0],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]]'
转换后会报错:
latlong = transform.TransformPoint(x,y) File "/usr/lib/python3/dist-packages/osgeo/osr.py", line 711, in TransformPoint return _osr.CoordinateTransformation_TransformPoint(self, *args)NotImplementedError: Wrong number or type of arguments for overloaded function 'CoordinateTransformation_TransformPoint'. Possible C/C++ prototypes are: OSRCoordinateTransformationShadow::TransformPoint(double [3]) OSRCoordinateTransformationShadow::TransformPoint(double [3],double,double,double)**想想之前也没发现过这个问题呀,最后发现之前投影坐标系:**'PROJCS["Xian_1980_3_Degree_GK_Zone_37",GEOGCS["GCS_Xian_1980",DATUM["D_Xian_1980",SPHEROID["Xian_1980",6378140.0,298.257]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",37500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",111.0],PARAMETER["Scale_Factor",1.0],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]]'**不是高斯-克吕格投影而是横轴墨卡托,我想原因可能是gdal库里只能支持高斯-克吕格投影吧。**
以上是“如何解决pythongdal投影坐标系转换的问题”这篇文章的所有内容,感谢各位的阅读!希望分享的内容对大家有帮助,更多相关知识,欢迎关注创新互联行业资讯频道!
分享文章:如何解决pythongdal投影坐标系转换的问题-创新互联
当前链接:http://myzitong.com/article/idhhs.html