Jupyter Kernel : Is there a way to rename them?

2019-04-07 23:16发布

I mis-typed the name for the kernel while issuing: python -m ipykernel install --name and the wrong name is showing up the Jupyter's "Change kernel" menu. Is there a way to change just the name (without unstalling and installing it with the right name again)? I could not find where Jupyter is storing the names of the installed kernels. That could perhaps be edited?
Thanks, etc.

1条回答
不美不萌又怎样
2楼-- · 2019-04-07 23:48

You can use the kernelspec command to get information about the installed Kernels for your installation.

The command jupyter kernelspec list will provide you a list of the installed Kernels, something like:

Available kernels:
  python2          /Library/Python/2.7/site-packages/ipykernel/resources
  redisworkshop    /Users/tague/Library/Jupyter/kernels/RedisWorkshop
  bash             /Users/tague/Library/Jupyter/kernels/bash

The display name for a kernel is found in the kernel.json file in the corresponding directory for the kernel. Edit the display_name property in the kernel.json file and it will change the display name next time you start Jupyter.

查看更多
登录 后发表回答