You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, if you have project.optional-dependencies that have conflicting versions to the project.dependencies, the system isn't able to resolve it. What I would like is a way to force the versions in the optional dependencies to override the main ones. Is this possible?
Why would I even want to do such a thing?
Pytorch has a torch==2.0.1+cpu and torch==2.0.1+cu117 versions. If I want to deploy to a system without a GPU, I want to use just the CPU version of the package to minimize my environment. But I want the option to add GPU support by just calling rye sync --features gpu, and thus installing the GPU support (and corresponding GPU-related packages). This however fails, because the requirements resolver is unable to determine which version of torch to use.
Is there a way to force the resolver to use one version over another? Does my use case even make sense, or is there a better way to support both CPU and GPU builds with torch?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
Right now, if you have
project.optional-dependencies
that have conflicting versions to theproject.dependencies
, the system isn't able to resolve it. What I would like is a way to force the versions in the optional dependencies to override the main ones. Is this possible?Why would I even want to do such a thing?
Pytorch has a
torch==2.0.1+cpu
andtorch==2.0.1+cu117
versions. If I want to deploy to a system without a GPU, I want to use just the CPU version of the package to minimize my environment. But I want the option to add GPU support by just callingrye sync --features gpu
, and thus installing the GPU support (and corresponding GPU-related packages). This however fails, because the requirements resolver is unable to determine which version of torch to use.Is there a way to force the resolver to use one version over another? Does my use case even make sense, or is there a better way to support both CPU and GPU builds with torch?
Beta Was this translation helpful? Give feedback.
All reactions