Pytorch-lightning: map_location hasn't been implemented in load_from_checkpoint

Created on 6 Dec 2019  路  2Comments  路  Source: PyTorchLightning/pytorch-lightning

Describe the bug
Current load_from_checkpoint function does not support to load a gpu checkpoint on cpu devices, i.e. map the location.

To Reproduce

# on a cpu only device:
Model.load_from_checkpoint("GPU_CHECKPOINT_FILE")

Expected behavior
AssertionError: Torch not compiled with CUDA enabled

Desktop (please complete the following information):

  • OS: macOS Catalina 10.15.1
  • Browser: chrome
  • Version: 0.5.3.1
enhancement help wanted

Most helpful comment

weird, i thought we did. mind submitting a PR?

All 2 comments

weird, i thought we did. mind submitting a PR?

Sure will do.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

justusschock picture justusschock  路  3Comments

Vichoko picture Vichoko  路  3Comments

monney picture monney  路  3Comments

williamFalcon picture williamFalcon  路  3Comments

mmsamiei picture mmsamiei  路  3Comments