seaborn无法import_Seaborn ImportError:DLL加载失败:找不到指定的模块

I am getting the "ImportError: DLL load failed: The specified module could not be found." when importing the module seaborn.

I tried uninstalling both seaborn and matplotlib, then reinstalling by using

pip install seaborn

but no luck. I still get the same error.

ImportError Traceback (most recent call last)

in ()

----> 1 import seaborn

C:\Users\johnsam\venv\lib\site-packages\seaborn\__init__.py in ()

4

5 # Import seaborn objects

----> 6 from .rcmod import *

7 from .utils import *

8 from .palettes import *

C:\Users\johnsam\venv\lib\site-packages\seaborn\rcmod.py in ()

6 import matplotlib as mpl

7

----> 8 from . import palettes, _orig_rc_params

9

10

C:\Users\johnsam\venv\lib\site-packages\seaborn\palettes.py in ()

10 from .external.six.moves import range

11

---> 12 from .utils import desaturate, set_hls_values, get_color_cycle

13 from .xkcd_rgb import xkcd_rgb

14 from .crayons import crayons

C:\Users\johnsam\venv\lib\site-packages\seaborn\utils.py in ()

6

7 import numpy as np

----> 8 from scipy import stats

9 import pandas as pd

10 import matplotlib as mpl

C:\Program Files\Continuum\Anaconda3\lib\site-packages\scipy\stats\__init__.py in ()

332 from __future__ import division, print_function, absolute_import

333

--> 334 from .stats import *

335 from .distributions import *

336 from .rv import *

C:\Program Files\Continuum\Anaconda3\lib\site-packages\scipy\stats\stats.py in ()

179 from scipy.lib.six import callable, string_types

180 from numpy import array, asarray, ma, zeros, sum

--> 181 import scipy.special as special

182 import scipy.linalg as linalg

183 import numpy as np

C:\Program Files\Continuum\Anaconda3\lib\site-packages\scipy\special\__init__.py in ()

544 from __future__ import division, print_function, absolute_import

545

--> 546 from ._ufuncs import *

547

548 from .basic import *

ImportError: DLL load failed: The specified module could not be found.

Is there a way to get around this error?

解决方案

I was having this issue until I uninstalled and reinstalled scipy with the pip command. Just got to your command line and type pip uninstall scipy and pip install scipy.

Hopefully that works for you as well. I also uninstalled/installed seaborn before this although I'm not sure if that was necessary.

Using conda rather than pip may also work.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值