奇怪的python错误与seaborn相关' AttributeError:module' csv'没有属性' excel''

时间:2017-05-08 23:47:23

标签: python-3.x seaborn

我使用seaborn来修饰matplotlib中的一些情节。 在导入seaborn时,我们收到了这个错误:

import seaborn as sns

--> 407     def UnicodeReader(f, dialect=csv.excel, encoding="utf-8", **kwds):
    408         # ignore encoding
    409         return csv.reader(f, dialect=dialect, **kwds)

AttributeError: module 'csv' has no attribute 'excel'

还有其他人有这个问题吗?有关修复的任何想法吗?

1 个答案:

答案 0 :(得分:0)

如评论中所述,此错误的可能原因是名为csv.py的文件。