From 64f05fb875c2bc348c506417fcb0b33b1fc7f8ec Mon Sep 17 00:00:00 2001 From: Andre Martins Date: Thu, 3 Jul 2014 18:00:39 +0100 Subject: [PATCH] FIX Spanish parser in nlp_pipeline.py. --- python/nlp_pipeline.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/python/nlp_pipeline.py b/python/nlp_pipeline.py index 54b8eaa..52905fc 100644 --- a/python/nlp_pipeline.py +++ b/python/nlp_pipeline.py @@ -24,8 +24,10 @@ def __init__(self, pipeline, language): elif language == 'ES': self.sent_tokenizer = nltk.data.load('tokenizers/punkt/spanish.pickle') self.word_tokenizer = nltk.TreebankWordTokenizer() # For now... - self.tagger.load_tagger_model('/home/atm/workspace/CPP/TurboParser/models/spanish_ancora_finertags_nomwe_auto/spanish_ancora_finertags_nomwe_auto_tagger.model') - self.parser.load_parser_model('/home/atm/workspace/CPP/TurboParser/models/spanish_ancora_finertags_nomwe_auto/spanish_ancora_finertags_nomwe_auto_parser_pruned-true_model-standard.model') + self.tagger.load_tagger_model('/home/atm/workspace/CPP/TurboParser/models/spanish_conll2009_v2.0_nomwe_auto/spanish_conll2009_v2.0_nomwe_auto_tagger.model') + self.parser.load_parser_model('/home/atm/workspace/CPP/TurboParser/models/spanish_conll2009_v2.0_nomwe_auto/spanish_conll2009_v2.0_nomwe_auto_parser_pruned-true_model-standard.model') + self.lemmatizer = lemmatizer.BasicLemmatizer() + self.lemmatizer.load_lemmatizer_model('/home/atm/workspace/CPP/TurboParser/models/spanish_conll2009_v2.0_nomwe_auto/spanish_conll2009_v2.0_nomwe_auto_lemmatizer.model') elif language == 'EN': self.sent_tokenizer = nltk.data.load('tokenizers/punkt/english.pickle') self.word_tokenizer = nltk.TreebankWordTokenizer()