Ian McIntyre
2 min readNov 28, 2018

Creating Custom Conda Environments in an ArcGIS Pro Workflow

ArcGIS Pro comes with a working conda environment that provides GIS users with an introduction to the virtual environments required for efficiently developing and deploying python scripts. This environment is installed by default to: C:\Program Files\ArcGIS\Pro\bin\Python. This environment shouldn’t be altered, even by trained professionals (but admins can!).

To create a development environment, users should clone this root environment. From this cloned environment, development environments can be created, tested and deployed to production environments.

To caclone this environment first have ArcGIS Pro open, then open the command prompt and navigate to the Scripts folder in C:\Program Files\ArcGIS\Pro\bin\Python. The Scripts directory is where conda commands can be executed from.

cd  C:\Program Files\ArcGIS\Pro\bin\Python\Scripts

From this directory, conda will be used to activate the root environment.

activate root

Finally, this environment will be cloned. By default this environment will be stored in the local users AppData/ESRI directory. With this environment, other environments can be created and new libraries tested. This environemnt will only be available for the user and will be stored in C:\Users\<your username>\AppData\Local\ESRI\conda\envs\

conda create -n my_arcgispro_clone --clone arcgispro-py3

To use this environment, it must be activated. This can be accomplished from any directory as long as

activate my_arcgispro_clone

I prefer to use Jupyter Lab as my IDE, the library will have to be installed to this new cloned environment. The — channel argument, tells conda to use the conda-forge channel to locate these libraries.

conda install --channel conda-forge jupyterlab

The next command installs nb_conda, which allows users to access kernels from other environments from within this instance of Jupyter Lab. The next line installs nb_conda

conda install nb_conda

Now any environment that is created from either the original, or clone of the original and has jupyter lab, or notebook installed will have it’s kernel available from the

Ian McIntyre

@IMmapping to create and communicate meaningful spatial connections