Dockerfile.openvino 1.4 KB

12345678910111213141516171819202122232425262728293031323334
  1. # The Aphrodite Dockerfile is used to construct Aphrodite image that can be directly used
  2. # to run the OpenAI compatible server.
  3. FROM ubuntu:22.04 AS dev
  4. RUN apt-get update -y && \
  5. apt-get install -y python3-pip git && \
  6. apt-get install -y ffmpeg libsm6 libxext6 libgl1
  7. WORKDIR /workspace
  8. # copy requirements
  9. COPY requirements-build.txt /workspace/aphrodite-engine/
  10. COPY requirements-common.txt /workspace/aphrodite-engine/
  11. COPY requirements-openvino.txt /workspace/aphrodite-engine/
  12. COPY aphrodite/ /workspace/aphrodite-engine/aphrodite
  13. COPY kernels/core /workspace/aphrodite-engine/kernels/core
  14. COPY cmake/utils.cmake /workspace/aphrodite-engine/cmake/
  15. COPY CMakeLists.txt /workspace/aphrodite-engine/
  16. COPY setup.py /workspace/aphrodite-engine/
  17. # install build requirements
  18. RUN PIP_EXTRA_INDEX_URL="https://download.pytorch.org/whl/cpu" python3 -m pip install -r /workspace/aphrodite-engine/requirements-build.txt
  19. # build Aphrodite with OpenVINO backend
  20. RUN PIP_EXTRA_INDEX_URL="https://download.pytorch.org/whl/cpu https://storage.openvinotoolkit.org/simple/wheels/pre-release" APHRODITE_TARGET_DEVICE="openvino" python3 -m pip install -e /workspace/aphrodite-engine/
  21. # temporary hack until the dependencies are upgraded
  22. RUN pip install 'transformers==4.43.0'
  23. RUN pip install triton
  24. COPY examples/ /workspace/aphrodite-engine/examples
  25. COPY tests/benchmarks/ /workspace/aphrodite-engine/tests/benchmarks
  26. CMD ["/bin/bash"]