open('aclImdb/alldata-id.txt', encoding='utf-8') doesn't work in Python 2.x #1789
Labels
bug
Issue described a bug
difficulty medium
Medium issue: required good gensim understanding & python skills
good first issue
Issue for new contributors (not required gensim understanding + very simple)
In file doc2vec-IMDB.ipynb, this statement is not supported in Python 2.x but is in Python 3.x
with open('aclImdb/alldata-id.txt', encoding='utf-8') as alldata:
This works in Python 2.7:
import codecs
with codecs.open('aclImdb/alldata-id.txt', encoding='utf-8') as alldata:
The text was updated successfully, but these errors were encountered: