Select to view content in your preferred language

Adding notebook crashing ArcGIS

3417
11
Jump to solution
04-08-2021 05:57 PM
Labels (1)
by Anonymous User
Not applicable

Hey, so I'm running into a problem that I cannot find much info on at the moment.

I am trying to add/open notebooks on ArcGIS Pro, and it keeps crashing ArcGIS Pro, claiming there is an application error.

I am using ArcGIS Pro v2.7.2.  ArcPy environment is 3.6 (although python 3.9 is also installed on my PC for some reason).  Anaconda says "Anaconda3"?  Not sure how to find exact Anaconda version.  

Anybody know what to do?  I am considering uninstalling/re-installing everything, but my time is short.  

0 Kudos
1 Solution

Accepted Solutions
DanPatterson
MVP Esteemed Contributor

K drive... local drive?

in any event, you seem to have a lot of duplicates listed in your package list.

This is the latest for arcgis.  I wouldn't go to 1.8.5 yet since it is in pre-release

Files :: Anaconda.org

I can't compare your environment since I am on Pro 2.8 beta 1, but the duplicates in your package list certainly isn't good.

I just use Jupyter Notebook or JupyterLab unless I happen to be in ArcGIS Pro

jupyter_notebook.png

 


... sort of retired...

View solution in original post

0 Kudos
11 Replies
DanPatterson
MVP Esteemed Contributor

You are going to have to make sure that the arcgis_pro environment is activated.

Your python 3.9 environment may be interfering with the required environment associated with arcgis pro.

It might be easier to uninstall the 3.9 environment until you can things figured out (or install it on another machine)


... sort of retired...
0 Kudos
by Anonymous User
Not applicable

That probably makes sense.  I am new to all this stuff so I am just figuring out how it all works.  

However, this is the issue:  I actually have a py3 environment with deep learning packages installed (I do have another thread on DL stuff, but the notebook issue is now a different topic).  What I am trying to do is use the ArcGIS notebook to customize deep learning tools.  So I need both environments installed at once?  How do I achieve this? 

0 Kudos
DanPatterson
MVP Esteemed Contributor

Not sure why you need python 3.9, I don't see it listed as a supported version for arcgis (unless it changed recently).

If you have separate environments/clones, are you sure you are activating the correct one each time? ( I have to ask)


... sort of retired...
0 Kudos
by Anonymous User
Not applicable

I uninstalled Python 3.9 anyway.  I think Visual Studio Code got excited and downloaded it for me one day.  

Anyway, this is what my environment looks like.  This should be all from the Deep Learning 2.7 installer (https://github.com/Esri/deep-learning-frameworks).  

EDIT:  After looking at it, I'm not even sure if the DL package stuff is even installed.  Weird, because it was still doing Deep Learning stuff...  unless that added that into ArcGIS v2.7.

EDIT: I re-ran the installer but it is all the same.  Still has keras and tensorflow packages so must be the deep learning one.  I'm so confused because apparently the ArcGIS notebook is supposed to be an inhouse feature, not even connected to Jupyter (except in style and format).  

arcPY.png

0 Kudos
DanPatterson
MVP Esteemed Contributor

K drive... local drive?

in any event, you seem to have a lot of duplicates listed in your package list.

This is the latest for arcgis.  I wouldn't go to 1.8.5 yet since it is in pre-release

Files :: Anaconda.org

I can't compare your environment since I am on Pro 2.8 beta 1, but the duplicates in your package list certainly isn't good.

I just use Jupyter Notebook or JupyterLab unless I happen to be in ArcGIS Pro

jupyter_notebook.png

 


... sort of retired...
0 Kudos
by Anonymous User
Not applicable

Yes, k drive is local.  I cloned the environment and it ended up with 284 installed packages, appears to have left out duplicates.  

...and now suddenly notebook works in ArcGIS wow   😐  

Must have been an issue with duplicate packages in the default environment.  Pretty sure that happened when I did some PC upgrades and had to re-install Windows.  Also ended up re-installing ArcGIS on a secondary drive I had it on, and it didn't uninstall properly.  It all makes sense now.  

Now I am curious about how arcpy works when using it in a Jupyter notebook in Chrome (I will be progressing towards this method later on with deep learning, for instance with Google Colabs).  

Attached is an image of my trying to run code for training the model, and it doesn't want to recognize arcgis (with or with the first line "import arcgis").  Do I need to install arcgis packages into anaconda now?  

jupyter.png

0 Kudos
DanPatterson
MVP Esteemed Contributor

if arcgis isn't in the environment you are working in, it needs to be installed there as well.


... sort of retired...
0 Kudos
by Anonymous User
Not applicable

I see.  I have one last question for you.  I am trying to more or less follow this tutorial here (https://www.linkedin.com/pulse/machine-learning-object-detection-arcgis-houtan-emad?articleId=667817...).  So the author uses the "show_results" command to show batch samples and what not.  How do I display this in a notebook?  Is there a different type of cell for this?  I've been trying this in ArcGIS but it just spins out and crashes when I run these show_result steps.  It is critical that I see the data throughout this process, hence why I am crash coursing this like Trinity learning to fly a helicopter from the Matrix.  

0 Kudos
by Anonymous User
Not applicable

I still have the previous issue.  I think what is going on is that it is supposed to display the output in the notebook when I run it, but it isn't.  When I run the line of code, a shell window pops up and quickly disappears.  I suspect that this is the Conda shell that needs to be open when using Jupyter notebooks in browser, but for some reason it automatically closes when it opens in ArcGIS Pro.  I don't know what to do about that.  

EDIT:  To be more clear, lines like "data.show_batch()" do/show nothing.  There is no generated output cell.   I have an RTX 3080, pytorch is using it, shouldn't be any hardware issue.  

0 Kudos