diff --git a/installer/Dockerfile b/installer/Dockerfile index 0f3598878..6d88fc20d 100644 --- a/installer/Dockerfile +++ b/installer/Dockerfile @@ -24,6 +24,7 @@ RUN mv /opt/maxkb/app/model/* /opt/maxkb/model && \ apt-get update && apt-get install -y curl && \ pip3 install --upgrade pip && \ pip3 install poetry && \ + if [ `uname -m` == "aarch64" ]; then sed -i '/^torch/d' pyproject.toml; fi && \ poetry export -f requirements.txt --output requirements.txt --without-hashes && \ pip3 install --no-cache-dir -r requirements.txt && \ pip3 cache purge && \ diff --git a/pyproject.toml b/pyproject.toml index 36281841a..268c23c96 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -18,12 +18,7 @@ diskcache = "^5.6.3" pillow = "^10.2.0" filetype = "^1.2.0" chardet = "^5.2.0" -torch = [ - { version = "^2.2.1+cpu", markers = "platform_system == 'Linux' and platform_machine == 'x86_64'", source = "pytorch" }, - { version = "^2.2.1", markers = "platform_system == 'Linux' and platform_machine == 'aarch64'", source = "pytorch" }, - { version = "^2.2.1+cpu", markers = "platform_system == 'Windows'", source = "pytorch" }, - { version = "^2.2.1", markers = "platform_system == 'Darwin'", source = "pytorch" } -] +torch = {version = "^2.2.1+cpu", source = "pytorch"} sentence-transformers = "^2.2.2" blinker = "^1.6.3" openai = "^1.13.3"