-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Closed
Labels
bugSomething isn't workingSomething isn't workingneeds triageWaiting to be triaged by maintainersWaiting to be triaged by maintainersver: 2.5.x
Description
Bug description
If you set the pytorch default device to 'mps' on MacOS, pytorch lightning throws an exception on import.
The expected result is to not throw an exception and also to use the pytorch default device when doing computation.
What version are you seeing the problem on?
v2.5.1
How to reproduce the bug
import torch
torch.set_default_device('mps')
import pytorch_lightning as pl
Error messages and logs
RuntimeError: Placeholder storage has not been allocated on MPS device!
Environment
Current environment
#- PyTorch Lightning Version (e.g., 2.5.0): 2.5.1
#- PyTorch Version (e.g., 2.5): 2.6.0
#- Python version (e.g., 3.12): 3.12.9
#- OS (e.g., Linux): MacOS 15.3.2
#- CUDA/cuDNN version:
#- GPU models and configuration: M1 Max
#- How you installed Lightning(`conda`, `pip`, source): uv
More info
No response
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingneeds triageWaiting to be triaged by maintainersWaiting to be triaged by maintainersver: 2.5.x