bigscience-workshop / petals

🌸 Run LLMs at home, BitTorrent-style. Fine-tuning and inference up to 10x faster than offloading
https://petals.dev
MIT License
8.89k stars 490 forks source link

Restrict PyTorch version to <2.3.0 to resolve import error #577

Closed Priyanshupareek closed 2 months ago

Priyanshupareek commented 2 months ago

Fixes #576 This addresses the import error encountered with PyTorch 2.3.0 as detailed in issue #576. The error 'cannot import name '_refresh_per_optimizer_state' from 'torch.cuda.amp.grad_scaler' is resolved by pinning the PyTorch version to 2.2.2 in setup.cfg.

Small change:

nsarrazin commented 2 months ago

Tested this PR locally, seems to have fixed the issue for me! :grin:

CherukupalleNaveen commented 2 months ago

Yep! Even I have tested in my local. It's working fine.