ArcGIS Developers
Dashboard

ArcGIS API for Python

Download the samples Try it live

Interactive raster analytics using Jupyter Dashboards

The Python API, along with the Jupyter Dashboard project enables Python developers to quickly build and prototype interactive web apps. This sample illustrates one such app which can be used to detect the changes in vegetation between the two dates. Increases in vegetation are shown in green, and decreases are shown in magenta.

This sample uses the fast on-the-fly processing power of raster functions available in the raster module of the Python API.

To run this sample you need `jupyter_dashboards` package in your conda environment. You can install it as shown below. For information on this, [refer to the install instructions](http://jupyter-dashboards-layout.readthedocs.io/en/latest/getting-started.html#installing-and-enabling)
conda install jupyter_dashboards -c conda-forge

Using this Dashboard, you can distribute your raster processing algorithms using ArcGIS Image Server and Raster Analytics.

Import IPython Widgets and Display

In [ ]:
!conda install jupyter_dashboards -c conda-forge -y
In [1]:
from ipywidgets import widgets
from IPython.display import clear_output

Connect to ArcGIS Online and Access the Landsat Services

In [2]:
from arcgis.gis import GIS
from arcgis.raster.functions import *

gis = GIS()

landsat_item = gis.content.search("Landsat Multispectral tags:'Landsat on AWS','landsat 8', 'Multispectral', 'Multitemporal', 'imagery', 'temporal', 'MS'", 'Imagery Layer')[0]
landsat = landsat_item.layers[0]

Create a Map and Add Landsat Layers

In [1]:
map1 = gis.map("California, USA")
map1
Out[1]: