Faster RCNN訓練的時候,出現錯誤:python
from matplotlib import path, transforms File "/usr/local/lib/python2.7/dist-packages/matplotlib/__init__.py", line 124, in <module> from . import cbook ImportError: cannot import name cbook
同時python調用matplotlib也會出現如下錯誤:python2.7
File "/usr/local/lib/python2.7/dist-packages/matplotlib/fontconfig_pattern.py", line 32, in <module> from backports.functools_lru_cache import lru_cache ImportError: No module named functools_lru_cache
找了好久才找到解決辦法,至於緣由暫不清楚。spa
原來安裝matplotlib用的命令是:code
sudo pip install matplotlib
這樣就會有問題,不知道啥狀況。卸掉matplotlib:orm
sudo pip uninstall matplotlib
換成blog
sudo apt-get install python-matplotlib
就沒以上兩個問題了。ip