We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6e74172 commit 396531eCopy full SHA for 396531e
1 file changed
unsloth/models/_utils.py
@@ -556,10 +556,10 @@ def _is_openai_available(): return False
556
def is_big_gpu(index) -> bool:
557
558
if DEVICE_TYPE == "xpu":
559
- prop = torch.xpu.get_device_properties(index)
+ prop = DeviceProperties.create(torch.device("xpu", index) if type(index) is int else index)
560
min_sms = 16
561
else:
562
- prop = torch.cuda.get_device_properties(index)
+ prop = DeviceProperties.create(torch.device("cuda", index) if type(index) is int else index)
563
min_sms = 80
564
565
avail_sms = prop.multi_processor_count
0 commit comments