matplotlib,conda和cycler

时间:2017-09-15 10:58:23

标签: matplotlib virtualenv conda

我刚安装了带有Python 3 64位的Anaconda 4.3.23。我创建了虚拟环境并安装了conda install matplotlib。当我执行import matplotlib.pyplot as plt时,我收到以下错误:

---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-3-2d703b067d13> in <module>()
      2 import numpy as np
      3 import tensorflow as tf
----> 4 import matplotlib.pyplot as plt

~\AppData\Local\conda\conda\envs\tensorflow\lib\site-packages\matplotlib\__init__.py in <module>()
    122 from matplotlib.cbook import is_string_like, mplDeprecation, dedent, get_label
    123 from matplotlib.compat import subprocess
--> 124 from matplotlib.rcsetup import (defaultParams,
    125                                 validate_backend,
    126                                 cycler)

~\AppData\Local\conda\conda\envs\tensorflow\lib\site-packages\matplotlib\rcsetup.py in <module>()
     35 
     36 # Don't let the original cycler collide with our validating cycler
---> 37 from cycler import Cycler, cycler as ccycler
     38 
     39 # interactive_bk = ['gtk', 'gtkagg', 'gtkcairo', 'qt4agg',

ImportError: No module named 'cycler'

我尝试了conda install cycler,但又回来了:

# All requested packages already installed.
# packages in environment at C:\Users\test\AppData\Local\conda\conda\envs\tensorflow:
#
cycler                    0.10.0                   py35_0    conda-forge

我在新创建的虚拟环境tensorflow下运行了以上所有操作。有什么想法吗?

0 个答案:

没有答案