Kernel crashes when importing tensorflow
See original GitHub issueEnvironment data
- VS Code version: 1.60.1
- Jupyter Extension version (available under the Extensions sidebar): v2021.8.2041215044
- Python Extension version (available under the Extensions sidebar): v2021.9.1246542782
- OS (Windows | Mac | Linux distro) and version: debian 11
- Python and/or Anaconda version: 3.9.2
- Type of virtual environment used (N/A | venv | virtualenv | conda | …): none
- Jupyter server running: Local (I think, running notebook on a vm with ssh extension)
Expected behaviour
import tensorflow
would work
Actual behaviour
See screenshot below
Steps to reproduce:
Initially I got same error messages as here https://github.com/microsoft/vscode-jupyter/issues/7190, but unfortunately can’t reproduce them anymore.
Error: Kernel is dead
Error: Kernel is dead
at g._sendKernelShellControl (/home/debian/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.2041215044/out/client/extension.js:52:1006195)
at g.sendShellMessage (/home/debian/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.2041215044/out/client/extension.js:52:1005964)
at g.requestExecute (/home/debian/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.2041215044/out/client/extension.js:52:1008506)
at d.requestExecute (/home/debian/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.2041215044/out/client/extension.js:37:325680)
at w.requestExecute (/home/debian/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.2041215044/out/client/extension.js:32:18027)
at w.executeCodeCell (/home/debian/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.2041215044/out/client/extension.js:52:301076)
at w.execute (/home/debian/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.2041215044/out/client/extension.js:52:300703)
at w.start (/home/debian/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.2041215044/out/client/extension.js:52:296367)
at async t.CellExecutionQueue.executeQueuedCells (/home/debian/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.2041215044/out/client/extension.js:52:311160)
at async t.CellExecutionQueue.start (/home/debian/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.2041215044/out/client/extension.js:52:310700)
Issue Analytics
- State:
- Created 2 years ago
- Comments:9 (5 by maintainers)
Top Results From Across the Web
Kernel Died error post installing tensorflow - Apple Developer
I am facing the same issue today. After uninstalling anaconda python and reinstalling it, I realize that the issue occurs simply because I...
Read more >Python kernel dies when importing tensorflow 1.7
The kernel appears to have died. It will restart automatically. This issue only began after updating to tensorflow 1.7. I had not used ......
Read more >importing tensorflow kills kernel - You.com | The AI Search ...
import tensorflow as tf in a Jupyter notebook immediately triggers a pop-up: The kernel appears to have died. It will restart automatically.
Read more >Kernels dying when using tensorflow in Jupyter Notebooks.
Kernel dies when creating models using keras.sequential. Using tensorflow version 2.7 and python version 3.8.
Read more >The kernel appears to have died | Data Science and ... - Kaggle
The problem arises in the loop over training epochs. TensorFlow is set up to load the OpenMP library multiple times, which will cause...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Eh, apparently this has nothing to do with jupyter. Following message is returned when trying to import tensorflow on the same machine outside jupyter:
Error message could be better at jupyter side, but feel free to close this issue if you think otherwise.
@Napuu thanks for the information, i’ve tried to repro this and unfortunately i cannot. CLosing as you’ve managed to get this working.