upgrade jupyter notebook to arcgis 1.5

734
9
09-05-2018 07:24 AM
AlistairFox
Occasional Contributor

I've run the following "conda upgrade -c esri --no-pin arcgis"

but in my jupyter notebook its not picking up version 1.5 as the addlayer function is not found in the webmap object

how do i get jupyter notebook to see arcgis 1.5

9 Replies
DanPatterson_Retired
MVP Esteemed Contributor

I cancelled the process because conda wanted to downgrade some packages.  Did you get that notification when you did it?

JoshuaBixby
MVP Esteemed Contributor

What version of ArcGIS Pro are you using?  Since Esri has made the default conda environment read only starting at 2.2, what works for me is to clone the default environment and run the upgrade command without needing the --no-pin.

DanPatterson_Retired
MVP Esteemed Contributor

no pin was fine

Jupyter notebook

And Jupyter lab (still in its infancy though)

AlistairFox
Occasional Contributor

so my jupyter comes up with 1.2.0 version after the upgrade say 1.5 is installed fine from the python command prompt 

so what am i missing

0 Kudos
DanPatterson_Retired
MVP Esteemed Contributor

Well you are installing in a clone I presume?

I don't, I used conda on the original install.

You will note from the figures that I don't install in c:\program….  blah blah

I have full admin rights and I am the sole user on my machine (although that doesn't matter)

I have provided several blogs on this topic, but esri seems to be holding out on users controlling what they can install in the default environment  without having to clone. 

So it is either "let us control the base install" or "let esri control it and you must clone"

0 Kudos
AlistairFox
Occasional Contributor

I’m installing on the original install. I don’t follow the clone option.

Sent from my iPhone

0 Kudos
DanPatterson_Retired
MVP Esteemed Contributor

Install path?

I even just check ArcGIS in spyder to make sure

import arcgis

arcgis.__version__
'1.5.0'

dir(arcgis)
Out[196]: ['GIS', 'GeoAccessor', 'GeoSeriesAccessor', '__all__', '__builtins__', '__cached__',
 '__doc__', '__file__', '__loader__', '__name__', '__package__', '__path__', '__spec__',
 '__version__', '_impl', '_jupyter_nbextension_paths', 'aggregate_points', 'apps',
 'calculate_density', 'connect_origins_to_destinations', 'create_buffers',
 'create_drive_time_areas', 'create_route_layers', 'create_viewshed',
 'create_watersheds', 'derive_new_locations', 'dissolve_boundaries', 'enrich_layer',
 'env', 'extract_data', 'features', 'find_centroids', 'find_existing_locations',
 'find_hot_spots', 'find_nearest', 'find_outliers', 'find_similar_locations',
 'geoanalytics', 'geocode', 'geocoding', 'geometry', 'geoprocessing', 'gis',
 'interpolate_points', 'join_features', 'mapping', 'merge_layers', 'network',

 'overlay_layers', 'plan_routes', 'raster', 'realtime', 'schematics',
 'summarize_nearby', 'summarize_within', 'trace_downstream', 'widgets']

dir(arcgis.apps)
Out[197]: ['__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__',
 '__package__', '__path__', '__spec__', '_url_schemes', 'build_collector_url',
 'build_explorer_url', 'build_navigator_url', 'build_survey123_url', 'storymap',
 'workforce']

dir(arcgis.geometry)
Out[198]: ['BaseGeometry', 'Envelope', 'Geometry', 'GeometryFactory', 'HASARCPY', 'HASSHAPELY',
 'MultiPoint', 'Point', 'Polygon', 'Polyline', 'PropertyMap', 'SpatialReference',
 '__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__', 
'__package__', '__path__', '__spec__', '_types', 'absolute_import', 'add_metaclass',
 'arcgis', 'arcpy', 'areas_and_lengths', 'auto_complete', 'buffer', 'convex_hull',
 'copy', 'cut', 'densify', 'difference', 'distance', 'filters', 'find_transformation',
 'from_geo_coordinate_string', 'functions', 'generalize', 'intersect', 'json',
 'label_points', 'lengths', 'list_types', 'number_type', 'offset', 'project',
 'relation', 'reshape', 'simplify', 'sys', 'to_geo_coordinate_string', 'trace',
'trim_extend', 'union']
0 Kudos
DanPatterson_Retired
MVP Esteemed Contributor

Did you not get it to work then using conda in the original env?

0 Kudos
AlistairFox
Occasional Contributor

i did thanks. just needed to run the notebook from the right python command prompt