2016-04-27 1 views
0

Ich habe numpy, scipy und scikit-learn in Python 3.5 installiert. Wenn ich mein Programm starte, bekomme ich diesen Fehler.ImportError: DLL-Laden fehlgeschlagen: Das angegebene Modul konnte nicht gefunden werden (sklearn)

Traceback (most recent call last): 
    File "D:/Dropbox/Cong Toan/Tools/NLP_Tools/doc_sim.py", line 1, in <module> 
    from sklearn.feature_extraction.text import TfidfVectorizer 
    File "C:\Python35-32\lib\site-packages\sklearn\__init__.py", line 57, in <module> 
    from .base import clone 
    File "C:\Python35-32\lib\site-packages\sklearn\base.py", line 11, in <module> 
    from .utils.fixes import signature 
    File "C:\Python35-32\lib\site-packages\sklearn\utils\__init__.py", line 11, in <module> 
    from .validation import (as_float_array, 
    File "C:\Python35-32\lib\site-packages\sklearn\utils\validation.py", line 16, in <module> 
    from ..utils.fixes import signature 
    File "C:\Python35-32\lib\site-packages\sklearn\utils\fixes.py", line 324, in <module> 
    from scipy.sparse.linalg import lsqr as sparse_lsqr 
    File "C:\Python35-32\lib\site-packages\scipy\sparse\linalg\__init__.py", line 112, in <module> 
    from .isolve import * 
    File "C:\Python35-32\lib\site-packages\scipy\sparse\linalg\isolve\__init__.py", line 6, in <module> 
    from .iterative import * 
    File "C:\Python35-32\lib\site-packages\scipy\sparse\linalg\isolve\iterative.py", line 7, in <module> 
    from . import _iterative 
ImportError: DLL load failed: The specified module could not be found. 

Antwort

2

Es erfordert tatsächlich numpy + mkl. Aber es ist schwer zu sagen, ob das Problem mit Ihrer Distribution ist.

Mein Rat ist, dass Sie eine der verfügbaren Distributionen verwenden, die diese Bibliotheken bereits bringen. Ich empfehle WinPython, aber ich hörte auch gute Dinge über Anaconda.

Es ist einfach, andere Pakete zu installieren, mit WinPython mit:

Unofficial Windows Binaries for Python Extension Packages

von Christoph Gohlke.

Wenn Sie dieses Problem mit Ihrer aktuellen Distribution wirklich lösen möchten, müssen Sie weitere Informationen bereitstellen, z. B. installierte Versionen, installierte Module und wie Sie sie installiert haben.

1

Versuchen Sie Anaconda, es wird Ihr Problem lösen.

4

Ich habe das gleiche Problem auch, nach Tagen der Suche und Neuinstallation fast alles. Ich fand heraus, die Antwort:

Schritt 1: Deinstallieren scipy und numpy

Schritt 2: Dowload numpy + mkl (der Paketname ist numpy + mkl, nicht numpy Paket und MKL-Paket) und scipy von this page als armatita

erwähnt

Schritt 3: Installieren Sie auch numpy + mkl erste und SciPy danach

Viel Glück für Sie

+0

ich sklearn unsinstall hatte. Installierte numpy + mkl, scipy und dann scikit_learn von demselben Link heruntergeladen. Gestoppt das Jupyter-Notebook und neu gestartet. – Harminder