如何知道Jupyter笔记本中正在运行的笔记本?
问题描述:
我在浏览器中使用Jupyter笔记本进行Python编程,我已经安装了Anaconda(Python 3.5).但是我很确定Jupyter使用本地python解释器而不是anaconda运行我的python命令.如何更改它并将Anaconda用作解释器?
I use Jupyter notebook in a browser for Python programming, I have installed Anaconda (Python 3.5). But I'm quite sure that Jupyter in running my python commands with the native python interpreter and not with anaconda. How can I change it and use Anaconda as interpreter ?
谢谢!
Ubuntu 16.10-Anaconda3
Ubuntu 16.10 -- Anaconda3
答
from platform import python_version
print(python_version())
这将为您提供运行脚本的python的确切版本.例如输出:
This will give you the exact version of python running your script. eg output:
3.6.5