ImportError: cannot import name 'rcParams' from 'matplotlib' - python

I have tried to uninstall and reinstall matplotlib in my tf-gpu enviornment I made but I keep getting this error:
ImportError: cannot import name 'rcParams' from 'matplotlib'
This is the entire output I am getting on jupyter notebook:
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
<ipython-input-9-8d7d44d0fddd> in <module>
17 # import matplotlib.pyplot as plt
18 from sklearn.metrics import confusion_matrix
---> 19 from mlxtend.plotting import plot_confusion_matrix
20
21 # Removes annoying warning messages in tensorflow and python
~\AppData\Local\Continuum\anaconda3\envs\tf-gpu\lib\site-packages\mlxtend\plotting\__init__.py in <module>
5 # License: BSD 3 clause
6
----> 7 from .decision_regions import plot_decision_regions
8 from .learning_curves import plot_learning_curves
9 from .plot_confusion_matrix import plot_confusion_matrix
~\AppData\Local\Continuum\anaconda3\envs\tf-gpu\lib\site-packages\mlxtend\plotting\decision_regions.py in <module>
8
9 from itertools import cycle
---> 10 import matplotlib.pyplot as plt
11 import numpy as np
12 from mlxtend.utils import check_Xy, format_kwarg_dictionaries
~\AppData\Local\Continuum\anaconda3\envs\tf-gpu\lib\site-packages\matplotlib\pyplot.py in <module>
30 from cycler import cycler
31 import matplotlib
---> 32 import matplotlib.colorbar
33 import matplotlib.image
34 from matplotlib import rcsetup, style
~\AppData\Local\Continuum\anaconda3\envs\tf-gpu\lib\site-packages\matplotlib\colorbar.py in <module>
25
26 import matplotlib as mpl
---> 27 import matplotlib.artist as martist
28 import matplotlib.cbook as cbook
29 import matplotlib.collections as collections
~\AppData\Local\Continuum\anaconda3\envs\tf-gpu\lib\site-packages\matplotlib\artist.py in <module>
10
11 import matplotlib
---> 12 from . import cbook, docstring, rcParams
13 from .path import Path
14 from .transforms import (Bbox, IdentityTransform, Transform, TransformedBbox,
ImportError: cannot import name 'rcParams' from 'matplotlib' (unknown location)
I was not able to find a solution online, so I wanted to start a thread on this again.
UPDATE:
I tried to uninstall matplotlib using conda/pip but it still shows up in conda list output:
# Name Version Build Channel
_tflow_select 2.1.0 gpu
absl-py 0.8.1 py37_0
asn1crypto 1.0.0 pypi_0 pypi
astor 0.8.0 py37_0
attrs 19.3.0 py_0
backcall 0.1.0 py37_0
blas 1.0 mkl
bleach 3.1.0 py37_0
bzip2 1.0.8 he774522_0
ca-certificates 2019.11.27 0
censusdata 1.5 pypi_0 pypi
censusgeocode 0.4.3.post1 pypi_0 pypi
certifi 2019.11.28 py37_0
cffi 1.12.3 pypi_0 pypi
chardet 3.0.4 pypi_0 pypi
click 7.0 py37_0
click-plugins 1.1.1 py_0
cligj 0.5.0 py37_0
colorama 0.4.3 py_0
cryptography 2.7 pypi_0 pypi
cudatoolkit 10.0.130 0
cudnn 7.6.5 cuda10.0_0
curl 7.67.0 h2a8f88b_0
decorator 4.4.1 py_0
defusedxml 0.6.0 py_0
entrypoints 0.3 py37_0
et-xmlfile 1.0.1 pypi_0 pypi
expat 2.2.5 he025d50_0
fiona 1.8.4 py37h22081e2_0
freexl 1.0.5 hfa6e2cd_0
gast 0.3.2 py_0
gdal 2.3.3 py37hdf43c64_0
geopandas 0.6.1 py_0
geos 3.7.1 h33f27b4_0
grpcio 1.16.1 py37h351948d_1
h5py 2.9.0 py37h5e291fa_0
haversine 2.1.2 pypi_0 pypi
hdf4 4.2.13 h712560f_2
hdf5 1.10.4 h7ebc959_0
icc_rt 2019.0.0 h0cc432a_1
icu 58.2 ha66f8fd_1
idna 2.8 pypi_0 pypi
importlib_metadata 1.3.0 py37_0
intel-openmp 2019.4 245
ipfn 1.3.0 pypi_0 pypi
ipykernel 5.1.3 py37h39e3cac_0
ipython 7.11.1 py37h39e3cac_0
ipython_genutils 0.2.0 py37_0
ipywidgets 7.5.1 py_0
jdcal 1.4.1 pypi_0 pypi
jedi 0.15.2 py37_0
jinja2 2.10.3 py_0
joblib 0.14.0 pypi_0 pypi
jpeg 9b hb83a4c4_2
jsonschema 3.2.0 py37_0
jupyter 1.0.0 py37_7
jupyter_client 5.3.4 py37_0
jupyter_console 6.1.0 py_0
jupyter_core 4.6.1 py37_0
kealib 1.4.7 h07cbb95_6
keras 2.2.4 0
keras-applications 1.0.8 py_0
keras-base 2.2.4 py37_0
keras-preprocessing 1.1.0 py_1
krb5 1.16.4 hc04afaa_0
libboost 1.67.0 hd9e427e_4
libcurl 7.67.0 h2a8f88b_0
libgdal 2.3.3 h10f50ba_0
libiconv 1.15 h1df5818_7
libkml 1.3.0 he5f2a48_4
libnetcdf 4.6.1 h411e497_2
libpng 1.6.37 h2a8f88b_0
libpq 11.2 h3235a2c_0
libprotobuf 3.11.2 h7bd577a_0
libsodium 1.0.16 h9d3ae62_0
libspatialindex 1.9.3 h33f27b4_0
libspatialite 4.3.0a hc36aec2_19
libssh2 1.8.2 h7a1dbc1_0
libtiff 4.1.0 h56a325e_0
libxml2 2.9.9 h464c3ec_0
m2w64-gcc-libgfortran 5.3.0 6
m2w64-gcc-libs 5.3.0 7
m2w64-gcc-libs-core 5.3.0 7
m2w64-gmp 6.1.0 2
m2w64-libwinpthread-git 5.0.0.4634.697f757 2
markdown 3.1.1 py37_0
markupsafe 1.1.1 py37he774522_0
matplotlib 3.1.1 pypi_0 pypi
mistune 0.8.4 py37he774522_0
mkl 2019.4 245
mkl-service 2.3.0 py37hb782905_0
mkl_fft 1.0.15 py37h14836fe_0
mkl_random 1.1.0 py37h675688f_0
mlxtend 0.17.0 pypi_0 pypi
more-itertools 8.0.2 py_0
msys2-conda-epoch 20160418 1
munch 2.5.0 py_0
nbconvert 5.6.1 py37_0
nbformat 4.4.0 py37_0
networkx 2.4 pypi_0 pypi
notebook 6.0.2 py37_0
numpy 1.18.1 py37h93ca92e_0
numpy-base 1.18.1 py37hc3f5095_1
openpyxl 3.0.2 pypi_0 pypi
openssl 1.1.1d he774522_3
pandas 0.25.3 py37ha925a31_0
pandoc 2.2.3.2 0
pandocfilters 1.4.2 py37_1
parso 0.5.2 py_0
patsy 0.5.1 py37_0
pcre 8.43 ha925a31_0
pickleshare 0.7.5 py37_0
pip 19.3.1 py37_0
plotly 4.1.1 pypi_0 pypi
proj4 5.2.0 ha925a31_1
prometheus_client 0.7.1 py_0
prompt_toolkit 3.0.2 py_0
protobuf 3.11.2 py37h33f27b4_0
pycparser 2.19 pypi_0 pypi
pygments 2.5.2 py_0
pyopenssl 19.0.0 pypi_0 pypi
pyproj 1.9.6 py37h6782396_0
pyqt 5.9.2 py37h6538335_2
pyreadline 2.1 py37_1
pyrsistent 0.15.6 py37he774522_0
python 3.7.6 h60c2a47_2
python-dateutil 2.8.1 py_0
pytz 2019.3 py_0
pywin32 227 py37he774522_1
pywinpty 0.5.7 py37_0
pyyaml 5.2 py37he774522_0
pyzmq 18.1.0 py37ha925a31_0
qt 5.9.7 vc14h73c81de_0
qtconsole 4.6.0 py_1
requests 2.22.0 pypi_0 pypi
requests-toolbelt 0.9.1 pypi_0 pypi
retrying 1.3.3 pypi_0 pypi
rtree 0.8.3 py37_0
scipy 1.3.2 py37h29ff71c_0
seaborn 0.9.0 pypi_0 pypi
send2trash 1.5.0 py37_0
setuptools 44.0.0 py37_0
shapely 1.6.4 py37h222a598_0
sip 4.19.8 py37h6538335_0
six 1.13.0 py37_0
sklearn 0.0 pypi_0 pypi
sqlite 3.30.1 he774522_0
statsmodels 0.10.1 py37h8c2d366_0
tensorboard 1.14.0 py37he3c9ec2_0
tensorflow 1.14.0 gpu_py37h5512b17_0
tensorflow-base 1.14.0 gpu_py37h55fc52a_0
tensorflow-estimator 1.14.0 py_0
tensorflow-gpu 1.14.0 h0d30ee6_0
termcolor 1.1.0 py37_1
terminado 0.8.3 py37_0
testpath 0.4.4 py_0
time-series 0.2 pypi_0 pypi
tk 8.6.8 hfa6e2cd_0
tornado 6.0.3 py37he774522_0
traitlets 4.3.3 py37_0
urllib3 1.25.6 pypi_0 pypi
vc 14.1 h0510ff6_4
vs2015_runtime 14.16.27012 hf0eaf9b_1
wcwidth 0.1.7 py37_0
webencodings 0.5.1 py37_1
werkzeug 0.16.0 py_0
wheel 0.33.6 py37_0
widgetsnbextension 3.5.1 py37_0
wincertstore 0.2 py37_0
winpty 0.4.3 4
wrapt 1.11.2 py37he774522_0
xerces-c 3.2.2 ha925a31_0
xlrd 1.2.0 py37_0
xz 5.2.4 h2fa13f4_4
yaml 0.1.7 hc54c509_2
zeromq 4.3.1 h33f27b4_3
zipp 0.6.0 py_0
zlib 1.2.11 h62dcd97_3
zstd 1.3.7 h508b16e_0

Try the following:
from pylab import rcParams

I came across this error after reinstalling matplotlib twice and facing other Errors, which are:
ValueError: setting an array element with a sequence
ValueError: 'transform' must be an instance of 'matplotlib.transform.Transform'
I was able to solve the above issues by reinstalling matplotlib using:
conda install -f matplotlib
But surprisingly I was able to solve this (ImportError: cannot import name 'rcParams' from 'matplotlib') just by restarting the Spyder (Python 3.7) from File Menu > Restart option.
I restarted and then ran the code without any modifications, and it worked.

I was able to fix the issue above by first uninstalling and installing matplotlib. Then completely creating a new notebook. For some reason the old notebook still gave me the same error but when I create a new notebook in the same environment it worked, go figure.

I'm not certain if this corresponds to a recent change in how matplotlib works or if it was always so, but when I encountered the same error, it seemed that the issue was that rcParams cannot be directly imported with an import statement. You must first import matplotlib, thus causing the module to be loaded into memory, cached, and possibly generate some dynamic objects. Then you can access rcParams.
Case in point, this fails:
import matplotlib.rcParams as rcp
Traceback (most recent call last):
File "/home/nc/miniconda3/envs/pybnn/lib/python3.8/site-packages/IPython/core/interactiveshell.py", line 3417, in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
File "<ipython-input-2-d4bca3da3c19>", line 1, in <module>
import matplotlib.rcParams as rcp
File "/snap/pycharm-community/211/plugins/python-ce/helpers/pydev/_pydev_bundle/pydev_import_hook.py", line 21, in do_import
module = self._system_import(name, *args, **kwargs)
ModuleNotFoundError: No module named 'matplotlib.rcParams'
However, this works:
import matplotlib as mpl
rcp = mpl.rcParams
Backend Qt5Agg is interactive backend. Turning interactive mode on.
WARNING: QApplication was not created in the main() thread.
type(rcp)
Out[5]: matplotlib.RcParams
I'm using matplotlib 3.3.1.

Uninstall anaconda and run again it worked for me

Related

No module named 'matplotlib.artist'

I faced with this error
No module named 'matplotlib.artist'
here is the complete error:
---------------------------------------------------------------------------
ModuleNotFoundError Traceback (most recent call last)
<ipython-input-2-cf8446fccc06> in <module>
5 import numpy as np
6 #import seaborn as sns
----> 7 import matplotlib.pyplot as plt
8 from warnings import filterwarnings
9 filterwarnings('ignore')
~\AppData\Roaming\Python\Python37\site-packages\matplotlib\pyplot.py in <module>
30 from cycler import cycler
31 import matplotlib
---> 32 import matplotlib.colorbar
33 import matplotlib.image
34 from matplotlib import rcsetup, style
~\AppData\Roaming\Python\Python37\site-packages\matplotlib\colorbar.py in <module>
25
26 import matplotlib as mpl
---> 27 import matplotlib.artist as martist
28 import matplotlib.cbook as cbook
29 import matplotlib.collections as collections
ModuleNotFoundError: No module named 'matplotlib.artist'
from yesterday when I want to use
import matplotlib.pyplot as plt
or
import seaborn as sns
I am using 3.7.4, matplotlib 3.1.1,seaborn 0.9.0
here is the full pip list
Package Version
---------------------------------- ---------
-atplotlib 3.1.1
alabaster 0.7.12
anaconda-client 1.7.2
anaconda-navigator 1.9.7
anaconda-project 0.8.3
asn1crypto 1.0.1
astroid 2.3.1
astropy 3.2.1
atomicwrites 1.3.0
attrs 19.2.0
Babel 2.7.0
backcall 0.1.0
backports.functools-lru-cache 1.5
backports.os 0.1.1
backports.shutil-get-terminal-size 1.0.0
backports.tempfile 1.0
backports.weakref 1.0.post1
beautifulsoup4 4.8.0
bitarray 1.0.1
bkcharts 0.2
bleach 3.1.0
bokeh 1.3.4
boto 2.49.0
Bottleneck 1.2.1
certifi 2019.9.11
cffi 1.12.3
chardet 3.0.4
Click 7.0
cloudpickle 1.2.2
clyent 1.2.2
colorama 0.4.1
comtypes 1.1.7
conda 4.7.12
conda-build 3.18.9
conda-package-handling 1.6.0
conda-verify 3.4.2
contextlib2 0.6.0
cryptography 2.7
cycler 0.10.0
Cython 0.29.13
cytoolz 0.10.0
dask 2.5.2
decorator 4.4.0
defusedxml 0.6.0
distributed 2.5.2
docutils 0.15.2
entrypoints 0.3
et-xmlfile 1.0.1
fastcache 1.1.0
filelock 3.0.12
Flask 1.1.1
fsspec 0.5.2
future 0.17.1
gevent 1.4.0
glob2 0.7
greenlet 0.4.15
h5py 2.9.0
HeapDict 1.0.1
html5lib 1.0.1
idna 2.8
imageio 2.6.0
imagesize 1.1.0
importlib-metadata 0.23
ipykernel 5.1.2
ipython 7.8.0
ipython-genutils 0.2.0
ipywidgets 7.5.1
isort 4.3.21
itsdangerous 1.1.0
jdcal 1.4.1
jedi 0.15.1
Jinja2 2.10.3
joblib 0.13.2
json5 0.8.5
jsonschema 3.0.2
jupyter 1.0.0
jupyter-client 5.3.3
jupyter-console 6.0.0
jupyter-core 4.5.0
jupyterlab 1.1.4
jupyterlab-server 1.0.6
keyring 18.0.0
kiwisolver 1.1.0
lazy-object-proxy 1.4.2
libarchive-c 2.8
llvmlite 0.29.0
locket 0.2.0
lxml 4.4.1
MarkupSafe 1.1.1
matplotlib 3.1.1
mccabe 0.6.1
menuinst 1.4.16
mistune 0.8.4
mkl-fft 1.0.14
mkl-random 1.1.0
mkl-service 2.3.0
mock 3.0.5
more-itertools 7.2.0
mpmath 1.1.0
msgpack 0.6.1
multipledispatch 0.6.0
navigator-updater 0.2.1
nbconvert 5.6.0
nbformat 4.4.0
networkx 2.3
nltk 3.4.5
nose 1.3.7
notebook 6.0.1
numba 0.45.1
numexpr 2.7.0
numpy 1.16.5
numpydoc 0.9.1
olefile 0.46
openpyxl 3.0.0
packaging 19.2
pandas 0.25.1
pandocfilters 1.4.2
parso 0.5.1
partd 1.0.0
path.py 12.0.1
pathlib2 2.3.5
patsy 0.5.1
pep8 1.7.1
pickleshare 0.7.5
Pillow 6.2.0
pip 19.2.3
pkginfo 1.5.0.1
pluggy 0.13.0
ply 3.11
progressbar2 3.42.0
prometheus-client 0.7.1
prompt-toolkit 2.0.10
psutil 5.6.3
py 1.8.0
pycodestyle 2.5.0
pycosat 0.6.3
pycparser 2.19
pycrypto 2.6.1
pycurl 7.43.0.3
pyflakes 2.1.1
Pygments 2.4.2
pykg2vec 0.0.48
pylint 2.4.2
pyodbc 4.0.27
pyOpenSSL 19.0.0
pyparsing 2.4.2
pyreadline 2.1
pyrsistent 0.15.4
PySocks 1.7.1
pytest 5.2.1
pytest-arraydiff 0.3
pytest-astropy 0.5.0
pytest-doctestplus 0.4.0
pytest-openfiles 0.4.0
pytest-remotedata 0.3.2
python-dateutil 2.8.0
python-utils 2.3.0
pytz 2019.3
PyWavelets 1.0.3
pywin32 223
pywinpty 0.5.5
PyYAML 5.1.2
pyzmq 18.1.0
QtAwesome 0.6.0
qtconsole 4.5.5
QtPy 1.9.0
requests 2.22.0
rope 0.14.0
ruamel-yaml 0.15.46
scikit-image 0.15.0
scikit-learn 0.21.3
scipy 1.3.1
seaborn 0.9.0
Send2Trash 1.5.0
setuptools 41.4.0
simplegeneric 0.8.1
singledispatch 3.4.0.3
six 1.12.0
snowballstemmer 2.0.0
sortedcollections 1.1.2
sortedcontainers 2.1.0
soupsieve 1.9.3
Sphinx 2.2.0
sphinx-gallery 0.4.0
sphinx-rtd-theme 0.4.3
sphinxcontrib-applehelp 1.0.1
sphinxcontrib-devhelp 1.0.1
sphinxcontrib-htmlhelp 1.0.2
sphinxcontrib-jsmath 1.0.1
sphinxcontrib-qthelp 1.0.2
sphinxcontrib-serializinghtml 1.1.3
sphinxcontrib-websupport 1.1.2
spyder 3.3.6
spyder-kernels 0.5.2
SQLAlchemy 1.3.9
statsmodels 0.10.1
sympy 1.4
tables 3.5.2
tblib 1.4.0
terminado 0.8.2
testpath 0.4.2
toolz 0.10.0
tornado 6.0.3
tqdm 4.36.1
traitlets 4.3.3
unicodecsv 0.14.1
urllib3 1.24.2
wcwidth 0.1.7
webencodings 0.5.1
Werkzeug 0.16.0
wheel 0.33.6
widgetsnbextension 3.5.1
win-inet-pton 1.1.0
win-unicode-console 0.5
wincertstore 0.2
wrapt 1.11.2
xlrd 1.2.0
XlsxWriter 1.2.1
xlwings 0.15.10
xlwt 1.3.0
zict 1.0.0
zipp 0.6.0
conda lsit gives me this:
_ipyw_jlab_nb_ext_conf 0.1.0 py37_0
alabaster 0.7.12 py37_0
anaconda 2019.10 py37_0
anaconda-client 1.7.2 py37_0
anaconda-navigator 1.9.7 py37_0
anaconda-project 0.8.3 py_0
asn1crypto 1.0.1 py37_0
astroid 2.3.1 py37_0
astropy 3.2.1 py37he774522_0
atomicwrites 1.3.0 py37_1
attrs 19.2.0 py_0
babel 2.7.0 py_0
backcall 0.1.0 py37_0
backports 1.0 py_2
backports.functools_lru_cache 1.5 py_2
backports.os 0.1.1 py37_0
backports.shutil_get_terminal_size 1.0.0 py37_2
backports.tempfile 1.0 py_1
backports.weakref 1.0.post1 py_1
beautifulsoup4 4.8.0 py37_0
bitarray 1.0.1 py37he774522_0
bkcharts 0.2 py37_0
blas 1.0 mkl
bleach 3.1.0 py37_0
blosc 1.16.3 h7bd577a_0
bokeh 1.3.4 py37_0
boto 2.49.0 py37_0
bottleneck 1.2.1 py37h452e1ab_1
bzip2 1.0.8 he774522_0
ca-certificates 2019.8.28 0
certifi 2019.9.11 py37_0
cffi 1.12.3 py37h7a1dbc1_0
chardet 3.0.4 py37_1003
click 7.0 py37_0
cloudpickle 1.2.2 py_0
clyent 1.2.2 py37_1
colorama 0.4.1 py37_0
comtypes 1.1.7 py37_0
conda 4.7.12 py37_0
conda-build 3.18.9 py37_3
conda-env 2.6.0 1
conda-package-handling 1.6.0 py37h62dcd97_0
conda-verify 3.4.2 py_1
console_shortcut 0.1.1 3
contextlib2 0.6.0 py_0
cryptography 2.7 py37h7a1dbc1_0
curl 7.65.3 h2a8f88b_0
cycler 0.10.0 py37_0
cython 0.29.13 py37ha925a31_0
cytoolz 0.10.0 py37he774522_0
dask 2.5.2 py_0
dask-core 2.5.2 py_0
decorator 4.4.0 py37_1
defusedxml 0.6.0 py_0
distributed 2.5.2 py_0
docutils 0.15.2 py37_0
entrypoints 0.3 py37_0
et_xmlfile 1.0.1 py37_0
fastcache 1.1.0 py37he774522_0
filelock 3.0.12 py_0
flask 1.1.1 py_0
freetype 2.9.1 ha9979f8_1
fsspec 0.5.2 py_0
future 0.17.1 py37_0
get_terminal_size 1.0.0 h38e98db_0
gevent 1.4.0 py37he774522_0
glob2 0.7 py_0
greenlet 0.4.15 py37hfa6e2cd_0
h5py 2.9.0 py37h5e291fa_0
hdf5 1.10.4 h7ebc959_0
heapdict 1.0.1 py_0
html5lib 1.0.1 py37_0
icc_rt 2019.0.0 h0cc432a_1
icu 58.2 ha66f8fd_1
idna 2.8 py37_0
imageio 2.6.0 py37_0
imagesize 1.1.0 py37_0
importlib_metadata 0.23 py37_0
intel-openmp 2019.4 245
ipykernel 5.1.2 py37h39e3cac_0
ipython 7.8.0 py37h39e3cac_0
ipython_genutils 0.2.0 py37_0
ipywidgets 7.5.1 py_0
isort 4.3.21 py37_0
itsdangerous 1.1.0 py37_0
jdcal 1.4.1 py_0
jedi 0.15.1 py37_0
jinja2 2.10.3 py_0
joblib 0.13.2 py37_0
jpeg 9b hb83a4c4_2
json5 0.8.5 py_0
jsonschema 3.0.2 py37_0
jupyter 1.0.0 py37_7
jupyter_client 5.3.3 py37_1
jupyter_console 6.0.0 py37_0
jupyter_core 4.5.0 py_0
jupyterlab 1.1.4 pyhf63ae98_0
jupyterlab_server 1.0.6 py_0
keyring 18.0.0 py37_0
kiwisolver 1.1.0 py37ha925a31_0
krb5 1.16.1 hc04afaa_7
lazy-object-proxy 1.4.2 py37he774522_0
libarchive 3.3.3 h0643e63_5
libcurl 7.65.3 h2a8f88b_0
libiconv 1.15 h1df5818_7
liblief 0.9.0 ha925a31_2
libpng 1.6.37 h2a8f88b_0
libsodium 1.0.16 h9d3ae62_0
libssh2 1.8.2 h7a1dbc1_0
libtiff 4.0.10 hb898794_2
libxml2 2.9.9 h464c3ec_0
libxslt 1.1.33 h579f668_0
llvmlite 0.29.0 py37ha925a31_0
locket 0.2.0 py37_1
lxml 4.4.1 py37h1350720_0
lz4-c 1.8.1.2 h2fa13f4_0
lzo 2.10 h6df0209_2
m2w64-gcc-libgfortran 5.3.0 6
m2w64-gcc-libs 5.3.0 7
m2w64-gcc-libs-core 5.3.0 7
m2w64-gmp 6.1.0 2
m2w64-libwinpthread-git 5.0.0.4634.697f757 2
markupsafe 1.1.1 py37he774522_0
matplotlib 3.1.1 py37hc8f65d3_0
mccabe 0.6.1 py37_1
menuinst 1.4.16 py37he774522_0
mistune 0.8.4 py37he774522_0
mkl 2019.4 245
mkl-service 2.3.0 py37hb782905_0
mkl_fft 1.0.14 py37h14836fe_0
mkl_random 1.1.0 py37h675688f_0
mock 3.0.5 py37_0
more-itertools 7.2.0 py37_0
mpmath 1.1.0 py37_0
msgpack-python 0.6.1 py37h74a9793_1
msys2-conda-epoch 20160418 1
multipledispatch 0.6.0 py37_0
navigator-updater 0.2.1 py37_0
nbconvert 5.6.0 py37_1
nbformat 4.4.0 py37_0
networkx 2.3 py_0
nltk 3.4.5 py37_0
nose 1.3.7 py37_2
notebook 6.0.1 py37_0
numba 0.45.1 py37hf9181ef_0
numexpr 2.7.0 py37hdce8814_0
numpy 1.16.5 py37h19fb1c0_0
numpy-base 1.16.5 py37hc3f5095_0
numpydoc 0.9.1 py_0
olefile 0.46 py37_0
openpyxl 3.0.0 py_0
openssl 1.1.1d he774522_2
packaging 19.2 py_0
pandas 0.25.1 py37ha925a31_0
pandoc 2.2.3.2 0
pandocfilters 1.4.2 py37_1
parso 0.5.1 py_0
partd 1.0.0 py_0
path.py 12.0.1 py_0
pathlib2 2.3.5 py37_0
patsy 0.5.1 py37_0
pep8 1.7.1 py37_0
pickleshare 0.7.5 py37_0
pillow 6.2.0 py37hdc69c19_0
pip 19.2.3 py37_0
pkginfo 1.5.0.1 py37_0
pluggy 0.13.0 py37_0
ply 3.11 py37_0
powershell_shortcut 0.0.1 2
prometheus_client 0.7.1 py_0
prompt_toolkit 2.0.10 py_0
psutil 5.6.3 py37he774522_0
py 1.8.0 py37_0
py-lief 0.9.0 py37ha925a31_2
pycodestyle 2.5.0 py37_0
pycosat 0.6.3 py37hfa6e2cd_0
pycparser 2.19 py37_0
pycrypto 2.6.1 py37hfa6e2cd_9
pycurl 7.43.0.3 py37h7a1dbc1_0
pyflakes 2.1.1 py37_0
pygments 2.4.2 py_0
pylint 2.4.2 py37_0
pyodbc 4.0.27 py37ha925a31_0
pyopenssl 19.0.0 py37_0
pyparsing 2.4.2 py_0
pyqt 5.9.2 py37h6538335_2
pyreadline 2.1 py37_1
pyrsistent 0.15.4 py37he774522_0
pysocks 1.7.1 py37_0
pytables 3.5.2 py37h1da0976_1
pytest 5.2.1 py37_0
pytest-arraydiff 0.3 py37h39e3cac_0
pytest-astropy 0.5.0 py37_0
pytest-doctestplus 0.4.0 py_0
pytest-openfiles 0.4.0 py_0
pytest-remotedata 0.3.2 py37_0
python 3.7.4 h5263a28_0
python-dateutil 2.8.0 py37_0
python-libarchive-c 2.8 py37_13
pytz 2019.3 py_0
pywavelets 1.0.3 py37h8c2d366_1
pywin32 223 py37hfa6e2cd_1
pywinpty 0.5.5 py37_1000
pyyaml 5.1.2 py37he774522_0
pyzmq 18.1.0 py37ha925a31_0
qt 5.9.7 vc14h73c81de_0
qtawesome 0.6.0 py_0
qtconsole 4.5.5 py_0
qtpy 1.9.0 py_0
requests 2.22.0 py37_0
rope 0.14.0 py_0
ruamel_yaml 0.15.46 py37hfa6e2cd_0
scikit-image 0.15.0 py37ha925a31_0
scikit-learn 0.21.3 py37h6288b17_0
scipy 1.3.1 py37h29ff71c_0
seaborn 0.9.0 py37_0
send2trash 1.5.0 py37_0
setuptools 41.4.0 py37_0
simplegeneric 0.8.1 py37_2
singledispatch 3.4.0.3 py37_0
sip 4.19.8 py37h6538335_0
six 1.12.0 py37_0
snappy 1.1.7 h777316e_3
snowballstemmer 2.0.0 py_0
sortedcollections 1.1.2 py37_0
sortedcontainers 2.1.0 py37_0
soupsieve 1.9.3 py37_0
sphinx 2.2.0 py_0
sphinxcontrib 1.0 py37_1
sphinxcontrib-applehelp 1.0.1 py_0
sphinxcontrib-devhelp 1.0.1 py_0
sphinxcontrib-htmlhelp 1.0.2 py_0
sphinxcontrib-jsmath 1.0.1 py_0
sphinxcontrib-qthelp 1.0.2 py_0
sphinxcontrib-serializinghtml 1.1.3 py_0
sphinxcontrib-websupport 1.1.2 py_0
spyder 3.3.6 py37_0
spyder-kernels 0.5.2 py37_0
sqlalchemy 1.3.9 py37he774522_0
sqlite 3.30.0 he774522_0
statsmodels 0.10.1 py37h8c2d366_0
sympy 1.4 py37_0
tbb 2019.4 h74a9793_0
tblib 1.4.0 py_0
terminado 0.8.2 py37_0
testpath 0.4.2 py37_0
tk 8.6.8 hfa6e2cd_0
toolz 0.10.0 py_0
tornado 6.0.3 py37he774522_0
tqdm 4.36.1 py_0
traitlets 4.3.3 py37_0
unicodecsv 0.14.1 py37_0
urllib3 1.24.2 py37_0
vc 14.1 h0510ff6_4
vs2015_runtime 14.16.27012 hf0eaf9b_0
wcwidth 0.1.7 py37_0
webencodings 0.5.1 py37_1
werkzeug 0.16.0 py_0
wheel 0.33.6 py37_0
widgetsnbextension 3.5.1 py37_0
win_inet_pton 1.1.0 py37_0
win_unicode_console 0.5 py37_0
wincertstore 0.2 py37_0
winpty 0.4.3 4
wrapt 1.11.2 py37he774522_0
xlrd 1.2.0 py37_0
xlsxwriter 1.2.1 py_0
xlwings 0.15.10 py37_0
xlwt 1.3.0 py37_0
xz 5.2.4 h2fa13f4_4
yaml 0.1.7 hc54c509_2
zeromq 4.3.1 h33f27b4_3
zict 1.0.0 py_0
zipp 0.6.0 py_0
zlib 1.2.11 h62dcd97_3
zstd 1.3.7 h508b16e_0
as you see there is something suspicious here in pip list:
-atplotlib
I do not know what is that! it
looks like matplotlib without first letter m
I have search a lot and did a lot of efforts based on this
Getting an error that reads: ModuleNotFoundError: No module named 'matplotlib.artist'
https://github.com/matplotlib/matplotlib/issues/6771/
like, reinstall matplotlib, reinstall anaconda ...
but it does not work! In my view, it might be something related to the path, but I can not find the solution.
I also uninstall my anaconda two times still have the problem!
any suggestion would be appreciated
Go to this location
~\AppData\Roaming\Python\Python37\site-packages\
There will be two folders named as
~atplotlib
and
matplotlib
Please rename ~atplotlib to matplotlib
The system will ask you that there is another folder with the same name, so do you want to merge.
Select merge option.
In my case, this resolved the matter.
I also had similar problem, the below command solved the problem, run it in anaconda command prompt.
conda install matplotlib --force
source: https://github.com/matplotlib/matplotlib/issues/6771/
I had the same problem using Python 3.9. I had no folder named ~atplotlib so I couldn't merge it as suggested. I however found ~andas (pandas) in site-packages which I attempted to merge but was unsuccessful.
I uninstalled matplotlib using "pip uninstall matplotlib" and then reinstalled pandas after removing all pandas folders in site-packages. I noticed the numpy was included at the same time and created a new folder ~umpy so now I just removed everything again that contained numpy, pandas or matplotlib from site-packages (after uninstalling via pip).
Then I installed the modules in the order pandas, (numpy included), matplotlib using pip. And now finally it works. Utterly confusing.
I have done all steps including uninstalling,
How to remove anaconda from windows completely?
using anaconda clean,
completely removing all folder related to python in C:\Users\myusdername
removing from path
uninstall by anaconda
I just nopticed that the error says that
AppData\Roaming\Python\Python37\site-packages\matplotlib\pyplot.py
I manually remove python form the
AppData\Roaming\Python\Python37
r=then it works!!
I face the same problem and I used the below command. Please use this command in Anaconda prompt.
>conda install matplotlib
after upgrading Matplotlib check this as well
Go to this location
~\AppData\Roaming\Python\Python37\site-packages\
and check the folder name ..
for some weird reason matplotlib is saved as ~atplotlib folder.
just rename ~atplotlib folder as matplotlib
I had the same problem. Resolved by installing the 'matplotlib-base" in anaconda.
Follow the below steps for the same:
Open Anaconda navigator
Choose the "Environments"
Choose "base(root)" environment
select the option "All" then Search for "matplotlib"
choose matplotlib-base Then Click on botton
Restart your JuputerNotebook kernal and then import the matplotlib

Troubles using JupyterNotebook

im having troubles while using JupyterNotebook.
When I try to import SciPy and NumPy while using JupyterNotebook im always getting Errors:
import scipy as sp
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
<ipython-input-1-6b0df46be2d8> in <module>
----> 1 import scipy as sp
~\Anaconda3\envs\MachineL\lib\site-packages\scipy\__init__.py in <module>
60 __all__ = ['test']
61
---> 62 from numpy import show_config as show_numpy_config
63 if show_numpy_config is None:
64 raise ImportError(
ImportError: cannot import name 'show_config'
And when I try to check if NumPy works:
import numpy as np
print("I like", np.pi)
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
<ipython-input-1-dbcfc58336e0> in <module>
1 import numpy as np
----> 2 print("I like", np.pi)
AttributeError: module 'numpy' has no attribute 'pi'
But the really confusing thing is that everything works when I try everything in a terminal.
>>> import scipy as sp
>>> print(sp.__version__)
1.3.1
or
>>> import numpy as np
>>> print("I like", np.pi)
I like 3.141592653589793
And I dont know what the problem could be...
I first thought that my JupyterNotebook would use a different VirtualEnvironment so I tried this:
(In JupyterNotebook):
pip list
Package Version
-------------------- ---------
absl-py 0.8.1
astor 0.8.0
attrs 19.2.0
backcall 0.1.0
bleach 3.1.0
certifi 2019.9.11
colorama 0.4.1
cycler 0.10.0
decorator 4.4.0
defusedxml 0.6.0
entrypoints 0.3
gast 0.2.2
google-pasta 0.1.7
grpcio 1.24.1
h5py 2.10.0
ipykernel 5.1.2
ipython 7.8.0
ipython-genutils 0.2.0
jedi 0.15.1
Jinja2 2.10.3
jsonschema 3.0.2
jupyter-client 5.3.4
jupyter-core 4.6.0
Keras-Applications 1.0.8
Keras-Preprocessing 1.1.0
kiwisolver 1.1.0
Markdown 3.1.1
MarkupSafe 1.1.1
matplotlib 3.1.1
mistune 0.8.4
nbconvert 5.6.0
nbformat 4.4.0
notebook 6.0.1
numpy 1.17.3
opt-einsum 3.1.0
pandas 0.25.1
pandocfilters 1.4.2
parso 0.5.1
pickleshare 0.7.5
pip 19.2.3
prometheus-client 0.7.1
prompt-toolkit 2.0.10
protobuf 3.10.0
Pygments 2.4.2
pyparsing 2.4.2
pyrsistent 0.15.4
python-dateutil 2.8.0
pytz 2019.3
pywin32 223
pywinpty 0.5.5
pyzmq 18.1.0
scipy 1.3.1
Send2Trash 1.5.0
setuptools 41.4.0
six 1.12.0
tensorboard 2.0.0
tensorflow 2.0.0
tensorflow-estimator 2.0.0
termcolor 1.1.0
terminado 0.8.2
testpath 0.4.2
tornado 6.0.3
traitlets 4.3.3
wcwidth 0.1.7
webencodings 0.5.1
Werkzeug 0.16.0
wheel 0.33.6
wincertstore 0.2
wrapt 1.11.2
And then I tried the same thing in my VirtualEnvironment:
Package Version
-------------------- ---------
absl-py 0.8.1
astor 0.8.0
attrs 19.2.0
backcall 0.1.0
bleach 3.1.0
certifi 2019.9.11
colorama 0.4.1
cycler 0.10.0
decorator 4.4.0
defusedxml 0.6.0
entrypoints 0.3
gast 0.2.2
google-pasta 0.1.7
grpcio 1.24.1
h5py 2.10.0
ipykernel 5.1.2
ipython 7.8.0
ipython-genutils 0.2.0
jedi 0.15.1
Jinja2 2.10.3
jsonschema 3.0.2
jupyter-client 5.3.4
jupyter-core 4.6.0
Keras-Applications 1.0.8
Keras-Preprocessing 1.1.0
kiwisolver 1.1.0
Markdown 3.1.1
MarkupSafe 1.1.1
matplotlib 3.1.1
mistune 0.8.4
nbconvert 5.6.0
nbformat 4.4.0
notebook 6.0.1
numpy 1.17.3
opt-einsum 3.1.0
pandas 0.25.1
pandocfilters 1.4.2
parso 0.5.1
pickleshare 0.7.5
pip 19.2.3
prometheus-client 0.7.1
prompt-toolkit 2.0.10
protobuf 3.10.0
Pygments 2.4.2
pyparsing 2.4.2
pyrsistent 0.15.4
python-dateutil 2.8.0
pytz 2019.3
pywin32 223
pywinpty 0.5.5
pyzmq 18.1.0
scipy 1.3.1
Send2Trash 1.5.0
setuptools 41.4.0
six 1.12.0
tensorboard 2.0.0
tensorflow 2.0.0
tensorflow-estimator 2.0.0
termcolor 1.1.0
terminado 0.8.2
testpath 0.4.2
tornado 6.0.3
traitlets 4.3.3
wcwidth 0.1.7
webencodings 0.5.1
Werkzeug 0.16.0
wheel 0.33.6
wincertstore 0.2
wrapt 1.11.2
The python version im using:
import sys
print(sys.version)
3.6.9 |Anaconda, Inc.| (default, Jul 30 2019, 14:00:49) [MSC v.1915 64 bit (AMD64)]
This output is equally to the output of my terminal
And after I tried this I was pretty sure that both use the same VirtualEnvironment, so I dont really know what I should try anymore.
Thank you for your time, I hope anybody can help me.
Is there perhaps a numpy.py script anywhere in your Jupiter notebook directory? This could be taking priority over the actual numpy module. Try to change the directory that your working in with your jupiter notebook and restart the kernel I believe this will solve the issue.

Import error of contextily package in python

I installed the package contextily with pip install contextily, it appears when I do conda list
# Name Version Build Channel
_ipyw_jlab_nb_ext_conf 0.1.0 py36h2fc01ae_0
affine 2.2.2 py_0 conda-forge
alabaster 0.7.10 py36h174008c_0
anaconda-client 1.7.2 py36_0
anaconda-navigator 1.9.6 py36_0
anaconda-project 0.8.2 py36h9ee5d53_0
appnope 0.1.0 py36hf537a9a_0
appscript 1.0.1 py36h9e71e49_1
arrow 0.13.1 pypi_0 pypi
asn1crypto 0.24.0 py36_0
astroid 1.6.1 py36_0
astropy 2.0.3 py36h1de35cc_0
attrs 17.4.0 py36_0
autobahn 18.6.1 pypi_0 pypi
babel 2.5.3 py36_0
backports 1.0 py36ha3c1827_1
backports.shutil_get_terminal_size 1.0.0 py36hd7a2ee4_2
beautifulsoup4 4.6.0 py36h72d3c9f_1
bitarray 0.8.1 py36h1de35cc_1
bkcharts 0.2 py36h073222e_0
blas 1.0 mkl
blaze 0.11.3 py36h02e7a37_0
bleach 2.1.2 py36_0
bokeh 0.12.13 py36h2f9c1c0_0
boost-cpp 1.67.0 h3a22d5f_0 conda-forge
boto 2.48.0 py36hdbc59ac_1
boto3 1.9.111 py_0 conda-forge
botocore 1.12.111 py_0 conda-forge
bottleneck 1.2.1 py36hbd380ad_0
branca 0.3.1 pypi_0 pypi
bzip2 1.0.6 hd86a083_4
ca-certificates 2019.3.9 hecc5488_0 conda-forge
cairo 1.14.12 hab642c4_1
cartopy 0.17.0 py36h707127b_1000 conda-forge
certifi 2019.3.9 py36_0 conda-forge
cffi 1.11.4 py36h342bebf_0
chardet 3.0.4 py36h96c241c_1
click 6.7 py36hec950be_0
click-plugins 1.0.4 py_0 conda-forge
cligj 0.5.0 pypi_0 pypi
cloudpickle 0.5.2 py36_1
clyent 1.2.2 py36hae3ad88_0
colorama 0.3.9 py36hd29a30c_0
conda 4.4.10 py36_0
conda-build 3.4.1 py36_0
conda-env 2.6.0 h36134e3_0
conda-verify 2.0.0 py36he837df3_0
contextily 0.99.0 pypi_0 pypi
contextlib2 0.5.5 py36hd66e5e7_0
cryptography 2.1.4 py36h842514c_0
curl 7.58.0 ha441bb4_0
cycler 0.10.0 py36hfc81398_0
cython 0.27.3 py36h6ecb376_0
cytoolz 0.9.0 py36h1de35cc_0
dask 0.16.1 py36_0
dask-core 0.16.1 py36_0
datashape 0.5.4 py36hfb22df8_0
dbus 1.12.2 h5243cc1_1
decorator 4.2.1 py36_0
descartes 1.1.0 pypi_0 pypi
distributed 1.20.2 py36_0
docutils 0.14 py36hbfde631_0
drawnow 0.71.2 pypi_0 pypi
entrypoints 0.2.3 py36hd81d71f_2
et_xmlfile 1.0.1 py36h1315bdc_0
expat 2.2.5 hb8e80ba_0
fastcache 1.0.2 py36h1de35cc_2
filelock 2.0.13 py36hf9de95b_0
fiona 1.8.6 pypi_0 pypi
flask 0.12.2 py36h5658096_0
flask-cors 3.0.3 py36h7387b97_0
folium 0.8.2 pypi_0 pypi
fontconfig 2.12.6 h9850fc5_0
freetype 2.8 h12048fb_1
freexl 1.0.5 h1de35cc_1002 conda-forge
geographiclib 1.49 py_0 conda-forge
geopandas 0.4.1 pypi_0 pypi
geopy 1.18.1 py_0 conda-forge
geos 3.6.2 h0a44026_1004 conda-forge
get_terminal_size 1.0.0 h7520d66_0
gettext 0.19.8.1 h15daf44_3
gevent 1.2.2 py36ha70b9d6_0
giflib 5.1.4 h1de35cc_1001 conda-forge
glib 2.53.6 h33f6a65_2
glob2 0.6 py36h94c9186_0
gmp 6.1.2 hb37e062_1
gmpy2 2.0.8 py36hf9c35bd_2
greenlet 0.4.12 py36hf09ba7b_0
h5py 2.7.1 py36h39cdac5_0
hdf4 4.2.13 0 conda-forge
hdf5 1.10.1 ha036c08_1
heapdict 1.0.0 py36_2
html5lib 1.0.1 py36h2f9c1c0_0
icu 58.2 h4b95b61_1
idna 2.6 py36h8628d0a_1
imageio 2.2.0 py36h5e01289_0
imagesize 0.7.1 py36h3495948_0
intel-openmp 2018.0.0 h8158457_8
ipykernel 4.8.0 py36_0
ipython 6.2.1 py36h3dda519_1
ipython_genutils 0.2.0 py36h241746c_0
ipywidgets 7.1.1 py36_0
isort 4.2.15 py36hceb2a01_0
itsdangerous 0.24 py36h49fbb8d_1
jbig 2.1 h4d881f8_0
jdcal 1.3 py36h1986823_0
jedi 0.11.1 py36_0
jinja2 2.10 py36hd36f9c5_0
jmespath 0.9.3 py_1 conda-forge
jpeg 9b he5867d9_2
json-c 0.12.1 h470a237_1 conda-forge
jsonschema 2.6.0 py36hb385e00_0
jupyter 1.0.0 py36_4
jupyter_client 5.2.2 py36_0
jupyter_console 5.2.0 py36hccf5b1c_1
jupyter_core 4.4.0 py36h79cf704_0
jupyterlab 0.31.5 py36_0
jupyterlab_launcher 0.10.2 py36_0
kealib 1.4.8 hfc679d8_0 conda-forge
kiwisolver 1.0.1 py36h04f5b5a_1002 conda-forge
lazy-object-proxy 1.3.1 py36h2fbbe47_0
libcurl 7.58.0 hf30b1f0_0
libcxx 4.0.1 h579ed51_0
libcxxabi 4.0.1 hebd6815_0
libdap4 3.19.1 0 conda-forge
libedit 3.1 hb4e282d_0
libffi 3.2.1 h475c297_4
libgdal 2.2.2 h3559a57_1
libgfortran 3.0.1 h93005f0_2
libiconv 1.15 hdd342a3_7
libkml 1.3.0 h677b1dd_1008 conda-forge
libnetcdf 4.4.1.1 10 conda-forge
libpng 1.6.34 he12f830_0
libpq 10.6 hbe1e24e_1000 conda-forge
libsodium 1.0.15 hd9e47c5_0
libspatialite 4.3.0a h0a2fa02_18
libssh2 1.8.0 h322a93b_4
libtiff 4.0.9 h0dac147_0
libxml2 2.9.7 hab757c2_0
libxslt 1.1.32 hb819dd2_0
llvmlite 0.21.0 py36hff739e7_0
locket 0.2.0 py36hca03003_1
lxml 4.1.1 py36hef8c89e_1
lzo 2.10 h362108e_2
markupsafe 1.0 py36h3a1e703_1
matplotlib 3.0.3 pypi_0 pypi
mccabe 0.6.1 py36hdaeb55d_0
mercantile 1.0.4 py_0 conda-forge
mistune 0.8.3 py36_0
mkl 2018.0.1 hfbd8650_4
mkl-service 1.1.2 py36h7ea6df4_4
mpc 1.0.3 h7a72875_5
mpfr 3.1.5 h711e7fd_2
mpmath 1.0.0 py36hf1b8295_2
msgpack-python 0.5.1 py36h04f5b5a_0
multipledispatch 0.4.9 py36hc5f92b5_0
munch 2.3.2 pypi_0 pypi
navigator-updater 0.1.0 py36h7aee5fb_0
nbconvert 5.3.1 py36h810822e_0
nbformat 4.4.0 py36h827af21_0
ncurses 6.0 hd04f020_2
networkx 2.1 py36_0
nltk 3.2.5 py36h1190bce_0
nose 1.3.7 py36h73fae2b_2
notebook 5.4.0 py36_0
numba 0.36.2 np114py36hc2f221f_0
numexpr 2.6.4 py36habcfcfe_0
numpy 1.14.2 py36ha9ae307_0
numpydoc 0.7.0 py36he54d08e_0
odo 0.5.1 py36hc1af34a_0
olefile 0.45.1 py36_0
openjpeg 2.3.0 h3bf0609_1003 conda-forge
openpyxl 2.4.10 py36_0
openssl 1.0.2r h1de35cc_0 conda-forge
owslib 0.17.1 py_0 conda-forge
packaging 16.8 py36he5e8135_0
pandas 0.24.1 py36h0a44026_0 conda-forge
pandoc 1.19.2.1 ha5e8f32_1
pandocfilters 1.4.2 py36h3b0b094_1
parso 0.1.1 py36hc90e01c_0
partd 0.3.8 py36hf5c4cb8_0
path.py 10.5 py36h7bcb313_0
pathlib2 2.3.0 py36h877a6d8_0
patsy 0.5.0 py36_0
pcre 8.41 hfb6ab37_1
pep8 1.7.1 py36_0
pexpect 4.3.1 py36_0
pickleshare 0.7.4 py36hf512f8e_0
pillow 5.0.0 py36hfcce615_0
pip 19.0.3 pypi_0 pypi
pixman 0.34.0 h1de35cc_1003 conda-forge
pkginfo 1.4.1 py36h25bf955_0
place 0.5.5 pypi_0 pypi
pluggy 0.6.0 py36hb1d0581_0
ply 3.10 py36h10e714e_0
poppler 0.60.1 hb654a48_0
poppler-data 0.4.9 1 conda-forge
proj 0.1.0 pypi_0 pypi
proj4 4.9.3 h470a237_8 conda-forge
prompt_toolkit 1.0.15 py36haeda067_0
psutil 5.4.3 py36h1de35cc_0
ptyprocess 0.5.2 py36he6521c3_0
py 1.5.2 py36ha69170d_0
pycodestyle 2.3.1 py36h83e8646_0
pycosat 0.6.3 py36hee92d8f_0
pycparser 2.18 py36h724b2fc_1
pycrypto 2.6.1 py36h1de35cc_7
pycurl 7.43.0.1 py36hdbc3d79_0
pyepsg 0.4.0 py_0 conda-forge
pyflakes 1.6.0 py36hea45e83_0
pygments 2.2.0 py36h240cd3f_0
pykdtree 1.3.1 py36h917ab60_1002 conda-forge
pylint 1.8.2 py36_0
pyodbc 4.0.22 py36h0a44026_0
pyopenssl 17.5.0 py36h51e4350_0
pyparsing 2.2.0 py36hb281f35_0
pyproj 1.9.6 pypi_0 pypi
pyqt 5.6.0 py36he5c6137_6
pyserial 3.4 pypi_0 pypi
pyshp 2.1.0 py_0 conda-forge
pysocks 1.6.7 py36hfa33cec_1
pytables 3.4.2 py36hfbd7ab0_2
pytest 3.3.2 py36_0
python 3.6.4 hc167b69_1
python-dateutil 2.6.1 py36h86d2abb_1
python.app 2 py36h54569d5_7
pytz 2017.3 py36hf0bf824_0
pywavelets 0.5.2 py36h2710a04_0
pyyaml 3.12 py36h2ba1e63_1
pyzmq 16.0.3 py36he48b5ad_0
qt 5.6.2 h9975529_14
qtawesome 0.4.4 py36h468c6fb_0
qtconsole 4.3.1 py36hd96c0ff_0
qtpy 1.6.0 py_0
rasterio 0.36.0 py36h01fd17b_1
readline 7.0 hc1231fa_4
requests 2.18.4 py36h4516966_1
rope 0.10.7 py36h68959ac_0
ruamel_yaml 0.15.35 py36h1de35cc_1
s3transfer 0.2.0 py36_0 conda-forge
scikit-image 0.13.1 py36h1de35cc_1
scikit-learn 0.19.1 py36hffbff8c_0
scipy 1.0.0 py36h1de22e9_0
seaborn 0.8.1 py36h595ecd9_0
send2trash 1.4.2 py36_0
setuptools 38.4.0 py36_0
shapely 1.6.4 py36h2e8a847_1000 conda-forge
simplegeneric 0.8.1 py36_2
singledispatch 3.4.0.3 py36hf20db9d_0
sip 4.18.1 py36h2824476_2
six 1.11.0 py36h0e22d5e_1
snowballstemmer 1.2.1 py36h6c7b616_0
snuggs 1.4.3 py_0 conda-forge
sortedcollections 0.5.3 py36he9c3ed6_0
sortedcontainers 1.5.9 py36_0
sphinx 1.6.6 py36_0
sphinxcontrib 1.0 py36h9364dc8_1
sphinxcontrib-websupport 1.0.1 py36h92f4a7a_1
spyder 3.2.6 py36_0
sqlalchemy 1.2.1 py36h1de35cc_0
sqlite 3.22.0 h3efe00b_0
statsmodels 0.8.0 py36h9c68fc9_0
sympy 1.1.1 py36h7f3cf04_0
tblib 1.3.2 py36hda67792_0
terminado 0.8.1 py36_1
testpath 0.3.1 py36h625a49b_0
tk 8.6.7 h35a86e2_3
toolz 0.9.0 py36_0
tornado 4.5.3 py36_0
traitlets 4.3.2 py36h65bd3ce_0
txaio 2.10.0 pypi_0 pypi
typing 3.6.2 py36haa2d9ef_0
unicodecsv 0.14.1 py36he531d66_0
unixodbc 2.3.4 h4cb4dde_1
urllib3 1.22 py36h68b9469_0
vpnotebook 0.1.3 pypi_0 pypi
vpython 7.4.4 pypi_0 pypi
wcwidth 0.1.7 py36h8c6ec74_0
webencodings 0.5.1 py36h3b9701d_1
werkzeug 0.14.1 py36_0
wheel 0.30.0 py36h5eb2c71_1
widgetsnbextension 3.1.0 py36_0
wrapt 1.10.11 py36hc29e774_0
xerces-c 3.2.2 h44e365a_1001 conda-forge
xlrd 1.1.0 py36h336f4a2_1
xlsxwriter 1.0.2 py36h3736301_0
xlwings 0.11.5 py36_0
xlwt 1.2.0 py36h5ad1178_0
xz 5.2.3 h0278029_2
yaml 0.1.7 hc338f04_2
zeromq 4.2.2 ha360ad0_2
zict 0.1.3 py36h71da714_0
zlib 1.2.11 hf3cbc9b_2
when i run it in conda, this error appears:
I
mportError Traceback (most recent call last)
<ipython-input-1-39efe3472e8a> in <module>()
1 import geopandas as gpd
2 import folium
----> 3 import contextily as ctx
/Users/localadmin/anaconda3/lib/python3.6/site-packages/contextily/__init__.py in <module>()
4
5 from . import tile_providers as sources
----> 6 from .place import Place, plot_map
7 from .tile import *
8 from .plotting import add_basemap, add_attribution
/Users/localadmin/anaconda3/lib/python3.6/site-packages/contextily/place.py in <module>()
4 import matplotlib.pyplot as plt
5 from warnings import warn
----> 6 from .tile import howmany, bounds2raster, bounds2img, _sm2ll, _calculate_zoom
7 from .plotting import ATTRIBUTION, INTERPOLATION, ZOOM, add_attribution
8
/Users/localadmin/anaconda3/lib/python3.6/site-packages/contextily/tile.py in <module>()
8 import numpy as np
9 import pandas as pd
---> 10 import rasterio as rio
11 from PIL import Image
12 from cartopy.io.img_tiles import _merge_tiles as merge_tiles
/Users/localadmin/anaconda3/lib/python3.6/site-packages/rasterio/__init__.py in <module>()
13 import warnings
14
---> 15 from rasterio._base import (
16 eval_window, window_shape, window_index, gdal_version)
17 from rasterio.dtypes import (
ImportError: dlopen(/Users/localadmin/anaconda3/lib/python3.6/site-packages/rasterio/_base.cpython-36m-darwin.so, 2): Library not loaded: #rpath/libuuid.1.dylib
Referenced from: /Users/localadmin/anaconda3/lib/libgdal.20.dylib
Reason: image not found
I could not find a post that solves that problem
just install another conda new environment, according to enter link description here. It works for me.

Python 3.7 anaconda environment - import _ssl DLL load fail error

I created anaconda environment with Python=3.7 and have trouble with the error of _ssl and DLL. When I tried to get back to my base environment, I have trouble getting the background processes to complete as shown in the figure below, this goes on forever.
The error:
C:\Users\abhil\AppData\Local\Continuum\anaconda3\envs\HeisenbergPy37\python.exe "C:\Program Files\JetBrains\PyCharm Community Edition 2018.1.1\helpers\pydev\pydevconsole.py" --mode=client --port=63950
Traceback (most recent call last):
File "C:\Program Files\JetBrains\PyCharm Community Edition 2018.1.1\helpers\pydev\pydevconsole.py", line 5, in <module>
from _pydev_comm.rpc import make_rpc_client, start_rpc_server, start_rpc_server_and_make_client
File "C:\Program Files\JetBrains\PyCharm Community Edition 2018.1.1\helpers\pydev\_pydev_comm\rpc.py", line 4, in <module>
from _pydev_comm.server import TSingleThreadedServer
File "C:\Program Files\JetBrains\PyCharm Community Edition 2018.1.1\helpers\pydev\_pydev_comm\server.py", line 4, in <module>
from _shaded_thriftpy.server import TServer
File "C:\Program Files\JetBrains\PyCharm Community Edition 2018.1.1\helpers\third_party\thriftpy\_shaded_thriftpy\server.py", line 9, in <module>
from _shaded_thriftpy.transport import (
File "C:\Program Files\JetBrains\PyCharm Community Edition 2018.1.1\helpers\third_party\thriftpy\_shaded_thriftpy\transport\__init__.py", line 57, in <module>
from .sslsocket import TSSLSocket, TSSLServerSocket # noqa
File "C:\Program Files\JetBrains\PyCharm Community Edition 2018.1.1\helpers\third_party\thriftpy\_shaded_thriftpy\transport\sslsocket.py", line 7, in <module>
import ssl
File "C:\Users\abhil\AppData\Local\Continuum\anaconda3\envs\HeisenbergPy37\lib\ssl.py", line 98, in <module>
import _ssl # if we can't import it, let the error propagate
ImportError: DLL load failed: The specified module could not be found.
Process finished with exit code 1
All packages installed with
conda create -n anaconda python=3.7
C:\WINDOWS\system32>conda list
# packages in environment at C:\Users\abhil\AppData\Local\Continuum\anaconda3\envs\HeisenbergPy37:
#
# Name Version Build Channel
alabaster 0.7.12 py37_0
anaconda 2018.12 py37_0
anaconda-client 1.7.2 py37_0
anaconda-project 0.8.2 py37_0
asn1crypto 0.24.0 py37_0
astroid 2.1.0 py37_0
astropy 3.1 py37he774522_0
atomicwrites 1.2.1 py37_0
attrs 18.2.0 py37h28b3542_0
babel 2.6.0 py37_0
backcall 0.1.0 py37_0
backports 1.0 py37_1
backports.os 0.1.1 py37_0
backports.shutil_get_terminal_size 1.0.0 py37_2
beautifulsoup4 4.6.3 py37_0
bitarray 0.8.3 py37hfa6e2cd_0
bkcharts 0.2 py37_0
blas 1.0 mkl
blaze 0.11.3 py37_0
bleach 3.0.2 py37_0
blosc 1.14.4 he51fdeb_0
bokeh 1.0.2 py37_0
boto 2.49.0 py37_0
bottleneck 1.2.1 py37h452e1ab_1
bzip2 1.0.6 hfa6e2cd_5
ca-certificates 2018.03.07 0
certifi 2018.11.29 py37_0
cffi 1.11.5 py37h74b6da3_1
chardet 3.0.4 py37_1
click 7.0 py37_0
cloudpickle 0.6.1 py37_0
clyent 1.2.2 py37_1
colorama 0.4.1 py37_0
comtypes 1.1.7 py37_0
console_shortcut 0.1.1 3
contextlib2 0.5.5 py37_0
cryptography 2.4.2 py37h7a1dbc1_0
curl 7.63.0 h2a8f88b_1000
cycler 0.10.0 py37_0
cython 0.29.2 py37ha925a31_0
cytoolz 0.9.0.1 py37hfa6e2cd_1
dask 1.0.0 py37_0
dask-core 1.0.0 py37_0
datashape 0.5.4 py37_1
decorator 4.3.0 py37_0
defusedxml 0.5.0 py37_1
distributed 1.25.1 py37_0
docutils 0.14 py37_0
entrypoints 0.2.3 py37_2
et_xmlfile 1.0.1 py37_0
fastcache 1.0.2 py37hfa6e2cd_2
filelock 3.0.10 py37_0
flask 1.0.2 py37_1
flask-cors 3.0.7 py37_0
freetype 2.9.1 ha9979f8_1
get_terminal_size 1.0.0 h38e98db_0
gevent 1.3.7 py37he774522_1
glob2 0.6 py37_1
greenlet 0.4.15 py37hfa6e2cd_0
h5py 2.8.0 py37h3bdd7fb_2
hdf5 1.10.2 hac2f561_1
heapdict 1.0.0 py37_2
html5lib 1.0.1 py37_0
icc_rt 2019.0.0 h0cc432a_1
icu 58.2 ha66f8fd_1
idna 2.8 py37_0
imageio 2.4.1 py37_0
imagesize 1.1.0 py37_0
importlib_metadata 0.6 py37_0
intel-openmp 2019.1 144
ipykernel 5.1.0 py37h39e3cac_0
ipython 7.2.0 py37h39e3cac_0
ipython_genutils 0.2.0 py37_0
ipywidgets 7.4.2 py37_0
isort 4.3.4 py37_0
itsdangerous 1.1.0 py37_0
jdcal 1.4 py37_0
jedi 0.13.2 py37_0
jinja2 2.10 py37_0
jpeg 9b hb83a4c4_2
jsonschema 2.6.0 py37_0
jupyter 1.0.0 py37_7
jupyter_client 5.2.4 py37_0
jupyter_console 6.0.0 py37_0
jupyter_core 4.4.0 py37_0
jupyterlab 0.35.3 py37_0
jupyterlab_server 0.2.0 py37_0
keyring 17.0.0 py37_0
kiwisolver 1.0.1 py37h6538335_0
krb5 1.16.1 hc04afaa_7
lazy-object-proxy 1.3.1 py37hfa6e2cd_2
libarchive 3.3.3 h0643e63_5
libcurl 7.63.0 h2a8f88b_1000
libiconv 1.15 h1df5818_7
libpng 1.6.35 h2a8f88b_0
libsodium 1.0.16 h9d3ae62_0
libssh2 1.8.0 h7a1dbc1_4
libtiff 4.0.9 h36446d0_2
libxml2 2.9.8 hadb2253_1
libxslt 1.1.32 hf6f1972_0
llvmlite 0.26.0 py37ha925a31_0
locket 0.2.0 py37_1
lxml 4.2.5 py37hef2cd61_0
lz4-c 1.8.1.2 h2fa13f4_0
lzo 2.10 h6df0209_2
m2w64-gcc-libgfortran 5.3.0 6
m2w64-gcc-libs 5.3.0 7
m2w64-gcc-libs-core 5.3.0 7
m2w64-gmp 6.1.0 2
m2w64-libwinpthread-git 5.0.0.4634.697f757 2
markupsafe 1.1.0 py37he774522_0
matplotlib 3.0.2 py37hc8f65d3_0
mccabe 0.6.1 py37_1
menuinst 1.4.14 py37hfa6e2cd_0
mistune 0.8.4 py37he774522_0
mkl 2019.1 144
mkl-service 1.1.2 py37hb782905_5
mkl_fft 1.0.6 py37h6288b17_0
mkl_random 1.0.2 py37h343c172_0
more-itertools 4.3.0 py37_0
mpmath 1.1.0 py37_0
msgpack-python 0.5.6 py37he980bc4_1
msys2-conda-epoch 20160418 1
multipledispatch 0.6.0 py37_0
nbconvert 5.4.0 py37_1
nbformat 4.4.0 py37_0
networkx 2.2 py37_1
nltk 3.4 py37_1
nose 1.3.7 py37_2
notebook 5.7.4 py37_0
numba 0.41.0 py37hf9181ef_0
numexpr 2.6.8 py37hdce8814_0
numpy 1.15.4 py37h19fb1c0_0
numpy-base 1.15.4 py37hc3f5095_0
numpydoc 0.8.0 py37_0
odo 0.5.1 py37_0
olefile 0.46 py37_0
openpyxl 2.5.12 py37_0
openssl 1.1.1a he774522_0
packaging 18.0 py37_0
pandas 0.23.4 py37h830ac7b_0
pandoc 1.19.2.1 hb2460c7_1
pandocfilters 1.4.2 py37_1
parso 0.3.1 py37_0
partd 0.3.9 py37_0
path.py 11.5.0 py37_0
pathlib2 2.3.3 py37_0
patsy 0.5.1 py37_0
pep8 1.7.1 py37_0
pickleshare 0.7.5 py37_0
pillow 5.3.0 py37hdc69c19_0
pip 18.1 py37_0
pkginfo 1.4.2 py37_1
pluggy 0.8.0 py37_0
ply 3.11 py37_0
prometheus_client 0.5.0 py37_0
prompt_toolkit 2.0.7 py37_0
psutil 5.4.8 py37he774522_0
py 1.7.0 py37_0
pycodestyle 2.4.0 py37_0
pycosat 0.6.3 py37hfa6e2cd_0
pycparser 2.19 py37_0
pycrypto 2.6.1 py37hfa6e2cd_9
pycurl 7.43.0.2 py37h7a1dbc1_0
pyflakes 2.0.0 py37_0
pygments 2.3.1 py37_0
pylint 2.2.2 py37_0
pyodbc 4.0.25 py37ha925a31_0
pyopenssl 18.0.0 py37_0
pyparsing 2.3.0 py37_0
pyqt 5.9.2 py37h6538335_2
pysocks 1.6.8 py37_0
pytables 3.4.4 py37he6f6034_0
pytest 4.0.2 py37_0
pytest-arraydiff 0.3 py37h39e3cac_0
pytest-astropy 0.5.0 py37_0
pytest-doctestplus 0.2.0 py37_0
pytest-openfiles 0.3.1 py37_0
pytest-remotedata 0.3.1 py37_0
python 3.7.1 h8c8aaf0_6
python-dateutil 2.7.5 py37_0
python-libarchive-c 2.8 py37_6
pytz 2018.7 py37_0
pywavelets 1.0.1 py37h8c2d366_0
pywin32 223 py37hfa6e2cd_1
pywinpty 0.5.5 py37_1000
pyyaml 3.13 py37hfa6e2cd_0
pyzmq 17.1.2 py37hfa6e2cd_0
qt 5.9.7 vc14h73c81de_0
qtawesome 0.5.3 py37_0
qtconsole 4.4.3 py37_0
qtpy 1.5.2 py37_0
requests 2.21.0 py37_0
rope 0.11.0 py37_0
ruamel_yaml 0.15.46 py37hfa6e2cd_0
scikit-image 0.14.1 py37ha925a31_0
scikit-learn 0.20.1 py37h343c172_0
scipy 1.1.0 py37h29ff71c_2
seaborn 0.9.0 py37_0
send2trash 1.5.0 py37_0
setuptools 40.6.3 py37_0
simplegeneric 0.8.1 py37_2
singledispatch 3.4.0.3 py37_0
sip 4.19.8 py37h6538335_0
six 1.12.0 py37_0
snappy 1.1.7 h777316e_3
snowballstemmer 1.2.1 py37_0
sortedcollections 1.0.1 py37_0
sortedcontainers 2.1.0 py37_0
sphinx 1.8.2 py37_0
sphinxcontrib 1.0 py37_1
sphinxcontrib-websupport 1.1.0 py37_1
spyder 3.3.2 py37_0
spyder-kernels 0.3.0 py37_0
sqlalchemy 1.2.15 py37he774522_0
sqlite 3.26.0 he774522_0
statsmodels 0.9.0 py37h452e1ab_0
sympy 1.3 py37_0
tblib 1.3.2 py37_0
terminado 0.8.1 py37_1
testpath 0.4.2 py37_0
tk 8.6.8 hfa6e2cd_0
toolz 0.9.0 py37_0
tornado 5.1.1 py37hfa6e2cd_0
tqdm 4.28.1 py37h28b3542_0
traitlets 4.3.2 py37_0
unicodecsv 0.14.1 py37_0
urllib3 1.24.1 py37_0
vc 14.1 h0510ff6_4
vs2015_runtime 14.15.26706 h3a45250_0
wcwidth 0.1.7 py37_0
webencodings 0.5.1 py37_1
werkzeug 0.14.1 py37_0
wheel 0.32.3 py37_0
widgetsnbextension 3.4.2 py37_0
win_inet_pton 1.0.1 py37_1
win_unicode_console 0.5 py37_0
wincertstore 0.2 py37_0
winpty 0.4.3 4
wrapt 1.10.11 py37hfa6e2cd_2
xlrd 1.2.0 py37_0
xlsxwriter 1.1.2 py37_0
xlwings 0.15.1 py37_0
xlwt 1.3.0 py37_0
xz 5.2.4 h2fa13f4_4
yaml 0.1.7 hc54c509_2
zeromq 4.2.5 he025d50_1
zict 0.1.3 py37_0
zlib 1.2.11 h62dcd97_3
zstd 1.3.7 h508b16e_0
I have answerd this here, to my understanding this error is caused by the missing/misplacement of libcrypto file in anaconda3/DLLs folder:
From anaconda3\Library\bin copy below files and paste them in anaconda3/DLLs:
- libcrypto-1_1-x64.dll
- libssl-1_1-x64.dll
This can be fixed by manually adding in the PATH variables in PyCharm to the console.
Open your Anaconda cmd
Activate your Conda environment
Get the full PATH value by typing echo %PATH%
if you are on Windows 7/can't copy the output, cd the cmd to your desktop and type echo %PATH% > path_val.txt
this will create a txt file so you can copy/paste the values easier.
In PyCharm, go to Settings -> Build, Execution, Deployment -> Console -> Python Console -> click the folder on the right of Environment variables.
Click the plus button to add a new Environment Variable
The name should be PATH
The value is the entire output from the echo %PATH% command above.
Click OK, then apply.
You can try to set system environment variables, like "C:\Python\Anaconda3;C:\Python\Anaconda3\Scripts;
C:\Python\Anaconda3\Library\bin;".
Only "C:\Python\Anaconda3\Scripts;" is not enough, and it works to me.
I had the same issue on Windows 10 Pro x64 and PyCharm CE 2018.3
A solution that worked for me: Re-install Anaconda3 for all users (with Admin priveledges) and choose "add python.exe to Path" (even though it is nor recommended). Then PyCharm connected successfully without this error.
A work around that also worked: Use another environment (pyenv or conda). It worked for me when I faced the same issue on
Some other suggestions I saw on Internet:
run Anaconda3\Scripts>conda update --all
but this threw the HTTP connection error rises, which might be related.
if running under a virtual env (i.e. your have issued the command: conda activate <env_name>)
The files (libcrypto-1_1-x64.dll and libssl-1_1-x64.dll) to copy are found under:
C:\USER<username>.conda\envs<env_name>\Library\bin
They have to be copied into:
C:\USER<username>.conda\envs<env_name>\DLLs
None of the above worked for me, but instead it was a problem with OpenSSL on Windows 10 Enterprise. I fixed it by downloading and installing OpenSSL from here: https://slproweb.com/products/Win32OpenSSL.html
Thanks for the answer!
This works definately.
I have answerd this here, to my understanding this error is caused by the missing/misplacement of libcrypto file in anaconda3/DLLs folder:
From anaconda3\Library\bin copy below files and paste them in anaconda3/DLLs:
libcrypto-1_1-x64.dll
libssl-1_1-x64.dll
In my case the error was a result of spinning pipenv from non-base conda env. Setting variable in PyCharm or moving files in base anaconda structure didn't help, because PyCharm looked for these DLLs in my conda env in the middle.
So I had to move files from base conda structure:
C:\Users<username>\AppData\Local\Continuum\anaconda3\Library\bin
To my conda env from which I spinned the final Pipenv I use in PyCharm:
C:\Users<username>\AppData\Local\Continuum\anaconda3\envs<conda_env_name>\DLLs
The files I had to move to have IPython work correctly:
libcrypto-1_1-x64.dll
libssl-1_1-x64.dll
sqlite3.dll
sqlite3.exe
The reason is that not all libraries/binaries are propagated to the virtual envs. Virtual envs are able to find these files in "root Python". Venvs stay lighter thanks to not copying them.
However, PyCharm gets confused in a setup such as mine, and treats the conda env in the middle as a "root Python", and can't find the libraries/bins. This problem can potentially make itself apparent with other dlls or bins.
It may be worth to move all missing files this way.
another solution: edit python3.7's site.py(in Lib dir):
from os.path import join, abspath, dirname
base_path = dirname(dirname(abspath(__file__)))
os.environ['PATH'] = '%s%s' % (
os.environ['PATH'],
join(base_path, 'Library', 'bin'),
)
I had the same issue and my main IDE is Sublime Text 4.
Environment: Windows 10 with Anaconda
What I needed: from cryptography.fernet import Fernet
The marked solution was unachievable for me and the following answer solved it right away:
pip install --upgrade pip
pip uninstall pyopenssl cryptography
pip install pyopenssl cryptography
Validate with:
python -v -c "from OpenSSL import SSL"
Source: https://groups.google.com/g/qatrack/c/24RB6hesOko?pli=1
Incase someone is searching for Eclipse PyDev, It's same as Rob's answer.
No. 4 can be found at Window -> Preferences -> PyDev -> Interpreters -> Python Interpreters -> Environment -> Click New and add PATH
I have updated to Python 3.8 (with miniconda) and it did not work with Pycharm generating "anaconda-environment-import-ssl-dll-load-fail-error". I have tried several proposals here and tweaked env variables in different way w/o much success.
Finally I have updated to Pycharm 2020.2.3 and it worked like a charm, no tweaks ..

import featuretools and AttributeError: module 'tornado.platform.asyncio' has no attribute 'AnyThreadEventLoopPolicy'

these are all the packages installed and the environment is Windows 7.1
# Name Version Build Channel
_ipyw_jlab_nb_ext_conf 0.1.0 py36he6757f0_0
alabaster 0.7.10 py36hcd07829_0
anaconda 5.1.0 py36_2
anaconda-client 1.6.9 py36_0
anaconda-navigator 1.7.0 py36_0
anaconda-project 0.8.2 py36hfad2e28_0
asn1crypto 0.24.0 py36_0
astroid 1.6.1 py36_0
astropy 2.0.3 py36hfa6e2cd_0
attrs 17.4.0 py36_0
babel 2.5.3 py36_0
backports 1.0 py36h81696a8_1
backports.shutil_get_terminal_size 1.0.0 py36h79ab834_2
beautifulsoup4 4.6.0 py36hd4cc5e8_1
bitarray 0.8.1 py36hfa6e2cd_1
bkcharts 0.2 py36h7e685f7_0
blaze 0.11.3 py36h8a29ca5_0
bleach 2.1.2 py36_0
bokeh 0.12.13 py36h047fa9f_0
boto 2.48.0 py36h1a776d2_1
boto3 1.9.42 <pip>
botocore 1.12.42 <pip>
bottleneck 1.2.1 py36hd119dfa_0
bzip2 1.0.6 hbe05fcf_4
ca-certificates 2017.08.26 h94faf87_0
certifi 2018.1.18 py36_0
cffi 1.11.4 py36hfa6e2cd_0
chardet 3.0.4 py36h420ce6e_1
click 6.7 py36hec8c647_0
cloudpickle 0.5.2 py36_1
clyent 1.2.2 py36hb10d595_1
colorama 0.3.9 py36h029ae33_0
comtypes 1.1.4 py36_0
conda 4.4.10 py36_0
conda-build 3.4.1 py36_0
conda-env 2.6.0 h36134e3_1
conda-verify 2.0.0 py36h065de53_0
console_shortcut 0.1.1 h6bb2dd7_3
contextlib2 0.5.5 py36he5d52c0_0
cryptography 2.1.4 py36he1d7878_0
curl 7.58.0 h7602738_0
cycler 0.10.0 py36h009560c_0
cython 0.27.3 py36h22f4c84_0
cytoolz 0.9.0 py36hfa6e2cd_0
dask 0.16.1 py36_0
dask 0.20.1 <pip>
dask-core 0.16.1 py36_0
datashape 0.5.4 py36h5770b85_0
decorator 4.2.1 py36_0
distributed 1.20.2 py36_0
distributed 1.24.1 <pip>
docutils 0.14 py36h6012d8f_0
entrypoints 0.2.3 py36hfd66bb0_2
et_xmlfile 1.0.1 py36h3d2d736_0
fastcache 1.0.2 py36hfa6e2cd_2
featuretools 0.4.0 <pip>
filelock 2.0.13 py36h20000bf_0
flask 0.12.2 py36h98b5e8f_0
flask-cors 3.0.3 py36h8a3855d_0
freetype 2.8 h51f8f2c_1
future 0.17.1 <pip>
get_terminal_size 1.0.0 h38e98db_0
gevent 1.2.2 py36h342a76c_0
glob2 0.6 py36hdf76b57_0
greenlet 0.4.12 py36ha00ad21_0
h5py 2.7.1 py36he54a1c3_0
hdf5 1.10.1 h98b8871_1
heapdict 1.0.0 py36_2
html5lib 1.0.1 py36h047fa9f_0
icc_rt 2017.0.4 h97af966_0
icu 58.2 ha66f8fd_1
idna 2.6 py36h148d497_1
imageio 2.2.0 py36had6c2d2_0
imagesize 0.7.1 py36he29f638_0
intel-openmp 2018.0.0 hd92c6cd_8
ipykernel 4.8.0 py36_0
ipython 6.2.1 py36h9cf0123_1
ipython_genutils 0.2.0 py36h3c5d0ee_0
ipywidgets 7.1.1 py36_0
isort 4.2.15 py36h6198cc5_0
itsdangerous 0.24 py36hb6c5a24_1
jdcal 1.3 py36h64a5255_0
jedi 0.11.1 py36_0
jinja2 2.10 py36h292fed1_0
jmespath 0.9.3 <pip>
jpeg 9b hb83a4c4_2
jsonschema 2.6.0 py36h7636477_0
jupyter 1.0.0 py36_4
jupyter_client 5.2.2 py36_0
jupyter_console 5.2.0 py36h6d89b47_1
jupyter_core 4.4.0 py36h56e9d50_0
jupyterlab 0.31.4 py36_0
jupyterlab_launcher 0.10.2 py36_0
lazy-object-proxy 1.3.1 py36hd1c21d2_0
libcurl 7.58.0 h7602738_0
libiconv 1.15 h1df5818_7
libpng 1.6.34 h79bbb47_0
libssh2 1.8.0 hd619d38_4
libtiff 4.0.9 h0f13578_0
libxml2 2.9.7 h79bbb47_0
libxslt 1.1.32 hf6f1972_0
llvmlite 0.21.0 py36he0b0552_0
locket 0.2.0 py36hfed976d_1
lxml 4.1.1 py36hef2cd61_1
lzo 2.10 h6df0209_2
markupsafe 1.0 py36h0e26971_1
matplotlib 2.1.2 py36h016c42a_0
mccabe 0.6.1 py36hb41005a_1
menuinst 1.4.11 py36hfa6e2cd_0
mistune 0.8.3 py36_0
mkl 2018.0.1 h2108138_4
mkl-service 1.1.2 py36h57e144c_4
mpmath 1.0.0 py36hacc8adf_2
msgpack 0.5.6 <pip>
msgpack-python 0.5.1 py36he980bc4_0
multipledispatch 0.4.9 py36he44c36e_0
navigator-updater 0.1.0 py36h8a7b86b_0
nbconvert 5.3.1 py36h8dc0fde_0
nbformat 4.4.0 py36h3a5bc1b_0
networkx 2.1 py36_0
nltk 3.2.5 py36h76d52bb_0
nose 1.3.7 py36h1c3779e_2
notebook 5.4.0 py36_0
numba 0.36.2 np114py36h12cb543_0
numexpr 2.6.4 py36h30784b8_0
numpy 1.14.0 py36h4a99626_1
numpydoc 0.7.0 py36ha25429e_0
odo 0.5.1 py36h7560279_0
olefile 0.45.1 py36_0
openpyxl 2.4.10 py36_0
openssl 1.0.2n h74b6da3_0
packaging 16.8 py36ha0986f6_1
pandas 0.23.4 <pip>
pandas 0.22.0 py36h6538335_0
pandoc 1.19.2.1 hb2460c7_1
pandocfilters 1.4.2 py36h3ef6317_1
parso 0.1.1 py36hae3edee_0
partd 0.3.8 py36hc8e763b_0
path.py 10.5 py36h2b94a8f_0
pathlib2 2.3.0 py36h7bfb78b_0
patsy 0.5.0 py36_0
pep8 1.7.1 py36_0
pickleshare 0.7.4 py36h9de030f_0
pillow 5.0.0 py36h0738816_0
pip 18.1 <pip>
pip 9.0.1 py36h226ae91_4
pkginfo 1.4.1 py36hb0f9cfa_1
pluggy 0.6.0 py36hc7daf1e_0
ply 3.10 py36h1211beb_0
prompt_toolkit 1.0.15 py36h60b8f86_0
psutil 5.4.8 <pip>
psutil 5.4.3 py36hfa6e2cd_0
py 1.5.2 py36hbcfbabc_0
pycodestyle 2.3.1 py36h7cc55cd_0
pycosat 0.6.3 py36h413d8a4_0
pycparser 2.18 py36hd053e01_1
pycrypto 2.6.1 py36hfa6e2cd_7
pycurl 7.43.0.1 py36h74b6da3_0
pyflakes 1.6.0 py36h0b975d6_0
pygments 2.2.0 py36hb010967_0
pylint 1.8.2 py36_0
pyodbc 4.0.22 py36h6538335_0
pyopenssl 17.5.0 py36h5b7d817_0
pyparsing 2.2.0 py36h785a196_1
pyqt 5.6.0 py36hb5ed885_5
pysocks 1.6.7 py36h698d350_1
pytables 3.4.2 py36h71138e3_2
pytest 3.3.2 py36_0
python 3.6.4 h6538335_1
python-dateutil 2.6.1 py36h509ddcb_1
pytz 2017.3 py36h1d3fa6b_0
pywavelets 0.5.2 py36hc649158_0
pywin32 222 py36hfa6e2cd_0
pywinpty 0.5 py36h6538335_1
pyyaml 3.12 py36h1d1928f_1
pyzmq 16.0.3 py36he714bf5_0
qt 5.6.2 vc14h6f8c307_12 [vc14]
qtawesome 0.4.4 py36h5aa48f6_0
qtconsole 4.3.1 py36h99a29a9_0
qtpy 1.3.1 py36hb8717c5_0
requests 2.18.4 py36h4371aae_1
rope 0.10.7 py36had63a69_0
ruamel_yaml 0.15.35 py36hfa6e2cd_1
s3fs 0.1.6 <pip>
s3transfer 0.1.13 <pip>
scikit-image 0.13.1 py36hfa6e2cd_1
scikit-learn 0.19.1 py36h53aea1b_0
scipy 1.0.0 py36h1260518_0
seaborn 0.8.1 py36h9b69545_0
send2trash 1.4.2 py36_0
setuptools 38.4.0 py36_0
simplegeneric 0.8.1 py36_2
singledispatch 3.4.0.3 py36h17d0c80_0
sip 4.18.1 py36h9c25514_2
six 1.11.0 py36h4db2310_1
snowballstemmer 1.2.1 py36h763602f_0
sortedcollections 0.5.3 py36hbefa0ab_0
sortedcontainers 1.5.9 py36_0
sphinx 1.6.6 py36_0
sphinxcontrib 1.0 py36hbbac3d2_1
sphinxcontrib-websupport 1.0.1 py36hb5e5916_1
spyder 3.2.6 py36_0
sqlalchemy 1.2.1 py36hfa6e2cd_0
sqlite 3.22.0 h9d3ae62_0
statsmodels 0.8.0 py36h6189b4c_0
sympy 1.1.1 py36h96708e0_0
tblib 1.3.2 py36h30f5020_0
terminado 0.8.1 py36_1
testpath 0.3.1 py36h2698cfe_0
tk 8.6.7 hcb92d03_3
toolz 0.9.0 py36_0
tornado 4.5.3 py36_0
tqdm 4.28.1 <pip>
traitlets 4.3.2 py36h096827d_0
typing 3.6.2 py36hb035bda_0
unicodecsv 0.14.1 py36h6450c06_0
urllib3 1.22 py36h276f60a_0
vc 14 h0510ff6_3
vs2015_runtime 14.0.25123 3
wcwidth 0.1.7 py36h3d5aa90_0
webencodings 0.5.1 py36h67c50ae_1
werkzeug 0.14.1 py36_0
wheel 0.30.0 py36h6c3ec14_1
widgetsnbextension 3.1.0 py36_0
win_inet_pton 1.0.1 py36he67d7fd_1
win_unicode_console 0.5 py36hcdbd4b5_0
wincertstore 0.2 py36h7fe50ca_0
winpty 0.4.3 4
wrapt 1.10.11 py36he5f5981_0
xlrd 1.1.0 py36h1cb58dc_1
xlsxwriter 1.0.2 py36hf723b7d_0
xlwings 0.11.5 py36_0
xlwt 1.3.0 py36h1a4751e_0
yaml 0.1.7 hc54c509_2
zict 0.1.3 py36h2d8e73e_0
zlib 1.2.11 h8395fce_2
When I imported featuretools on jupyter notebook, it raised an error.
Anyone knows how to fix?
--------------------------------------------------------------------------- AttributeError Traceback (most recent call
last) in ()
1 # Automated feature engineering
----> 2 import featuretools as ft
D:\Program Files\Anaconda3\lib\site-packages\featuretools__init__.py
in ()
5 from .entityset.api import *
6 from . import primitives
----> 7 from .synthesis.api import *
8 from .primitives import Feature, list_primitives
9 from .computational_backends.api import *
D:\Program
Files\Anaconda3\lib\site-packages\featuretools\synthesis__init__.py
in ()
1 from future import absolute_import
2 # flake8: noqa
----> 3 from .api import *
D:\Program
Files\Anaconda3\lib\site-packages\featuretools\synthesis\api.py in
()
3 # flake8: noqa
4 from .deep_feature_synthesis import DeepFeatureSynthesis
----> 5 from .dfs import dfs
6 from .encode_features import encode_features
D:\Program
Files\Anaconda3\lib\site-packages\featuretools\synthesis\dfs.py in
()
3 from .deep_feature_synthesis import DeepFeatureSynthesis
4
----> 5 from featuretools.computational_backends import calculate_feature_matrix
6 from featuretools.entityset import EntitySet
7
D:\Program
Files\Anaconda3\lib\site-packages\featuretools\computational_backends__init__.py
in ()
1 # flake8: noqa
----> 2 from .api import *
D:\Program
Files\Anaconda3\lib\site-packages\featuretools\computational_backends\api.py
in ()
1 # flake8: noqa
----> 2 from .calculate_feature_matrix import (
3 approximate_features,
4 calculate_feature_matrix
5 )
D:\Program
Files\Anaconda3\lib\site-packages\featuretools\computational_backends\calculate_feature_matrix.py
in ()
15
16 from .pandas_backend import PandasBackend
---> 17 from .utils import (
18 bin_cutoff_times,
19 calc_num_per_chunk,
D:\Program
Files\Anaconda3\lib\site-packages\featuretools\computational_backends\utils.py
in ()
8 import pandas as pd
9 import psutil
---> 10 from distributed import Client, LocalCluster
11 from pandas.tseries.frequencies import to_offset
12
D:\Program Files\Anaconda3\lib\site-packages\distributed__init__.py
in ()
3 from . import config
4 from dask.config import config
----> 5 from .actor import Actor, ActorFuture
6 from .core import connect, rpc
7 from .deploy import LocalCluster, Adaptive
D:\Program Files\Anaconda3\lib\site-packages\distributed\actor.py in
()
2 import functools
3
----> 4 from .client import Future, default_client
5 from .compatibility import get_thread_identity, Queue
6 from .protocol import to_serialize
D:\Program Files\Anaconda3\lib\site-packages\distributed\client.py in
()
42 from tornado.queues import Queue
43
---> 44 from .batched import BatchedSend
45 from .utils_comm import (WrappedKey, unpack_remotedata, pack_data,
46 scatter_to_workers, gather_from_workers)
D:\Program Files\Anaconda3\lib\site-packages\distributed\batched.py in
()
8 from tornado.ioloop import IOLoop
9
---> 10 from .core import CommClosedError
11 from .utils import parse_timedelta
12
D:\Program Files\Anaconda3\lib\site-packages\distributed\core.py in
()
18
19 from .compatibility import get_thread_identity
---> 20 from .comm import (connect, listen, CommClosedError,
21 normalize_address,
22 unparse_host_port, get_address_host_port)
D:\Program
Files\Anaconda3\lib\site-packages\distributed\comm__init__.py in
()
7 get_local_address_for,
8 )
----> 9 from .core import connect, listen, Comm, CommClosedError
10
11
D:\Program Files\Anaconda3\lib\site-packages\distributed\comm\core.py
in ()
10
11 from ..metrics import time
---> 12 from ..utils import parse_timedelta
13 from . import registry
14 from .addressing import parse_address
D:\Program Files\Anaconda3\lib\site-packages\distributed\utils.py in
() 1388 import asyncio 1389 import
tornado.platform.asyncio
-> 1390 asyncio.set_event_loop_policy(tornado.platform.asyncio.AnyThreadEventLoopPolicy())
1391 1392
AttributeError: module 'tornado.platform.asyncio' has no attribute
'AnyThreadEventLoopPolicy'
I have same issue.
I not find class 'AnyThreadEventLoopPolicy' in tornado/platform/asyncio.py of tornado's version '4.5.1', but in source code tornado master of github.
so you can install the newest tornado.
Now, pip can not install tornado-5.1.1
you can follow steps:
1: download tornado-5.1.1
2: pip install *.whl or cd file_dir python setup.py install

Categories