利用arcgis api for python分析卫星影像
arcgis api for python
jupyter notebook
scikit-mage
Landsat8卫星影像
scipy、matplotlib、scikit-image库的使用
下面的示例使用scikit-image库识别沙特阿拉伯的农场特征。然后,它统计农场的数量并报告。
数据源使用ArcGIS Online上可用的多光谱Landsat8卫星影像。
本次教程用到科学计算scipy、可视化matplotlib、以及图像处理库scikit-image。如果没有相应的库请安装,conda和pip安装皆可。
conda install scipy
conda install matplotlib
conda install scikit-image
开发平台使用的是jupyter notebook
from arcgis.gis import GIS
agol = GIS()
l8 = agol.content.search('Landsat Multispectral', 'Imagery Layer')[0]
l8
l8lyr = l8.layers[0]
定义 Saudi Arabia 农场范围并显示
l8lyr.extent = {
'spatialReference': {
'latestWkid': 3857, 'wkid': 102100},
'type': 'extent',
'xmax': 4296559.143733407