-
Notifications
You must be signed in to change notification settings - Fork 52
Description
Hi,
has anybody used the German 2001 .dic with this library? I am getting "KeyError: 8" when I try to load the lexicon.
I've managed to solve this issue myself by accessing to the liwc/liwc/dic.py file and changing the read_dic(filepath) method to read my file using the utf-8 encoding.
Thank you for sharing your own solution. I would appreciate if you provided the details about it.
I just added encoding='utf-8' to liwc/liwc/dic.py, but apparently that is not right, because I keep getting "KeyError: '8'"
with open(filepath, encoding='utf-8') as lines:
By the way, I am trying to use this library not with a Spanish but with a German (from 2001) version. That is why I think your suggested solution might make this library work with the German 2001 .dic
Originally posted by @vicru in #15 (comment)