Skip to content

Commit 081ab41

Browse files
authored
Merge pull request huggingface#4 from kaixuanliu/ipex
add import ipex
2 parents 09a0d3f + 8d8148c commit 081ab41

File tree

1 file changed

+1
-0
lines changed
  • backends/python/server/text_embeddings_server/utils

1 file changed

+1
-0
lines changed

backends/python/server/text_embeddings_server/utils/device.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ def get_device() :
4848
if hasattr(torch, "hpu") and torch.hpu.is_available(): # type: ignore
4949
device = torch.device("hpu")
5050
elif use_ipex():
51+
import intel_extension_for_pytorch as ipex
5152
if hasattr(torch, "xpu") and torch.xpu.is_available():
5253
device = torch.device("xpu")
5354

0 commit comments

Comments
 (0)