Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't Find Jupyter Notebook Kernel

I currently use a Mac. I recently created a new python virtual environment and installed jupyter. When I activate jupyter notebook within the virtual environment, it says it cannot find any python kernels. I have another virtual environment that also has jupyter installed and it works perfectly fine. Can anyone help? Also, I'm not sure where the Kernels are even located on my machine. Library/Jupyter only has a runtime folder.

like image 570
user3002486 Avatar asked Jan 07 '17 05:01

user3002486


People also ask

How do I find my Jupyter kernel?

The kernel being used is in the upper right-hand corner of a Jupyter notebook (it defaults to Python 2 or Python 3 if you just use the base environments). You can choose the environment from the Kernel menu, as shown in the screenshot below. Before a kernel appears in drop-down list of kernels, you have to register it.

Why is my Jupyter Notebook not connecting to kernel?

Before we get into the solutions, what is a kernel error? A kernel error occurs basically when you try opening a python 3 file in the wrong directory. The truth is Jupyter and Python are two different software entirely. So, a kernel error occurs when Jupyter fails to connect with a specific version of Python.

Where did my Jupyter Notebook go?

Use My Data: Just click the My Data (folder icon) in the left menu bar. Once it opens just click Back, to go up one level to /resources and you can find your Jupyter notebooks there (may need to scroll down a little). Click on the desired notebook (. ipynb) file and it will open up in Jupyter.


1 Answers

I need to do 2 things to get this to work:
conda install -y ipykernel
python -m ipykernel install --user --name myenv

Kind of frustrating and I never see it mentioned much in the docs. Jupyter set up remains a pretty painful process in my opinion. This is from beginning to end, if it helps anyone:

conda create -n myenv python=3.7
conda activate myenv
conda install -y -c conda-forge jupyterlab
conda install -y -c anaconda jupyter
conda install -y ipykernel
python -m ipykernel install --user --name myenv
like image 172
nathan Avatar answered Oct 01 '22 02:10

nathan