arcpy-栅格转其他格式

import arcpy
in_format=arcpy.GetParameterAsText(0)
out_format=arcpy.GetParameterAsText(1)
out_folder=arcpy.GetParameterAsText(3)
arcpy.env.workspace=arcpy.GetParameterAsText(2)
rasters=arcpy.ListRasters("*",)
arcpy.RasterToOtherFormat_conversion(rasters,out_folder,out_format)

注意栅格名称中不要出现中文字符。

RasterToOtherFormat_conversion帮助页:http://desktop.arcgis.com/zh-cn/arcmap/10.3/tools/conversion-toolbox/raster-to-other-format.htm

 

插个广告,制作ArcGIS的Tool工具学习下面的教程就对了:
零基础学习Python制作ArcGIS自定义工具观看链接
《零基础学习Python制作ArcGIS自定义工具》课程简介
posted @ 2019-09-23 20:45  yzhyingcool  阅读(1032)  评论(0编辑  收藏  举报