From c24d9370377021e2a1aeb51747047a21bfb0eac7 Mon Sep 17 00:00:00 2001 From: Binh Tang Date: Fri, 4 Mar 2022 14:27:46 -0800 Subject: [PATCH] Refactor codebase to use `trainer.loggers` over `trainer.logger` when needed (#11920) Summary: ### New commit log messages - [7e2f9fbad Refactor codebase to use `trainer.loggers` over `trainer.logger` when needed (#11920)](https://github.com/PyTorchLightning/pytorch-lightning/pull/11920) Reviewed By: edward-io Differential Revision: D34583686 fbshipit-source-id: 98e557b761555c24ff296fff3ec6881d141fa777 --- d2go/utils/testing/lightning_train_helper.py | 2 +- tests/runner/test_runner_lightning_task.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/d2go/utils/testing/lightning_train_helper.py b/d2go/utils/testing/lightning_train_helper.py index 82f5d7a4..8f51e2da 100644 --- a/d2go/utils/testing/lightning_train_helper.py +++ b/d2go/utils/testing/lightning_train_helper.py @@ -14,7 +14,7 @@ def get_lt_trainer(output_dir: str, cfg): if cfg.TEST.EVAL_PERIOD > 0 else cfg.SOLVER.MAX_ITER, callbacks=[checkpoint_callback], - logger=None, + logger=False, ) diff --git a/tests/runner/test_runner_lightning_task.py b/tests/runner/test_runner_lightning_task.py index e9112d4d..83aca0e5 100644 --- a/tests/runner/test_runner_lightning_task.py +++ b/tests/runner/test_runner_lightning_task.py @@ -37,7 +37,7 @@ def _get_trainer(self, output_dir: str) -> pl.Trainer: limit_train_batches=1, num_sanity_val_steps=0, callbacks=[checkpoint_callback], - logger=None, + logger=False, ) def _compare_state_dict( @@ -200,7 +200,7 @@ def prepare_for_quant_convert(self, cfg): limit_train_batches=1, num_sanity_val_steps=0, callbacks=callbacks, - logger=None, + logger=False, ) with EventStorage() as storage: task.storage = storage