【发布时间】:2018-07-26 23:08:40
【问题描述】:
当时我正在使用pickle.load 加载文件时遇到此错误。
with open("tfidf_vectorizer", mode='r+b') as handle:
tfidf_vectorizer = pickle.load(handle)
UnicodeDecodeError: 'ascii' 编解码器无法在位置解码字节 0xdb 0: 序数不在范围内(128)
【问题讨论】:
-
请将完整的错误回溯添加到您的问题中。
-
为什么你的文件
tfidf_vectorizer没有扩展名。不应该是tfidf_vectorizer.json或@KlausD 之类的东西。
标签: python python-3.x