How to create two dependency groups where dependencies are all URLs #8179
Unanswered
fernandobperezm
asked this question in
Q&A
Replies: 1 comment
-
I am asking a similar question. I would like to let the user choose which cuda version they would like to use. cuda 11.8, coda 12.4 etc. I tried the following:
Then, I run the following command:
But it will respond that I have incompatible constraints:
The only solution I found for now is to not include torch on the dependencies and to let the user to install it but adding it to its own requirement file or pyproject file. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I'm trying to install torch on my laptop (macOS M1) and two linux servers (one with CPU and the other with GPU). I'm trying to have a single pyproject.toml and handle the dependencies using groups as follows:
What I want to achieve is that on installation, I decide whether to install the CPU versions (laptop or server with only CPU) or the GPU version (server with GPU). I tried following the comments on 6409 6409-2 with no luck.
My installation command on macOS and linux+cpu server is:
poetry install --with torchcpu --sync
On the GPU server is:
poetry install --with torchcu116 --sync
However, anytime I run those commands it fails with the following error:
... depends on both torch (1.13.1) @ https://download.pytorch.org/whl/cpu/torch-1.13.1-cp310-none-macosx_11_0_arm64.whl and torch (1.13.1+cu116) @ https://download.pytorch.org/whl/cu116/torch-1.13.1%2Bcu116-cp310-cp310-linux_x86_64.whl, version solving failed.
Is there a way to achieve what I want with Poetry?
Thanks in advance!
Beta Was this translation helpful? Give feedback.
All reactions