LR Schedulers compatibility
coenvdgrinten opened this issue · comments
Hi all,
When implementing other LR Schedulers besides the ReduceLROnPlateau LR scheduler, the following exception is raised:
lightning_lite.utilities.exceptions.MisconfigurationException: The provided lr scheduler
<lr_scheduler>doesn't follow PyTorch's LRScheduler API. You should override the
LightningModule.lr_scheduler_step hook with your own logic if you are using a custom LR scheduler.
However, this issue does not appear when implementing the ReduceLROnPlateau given by the original template. I've tried several different schedulers where this issue persists. This issue seems to be due to the lightning module, however lightning is already the latest version.
Any idea how to circumvent this issue?
This issue is related not related to the Lightning-Hydra template.
@coenvdgrinten Hi, I met the same issue here. I am using pytorch (2.0.0) and pytorch-lightning (1.6.4). Do you have any solution for it?
Hi there, sorry for the late response.
So far i've not been able to resolve this. If is find a solution, i will post it here.
@coenvdgrinten Hi, I think I just find a solution for it. If you update both pytorch and pytorch-lightning to above 2.0, the issue will disappear.