Second, I'll dive into some of the background of exactly what the Jupyter notebook abstraction is doing, how it interacts with the complexities of the operating system, and how you can think about where the "leaks" are, and thus better understand what's happening when things stop working.
In the wake of several discussions on this topic with colleagues, some online ( exhibit A, exhibit B) and some off, I decided to treat this issue in depth here.įirst, I'll provide a quick, bare-bones answer to the general question, how can I install a Python package so it works with my jupyter notebook, using pip and/or conda?. In other words, the Jupyter notebook, like all abstractions, is leaky. In the simplest contexts this issue does not arise, but when it does, debugging the problem requires knowledge of the intricacies of the operating system, the intricacies of Python package installation, and the intricacies of Jupyter itself. etc.).įundamentally the problem is usually rooted in the fact that the Jupyter kernels are disconnected from Jupyter's shell in other words, the installer points to a different Python version than is being used in the notebook.
this, that, here, there, another, this one, that one, and this.
This issue is a perrennial source of StackOverflow questions (e.g.
I installed package X and now I can't import it in the notebook. I most often see this manifest itself with the following issue: Open a command prompt, and enter the following command.In software, it's said that all abstractions are leaky, and this is true for the Jupyter notebook as it is for any other software. Uncheck the option to "Learn more about Anaconda Cloud" (unless you really want to), and click Finish. It will take a little while (just a minute or 2) going through the actual installation, but you should finally get a success message. Select "Just Me" when it asks who to install for, and click Next.Īccept the default value for Install Location and click Next.Įnsure that both of the Advanced Installation Options checkboxes are selected, and then click Install. When it is done downloading, double-click on this file to begin the installation process.Īgree to the License Agreement, and click Next. It should download a file called "Miniconda3-latest-Windows-x86_64.exe" to your Downloads folder.
Click on the "64-bit (exe installer)" link underneath "Windows". After we have finished installing miniconda, we will install a couple of useful packages that we plan to use during this workshop. Miniconda simply installs Python and the machinery to add additional packages that are enabled in the conda package management system. Rather than installing the whole thing, we will be installing miniconda. The entire Anaconda package is quite large. It also allows for simple control over virtual environments (called conda envs) that make dependency resolution for particular software or pipelines a breeze. This is a powerful tool that allows users to install packages easily and without root access. BackgroundĬontinuum Analytics has developed the Anaconda package management system for Python.
This guide is focused on how to install the miniconda package on a Windows machine.