Traceback (most recent call last):
File "try5.py", line 3, in <module>
from matplotlib import pyplot as plt
File "/home/zaverichintan/miniconda2/lib/python2.7/site-packages/matplotlib/__init__.py", line 129, in <module>
from matplotlib.externals.six.moves.urllib.request import urlopen
File "/home/zaverichintan/miniconda2/lib/python2.7/site-packages/matplotlib/externals/six.py", line 90, in __get__
result = self._resolve()
File "/home/zaverichintan/miniconda2/lib/python2.7/site-packages/matplotlib/externals/six.py", line 158, in _resolve
module = _import_module(self.mod)
File "/home/zaverichintan/miniconda2/lib/python2.7/site-packages/matplotlib/externals/six.py", line 80, in _import_module
__import__(name)
File "/home/zaverichintan/miniconda2/lib/python2.7/urllib2.py", line 94, in <module>
import httplib
File "/home/zaverichintan/miniconda2/lib/python2.7/httplib.py", line 69, in <module>
from array import array
ImportError: cannot import name array
我导入了numpy,scipy,matplotlib和opencv。 代码在Windows 7机器上执行但升级到ubuntu 16.04后,得到这样的错误。 python版本显示2.7,但在ubuntu网站上显示的是python 3。 任何帮助表示赞赏。