From 0e2ab6ca1a1c6de948124d6a942791cc2e57da55 Mon Sep 17 00:00:00 2001 From: Eunwoo Shin Date: Mon, 23 Sep 2024 16:33:25 +0900 Subject: [PATCH] Fix a wrong HPO log (#3972) * fix wrong log * fix wrong hpo log --- src/otx/engine/hpo/hpo_api.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/otx/engine/hpo/hpo_api.py b/src/otx/engine/hpo/hpo_api.py index 3fe01e1d786..49f10cfd6a8 100644 --- a/src/otx/engine/hpo/hpo_api.py +++ b/src/otx/engine/hpo/hpo_api.py @@ -336,8 +336,11 @@ def _adapt_batch_size_search_space(self, adapt_mode: Literal["Safe", "Full"]) -> self._engine.datamodule.train_subset.batch_size = origin_bs self._engine.model.optimizer_callable.optimizer_kwargs["lr"] = origin_lr # type: ignore[attr-defined] + logger.info( + "Max value of batch size search space : " + f"{self._hpo_config['search_space']['datamodule.train_subset.batch_size']['max']} -> {adapted_bs}", + ) self._hpo_config["search_space"]["datamodule.train_subset.batch_size"]["max"] = adapted_bs - logger.info(f"Max value of batch size search space : {origin_bs} -> {adapted_bs}") @staticmethod def _remove_wrong_search_space(search_space: dict[str, dict[str, Any]]) -> None: