Currently we attach the Logger class to AutoBase, PipelineBase and ComponentBase as instance state:
from evalml.utils import Logger
...
class PipelineBase:
def __init__(self, ...):
....
self.logger = Logger()
....
def describe(self):
self.logger.log('Message')
However, there's no reason we need to do that; I'd argue the logger should never be instance state.
I'd like us to move towards a simpler API like this:
from evalml.utils import Logger
logger = Logger()
class PipelineBase:
def describe(self):
logger.log('Message')
A related open question is: how do we configure the logger? It supports a verbose option; how do we support enabling that, if necessary? This relates to a more broad question about how config should work for evalml in general. And it could be a separate issue to file; I think progress can be made independently on the proposed logging update.
Currently we attach the Logger class to
AutoBase
,PipelineBase
andComponentBase
as instance state:However, there's no reason we need to do that; I'd argue the logger should never be instance state.
I'd like us to move towards a simpler API like this:
A related open question is: how do we configure the logger? It supports a verbose option; how do we support enabling that, if necessary? This relates to a more broad question about how config should work for evalml in general. And it could be a separate issue to file; I think progress can be made independently on the proposed logging update.