fix(python): move accelerate and GPU-specific libs to build-type (#3194)

Some of the dependencies in `requirements.txt`, even if generic, pulls
down the line CUDA libraries.

This changes moves mostly all GPU-specific libs to the build-type, and
tries a safer approach. In `requirements.txt` now are listed only
"first-level" dependencies, for instance, grpc, but libs-dependencies
are moved down to the respective build-type `requirements.txt` to avoid
any mixin.

This should fix #2737 and #1592.

Signed-off-by: Ettore Di Giacinto <mudler@localai.io>
This commit is contained in:
Ettore Di Giacinto 2024-08-07 17:02:32 +02:00 committed by GitHub
parent abcf0ff000
commit 61b5602111
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
79 changed files with 212 additions and 61 deletions

View file

@ -0,0 +1,3 @@
transformers
accelerate
torch

View file

@ -1,2 +1,4 @@
--extra-index-url https://download.pytorch.org/whl/cu118
torch
transformers
accelerate

View file

@ -1 +1,3 @@
torch
transformers
accelerate

View file

@ -1,4 +1,3 @@
accelerate
grpcio==1.65.4
protobuf
certifi