-
Hi, I'm trying to install a CPU version of (py)torch using the following command, but I can't seem to get What is the pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu Many thanks for any help! |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments
-
I've got it working: Option 1 (easier)Following https://pixi.sh/v0.22.0/reference/configuration/#the-pypi-options-table, add to [tool.pixi.pypi-options]
index-url = "https://pypi.org/simple"
extra-index-urls = ["https://download.pytorch.org/whl/cpu"] Option 2 (more work)Following https://pixi.sh/v0.22.0/reference/configuration/#pypi-dependencies, pass in the appropriate URL (within torch = { url = "https://download.pytorch.org/whl/cpu/torch-2.4.0%2Bcpu-cp312-cp312-linux_x86_64.whl#sha256=78dbf5f2789933a7ea2dabeead4daa44679b1e0d8eb35ddb7071c8ab7b181eb3" } Thanks again for an amazing lib! |
Beta Was this translation helpful? Give feedback.
-
I am using this way: pixi.toml [pypi-dependencies]
torch = { version = "*", index = "https://download.pytorch.org/whl/cpu" } but it's no way to do this w/ |
Beta Was this translation helpful? Give feedback.
-
Pytorch Installation - Pixi by prefix.dev I just follow the official docs : [system-requirements]
cuda = "12.0"
[dependencies]
# pytorch-gpu = ">=2.5.1,<2.8"
pytorch-gpu = "*"
cuda-version = "12.6.*" Then More: [workspace]
channels = ["conda-forge", "pytorch"]
name = "build-llm-demo"
platforms = ["win-64"]
version = "0.1.0"
[system-requirements]
cuda = "12.0"
[dependencies]
python = "3.11.*"
pandas = "<=2.1.4"
pydantic-settings = ">=2.9.1,<3"
ruff = ">=0.12.0,<0.13"
pyright = ">=1.1.402,<2"
pytest = ">=8.4.1,<9"
# pytorch-gpu = ">=2.5.1,<2.8"
pytorch-gpu = "*"
cuda-version = "12.6.*"
ipykernel = ">=6.29.5,<7"
pixi-pycharm = ">=0.0.8,<0.0.9"
ipywidgets = ">=8.1.7,<9"
transformers = ">=4.13,<4.38"
huggingface_hub = ">=0.33.1,<0.34"
matplotlib = ">=3.10.3,<4"
itables = ">=2.4.2,<3"
tiktoken = ">=0.9.0,<0.10"
jupyterlab = ">=4.4.4,<5"
pypandoc = ">=1.15,<2"
pandoc = ">=3.7.0.2,<4"
jupytext = ">=1.17.2,<2"
torchvision = ">=0.22.0,<0.23"
[pypi-dependencies]
fastapi = { version = ">=0.115.13, <0.116", extras = ["standard"] }
uvicorn = { version = ">=0.34.3, <0.35", extras = ["standard"] }
gunicorn = ">=23.0.0, <24"
build-llm-learn = { path = ".", editable = true }
tensorflow = ">=2.18.0, <3"
bpemb = ">=0.3.6,<0.4" |
Beta Was this translation helpful? Give feedback.
-
There is another way from pypi: Pytorch Installation - Pixi by prefix.dev [pypi-dependencies]
torch = { version = ">=2.5.1", index = "https://download.pytorch.org/whl/cu124" }
torchvision = { version = ">=0.20.1", index = "https://download.pytorch.org/whl/cu124" } (doesnt seem like need Full code: [workspace]
authors = ["norlz <[email protected]>"]
channels = ["conda-forge"]
name = "iopaint-exe"
platforms = ["win-64"]
version = "0.1.0"
[dependencies]
python = "3.10.*"
[pypi-dependencies]
iopaint = "==1.5.3"
torch = { version = ">=2.5.1", index = "https://download.pytorch.org/whl/cu124" }
torchvision = { version = ">=0.20.1", index = "https://download.pytorch.org/whl/cu124" } |
Beta Was this translation helpful? Give feedback.
-
Update: In some setup
Seems crucial. Otherwise I get things like
|
Beta Was this translation helpful? Give feedback.
I've got it working:
Option 1 (easier)
Following https://pixi.sh/v0.22.0/reference/configuration/#the-pypi-options-table, add to
pyproject.toml
:Option 2 (more work)
Following https://pixi.sh/v0.22.0/reference/configuration/#pypi-dependencies, pass in the appropriate URL (within
pyproject.toml
, e.g.Thanks again for an amazing lib!