导入错误:导入 _rolling_ball_cy 时 DLL 加载失败:

时间:2021-01-12 15:59:47

标签: python python-3.x opencv scikit-learn scikit-image

我是 Python 的新手,正在开发一个小型 opencv 应用程序。 我需要来自 scikit-image 的 local_threshold 但出现以下错误:

<块引用>

回溯(最近一次调用最后一次):文件 “D:/Projects/Python/Document_Scanner/main.py”,第 6 行,在 from skimage.filters import threshold_local File "C:\Users\nash2\AppData\Local\Programs\Python\Python38-32\lib\site-packages\skimage\filters_init_.py", 第 4 行,在 从 .edges 导入(sobel、sobel_h、sobel_v、文件“C:\Users\nash2\AppData\Local\Programs\Python\Python38-32\lib\site-packages\skimage\filters\edges.py”, 第 18 行,在 from ..restoration.uft import laplacian File "C:\Users\nash2\AppData\Local\Programs\Python\Python38-32\lib\site-packages\skimage\restoration_init_.py" , 第 13 行,在 从.rolling_ball 导入rolling_ball、ball_kernel、ellipsoid_kernel 文件 "C:\Users\nash2\AppData\Local\Programs\Python\Python38-32\lib\site-packages\skimage\restoration\rolling_ball.py", 第 3 行,在 from ._rolling_ball_cy import apply_kernel, apply_kernel_nan ImportError: DLL load failed while importing _rolling_ball_cy: The 找不到指定的模块。

我尝试恢复到旧版本的 scikit-image ,但仍然出现错误。 我当前的 scikit-image 版本是 0.18.0

3 个答案:

答案 0 :(得分:2)

安装scikit-image老版本(0.18.0rc0版本)我解决了这个问题

答案 1 :(得分:0)

我能够通过在我的机器上重新安装 python 来让它工作。希望它可以帮助某人。

答案 2 :(得分:0)

您需要安装和分发 Microsoft 的 vcredist_x64.exe 的内容。特别是您需要 VCOMP140.DLL