Skip to content

Commit

Permalink
Removed stats option from MLP Lite.
Browse files Browse the repository at this point in the history
  • Loading branch information
Marko Kollo committed Jun 27, 2019
1 parent 31be929 commit 5213c89
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
from utils.mlp_task_adapter import MLPTaskAdapter
from utils.mlp_task_adapter import Helpers


class MLPLitePreprocessor(object):
"""
Cleans texts for classification. Lemmatizes text.
"""


def _reload_env(self):
import dotenv
dotenv.load_dotenv(".env")
Expand Down
2 changes: 1 addition & 1 deletion task_manager/document_preprocessor/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ def log_preprocessor_status(code, status):
'arguments': {
'mlp_url': MLP_URL,
},
'output_type': ['lemmas', 'full'],
'output_type': ['lemmas'],
'field_properties': mlp_field_properties,
'is_enabled': True
}
Expand Down
2 changes: 2 additions & 0 deletions utils/mlp_task_adapter.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ def _start_mlp_celery_task(self, mlp_input):
self.tasks.append(task_info)

except Exception as e:
logging.getLogger(ERROR_LOGGER).exception(mlp_input)
logging.getLogger(ERROR_LOGGER).exception("Response Status: {} and Response Content: {}".format(response.status_code, response.text))


Expand All @@ -109,6 +110,7 @@ def _poll_task_status(self, task_id: str):
result = response.json()
return result
except Exception as e:
logging.getLogger(ERROR_LOGGER).exception(task_id)
logging.getLogger(ERROR_LOGGER).exception("Response Status: {} and Response Content: {}".format(response.status_code, response.text))


Expand Down

0 comments on commit 5213c89

Please sign in to comment.