Disable IPEX attention if the GPU supports 64 bit

This commit is contained in:
Disty0
2023-12-05 19:27:14 +03:00
parent 3a36c07c6c
commit 629a46aaa5
2 changed files with 8 additions and 3 deletions
+3 -2
View File
@@ -166,8 +166,9 @@ def ipex_init(): # pylint: disable=too-many-statements
torch.cuda.get_device_id_list_per_card = torch.xpu.get_device_id_list_per_card
ipex_hijacks()
attention_init()
ipex_diffusers()
if not torch.xpu.has_fp64_dtype():
attention_init()
ipex_diffusers()
except Exception as e:
return False, e
return True, None