In [1]:
!wget -c http://dds.cr.usgs.gov/srtm/version2_1/SRTM3/Africa/N00E018.hgt.zip
In [2]:
!unzip N00E018.hgt.zip
使用GDAL(http://www.gdal.org) 进行转换。
In [3]:
!gdal_translate -of GTiff -co "TILED=YES" -a_srs "+proj=latlong" N00E018.hgt N00E018_adapted.tif
In [4]:
!gdalwarp -of GTiff -co "TILED=YES" -srcnodata 32767 -t_srs "+proj=merc +ellps=sphere +R=6378137 \
+a=6378137 +units=m" -rcs -order 3 -tr 30 30 -multi N00E018_adapted.tif N00E018_warped.tif
In [5]:
!gdaldem hillshade N00E018_warped.tif N00E018_hillshade.tif
In [7]:
!gdal_contour -a elev N00E018_adapted.tif N00E018_contour25.shp -i 25.0
In [8]:
!ls -l -h
In [ ]: