Skip to content

weights_only default flip for torch.load #1356

Closed
@mikaylagawarecki

Description

@mikaylagawarecki

🐛 Describe the bug

We've flipped the default for the weights_only argument in torch.load to True in pytorch/pytorch, see here for details + documentation and this is coming in torch 2.6.

This is expected to be quite a BC-breaking change, especially if any torch.load calls in torchchat are not loading state_dicts of plain tensors.

We should make sure that all the torch.load calls in torchchat are still working.

For example, this one does not explicitly set weights_only so might now be failing since torchchat doesn't use pytorch nightlies in CI

cc @Jack-Khuu

Versions

main

Metadata

Metadata

Assignees

Labels

actionableItems in the backlog waiting for an appropriate impl/fixenhancementNew feature or requesttriagedThis issue has been looked at a team member, and triaged and prioritized into an appropriate module

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions