Skip to content

Commit

Permalink
Merge pull request #473 from MeTaNoV/patch-1
Browse files Browse the repository at this point in the history
Update flag_models.py to fix is_torch_npu_available as a function call
  • Loading branch information
staoxiao authored Feb 21, 2024
2 parents 9365f15 + 3c9ab5a commit af538b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion FlagEmbedding/flag_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def __init__(
self.device = torch.device("cuda")
elif torch.backends.mps.is_available():
self.device = torch.device("mps")
elif is_torch_npu_available:
elif is_torch_npu_available():
self.device = torch.device("npu")
else:
self.device = torch.device("cpu")
Expand Down

0 comments on commit af538b6

Please sign in to comment.