In poetry, how to specify dependency on different package versions based on hardware

Viewed 148

Is there a way how to specify different python package versions for different hardware configurations with Poetry?

E.g. I have several hardware configurations (machine with cuda 10.1 support and cuda 10.0 support). How should I specify dependency on packages that differ in their versions based on these (and also different package names based on the configurations).

Example which configuration is required for different cases:

  • CUDA 10.1
    • mxnet-cu101 = 1.6.0
    • torch = 1.5.0
  • CUDA 10.0
    • mxnet-cu100 = 1.5.1
    • torch = 1.2.0
0 Answers
Related