Skip to content

Deprecate progress_bar_refresh_rate from Trainer constructor #9500

@daniellepintz

Description

@daniellepintz

Proposed refactoring or deprecation

Deprecate progress_bar_refresh_rate from Trainer constructor and use default refresh rate of 1 if no progress bar callback is passed

Motivation

We are trying to minimize the number of arguments on Trainer constructor: #9006
progress_bar_refresh_rate makes more sense to be part of the Progress Bar callback (in fact it already is). If someone wants to customize the progress bar refresh rate, they must create a Progress Bar callback, just like if they wanted to customize any other part of the the progress bar.

Pitch

Deprecate progress_bar_refresh_rate from Trainer constructor:
https://github.com/PyTorchLightning/pytorch-lightning/blob/master/pytorch_lightning/trainer/trainer.py#L117

Don't send progress_bar_refresh_rate here: https://github.com/PyTorchLightning/pytorch-lightning/blob/master/pytorch_lightning/trainer/trainer.py#L415
and update the relevant functions in callback_connector.py

Considerations

One implication of this is there will no longer be a way to specify no progress bar callback - one will always be created by default (currently if you dont want a progress bar you can set progress_bar_refresh_rate equal to 0, which is a bit hacky IMO). Do people see this as a problem?

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions