My project's logger changes after executing .fit(). I tried to play around with the logging_configuration parameter when instantiating automl object, but the problem was not solved. Here is a minimal example.
import logging
import autosklearn.regression
AUTOML_CONFIG = dict(time_left_for_this_task=30, per_run_time_limit=10, memory_limit=None, n_jobs=1)
x=[1, 2, 3, 4]
y=[1, 2, 3, 4]
logging.basicConfig(level=logging.INFO, format="%(asctime)s %(name)s %(levelname)s:%(message)s")
logging.info("Initial")
automl = autosklearn.regression.AutoSklearnRegressor(**AUTOML_CONFIG)
logging.info("Create object")
automl.fit(x,y)
logging.info("Finished training")
logging.warning("Finished training")
Expected behaviour:
2022-08-10 14:06:13,635 root INFO:Initial
2022-08-10 14:06:13,635 root INFO:Create object
022-08-10 14:06:13,635 root INFO:Finished training
022-08-10 14:06:13,635 root WARNING:Finished training
What I get:
2022-08-10 14:06:13,635 root INFO:Initial
2022-08-10 14:06:13,635 root INFO:Create object
[WARNING] [2022-08-10 14:06:41,523:root] Finished training
Has anyone figured out how to prevent this happening to your root logger when using auto sklearn?