| #!/usr/bin/env python |
| # coding=utf-8 |
| |
| """MetricsEvaluator engine action. |
| |
| Use this module to add the project main code. |
| """ |
| |
| from .._compatibility import six |
| from .._logging import get_logger |
| |
| from marvin_python_toolbox.engine_base import EngineBaseTraining |
| |
| __all__ = ['MetricsEvaluator'] |
| |
| |
| logger = get_logger('metrics_evaluator') |
| |
| |
| class MetricsEvaluator(EngineBaseTraining): |
| |
| def __init__(self, **kwargs): |
| super(MetricsEvaluator, self).__init__(**kwargs) |
| |
| def execute(self, params, **kwargs): |
| """ |
| Setup the metrics with the result of the algorithms used to test the model. |
| Use the self.dataset and self.model prepared in the last actions. |
| |
| Eg. |
| |
| self.marvin_metrics = {...} |
| """ |
| self.marvin_metrics = {} |