File "/usr/local/lib/python3.5/site-packages/dateutil/rrule.py", line 55 raise ValueError

终于编译过去,结果呢?import caffe,出错:

quantum6@gh4ai:~/gh-install/caffe/python$ python3
Python 3.5.5 (default, Oct 28 2018, 15:55:43) 
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import caffe
Traceback (most recent call last):
  File "", line 1, in 
  File "/home/quantum6/gh-install/caffe/python/caffe/__init__.py", line 1, in 
    from .pycaffe import Net, SGDSolver, NesterovSolver, AdaGradSolver, RMSPropSolver, AdaDeltaSolver, AdamSolver, NCCL, Timer
  File "/home/quantum6/gh-install/caffe/python/caffe/pycaffe.py", line 15, in 
    import caffe.io
  File "/home/quantum6/gh-install/caffe/python/caffe/io.py", line 2, in 
    import skimage.io
  File "/usr/local/lib/python3.5/site-packages/skimage/__init__.py", line 177, in 
    from .data import data_dir
  File "/usr/local/lib/python3.5/site-packages/skimage/data/__init__.py", line 15, in 
    from ..io import imread, use_plugin
  File "/usr/local/lib/python3.5/site-packages/skimage/io/__init__.py", line 15, in 
    reset_plugins()
  File "/usr/local/lib/python3.5/site-packages/skimage/io/manage_plugins.py", line 95, in reset_plugins
    _load_preferred_plugins()
  File "/usr/local/lib/python3.5/site-packages/skimage/io/manage_plugins.py", line 75, in _load_preferred_plugins
    _set_plugin(p_type, preferred_plugins['all'])
  File "/usr/local/lib/python3.5/site-packages/skimage/io/manage_plugins.py", line 87, in _set_plugin
    use_plugin(plugin, kind=plugin_type)
  File "/usr/local/lib/python3.5/site-packages/skimage/io/manage_plugins.py", line 258, in use_plugin
    _load(name)
  File "/usr/local/lib/python3.5/site-packages/skimage/io/manage_plugins.py", line 302, in _load
    fromlist=[modname])
  File "/usr/local/lib/python3.5/site-packages/skimage/io/_plugins/matplotlib_plugin.py", line 4, in 
    from mpl_toolkits.axes_grid1 import make_axes_locatable
  File "/usr/local/lib/python3.5/site-packages/mpl_toolkits/axes_grid1/__init__.py", line 1, in 
    from . import axes_size as Size
  File "/usr/local/lib/python3.5/site-packages/mpl_toolkits/axes_grid1/axes_size.py", line 15, in 
    from matplotlib.axes import Axes
  File "/usr/local/lib/python3.5/site-packages/matplotlib/axes/__init__.py", line 1, in 
    from ._subplots import *
  File "/usr/local/lib/python3.5/site-packages/matplotlib/axes/_subplots.py", line 6, in 
    from matplotlib.axes._axes import Axes
  File "/usr/local/lib/python3.5/site-packages/matplotlib/axes/_axes.py", line 20, in 
    import matplotlib.dates as _  # <-registers a date unit converter
  File "/usr/local/lib/python3.5/site-packages/matplotlib/dates.py", line 144, in 
    from dateutil.rrule import (rrule, MO, TU, WE, TH, FR, SA, SU, YEARLY,
  File "/usr/local/lib/python3.5/site-packages/dateutil/rrule.py", line 55
    raise ValueError, "Can't create weekday with n == 0"
                    ^
SyntaxError: invalid syntax

  面对这样的错误,人们不禁要问,这究竟是……别问了,赶紧上网查:

pip install matplotlib --upgrade

  感谢党,感谢国家,感谢高手……终于可以import了。

你可能感兴趣的:(Linux/Shell,人工智能,Python/PyCharm)