fix for inductor no attribute prop.multi_processor_count (#2803)
This commit is contained in:
parent
6e74172c7c
commit
396531ec1f
1 changed files with 2 additions and 2 deletions
|
|
@ -556,10 +556,10 @@ from unsloth import DEVICE_TYPE
|
|||
def is_big_gpu(index) -> bool:
|
||||
|
||||
if DEVICE_TYPE == "xpu":
|
||||
prop = torch.xpu.get_device_properties(index)
|
||||
prop = DeviceProperties.create(torch.device("xpu", index) if type(index) is int else index)
|
||||
min_sms = 16
|
||||
else:
|
||||
prop = torch.cuda.get_device_properties(index)
|
||||
prop = DeviceProperties.create(torch.device("cuda", index) if type(index) is int else index)
|
||||
min_sms = 80
|
||||
|
||||
avail_sms = prop.multi_processor_count
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue