jupyter 更换kernel,更改Jupyter kernelspec以指向anaconda python

本文档描述了如何解决Jupyter Notebook的kernel指向系统Python而非Anaconda安装的问题。通过删除默认的/usr/local/share/jupyter/kernels/python3,使Jupyter使用与命令行相同的Anaconda Python版本作为默认kernel。
摘要由CSDN通过智能技术生成

I'm using Anaconda to manage both Python and Jupyter. That is:

>> which python

>> /home/.../software/anaconda3/bin/python

and

>> which jupyter

>> /home/.../software/anaconda3/bin/jupyter

But Jupyter's python kernel seems to be pointing to a system version of Python rather than my local version through Anaconda, since the sys.path is different in a Jupyter Python 3 notebook. Also, jupyter kernelspec list gives the following:

Available kernels:

ir /usr/local/share/jupyter/kernels/ir

matlab /usr/local/share/jupyter/kernels/matlab

python3 /usr/local/share/jupyter/kernels/python3

This doesn't seem altogether surprising since the docs say in section 1.5.5:

By default, kernel specs will go in a system-wide location (e.g. /usr/local/share/jupyter/kernels). If doing a --use

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值