在为我的Windows 10安装了Anaconda 3的新副本并运行了我的代码后,我收到了这个错误信息,我不确定为什么“Scipy”模块没有正确导入。我需要帮助来弄清楚这一点。
用户名/用户/用户名/桌面/sol-tl/sol_357.py
Traceback (most recent call last):
File "d:\Users\username\Desktop\some_name\my_script.py", line 37, in <module>
from fluorescence.calculator import (electron_plotter, enter_computation_scheme, total_plotter)
File "d:\Users\username\Desktop\sol-tl\fluorescence\calculator.py", line 18, in <module>
from fluorescence.imports_module import (np, List, Tuple, Path, perf_counter, ode, odeint,
File "d:\Users\username\Desktop\sol-tl\fluorescence\imports_module.py", line 25, in <module>
from scipy.optimize import curve_fit
File "D:\Users\username\Anaconda3\lib\site-packages\scipy\optimize\__init__.py", line 400, in <module>
from .optimize import *
File "D:\Users\username\Anaconda3\lib\site-packages\scipy\optimize\optimize.py", line 36, in <module>
from ._numdiff import approx_derivative
File "D:\Users\username\Anaconda3\lib\site-packages\scipy\optimize\_numdiff.py", line 6, in <module>
from scipy.sparse.linalg import LinearOperator
File "D:\Users\username\Anaconda3\lib\site-packages\scipy\sparse\linalg\__init__.py", line 114, in <module>
from .eigen import *
File "D:\Users\username\Anaconda3\lib\site-packages\scipy\sparse\linalg\eigen\__init__.py", line 9, in <module>
from .arpack import *
File "D:\Users\username\Anaconda3\lib\site-packages\scipy\sparse\linalg\eigen\arpack\__init__.py", line 20, in <module>
from .arpack import *
File "D:\Users\username\Anaconda3\lib\site-packages\scipy\sparse\linalg\eigen\arpack\arpack.py", line 42, in <module>
from . import _arpack
ImportError: DLL load failed while importing _arpack: The specified procedure could not be found.
1条答案
按热度按时间dxxyhpgq1#
考虑到
Anaconda
(3.9.12)的新版本在“Scipy”包方面存在问题,我从Conda
中删除了这个包,并使用pip
重新安装了它。现在,代码运行得很好。