簡體   English   中英

當我使用 Visual Studio Code 運行 Jupyter notebook 時出現導入錯誤

[英]ImportError when I run Jupyter notebook with Visual Studio Code

我想在 VSCode 中運行 .ipynb 筆記本,但它失敗並發送此消息。 請注意,在瀏覽器中,我可以毫無問題地運行所有內容。


IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE!

Importing the numpy C-extensions failed. This error can happen for
many reasons, often due to issues with your setup or how NumPy was
installed.

We have compiled some common reasons and troubleshooting tips at:

    https://numpy.org/devdocs/user/troubleshooting-importerror.html

Please note and check the following:

  * The Python version is: Python3.8 from "C:\Users\Marta\anaconda3\envs\geo_env\python.exe"
  * The NumPy version is: "1.21.3"

and make sure that they are the versions you expect.
Please carefully study the documentation linked above for further help.

Original error was: DLL load failed while importing _multiarray_umath: The specified module could not be found.```

您使用的numpy存在一些問題。 您可以嘗試重新安裝它嗎?

pip uninstall -y numpy

pip uninstall -y setuptools

pip install setuptools

pip install numpy

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM