Textblob翻译unicodeEncodeError

时间:2019-04-01 06:12:56

标签: python character-encoding textblob

您好,我使用textblob版本0.15.3,尝试简单地翻译文本时出现以下错误:

UnicodeEncodeError: 'charmap' codec can't encode character '\xa1' in position 0: character maps to <undefined>

这是我的代码:

from textblob import TextBlob

#create textblop objet for string
analysis = TextBlob("TextBlob sure looks like it has some interesting features!")

print(analysis.translate(to='es'))

0 个答案:

没有答案