From 1ef9dac86a87a4fda3dcf08663611d4668aaa86a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=2E=20Fernando=20S=C3=A1nchez?= Date: Wed, 10 May 2017 17:21:36 +0200 Subject: [PATCH] Made ANEW paths absolute --- emotion-anew/emotion-anew.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/emotion-anew/emotion-anew.py b/emotion-anew/emotion-anew.py index 6beb3b9..21eed3f 100644 --- a/emotion-anew/emotion-anew.py +++ b/emotion-anew/emotion-anew.py @@ -121,7 +121,7 @@ class EmotionTextPlugin(SentimentPlugin): dictionary={} lang = params.get("language", "auto") if lang == 'es': - with open(self._local_path+self.anew_path_es,'rb') as tabfile: + with open(self.anew_path_es,'rb') as tabfile: reader = csv.reader(tabfile, delimiter='\t') for row in reader: dictionary[row[2]]={} @@ -129,7 +129,7 @@ class EmotionTextPlugin(SentimentPlugin): dictionary[row[2]]['A']=row[5] dictionary[row[2]]['D']=row[7] else: - with open(self._local_path+self.anew_path_en,'rb') as tabfile: + with open(self.anew_path_en,'rb') as tabfile: reader = csv.reader(tabfile, delimiter='\t') for row in reader: dictionary[row[0]]={} @@ -152,4 +152,4 @@ class EmotionTextPlugin(SentimentPlugin): emotions.onyx__hasEmotion.append(emotion1) entry.emotions = [emotions,] - yield entry \ No newline at end of file + yield entry