python import error :ImportError('dateutil 2.5.0 is the minimum required version')

《深度学习——caffe之经典模型详解与实战》

root@xxx-virtual-machine:/home/xxx/caffe/examples/kaggle/facial_keypoints_detection# python
Python 2.7.15rc1 (default, Nov 12 2018, 14:31:15) 
[GCC 7.3.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import os
>>> import numpy as np
>>> from pandas.io.parsers import read_csv
Traceback (most recent call last):
  File "", line 1, in
  File "/usr/local/lib/python2.7/dist-packages/pandas/__init__.py", line 23, in
    from pandas.compat.numpy import *
  File "/usr/local/lib/python2.7/dist-packages/pandas/compat/__init__.py", line 422, in
    raise ImportError('dateutil 2.5.0 is the minimum required version')
ImportError: dateutil 2.5.0 is the minimum required version
 

解决方法:

非root用户

sudo pip uninstall python-dateutil

sudo apt-get install python-dateutil

root用户

pip uninstall python-dateutil

apt-get install python-dateutil

你可能感兴趣的:(python)