From 7a33c0bdad98d91d74fecd00f65178ed0ad9e787 Mon Sep 17 00:00:00 2001 From: charles Date: Tue, 14 Dec 2021 16:40:18 -0800 Subject: [PATCH] Remove deprecated trainer arguments (#223) * Remove deprecated trainer arguments: `weight summary` and `progress_bar_refresh_rate` * Remove deprecated example from README * Add RichModelSummary to the callbacks --- README.md | 3 --- configs/callbacks/default.yaml | 4 ++++ configs/trainer/debug.yaml | 2 -- configs/trainer/default.yaml | 2 -- 4 files changed, 4 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 4acfb2c..4370195 100644 --- a/README.md +++ b/README.md @@ -304,9 +304,6 @@ python run.py +trainer.fast_dev_run=true # raise exception if there are any numerical anomalies in tensors, like NaN or +/-inf python run.py +trainer.detect_anomaly=true -# print full weight summary of all PyTorch modules -python run.py trainer.weights_summary="full" - # print execution time profiling after training ends python run.py +trainer.profiler="simple" diff --git a/configs/callbacks/default.yaml b/configs/callbacks/default.yaml index 13bc1a0..751d312 100644 --- a/configs/callbacks/default.yaml +++ b/configs/callbacks/default.yaml @@ -16,5 +16,9 @@ early_stopping: patience: 100 # how many validation epochs of not improving until training stops min_delta: 0 # minimum change in the monitored metric needed to qualify as an improvement +model_summary: + _target_: pytorch_lightning.callbacks.RichModelSummary + max_depth: 1 + rich_progress_bar: _target_: pytorch_lightning.callbacks.RichProgressBar diff --git a/configs/trainer/debug.yaml b/configs/trainer/debug.yaml index a3fa378..981cf14 100644 --- a/configs/trainer/debug.yaml +++ b/configs/trainer/debug.yaml @@ -7,8 +7,6 @@ min_epochs: 1 max_epochs: 2 # prints -progress_bar_refresh_rate: null -weights_summary: "full" profiler: null # debugs diff --git a/configs/trainer/default.yaml b/configs/trainer/default.yaml index 53f9e2a..f8f1bf1 100644 --- a/configs/trainer/default.yaml +++ b/configs/trainer/default.yaml @@ -5,9 +5,7 @@ gpus: 0 min_epochs: 1 max_epochs: 10 -progress_bar_refresh_rate: 5 resume_from_checkpoint: null -weights_summary: "full" # number of validation steps to execute at the beginning of the training num_sanity_val_steps: 0