Schiphol IWF Routing


In [1]:
from arcgis.gis import GIS
from arcgis.lyr import FeatureCollection
from arcgis.viz import MapView
from IPython.display import display

Login to the GIS Portal


In [2]:
gis = GIS("https://www.arcgis.com", "scriptuser_schipholgroup", "PW4@script")

Map webmap Schiphol Basemap Floor 0


In [20]:
myMap = MapView(id='74b77396fe10429496308ff195a2f992')
myMap


The installed widget Javascript is the wrong version.

Connect to Schiphol Geocoder


In [4]:
geocoders = gis.tools.geocoders
SchipholGeocoder = geocoders[1]
SchipholGeocoder


Out[4]:
<Geocoder url:"http://etest2.esri.nl:8080/arcgis/rest/services/Schiphol/SchipholLocatorWM/GeocodeServer">

Search Schiphol Geocoder for HEMA Store and Map it


In [23]:
pointHEMA = SchipholGeocoder.geocode("HEMA"), {"title": "HEMA", "content": "STORE"}
shape = pointHEMA[0][0]

In [22]:
MapView.draw(shape)


---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-22-144c037b1085> in <module>()
----> 1 MapView.draw(shape)

TypeError: draw() missing 1 required positional argument: 'shape'

Search Schiphol Geocoder for C04 Gate and Map it


In [22]:
pointGateC04 = SchipholGeocoder.geocode("C04"), {"title": "C04", "content": "GATE"}
pointGateC04[0]


Out[22]:
[{'address': 'C04',
  'attributes': {'Addr_type': 'Address', 'Match_addr': 'C04', 'Score': 100},
  'location': {'m': -23728156529555.527,
   'x': 530462.4178989328,
   'y': 6855707.516911416,
   'z': 10},
  'score': 100}]

In [8]:
myMap.draw(pointGateC04[0][0]['location'],{"title": "C04", "content": "GATE"})

Routing from HEMA store to Gate


In [ ]:
routing = gis.tools.featureanalysis.plan_routes()