Commit 2aac16c1 authored by Leszek Szymczak's avatar Leszek Szymczak Committed by Mateusz Gniewkowski

Bug fixing

parent e323a2f2
......@@ -15,3 +15,4 @@ services:
- './config.ini:/home/worker/config.ini'
- './src:/home/worker/src'
- './main.py:/home/worker/main.py'
- './info.json:/home/worker/info.json'
"""Implementation of omwn_worker."""
"""Implementation of omwn_worker."""
import logging
import json
import lex_ws
import nltk
from nltk.corpus import wordnet as wn
my_logger = logging.getLogger(__name__)
......@@ -17,6 +19,8 @@ class OMWNWorker(lex_ws.LexWorker):
@classmethod
def static_init(cls, config):
"""Initialize worker."""
nltk.download('wordnet')
nltk.download('omw')
my_logger.info("Loading models...")
for lang in languages:
wn.lemmas("test", lang=languages[lang])
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment