From 16fbd8aa4e601976e094bf9192d8d07e1baa7708 Mon Sep 17 00:00:00 2001 From: Xavier Garceau-Aranda Date: Fri, 5 Jun 2026 19:54:24 +0200 Subject: [PATCH] docs(pyproject): clarify uv is required for installation Adds a comment above the [tool.uv.sources] block in the four pyproject.toml files that pin packages to the PyTorch XPU wheel index. The note explains that uv must be used to install these samples because vanilla pip does not parse [tool.uv.sources] / [[tool.uv.index]] and will not find the XPU wheels on PyPI. The READMEs already say to use uv, but the pyproject is what a developer reads when they're already poking at the codebase, so making the requirement local to the file helps anyone who tries pip first. --- AI-Upscaling-With-NPU/pyproject.toml | 6 ++++++ Finetune_Image_Captioning/pyproject.toml | 6 ++++++ Genre-driven-storytelling/pyproject.toml | 6 ++++++ LLM/PyTorch/pyproject.toml | 6 ++++++ 4 files changed, 24 insertions(+) diff --git a/AI-Upscaling-With-NPU/pyproject.toml b/AI-Upscaling-With-NPU/pyproject.toml index 9406d74..ccd50ab 100644 --- a/AI-Upscaling-With-NPU/pyproject.toml +++ b/AI-Upscaling-With-NPU/pyproject.toml @@ -39,6 +39,12 @@ dev = [ ] +# NOTE: Install with `uv sync`. The torch, torchvision, and +# pytorch-triton-xpu wheels for Intel XPU live on the PyTorch XPU index +# (https://download.pytorch.org/whl/xpu), not on PyPI. The [tool.uv.sources] +# block below tells uv to fetch them from there. Vanilla pip does not parse +# [tool.uv.sources] / [[tool.uv.index]] and will look for the packages on +# PyPI instead, which won't work for the XPU variants. [[tool.uv.index]] name = "pytorch" url = "https://download.pytorch.org/whl/cpu" diff --git a/Finetune_Image_Captioning/pyproject.toml b/Finetune_Image_Captioning/pyproject.toml index a690442..6db5f6f 100644 --- a/Finetune_Image_Captioning/pyproject.toml +++ b/Finetune_Image_Captioning/pyproject.toml @@ -15,6 +15,12 @@ dependencies = [ "evaluate>=0.4.3", "bert-score>=0.3.13", ] +# NOTE: Install with `uv sync`. The torch, torchvision, and +# pytorch-triton-xpu wheels for Intel XPU live on the PyTorch XPU index +# (https://download.pytorch.org/whl/xpu), not on PyPI. The [tool.uv.sources] +# block below tells uv to fetch them from there. Vanilla pip does not parse +# [tool.uv.sources] / [[tool.uv.index]] and will look for the packages on +# PyPI instead, which won't work for the XPU variants. [tool.uv.sources] torch = [ { index = "pytorch-xpu", marker = "sys_platform == 'win32' or sys_platform == 'linux'" }, diff --git a/Genre-driven-storytelling/pyproject.toml b/Genre-driven-storytelling/pyproject.toml index c5198ac..6a7cc32 100644 --- a/Genre-driven-storytelling/pyproject.toml +++ b/Genre-driven-storytelling/pyproject.toml @@ -15,6 +15,12 @@ dependencies = [ "matplotlib>=3.10.3", ] +# NOTE: Install with `uv sync`. The torch, torchvision, and +# pytorch-triton-xpu wheels for Intel XPU live on the PyTorch XPU index +# (https://download.pytorch.org/whl/xpu), not on PyPI. The [tool.uv.sources] +# block below tells uv to fetch them from there. Vanilla pip does not parse +# [tool.uv.sources] / [[tool.uv.index]] and will look for the packages on +# PyPI instead, which won't work for the XPU variants. [tool.uv.sources] torch = [ { index = "pytorch-xpu", marker = "sys_platform == 'win32' or sys_platform == 'linux'" }, diff --git a/LLM/PyTorch/pyproject.toml b/LLM/PyTorch/pyproject.toml index 590859b..e88051b 100644 --- a/LLM/PyTorch/pyproject.toml +++ b/LLM/PyTorch/pyproject.toml @@ -21,6 +21,12 @@ dependencies = [ "sounddevice>=0.5.2", ] +# NOTE: Install with `uv sync`. The torch, torchvision, torchaudio, and +# pytorch-triton-xpu wheels for Intel XPU live on the PyTorch XPU index +# (https://download.pytorch.org/whl/xpu), not on PyPI. The [tool.uv.sources] +# block below tells uv to fetch them from there. Vanilla pip does not parse +# [tool.uv.sources] / [[tool.uv.index]] and will look for the packages on +# PyPI instead, which won't work for the XPU variants. [tool.uv.sources] torch = [ { index = "pytorch-xpu", marker = "sys_platform == 'win32' or sys_platform == 'linux'" },