Traceback (most recent call last):
File "D:\dev\Lib\site-packages\numpy_core_init_.py", line 23, in
from . import multiarray
File "D:\dev\Lib\site-packages\numpy_core\multiarray.py", line 10, in
from . import overrides
File "D:\dev\Lib\site-packages\numpy_core\overrides.py", line 8, in
from numpy._core._multiarray_umath import (
ModuleNotFoundError: No module named 'numpy._core._multiarray_umath'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\dev\Lib\site-packages\numpy_init.py", line 127, in
from numpy.config import show as show_config
File "D:\dev\Lib\site-packages\numpy_config.py", line 4, in
from numpy._core.multiarray_umath import (
File "D:\dev\Lib\site-packages\numpy_core_init.py", line 49, in
raise ImportError(msg)
ImportError:
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.12 from "D:\dev\python.exe"
- The NumPy version is: "2.1.3"
and make sure that they are the versions you expect.
Please carefully study the documentation linked above for further help.
Original error was: No module named 'numpy._core._multiarray_umath'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "E:\project\pythonProject3\二级质谱数据的处理\3.py", line 2, in
import numpy
File "D:\dev\Lib\site-packages\numpy_init_.py", line 132, in
raise ImportError(msg) from e
ImportError: Error importing numpy: you should not try to import numpy from
its source directory; please exit the numpy source tree, and relaunch
your python interpreter from there.
为什么有这个问题