Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@ Afterwards, you can install the project using
pip install -r requirements.txt
```

If you are using *Intel GPU*, you can install the project using the command below

```
pip install -r requirements.txt --extra-index-url https://download.pytorch.org/whl/xpu
```

To test the installation, run

```
Expand Down
4 changes: 3 additions & 1 deletion src/sharp/cli/predict.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
"--device",
type=str,
default="default",
help="Device to run on. ['cpu', 'mps', 'cuda']",
help="Device to run on. ['cpu', 'mps', 'cuda', 'xpu']",
)
@click.option("-v", "--verbose", is_flag=True, help="Activate debug logs.")
def predict_cli(
Expand Down Expand Up @@ -103,6 +103,8 @@ def predict_cli(
if device == "default":
if torch.cuda.is_available():
device = "cuda"
elif torch.xpu.is_available():
device = "xpu"
elif torch.mps.is_available():
device = "mps"
else:
Expand Down