欧美一区二区三区老妇人-欧美做爰猛烈大尺度电-99久久夜色精品国产亚洲a-亚洲福利视频一区二区

python中sklearn找不到指定模塊怎么辦

這篇文章將為大家詳細(xì)講解有關(guān)python中sklearn找不到指定模塊怎么辦,小編覺得挺實用的,因此分享給大家做個參考,希望大家閱讀完這篇文章后可以有所收獲。

成都創(chuàng)新互聯(lián)專注為客戶提供全方位的互聯(lián)網(wǎng)綜合服務(wù),包含不限于做網(wǎng)站、成都網(wǎng)站制作、璧山網(wǎng)絡(luò)推廣、微信小程序定制開發(fā)、璧山網(wǎng)絡(luò)營銷、璧山企業(yè)策劃、璧山品牌公關(guān)、搜索引擎seo、人物專訪、企業(yè)宣傳片、企業(yè)代運營等,從售前售中售后,我們都將竭誠為您服務(wù),您的肯定,是我們最大的嘉獎;成都創(chuàng)新互聯(lián)為所有大學(xué)生創(chuàng)業(yè)者提供璧山建站搭建服務(wù),24小時服務(wù)熱線:18980820575,官方網(wǎng)址:chinadenli.net

在 import sklearn.manifold時出現(xiàn) ImportError: DLL load failed:找不到指定的模塊,具體如下:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\manifold\__init__.py", line 5, in <module>
    from .locally_linear import locally_linear_embedding, LocallyLinearEmbedding
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\manifold\locally_linear.py", line 17, in <module>
    from ..neighbors import NearestNeighbors
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\neighbors\__init__.py", line 9, in <module>
    from .graph import kneighbors_graph, radius_neighbors_graph
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\neighbors\graph.py", line 7, in <module>
    from .base import KNeighborsMixin, RadiusNeighborsMixin
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\neighbors\base.py", line 18, in <module>
    from ..metrics import pairwise_distances
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\metrics\__init__.py", line 35, in <module>
    from . import cluster
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\metrics\cluster\__init__.py", line 20, in <module>
    from .unsupervised import silhouette_samples
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\metrics\cluster\unsupervised.py", line 12, in <module>
    from ..pairwise import pairwise_distances
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\metrics\pairwise.py", line 30, in <module>
    from .pairwise_fast import _chi2_kernel_fast, _sparse_manhattan
ImportError: DLL load failed: 找不到指定的模塊。

解決方法:

在保證scipy和numpy成功安裝的條件下,并且安裝了pip后使用命令 pip install -U scikit-learn 更新一下即可。

若遇到如下問題:

Exception:
Traceback (most recent call last):
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\shutil.py", line 387, in _rmtree_unsafe
    os.unlink(fullname)
PermissionError: [WinError 5] 拒絕訪問。: 'C:\\Users\\user\\AppData\\Local\\Temp\\pip-njirl_1q-uninstall\\users\\user\\appdata\\local\\programs\\python\\python36\\lib\\site-packages\\sklearn\\feature_extraction\\_hashing.cp36-win_amd64.pyd'
 
During handling of the above exception, another exception occurred:
 
Traceback (most recent call last):
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\basecommand.py", line 215, in main
    status = self.run(options, args)
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\commands\install.py", line 342, in run
    prefix=options.prefix_path,
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\req\req_set.py", line 795, in install
    requirement.commit_uninstall()
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\req\req_install.py", line 767, in commit_uninstall
    self.uninstalled.commit()
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\req\req_uninstall.py", line 142, in commit
    rmtree(self.save_dir)
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\_vendor\retrying.py", line 49, in wrapped_f
    return Retrying(*dargs, **dkw).call(f, *args, **kw)
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\_vendor\retrying.py", line 212, in call
    raise attempt.get()
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\_vendor\retrying.py", line 247, in get
    six.reraise(self.value[0], self.value[1], self.value[2])
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\_vendor\six.py", line 686, in reraise
    raise value
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\_vendor\retrying.py", line 200, in call
    attempt = Attempt(fn(*args, **kwargs), attempt_number, False)
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\utils\__init__.py", line 102, in rmtree
    οnerrοr=rmtree_errorhandler)
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\shutil.py", line 494, in rmtree
    return _rmtree_unsafe(path, onerror)
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\shutil.py", line 384, in _rmtree_unsafe
    _rmtree_unsafe(fullname, onerror)
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\shutil.py", line 384, in _rmtree_unsafe
    _rmtree_unsafe(fullname, onerror)
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\shutil.py", line 384, in _rmtree_unsafe
    _rmtree_unsafe(fullname, onerror)
  [Previous line repeated 7 more times]
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\shutil.py", line 389, in _rmtree_unsafe
    onerror(os.unlink, fullname, sys.exc_info())
  File "C:\Users\user\AppData\Local\Programs\Python\Python36\lib\site-packages\pip\utils\__init__.py", line 114, in rmtree_errorhandler
    func(path)
PermissionError: [WinError 5] 拒絕訪問。: 'C:\\Users\\user\\AppData\\Local\\Temp\\pip-njirl_1q-uninstall\\users\\user\\appdata\\local\\programs\\python\\python36\\lib\\site-packages\\sklearn\\feature_extraction\\_hashing.cp36-win_amd64.pyd'

使用 pip install --user package_name命令即可解決。

關(guān)于python中sklearn找不到指定模塊怎么辦就分享到這里了,希望以上內(nèi)容可以對大家有一定的幫助,可以學(xué)到更多知識。如果覺得文章不錯,可以把它分享出去讓更多的人看到。

新聞名稱:python中sklearn找不到指定模塊怎么辦
網(wǎng)頁網(wǎng)址:http://chinadenli.net/article44/pgpehe.html

成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供網(wǎng)站收錄微信公眾號軟件開發(fā)網(wǎng)站改版面包屑導(dǎo)航網(wǎng)站內(nèi)鏈

廣告

聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)

成都做網(wǎng)站