pytorch-lightning
7983ecba - Fix LearningRateMonitor TypeError on MPS with float64 lr values (#21545)

Commit
238 days ago
Fix LearningRateMonitor TypeError on MPS with float64 lr values (#21545) * Fix LearningRateMonitor TypeError on MPS with float64 lr values When an optimizer's learning rate is np.float64, the LearningRateMonitor crashes on MPS because MPS doesn't support float64 tensors. Fix by converting values to Python float before creating the tensor, which ensures compatibility with all device backends. Fixes #20250 * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * update * update --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: deependujha <deependujha21@gmail.com>
Author
Parents
Loading