我前段時間一直在使用ipython和jupyter一段時間。在近6個月內沒有使用它之後,我想再次開始使用它。新鮮的Windows 10安裝anaconda和jupyter - 內核錯誤(Python 2.7和3.5)
我安裝jupyter的最新版本,更新我的Python 2.7安裝,有點子的工作和安裝必要的程序包:
pip install jupyter
pip install notebook
等幹了那事我試圖進入一箇舊的筆記本電腦後(筆試在2.7中),但沒有與內核的連接。我想,當然,爲什麼不更新到最新的python 3版本並嘗試。這導致了同樣的問題。
我繼續安裝anaconda並創建了兩個虛擬envs,一個使用python 2.7,一個使用python 3.5。都安裝這樣的:
conda create --name py27 python=2.7 anaconda
conda create --name py35 python=3.5 anaconda
之後,我確信這兩個venvs已經jupyter通過激活他們,並試圖安裝包安裝。 (這是用py27和py35完成的,它們是從上面命令看到的venvs的名稱)。
activate py27
conda install jupyter
之後,我試圖運行:
jupyter notebook
我創建了一個新的記事本文件,看看我是否有訪問內核。然而有人明確指出,我沒有跟以下錯誤:
Traceback (most recent call last):
File "E:\Anaconda3\envs\py35\lib\site-packages\notebook\base\handlers.py", line 458, in wrapper
result = yield gen.maybe_future(method(self, *args, **kwargs))
File "E:\Anaconda3\envs\py35\lib\site-packages\tornado\gen.py", line 1008, in run
value = future.result()
File "E:\Anaconda3\envs\py35\lib\site-packages\tornado\concurrent.py", line 232, in result
raise_exc_info(self._exc_info)
File "<string>", line 3, in raise_exc_info
File "E:\Anaconda3\envs\py35\lib\site-packages\tornado\gen.py", line 1014, in run
yielded = self.gen.throw(*exc_info)
File "E:\Anaconda3\envs\py35\lib\site-packages\notebook\services\sessions\handlers.py", line 58, in post
sm.create_session(path=path, kernel_name=kernel_name))
File "E:\Anaconda3\envs\py35\lib\site-packages\tornado\gen.py", line 1008, in run
value = future.result()
File "E:\Anaconda3\envs\py35\lib\site-packages\tornado\concurrent.py", line 232, in result
raise_exc_info(self._exc_info)
File "<string>", line 3, in raise_exc_info
File "E:\Anaconda3\envs\py35\lib\site-packages\tornado\gen.py", line 1014, in run
yielded = self.gen.throw(*exc_info)
File "E:\Anaconda3\envs\py35\lib\site-packages\notebook\services\sessions\sessionmanager.py", line 73, in create_session
self.kernel_manager.start_kernel(path=kernel_path, kernel_name=kernel_name)
File "E:\Anaconda3\envs\py35\lib\site-packages\tornado\gen.py", line 1008, in run
value = future.result()
File "E:\Anaconda3\envs\py35\lib\site-packages\tornado\concurrent.py", line 232, in result
raise_exc_info(self._exc_info)
File "<string>", line 3, in raise_exc_info
File "E:\Anaconda3\envs\py35\lib\site-packages\tornado\gen.py", line 282, in wrapper
yielded = next(result)
File "E:\Anaconda3\envs\py35\lib\site-packages\notebook\services\kernels\kernelmanager.py", line 87, in start_kernel
super(MappingKernelManager, self).start_kernel(**kwargs)
File "E:\Anaconda3\envs\py35\lib\site-packages\jupyter_client\multikernelmanager.py", line 109, in start_kernel
km.start_kernel(**kwargs)
File "E:\Anaconda3\envs\py35\lib\site-packages\jupyter_client\manager.py", line 244, in start_kernel**kw)
File "E:\Anaconda3\envs\py35\lib\site-packages\jupyter_client\manager.py", line 190, in _launch_kernel
return launch_kernel(kernel_cmd, **kw)
File "E:\Anaconda3\envs\py35\lib\site-packages\jupyter_client\launcher.py", line 108, in launch_kernel
proc = Popen(cmd, **kwargs)
File "E:\Anaconda3\envs\py35\lib\subprocess.py", line 950, in __init__ restore_signals, start_new_session)
File "E:\Anaconda3\envs\py35\lib\subprocess.py", line 1220, in _execute_child startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified
這顯然是對我的py35 VENV試圖然而,我得到我的py27 VENV同樣的錯誤。我嘗試了幾個例如運行kernelspec,但沒有任何成功。
有人對可能出錯的建議?
http://stackoverflow.com/questions/35697794/ipython-kernel-error-after-uninstalling-anaconda –